1*a1b4a26bSAndrew Rist /************************************************************** 2cdf0e10cSrcweir * 3*a1b4a26bSAndrew Rist * Licensed to the Apache Software Foundation (ASF) under one 4*a1b4a26bSAndrew Rist * or more contributor license agreements. See the NOTICE file 5*a1b4a26bSAndrew Rist * distributed with this work for additional information 6*a1b4a26bSAndrew Rist * regarding copyright ownership. The ASF licenses this file 7*a1b4a26bSAndrew Rist * to you under the Apache License, Version 2.0 (the 8*a1b4a26bSAndrew Rist * "License"); you may not use this file except in compliance 9*a1b4a26bSAndrew Rist * with the License. You may obtain a copy of the License at 10cdf0e10cSrcweir * 11*a1b4a26bSAndrew Rist * http://www.apache.org/licenses/LICENSE-2.0 12*a1b4a26bSAndrew Rist * 13*a1b4a26bSAndrew Rist * Unless required by applicable law or agreed to in writing, 14*a1b4a26bSAndrew Rist * software distributed under the License is distributed on an 15*a1b4a26bSAndrew Rist * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 16*a1b4a26bSAndrew Rist * KIND, either express or implied. See the License for the 17*a1b4a26bSAndrew Rist * specific language governing permissions and limitations 18*a1b4a26bSAndrew Rist * under the License. 19*a1b4a26bSAndrew Rist * 20*a1b4a26bSAndrew Rist *************************************************************/ 21*a1b4a26bSAndrew Rist 22*a1b4a26bSAndrew Rist 23cdf0e10cSrcweir package com.sun.star.wizards.report; 24cdf0e10cSrcweir 25cdf0e10cSrcweir /** 26cdf0e10cSrcweir * This Interface separate the ReportBuilderImplementation from the layout. 27cdf0e10cSrcweir * Only these less methods are allowed to access from the ReportBuilderImplementation. 28cdf0e10cSrcweir * @author ll93751 29cdf0e10cSrcweir */ 30cdf0e10cSrcweir public interface IReportBuilderLayouter 31cdf0e10cSrcweir { 32cdf0e10cSrcweir 33cdf0e10cSrcweir /** 34cdf0e10cSrcweir * Get the internal name of the current layout. 35cdf0e10cSrcweir * This name identifies the layout in the internal access list. 36cdf0e10cSrcweir * @return the internal layout name. 37cdf0e10cSrcweir */ getName()38cdf0e10cSrcweir public String getName(); 39cdf0e10cSrcweir 40cdf0e10cSrcweir /** 41cdf0e10cSrcweir * Get the localized name of the layout, which is shown in the layout page of the report wizard. 42cdf0e10cSrcweir * This name comes out of the resource and will be translate in different languages. 43cdf0e10cSrcweir * @return localized name of the layout. 44cdf0e10cSrcweir */ getLocalizedName()45cdf0e10cSrcweir public String getLocalizedName(); 46cdf0e10cSrcweir 47cdf0e10cSrcweir /** 48cdf0e10cSrcweir * For Landscape give nOrientation == com.sun.star.wizards.report.ReportLayouter.SOOPTLANDSCAPE 49cdf0e10cSrcweir * All other numbers are interpreted as portrait format. 50cdf0e10cSrcweir * @param nOrientation 51cdf0e10cSrcweir */ setPageOrientation(int nOrientation)52cdf0e10cSrcweir public void setPageOrientation(int nOrientation); 53cdf0e10cSrcweir 54cdf0e10cSrcweir /** 55cdf0e10cSrcweir * dispose the layouter 56cdf0e10cSrcweir */ dispose()57cdf0e10cSrcweir public void dispose(); 58cdf0e10cSrcweir 59cdf0e10cSrcweir /** 60cdf0e10cSrcweir * Set the table name of the report 61cdf0e10cSrcweir * This is the name to the database table. 62cdf0e10cSrcweir * @param _nType something of com.sun.star.sdb.CommandType 63cdf0e10cSrcweir * @param TableName 64cdf0e10cSrcweir */ setTableName(int _nType, String TableName)65cdf0e10cSrcweir public void setTableName(int _nType, String TableName); 66cdf0e10cSrcweir 67cdf0e10cSrcweir /** 68cdf0e10cSrcweir * Insert the field names, these are the field names out of a given datebase table 69cdf0e10cSrcweir * @param FieldNames 70cdf0e10cSrcweir */ insertFieldNames(final String[] FieldNames)71cdf0e10cSrcweir public void insertFieldNames(final String[] FieldNames); 72cdf0e10cSrcweir 73cdf0e10cSrcweir /** 74cdf0e10cSrcweir * Insert the field type (Varchar, int, ...) as internal an int representation. 75cdf0e10cSrcweir * @param FieldTypes 76cdf0e10cSrcweir */ insertFieldTypes(int[] FieldTypes)77cdf0e10cSrcweir public void insertFieldTypes(int[] FieldTypes); 78cdf0e10cSrcweir 79cdf0e10cSrcweir /** 80cdf0e10cSrcweir * Insert the field width in count of chars as given in the database. 81cdf0e10cSrcweir * @param FieldWidths 82cdf0e10cSrcweir */ insertFieldWidths(int[] FieldWidths)83cdf0e10cSrcweir public void insertFieldWidths(int[] FieldWidths); 84cdf0e10cSrcweir 85cdf0e10cSrcweir /** 86cdf0e10cSrcweir * Insert the titles of the field names. This names are free formed 87cdf0e10cSrcweir * @param _aFieldTitles 88cdf0e10cSrcweir */ insertFieldTitles(String[] _aFieldTitles)89cdf0e10cSrcweir public void insertFieldTitles(String[] _aFieldTitles); 90cdf0e10cSrcweir 91cdf0e10cSrcweir /** 92cdf0e10cSrcweir * Insert the names of the groups, the group names are names out of the field names. 93cdf0e10cSrcweir * 94cdf0e10cSrcweir * If a group name is given here, it will not shown in the fields/titles, but must be in the field string list. 95cdf0e10cSrcweir * @param _aGroupFieldNames 96cdf0e10cSrcweir */ insertGroupNames(String[] _aGroupFieldNames)97cdf0e10cSrcweir public void insertGroupNames(String[] _aGroupFieldNames); 98cdf0e10cSrcweir 99cdf0e10cSrcweir /** 100cdf0e10cSrcweir * Insert the names of the groups which should be used as sorting, the group names are names out of the field names. 101cdf0e10cSrcweir * 102cdf0e10cSrcweir * If a group name is given here, it will not shown in the fields/titles, but must be in the field string list. 103cdf0e10cSrcweir * @param _aSortFieldNames 104cdf0e10cSrcweir */ insertSortingNames(String[][] _aSortFieldNames)105cdf0e10cSrcweir public void insertSortingNames(String[][] _aSortFieldNames); 106cdf0e10cSrcweir 107cdf0e10cSrcweir /** 108cdf0e10cSrcweir * This method redraws the whole layout with all it's content 109cdf0e10cSrcweir */ layout()110cdf0e10cSrcweir public void layout(); 111cdf0e10cSrcweir 112cdf0e10cSrcweir /** 113cdf0e10cSrcweir * Initialize the current Layouter with data's out of an other Layouter. 114cdf0e10cSrcweir * 115cdf0e10cSrcweir * This Method copies the internal fields, groups and titles 116cdf0e10cSrcweir * @param aOtherLayouter 117cdf0e10cSrcweir */ initializeData(IReportBuilderLayouter aOtherLayouter)118cdf0e10cSrcweir public void initializeData(IReportBuilderLayouter aOtherLayouter); 119cdf0e10cSrcweir loadAndSetBackgroundTemplate(String LayoutTemplatePath)120cdf0e10cSrcweir public void loadAndSetBackgroundTemplate(String LayoutTemplatePath); 121cdf0e10cSrcweir } 122