Package quadbase.reportdesigner.designer
Class QbReportDesigner
java.lang.Object
quadbase.reportdesigner.designer.QbReportDesigner
A Quadbase Espress Report Designer. This class provides the mechanism to open the Report Designer
application using an API. Attributes can be set to the QbReportDesigner Object so that it loads a
specified report or connects to a specified data source. In addition, the methods in this class
provide programmers a way to configure the Report Designer application using pure API.
To open up Report Designer with a specified .rpt file in an "application environment", simply use the following code:
-
QbReportDesigner designer =
- new QbReportDesigner(null, "templates/sample.rpt"); //applet == null
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final intsave report before inserting a drilldown reportstatic final intsave report before launching pageviewerstatic final intsave report before inserting a sub-report -
Constructor Summary
ConstructorsConstructorDescriptionQbReportDesigner(Object parent) Allocates a QbReportDesigner Object with specified parameters.QbReportDesigner(Object parent, String rptFile) Allocates a QbReportDesigner Object with a report.QbReportDesigner(Object parent, String dataRegistry, boolean newReport) Allocates a QbReportDesigner Object with specified parameters.QbReportDesigner(Object parent, String dataRegistry, boolean newReport, int displayRow) Allocates a QbReportDesigner Object with specified parameters.QbReportDesigner(Object parent, String dataRegistry, boolean newReport, int displayRow, String[] imagesPath) Allocates a QbReportDesigner Object with specified parameters.QbReportDesigner(Object parent, String dataRegistry, boolean newReport, int displayRow, ImagesPath imagesPath) Allocates a QbReportDesigner Object with specified parameters.QbReportDesigner(Object parent, String rptFile, int displayRow) Allocates a QbReportDesigner Object with a report where the number of rows outputted is limited.QbReportDesigner(Object parent, String rptFile, int displayRow, String[] imagesPath) Allocates a QbReportDesigner Object with specified parameters.QbReportDesigner(Object parent, String rptFile, int displayRow, ImagesPath imagesPath) Allocates a QbReportDesigner Object with specified parameters.QbReportDesigner(Object parent, String classFile, quadbase.common.paramquery.QueryInParamSet inSet, boolean newReport, int displayRow, String[] imagesPath) Allocates a QbReportDesigner Object with specified parameters.QbReportDesigner(Object parent, quadbase.common.util.internal.DBInfoBasic dbInfo, boolean newReport) Allocates a QbReportDesigner Object with specified database information.QbReportDesigner(Object parent, quadbase.common.util.internal.DBInfoBasic dbInfo, boolean newReport, int displayRow) Allocates a QbReportDesigner Object with specified database.QbReportDesigner(Object parent, quadbase.common.util.internal.DBInfoBasic dbInfo, quadbase.common.paramquery.QueryInParamSet inSet, boolean newReport) Allocates a QbReportDesigner Object with specified parameters.QbReportDesigner(Object parent, quadbase.common.util.internal.DBInfoBasic dbInfo, quadbase.common.paramquery.QueryInParamSet inSet, boolean newReport, int displayRow) Allocates a QbReportDesigner Object with specified parameters.QbReportDesigner(Object parent, quadbase.common.util.internal.DBInfoBasic dbInfo, quadbase.common.paramquery.QueryInParamSet inSet, boolean newReport, int displayRow, String[] imagesPath) Allocates a QbReportDesigner Object with specified parameters.QbReportDesigner(Object parent, quadbase.common.util.internal.DBInfoBasic dbInfo, quadbase.common.paramquery.QueryInParamSet inSet, boolean newReport, int displayRow, ImagesPath imagesPath) Allocates a QbReportDesigner Object with specified parameters.QbReportDesigner(Object parent, quadbase.reportdesigner.designer.ReportMain reportMain) Internal use only -
Method Summary
Modifier and TypeMethodDescriptionvoidAdding the DataSourceManagerListener to manipulate the data source tree in the Data Source Manager.voidDisables the Data Source used for the chart.voiddispose()Disposes the Window.booleanexit()Attempt to exit the program.Gets a BrowseDirectories object that can be used to set the default browsing directories for different browse dialogs.Gets the custom defined functions information.String[]Gets a preset list of parameters to be used when defining parameters in a query.It is recommended that the setVisible(true) method should be used instead of this method to launch the report designer.Gets the JTabbedPane that contains the 'Design', 'SubReport', and 'Preview' tabs.Returns the primary design tool barReturns the secondary design tool barquadbase.datasourcemanager.manager.IImportQRYFileGets the imported Query File associated with this Report Designer.static LookAndFeelReturns the preview tool barReturns a handle to the Menu Bar of the report.Returns the security level name used to open this Report Designer.static StringReturns servlet contextDeprecated.use getBrowseDirectories().getReportTemplatesDirectory() instead.booleanGets whether the user is prohibited from browsing any directory above the root directory.booleanReturns whether setExitOnCanel() is set.booleanReturns whether the user is forced to create a new report or not.static booleanReturns whether metric system is used in the Report Designer.booleanReturns whether to save on exit is enabled.booleanReturns whether the multiple data source option step should be skipped in the report wizard.booleanReturns whether the select predefined templates step should be skipped in the report wizard.booleanReturns whether the query result step should be skipped in the report wizard.voidThis method is used to load the report file from the API, after setting the relative path.voidvoidif QbDesignerPassword is required for server, using [-QbDesignerPassword] flag please pass in QbDesigner password to login QbReportDesigner before calling setVisible(...) or getDesigner(...) methodsvoidif server requires login, using [-RequireLogin] flag please pass in userName and password to login QbReportDesigner before calling setVisible(...) or getDesigner(...) methodsvoidmodifyWarningMessage(int modifiedMsg, String newMessage) Modify display warning message:
SAVE_RPT_BEFORE_DRILLDOWN - save report before inserting a drilldown report
SAVE_RPT_BEFORE_SUBREPORT - save report before inserting a subreport
SAVE_RPT_EBFORE_PAGEVIEWER - save report before launching pageviewervoidRemoves the DataSourceManagerListener.voidsave()Saves the report at its original location.voidSaves the report at fileLocation.voidsaveAs()Pops up the Save As Dialog for the user to browse the save location.static voidsetBrowseRootDirectory(String browseRootDir) Static method to set the browse root directory, which is the upper bound when the user browse the directories of the server.voidsetByPassSaveAsIO(quadbase.reportdesigner.designer.IByPassSaveAsForReport saveAsIO) Sets by pass save as IO by implementing IByPassSaveAsForReport interfacevoidsetChartDesignerHandle(quadbase.reportdesigner.designer.IChartHandle cdHandle) modify chart designer by implementing IChartHandle interfacevoidsetChartIO(IChartIO chartIO) Sets where and how charts get saved by passing in an argument chartIO that holds information on how to perform chart file IO.voidsetChartMenuEnabled(int menu, boolean enabled) Sets whether the specified chart menu is enabled.voidsetChartMenuItemEnabled(int menu, int item, boolean enabled) Sets whether the specified chart menu item is enabled.voidsetChartToolbarEnabled(int button, boolean enabled) Sets a button on the chart tool bar enabled or disabled.voidYou may include your own functions with the Formula an Scripts dialog boxes that the users can use when calling Report Designer from the API.voidsetDataRegistry(String dataRegistry) Sets the Data Registry to be used for the data source.voidsetDBProvider(IDBProvider provider) Sets the Database provider.static voidsetDebugMode(int mode) set debug mode to print out debug statementstatic voidsetDebugMode(String mode) set debug mode to print out debug statementvoidsetDefaultParamNames(String[] names) Internal use only.voidsetDirectoryBrowseUpEnabled(boolean state) Sets whether the user is prohibited from browsing any directory above the root directory.voidsetDisplayRow(int nRow) Sets a limit on the number of rows to be displayed by the report.voidsetDrillDownReportIO(quadbase.reportdesigner.designer.IDrillDownReportIO drptIO) Restrict the directory where the user of the Report Designer will be able to save their Drill Down report or Sub-Report (.rpt) files using a IDrillDownReportIO.voidsetExitOnCancel(boolean state) Set whether program should exit after clicking on any cancel button in the program.voidsetForceNewReport(boolean state) Forces the user to create a new report when Report Designer is loaded.voidsetImportQRYFile(quadbase.datasourcemanager.manager.IImportQRYFile f) Sets an IImportQRYFile Object to be used with this Report Designer.static voidsetLookAndFeel(LookAndFeel newLookAndFeel) Sets the look and feel of the designer UI.static voidsetMetricSystemUsed(boolean useMetric) Sets whether to use the metric system in the Report Designer.voidsetPathRelativeToERES(String path) Sets the reports path relative to ERESvoidsetReportIO(IReportIO rptIO) Restrict the directory where the user of the Report Designer will be able to save their .rpt files using an IReportIO.voidsetRootDirectoryForBrowse(String browseRoot) Sets a root directory for the user.voidsetSaveOnExitEnabled(boolean b) Sets whether to save the report when quitting the Report Designer.voidsetSecurityLevel(String level) Sets the "security level" used to open this Report Designer.static voidsetServerAddress(String address) Set the server address of EspressManager.static voidsetServerHosts(Vector hostnames) Set the list of host names for EspressManager when tunneling is used.static voidsetServerPortNumber(int port) Set the port number of EspressManager.static voidsetServletContext(String context) set servlet contextstatic voidsetServletHttpHeader(String headerName, String headerValue) Static method to set extra HTTP header that is sent with every request to ESMMessageServlet.static voidsetServletRunner(String comm_url) Set servlet runner hostname and port number.voidsetSkipMultiDataSourceStep(boolean b) Specify whether the multiple data source option step should be skipped in the report wizard.voidsetSkipPredefinedTemplatesStep(boolean b) Specify whether the select predefined templates step should be skipped in the report wizard.voidsetSkipQueryResultStep(boolean b) Specify whether the query result step should be skipped in the report wizard.voidsetSysExitOnExit(boolean state) Sets the state of whether System.exit() is called when the user selects File->Exit or click on the X button on the top right corner of the designer dialog.voidsetTemplatesDirectory(String temp_dir) Deprecated.use getBrowseDirectories().setReportTemplatesDirectory(String) instead.static voidsetUseSysResourceImages(boolean state) Sets whether to use images in JAR files (ReportDesigner.jar) or other resource that can be loaded by ClassLoader.getSystemResource(imagesPath).voidsetVisible(boolean b) Calling this method with 'true' argument will launch the report designer and start the wizard if necessary.booleanGets the state of whether System.exit() is called when the user selects File->Exit or click on the X button on the top right corner of the designer dialog.static voiduseServlet(boolean b) Determines whether to use SOCKET or HTTP or SERVLET for chart server connection Note that this static method MUST be called before any QbChart constructor.static booleanGets whether to use images in JAR files (ReportDesigner.jar) or other resource that can be loaded by ClassLoader.getSystemResource(imagesPath).voidAllow user to create or overwrite a file on the server.
-
Field Details
-
SAVE_RPT_BEFORE_DRILLDOWN
public static final int SAVE_RPT_BEFORE_DRILLDOWNsave report before inserting a drilldown report- See Also:
-
SAVE_RPT_BEFORE_SUBREPORT
public static final int SAVE_RPT_BEFORE_SUBREPORTsave report before inserting a sub-report- See Also:
-
SAVE_RPT_BEFORE_PAGEVIEWER
public static final int SAVE_RPT_BEFORE_PAGEVIEWERsave report before launching pageviewer- See Also:
-
-
Constructor Details
-
QbReportDesigner
Internal use only -
QbReportDesigner
Allocates a QbReportDesigner Object with specified parameters.- Parameters:
parent- an Object of the type or subclass of type java.awt.Component
-
QbReportDesigner
Allocates a QbReportDesigner Object with a report.- Parameters:
parent- an Object of the type or subclass of type java.awt.ComponentrptFile- the path to a report (.rpt) file
-
QbReportDesigner
Allocates a QbReportDesigner Object with a report where the number of rows outputted is limited.- Parameters:
parent- an Object of the type or subclass of type java.awt.ComponentrptFile- the path to a report (.rpt) filedisplayRow- sets the limit on the number of rows to be displayed
-
QbReportDesigner
Allocates a QbReportDesigner Object with specified parameters.- Parameters:
parent- an Object of the type or subclass of type java.awt.ComponentrptFile- the path to a report (.rpt) filedisplayRow- sets the limit on the number of rows to be displayedimagesPath- a String array of length 3 with the following properties:
imagesPath[0] a String that specifies the path to report images.
imagesPath[1] a String that specifies the path to chart images.
imagesPath[2] a String that specifies the path to background images.
-
QbReportDesigner
Allocates a QbReportDesigner Object with specified parameters.- Parameters:
parent- an Object of the type or subclass of type java.awt.ComponentrptFile- the path to a report (.rpt) filedisplayRow- sets the limit on the number of rows to be displayedimagesPath- an ImagesPath Object that stores information about the paths to images on the system.
-
QbReportDesigner
public QbReportDesigner(Object parent, quadbase.common.util.internal.DBInfoBasic dbInfo, boolean newReport) Allocates a QbReportDesigner Object with specified database information.- Parameters:
parent- an Object of the type or subclass of type java.awt.ComponentdbInfo- a DBInfoBasic Object that stores Database InformationnewReport- true = start from Data Source Manager, false = start from choosing whether to create a new report or open an existing report choice before going to Data Source Manager.
-
QbReportDesigner
public QbReportDesigner(Object parent, quadbase.common.util.internal.DBInfoBasic dbInfo, boolean newReport, int displayRow) Allocates a QbReportDesigner Object with specified database.- Parameters:
parent- an Object of the type or subclass of type java.awt.ComponentdbInfo- a DBInfoBasic Object that stores Database InformationnewReport- true = start from Data Source Manager, false = start from choosing whether to create a new report or open an existing report choice before going to Data Source Manager.displayRow- sets the limit on the number of rows to be displayed.
-
QbReportDesigner
public QbReportDesigner(Object parent, quadbase.common.util.internal.DBInfoBasic dbInfo, quadbase.common.paramquery.QueryInParamSet inSet, boolean newReport) Allocates a QbReportDesigner Object with specified parameters.- Parameters:
parent- an Object of the type or subclass of type java.awt.ComponentinSet- a QueryInParamSet Object that holds parameter information to Queries that will be used to query the databasenewReport- true = start from Data Source Manager, false = start from choosing whether to create a new report or open an existing report choice before going to Data Source Manager.
-
QbReportDesigner
public QbReportDesigner(Object parent, quadbase.common.util.internal.DBInfoBasic dbInfo, quadbase.common.paramquery.QueryInParamSet inSet, boolean newReport, int displayRow) Allocates a QbReportDesigner Object with specified parameters.- Parameters:
parent- an Object of the type or subclass of type java.awt.ComponentinSet- a QueryInParamSet Object that holds parameter information to Queries that will be used to query the databasenewReport- true = start from Data Source Manager, false = start from choosing whether to create a new report or open an existing report choice before going to Data Source Manager.displayRow- sets the limit on the number of rows to be displayed.
-
QbReportDesigner
public QbReportDesigner(Object parent, quadbase.common.util.internal.DBInfoBasic dbInfo, quadbase.common.paramquery.QueryInParamSet inSet, boolean newReport, int displayRow, String[] imagesPath) Allocates a QbReportDesigner Object with specified parameters.- Parameters:
parent- an Object of the type or subclass of type java.awt.ComponentinSet- a QueryInParamSet Object that holds parameter information to Queries that will be used to query the databasenewReport- true = start from Data Source Manager, false = start from choosing whether to create a new report or open an existing report choice before going to Data Source Manager.displayRow- sets the limit on the number of rows to be displayed.imagesPath- a String array of length 3 with the following properties:
imagesPath[0] a String that specifies the path to report images.
imagesPath[1] a String that specifies the path to chart images.
imagesPath[2] a String that specifies the path to background images.
-
QbReportDesigner
public QbReportDesigner(Object parent, String classFile, quadbase.common.paramquery.QueryInParamSet inSet, boolean newReport, int displayRow, String[] imagesPath) Allocates a QbReportDesigner Object with specified parameters.- Parameters:
parent- an Object of the type or subclass of type java.awt.ComponentclassFile- the class path for class file data sourceinSet- a QueryInParamSet Object that holds parameter information to Queries that will be used to query the databasenewReport- true = start from Data Source Manager, false = start from choosing whether to create a new report or open an existing report choice before going to Data Source Manager.displayRow- sets the limit on the number of rows to be displayed.imagesPath- a String array of length 3 with the following properties:
imagesPath[0] a String that specifies the path to report images.
imagesPath[1] a String that specifies the path to chart images.
imagesPath[2] a String that specifies the path to background images.
-
QbReportDesigner
public QbReportDesigner(Object parent, quadbase.common.util.internal.DBInfoBasic dbInfo, quadbase.common.paramquery.QueryInParamSet inSet, boolean newReport, int displayRow, ImagesPath imagesPath) Allocates a QbReportDesigner Object with specified parameters.- Parameters:
parent- an Object of the type or subclass of type java.awt.ComponentinSet- a QueryInParamSet Object that holds parameter information to Queries that will be used to query the databasenewReport- true = start from Data Source Manager, false = start from choosing whether to create a new report or open an existing report choice before going to Data Source Manager.displayRow- sets the limit on the number of rows to be displayed.imagesPath- an ImagesPath Object that stores information about the paths to images on the system.
-
QbReportDesigner
Allocates a QbReportDesigner Object with specified parameters.- Parameters:
parent- an Object of the type or subclass of type java.awt.ComponentdataRegistry- a specified path to a .xml file for the Data Registry to be used for the data source.newReport- true = start from Data Source Manager, false = start from choosing whether to create a new report or open an existing report choice before going to Data Source Manager.
-
QbReportDesigner
Allocates a QbReportDesigner Object with specified parameters.- Parameters:
parent- an Object of the type or subclass of type java.awt.ComponentdataRegistry- a specified path to a .xml file for the Data Registry to be used for the data source.newReport- true = start from Data Source Manager, false = start from choosing whether to create a new report or open an existing report choice before going to Data Source Manager.displayRow- sets the limit on the number of rows to be displayed.
-
QbReportDesigner
public QbReportDesigner(Object parent, String dataRegistry, boolean newReport, int displayRow, String[] imagesPath) Allocates a QbReportDesigner Object with specified parameters.- Parameters:
parent- an Object of the type or subclass of type java.awt.ComponentdataRegistry- a specified path to a .xml file for the Data Registry to be used for the data source.newReport- true = start from Data Source Manager, false = start from choosing whether to create a new report or open an existing report choice before going to Data Source Manager.displayRow- sets the limit on the number of rows to be displayed.imagesPath- a String array of length 3 with the following properties:
imagesPath[0] a String that specifies the path to report images.
imagesPath[1] a String that specifies the path to chart images.
imagesPath[2] a String that specifies the path to background images.
-
QbReportDesigner
public QbReportDesigner(Object parent, String dataRegistry, boolean newReport, int displayRow, ImagesPath imagesPath) Allocates a QbReportDesigner Object with specified parameters.- Parameters:
parent- an Object of the type or subclass of type java.awt.ComponentdataRegistry- a specified path to a .xml file for the Data Registry to be used for the data source.newReport- true = start from Data Source Manager, false = start from choosing whether to create a new report or open an existing report choice before going to Data Source Manager.displayRow- sets the limit on the number of rows to be displayed.imagesPath- an ImagesPath Object that stores information about the paths to images on the system.
-
-
Method Details
-
setDataRegistry
Sets the Data Registry to be used for the data source.- Parameters:
dataRegistry- a specified path to a .xml file for the Data Registry to be used for the data source.
-
setLookAndFeel
Sets the look and feel of the designer UI. User has to call this method before calling QbReportDesigner constructor. If UIManager.setLookAndFeel(newLookAndFeel) throws exception, this method does nothing.
Sample use of this method can be one of the following:QbReportDesigner.setLookAndFeel(new javax.swing.plaf.metal.MetalLookAndFeel()); //Java Metal QbReportDesigner.setLookAndFeel(new com.sun.java.swing.plaf.windows.WindowsLookAndFeel()); //Windows QbReportDesigner.setLookAndFeel(new com.sun.java.swing.plaf.motif.MotifLookAndFeel()); // MOTIF UI -
getLookAndFeel
-
setDebugMode
set debug mode to print out debug statement -
setDebugMode
public static void setDebugMode(int mode) set debug mode to print out debug statement -
getDesigner
It is recommended that the setVisible(true) method should be used instead of this method to launch the report designer. Use this method after calling setVisible(true) to get a reference to the designer JFrame object. -
setVisible
public void setVisible(boolean b) Calling this method with 'true' argument will launch the report designer and start the wizard if necessary. -
login
if server requires login, using [-RequireLogin] flag please pass in userName and password to login QbReportDesigner before calling setVisible(...) or getDesigner(...) methods -
login
if QbDesignerPassword is required for server, using [-QbDesignerPassword] flag please pass in QbDesigner password to login QbReportDesigner before calling setVisible(...) or getDesigner(...) methods -
dispose
public void dispose()Disposes the Window. -
setReportIO
Restrict the directory where the user of the Report Designer will be able to save their .rpt files using an IReportIO. -
setByPassSaveAsIO
public void setByPassSaveAsIO(quadbase.reportdesigner.designer.IByPassSaveAsForReport saveAsIO) Sets by pass save as IO by implementing IByPassSaveAsForReport interface -
setDrillDownReportIO
public void setDrillDownReportIO(quadbase.reportdesigner.designer.IDrillDownReportIO drptIO) Restrict the directory where the user of the Report Designer will be able to save their Drill Down report or Sub-Report (.rpt) files using a IDrillDownReportIO. -
setChartDesignerHandle
public void setChartDesignerHandle(quadbase.reportdesigner.designer.IChartHandle cdHandle) modify chart designer by implementing IChartHandle interface -
modifyWarningMessage
Modify display warning message:
SAVE_RPT_BEFORE_DRILLDOWN - save report before inserting a drilldown report
SAVE_RPT_BEFORE_SUBREPORT - save report before inserting a subreport
SAVE_RPT_EBFORE_PAGEVIEWER - save report before launching pageviewer -
getReportMenuBar
Returns a handle to the Menu Bar of the report. -
getDesignerToolBar
Returns the primary design tool bar -
getDesignerToolBar2
Returns the secondary design tool bar -
getPreviewToolBar
Returns the preview tool bar -
setSaveOnExitEnabled
public void setSaveOnExitEnabled(boolean b) Sets whether to save the report when quitting the Report Designer. -
isSaveOnExitEnabled
public boolean isSaveOnExitEnabled()Returns whether to save on exit is enabled. -
saveAs
public void saveAs()Pops up the Save As Dialog for the user to browse the save location. -
save
public void save()Saves the report at its original location. Overwrites the original. -
save
Saves the report at fileLocation. -
writeFile
Allow user to create or overwrite a file on the server.- Parameters:
filename- The name of the file.content- The content of the file.- Throws:
Exception
-
setDisplayRow
public void setDisplayRow(int nRow) Sets a limit on the number of rows to be displayed by the report. -
setRootDirectoryForBrowse
Sets a root directory for the user. After calling this method, the user is prohibited from browsing any directory above the root directory. -
getBrowseDirectories
Gets a BrowseDirectories object that can be used to set the default browsing directories for different browse dialogs. -
setDirectoryBrowseUpEnabled
public void setDirectoryBrowseUpEnabled(boolean state) Sets whether the user is prohibited from browsing any directory above the root directory. -
isDirectoryBrowseUpEnabled
public boolean isDirectoryBrowseUpEnabled()Gets whether the user is prohibited from browsing any directory above the root directory. -
setDBProvider
Sets the Database provider.- Parameters:
provider- a IDBProvider Object that has information about the database provider to be set.
-
exit
Attempt to exit the program.- Throws:
Exception
-
setExitOnCancel
public void setExitOnCancel(boolean state) Set whether program should exit after clicking on any cancel button in the program. -
isExitOnCancel
public boolean isExitOnCancel()Returns whether setExitOnCanel() is set. -
setForceNewReport
public void setForceNewReport(boolean state) Forces the user to create a new report when Report Designer is loaded. -
isForceNewReport
public boolean isForceNewReport()Returns whether the user is forced to create a new report or not. -
setDefaultParamNames
Internal use only. Specify a preset list of parameters to be used when defining parameters in a query. -
getDefaultParamNames
Gets a preset list of parameters to be used when defining parameters in a query. -
addDataSourceManagerListener
Adding the DataSourceManagerListener to manipulate the data source tree in the Data Source Manager. -
removeDataSourceManagerListener
Removes the DataSourceManagerListener. -
setCustomDefinedFunctions
You may include your own functions with the Formula an Scripts dialog boxes that the users can use when calling Report Designer from the API. Simply create a class that extends the ICustomDefinedFunctions interface and pass it in as an argument. -
getCustomDefinedFunctions
Gets the custom defined functions information. -
setImportQRYFile
public void setImportQRYFile(quadbase.datasourcemanager.manager.IImportQRYFile f) Sets an IImportQRYFile Object to be used with this Report Designer. This is used to alter the functionality of the import query file button inside the data source manager. After this set is done, the importQRYFile() method of the IImportQRYFile Object is called when the user clicks on the import query file button. -
getImportQRYFile
public quadbase.datasourcemanager.manager.IImportQRYFile getImportQRYFile()Gets the imported Query File associated with this Report Designer. -
setChartMenuItemEnabled
public void setChartMenuItemEnabled(int menu, int item, boolean enabled) Sets whether the specified chart menu item is enabled.- Parameters:
menu- the menu nameitem- the menu item nameenabled- true == enabled, false == not enabled
-
setChartMenuEnabled
public void setChartMenuEnabled(int menu, boolean enabled) Sets whether the specified chart menu is enabled.- Parameters:
menu- the menu nameenabled- true == enabled, false == not enabled
-
setChartToolbarEnabled
public void setChartToolbarEnabled(int button, boolean enabled) Sets a button on the chart tool bar enabled or disabled.- Parameters:
button- the index to the buttonenabled- true if and only if enabled
-
disableChartDataSource
public void disableChartDataSource()Disables the Data Source used for the chart. -
setChartIO
Sets where and how charts get saved by passing in an argument chartIO that holds information on how to perform chart file IO. -
setMetricSystemUsed
public static void setMetricSystemUsed(boolean useMetric) Sets whether to use the metric system in the Report Designer. -
isMetricSystemUsed
public static boolean isMetricSystemUsed()Returns whether metric system is used in the Report Designer. -
setSkipQueryResultStep
public void setSkipQueryResultStep(boolean b) Specify whether the query result step should be skipped in the report wizard. -
isSkipQueryResultStep
public boolean isSkipQueryResultStep()Returns whether the query result step should be skipped in the report wizard. The default value is false. -
setSkipMultiDataSourceStep
public void setSkipMultiDataSourceStep(boolean b) Specify whether the multiple data source option step should be skipped in the report wizard. -
isSkipMultiDataSourceStep
public boolean isSkipMultiDataSourceStep()Returns whether the multiple data source option step should be skipped in the report wizard. The default value is false. -
setSkipPredefinedTemplatesStep
public void setSkipPredefinedTemplatesStep(boolean b) Specify whether the select predefined templates step should be skipped in the report wizard. -
isSkipPredefinedTemplatesStep
public boolean isSkipPredefinedTemplatesStep()Returns whether the select predefined templates step should be skipped in the report wizard. The default value is false. -
setSecurityLevel
Sets the "security level" used to open this Report Designer. Users who use a particular "security level" setting to open the Report Designer will have restricted access to what the Administrator have configured for that particular "security level".- Parameters:
level- the name of the security level.
-
getSecurityLevel
Returns the security level name used to open this Report Designer. -
setTemplatesDirectory
Deprecated.use getBrowseDirectories().setReportTemplatesDirectory(String) instead. Set the templates directory. Open and save dialogs will initialize to this directory. The template directory must be relative to the working directory. The default is 'Templates/'. -
getTemplatesDirectory
Deprecated.use getBrowseDirectories().getReportTemplatesDirectory() instead. Returns the templates directory. Open and save dialogs will initialize to this directory. -
setServerAddress
Set the server address of EspressManager. Use this address instead of the one provided in the espressmanager.cfg file. It also eliminates the need of the espressmanager.cfg file in the working directory.- Throws:
UnknownHostException
-
setServerPortNumber
public static void setServerPortNumber(int port) Set the port number of EspressManager. Use this port number instead of the one provided in the espressmanager.cfg file. It also eliminates the need of the espressmanager.cfg file in the working directory. -
setServerHosts
Set the list of host names for EspressManager when tunneling is used. Use these hosts along with the ones provided in the espressmanager.cfg file. If the espressmanager.cfg file is not present, then only these hosts will be used. -
setServletRunner
Set servlet runner hostname and port number. Note: this static method MUST be called before any QbChart constructor- Parameters:
comm_url- servlet runner hostname and port number
-
useServlet
public static void useServlet(boolean b) Determines whether to use SOCKET or HTTP or SERVLET for chart server connection Note that this static method MUST be called before any QbChart constructor.- Parameters:
b- If true use SERVLET connection, otherwise use other connection The default value is false.
-
setServletContext
set servlet context -
getServletContext
Returns servlet context -
setSysExitOnExit
public void setSysExitOnExit(boolean state) Sets the state of whether System.exit() is called when the user selects File->Exit or click on the X button on the top right corner of the designer dialog.- Parameters:
state- the state
-
sysExitOnExit
public boolean sysExitOnExit()Gets the state of whether System.exit() is called when the user selects File->Exit or click on the X button on the top right corner of the designer dialog.- Returns:
- the current state
-
setUseSysResourceImages
public static void setUseSysResourceImages(boolean state) Sets whether to use images in JAR files (ReportDesigner.jar) or other resource that can be loaded by ClassLoader.getSystemResource(imagesPath).- Parameters:
state- the state
-
useSysResourceImages
public static boolean useSysResourceImages()Gets whether to use images in JAR files (ReportDesigner.jar) or other resource that can be loaded by ClassLoader.getSystemResource(imagesPath).- Returns:
- the state
-
getDesignerTabbedPane
Gets the JTabbedPane that contains the 'Design', 'SubReport', and 'Preview' tabs. Selecting different tabs causes the ChangeListener to be invoked. Users can override/extend the behavior of the ChangeListener for this JTabbedPane. -
setPathRelativeToERES
Sets the reports path relative to ERES -
loadFile
This method is used to load the report file from the API, after setting the relative path. And it won't trigger the ReportWizard asking for opening existing report or create new report, caused by method QbReportDesigner.getDesigner() -
loadFile
-
setBrowseRootDirectory
Static method to set the browse root directory, which is the upper bound when the user browse the directories of the server. Also, if browse root is set, the "Go Up" button will be disabled when the path reaches the root- Parameters:
browseRootDir- : MUST be the absolute path, and the user is responsible to make sure the path is correct
-
setServletHttpHeader
Static method to set extra HTTP header that is sent with every request to ESMMessageServlet. This header can be used to filter servlet requests.- Parameters:
headerName- : name of HTTP headerheaderValue- : value of HTTP header
-