EspressReport 6.6

quadbase.reportdesigner.ReportElements
Class SubReportObject

java.lang.Object
  extended by quadbase.reportdesigner.ReportElements.ReportElement
      extended by quadbase.reportdesigner.ReportElements.ReportCell
          extended by quadbase.reportdesigner.ReportElements.SubReportObject
All Implemented Interfaces:
java.io.Serializable

public class SubReportObject
extends ReportCell
implements java.io.Serializable

This represents a sub report that can be added to a QbReport -- in the ReportSection, or ReportTable.

See Also:
Serialized Form

Field Summary
static java.lang.String SUBREPORT_DIR
           
static java.lang.String XMLTAG
          For internal use only
 
Fields inherited from class quadbase.reportdesigner.ReportElements.ReportElement
bgColor, borderColor, CHART, COLUMN, COLUMNHEADER, FORMULA, GRID, height, ID_TYPE, IMAGE, isLocked, LABEL, LINE, min_height, min_width, NONE, rotate_angle, ROTATE_CLOCKWISE, ROTATE_COUNTERCLOCKWISE, ROTATE_NONE, roundCornerRadius, roundCornersArray, RTFOBJECT, SECTION, securityMap, snap, SORT_X, SORT_Y, SORT_Z, SUBREPORT, TABLE, TABLEOFCONTENTS, TITLE, visible, vsnap, width, x
 
Constructor Summary
SubReportObject()
          For internal use only.
SubReportObject(ISubReport sr)
          For internal use only.
SubReportObject(java.lang.String parentFile)
          For internal use only Construct a place holder for a sub-report.
SubReportObject(java.lang.String parentFile, java.lang.String id)
          internal use only
SubReportObject(java.lang.String parentFile, java.lang.String id, java.lang.String domainPath, quadbase.common.util.internal.FileInMemTable subFilesTable)
          internal use only
 
Method Summary
 void clearReportCache()
          For internal use only
 void clearReportCache(double percent)
          For internal use only
 void copy(SubReportObject _cell)
          internal use only Specifies this SubReportObject to be the same as "_cell"
static SubReportObject createSubReportObject(java.io.DataInput in, int version)
          For internal use only.
static SubReportObject createSubReportObject(java.io.DataInput in, int version, boolean pack, boolean fromReportDesigner, quadbase.common.util.internal.FileInMemTable subFilesTable)
          internal use only
static SubReportObject createSubReportObject(java.io.DataInput in, int version, boolean pack, boolean fromReportDesigner, quadbase.common.util.internal.FileInMemTable subFilesTable, boolean writeToFileSystem)
          internal use only
static SubReportObject createSubReportObject(java.io.DataInput in, int version, boolean pack, boolean fromReportDesigner, quadbase.common.util.internal.FileInMemTable subFilesTable, boolean writeToFileSystem, java.lang.String domainPath)
          internal use only
static SubReportObject createSubReportObject(java.io.DataInput in, int version, boolean pack, boolean fromReportDesigner, quadbase.common.util.internal.FileInMemTable subFilesTable, boolean writeToFileSystem, java.lang.String domainPath, boolean loadNewOnly)
           
static SubReportObject createSubReportObject(org.w3c.dom.Node node, int version)
          For internal use only.
 void deepCopy(SubReportObject _cell)
          For internal use only
 void deleteSubReportColDataFiles()
           
 boolean equals(SubReportObject _cell)
          Checks if this SubReportObject object's properties are the same as "_cell"
 byte[] getByteArray()
          internal use only
 byte[] getBytes()
          Returns the contained SubReport as a byte array
 ISubReport getCachedSubReport()
          internal use only
 int getCacheSize()
          return the number of SubReport that will be cached
 java.lang.String getChartPath()
          Deprecated. call this method from the parent QbReport
 java.lang.String getCustomerQueryForLinkedSubReport()
           
 java.lang.String getDomainPath()
           
 java.lang.String getFileName()
          Return the file location of the sub-report RPT file
 java.lang.String getFileName(quadbase.common.util.internal.FileInMemTable subFilesTable)
           
 java.lang.String getImagePath()
          Deprecated. call this method from the parent QbReport
 java.lang.String[] getParameterMap()
          For parameterized SubReport only, returns a String array of CELL_ID
 java.lang.String getParamShareReportID()
          Gets the id for this sub report object when sharing parameter values with main report.
 ISubReport getSubReport()
          For internal use only.
 ISubReport getSubReport(boolean isEnterpriseServer, boolean optimizeMemory, boolean useBackupData)
          Deprecated. Use getSubReport(boolean isEnterpriseServer, boolean optimizeMemory, boolean useBackupData, IReport qbreport) instead of this method.
 ISubReport getSubReport(boolean isEnterpriseServer, boolean optimizeMemory, boolean useBackupData, IReport ireport)
          Returns the contained ISubReport object, which can be class-casted to a SubReport object.
 ISubReport getSubReport(IReport qbreport)
          Returns the contained ISubReport object, which can be class-casted to a SubReport object.
 java.lang.String getText()
          gets the filename of the sub report
 java.lang.String getText(quadbase.common.util.internal.FileInMemTable subFilesTable)
           
 boolean hasUsableReport()
          For internal use only
 boolean isColDataPopulated()
           
 boolean isResizeWidth()
          Whether this SubReportObject resizes its width automatically to fit its contents.
 quadbase.reportdesigner.report.Report loadReport_std(quadbase.reportdesigner.report.Report mainreport, ReportTable tbl, boolean useDefaultParamValue)
          internal use only
 quadbase.reportdesigner.report.Report loadReport(quadbase.reportdesigner.report.Report mainreport, ReportTable tbl)
          For internal use only This method is used when the user loads a report directly from a file and the 'SubReportObject' object has no temporary reference to a 'Report' object.
 quadbase.reportdesigner.report.Report loadReport(quadbase.reportdesigner.report.Report mainreport, ReportTable tbl, boolean useDefaultParamValue)
           
 void read(java.io.DataInput in, int version)
          For internal use only.
 void readByteArray(java.io.DataInput in, int version, boolean fromReportDesigner, quadbase.common.util.internal.FileInMemTable subFilesTable, boolean write)
          internal use only
 void readByteArray(java.io.DataInput in, int version, boolean fromReportDesigner, quadbase.common.util.internal.FileInMemTable subFilesTable, boolean writeToFileSystem, boolean loadNewOnly)
           
 void readXML(org.w3c.dom.Node node, int version)
          For internal use only.
 void refreshColData()
           
 quadbase.reportdesigner.report.Report reloadReportWithParameters_std(quadbase.reportdesigner.report.Report subreport, quadbase.reportdesigner.report.Report mainreport, ReportTable tbl)
          For internal use only This method is called when the 'SubReportObject' object has a temporary referecne to a 'Report' object.
 quadbase.reportdesigner.report.Report reloadReportWithParameters(quadbase.reportdesigner.report.Report subreport, quadbase.reportdesigner.report.Report mainreport, ReportTable tbl)
           
 void setByteArray(byte[] barray)
          internal use only
 void setBytes(byte[] barray)
          Set the contained SubReport object.
 void setCacheSize(int size)
          Set the size of the cache for parameterized sub-reports.
 void setChartPath(java.lang.String path)
          Deprecated. use setChartPath from the QbReport object.
 void setCustomerQueryForLinkedSubReport(java.lang.String query)
           
 void setDomainAndCheckForUniqueFileName(java.lang.String path)
           
 void setDomainPath(java.lang.String path)
           
 void setFileName(java.lang.String fn)
          For internal use only.
 void setHTMLParameters(java.lang.String dirLocation, java.lang.String url, java.lang.String fileName)
          Not used.
 void setImagePath(java.lang.String path)
          Deprecated. call this method from the parent QbReport
 void setParameterMap(java.lang.String[] p)
          For parameterized SubReport only, sets the specified String array as CELL_ID.
 void setParamShareReportID(java.lang.String id)
          internal use only
 void setResizeWidth(boolean b)
          Sets whether this SubReportObject resizes its width automatically to fit its contents.
 void setSubReport(ISubReport report)
          For internal use only.
 void write(java.io.DataOutput out)
          For internal use only.
 void write(quadbase.common.util.internal.FileInMemTable subFilesTable, java.io.DataOutput out)
          For internal use only.
 void writeByteArray(java.io.DataOutput out, quadbase.common.util.internal.FileInMemTable subFilesTable)
          internal use only
 void writeXML(java.io.Writer out, boolean writeElementTag)
          internal use only
 
Methods inherited from class quadbase.reportdesigner.ReportElements.ReportCell
applyStyle, applyStyleButNotWH, applyTemplate, applyTemplate, clone, copy, copyTemplate, createCell, createCell, createFormulaObject, createFormulaObjectFromName, createFormulaObjectFromText, deepCopy, equals, formulaReferenced, getColIndex, getColumn, getDataFormat, getEntry, getFormula, getFormulaName, getFormulaObj, getScriptedValue, getSQLType, setColumn, setDataFormat, setEntry, setFormula, setFormulaObj, setScriptedValue
 
Methods inherited from class quadbase.reportdesigner.ReportElements.ReportElement
addSecurityLevel, applyImageTemplate, applyImageTemplateExceptBound, applySecurity, applyStyle, applyStyleButNotWH, applyTemplate, applyTemplate, applyTemplate, contains, contains, containsX, containsY, copy, copyTemplate, createScriptObject, createScriptObjectFromName, deepCopy, doesElementSupportRoundCorners, equals, findElementsAbove, findElementsBelow, findElementsToLeft, findElementsToRight, findElementsToRight, findElementType, findGroupElementType, findMaxXr, findMaxYd, findMinX, findMinY, findSpecificElements, getAlign, getAllColors, getBgColor, getBookmark, getBorder, getBorderColor, getBorderThickness, getBottomBorder, getCustomID, getDrawX, getDrawX, getDrawY, getDrawY, getDrillDownName, getElementType, getElementTypeName, getFirst2RowOfColumns, getFirst2RowOfColumns, getFont, getFontColor, getHeight, getHeight, getHeightOfElement, getHeightOfElement, getHeightToPoints, getHint, getID, getLeftBorder, getLink, getMaxXr, getMin_Height, getMin_Width, getMinX, getRefFont, getRefFontToDraw, getRightBorder, getRotateAngle, getRoundCornerRadius, getRoundCornersArray, getScript, getScriptName, getScriptObj, getSecuredScripts, getSecurityLevel, getSecurityLevels, getSecurityMap, getSnap, getStyleName, getTarget, getTopBorder, getVAlign, getVSnap, getWidth, getWidth, getWidthOfElement, getWidthOfElement, getWidthToPoints, getX, getX, getXPos, getXPos, getXToPoints, getY, getY, getYPos, getYPos, getYToPoints, getZ, hasBorder, inBottomHalf, inLeftEnd, inLeftHalf, inRightEnd, inRightHalf, inTopHalf, isCrossTabElt, isDrawAgain, isLocked, isNoWrap, isResizeToFitContent, isSecurityLevelDefined, isSecurityTextScript, isShiftSecuredColX, isShiftSecuredColXIncludeHeaderAndFooter, isSnapToGrid, isUnderline, isVisible, moveForCrossTabFixedField, moveForCrossTabFixedField, newArrayX, newArrayY, removeScriptReferenced, removeSecurityLevel, renameSecurityLevel, resize, resizeForCrossTabFixedField, resizeForCrossTabFixedField, scriptReferenced, securityScriptReferenced, setAlign, setBgColor, setBookmark, setBorder, setBorderColor, setBorderThickness, setBorderThickness, setBorderThickness, setBottomBorder, setCustomID, setDrawAgain, setDrawX, setDrawX, setDrawY, setDrawY, setDrillDownName, setFont, setFontColor, setHeight, setHeight, setHint, setID, setID, setInchGridSpace, setLeftBorder, setLink, setLocked, setMinHeight, setMinWidth, setNoWrap, setResizeToFitContent, setRightBorder, setRotateAngle, setRotateAngle, setRoundCornerRadius, setRoundCornersArray, setScript, setScriptName, setScriptObj, setScriptObjNull, setSecurityLevelProperties, setSecurityMap, setSecurityTextScript, setShiftSecuredColX, setShiftSecuredColXIncludeHeaderAndFooter, setSnap, setSnapToGrid, setSnapToGrid, setStyleName, setTarget, setText, setTopBorder, setUnderline, setVAlign, setVisible, setVSnap, setWidth, setWidth, setX, setX, setXX, setXX, setY, setY, setYY, setYY, setZ, shift, shiftObjectsOnMove, shiftOnMove, sortElement, sortElement, sortElementHorizontally, sortElementInXYOrder, sortElementVertically, swapElements, switchSecurityProperties
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

SUBREPORT_DIR

public static final java.lang.String SUBREPORT_DIR
See Also:
Constant Field Values

XMLTAG

public static final java.lang.String XMLTAG
For internal use only

See Also:
Constant Field Values
Constructor Detail

SubReportObject

public SubReportObject(java.lang.String parentFile)
For internal use only Construct a place holder for a sub-report.

Parameters:
parentFile - The file name of the root report. Assumes the root report to be saved and has a file name.
name - Name of the sub-report

SubReportObject

public SubReportObject(java.lang.String parentFile,
                       java.lang.String id)
internal use only


SubReportObject

public SubReportObject(java.lang.String parentFile,
                       java.lang.String id,
                       java.lang.String domainPath,
                       quadbase.common.util.internal.FileInMemTable subFilesTable)
internal use only


SubReportObject

public SubReportObject()
For internal use only.


SubReportObject

public SubReportObject(ISubReport sr)
For internal use only. Used only with ReportAPI.

Method Detail

copy

public void copy(SubReportObject _cell)
internal use only Specifies this SubReportObject to be the same as "_cell"

Parameters:
_cell - The SubReportObject object being emulated

deepCopy

public void deepCopy(SubReportObject _cell)
For internal use only


equals

public boolean equals(SubReportObject _cell)
Checks if this SubReportObject object's properties are the same as "_cell"

Parameters:
_cell - the SubReportObject object being compared to

getFileName

public java.lang.String getFileName()
Return the file location of the sub-report RPT file


getFileName

public java.lang.String getFileName(quadbase.common.util.internal.FileInMemTable subFilesTable)

setFileName

public void setFileName(java.lang.String fn)
For internal use only. Specifies the file location for the sub-report.


getParamShareReportID

public java.lang.String getParamShareReportID()
Gets the id for this sub report object when sharing parameter values with main report.


setParamShareReportID

public void setParamShareReportID(java.lang.String id)
internal use only


write

public void write(java.io.DataOutput out)
           throws java.io.IOException
For internal use only.

Overrides:
write in class ReportCell
Throws:
java.io.IOException

write

public void write(quadbase.common.util.internal.FileInMemTable subFilesTable,
                  java.io.DataOutput out)
           throws java.io.IOException
For internal use only.

Throws:
java.io.IOException

writeByteArray

public void writeByteArray(java.io.DataOutput out,
                           quadbase.common.util.internal.FileInMemTable subFilesTable)
                    throws java.io.IOException
internal use only

Throws:
java.io.IOException

writeXML

public void writeXML(java.io.Writer out,
                     boolean writeElementTag)
              throws java.io.IOException
internal use only

Overrides:
writeXML in class ReportCell
Throws:
java.io.IOException

createSubReportObject

public static SubReportObject createSubReportObject(org.w3c.dom.Node node,
                                                    int version)
                                             throws java.lang.Exception
For internal use only.

Throws:
java.lang.Exception

readXML

public void readXML(org.w3c.dom.Node node,
                    int version)
             throws java.lang.Exception
For internal use only.

Overrides:
readXML in class ReportCell
Throws:
java.lang.Exception

createSubReportObject

public static SubReportObject createSubReportObject(java.io.DataInput in,
                                                    int version)
                                             throws java.lang.Exception
For internal use only.

Throws:
java.lang.Exception

createSubReportObject

public static SubReportObject createSubReportObject(java.io.DataInput in,
                                                    int version,
                                                    boolean pack,
                                                    boolean fromReportDesigner,
                                                    quadbase.common.util.internal.FileInMemTable subFilesTable)
                                             throws java.lang.Exception
internal use only

Throws:
java.lang.Exception

createSubReportObject

public static SubReportObject createSubReportObject(java.io.DataInput in,
                                                    int version,
                                                    boolean pack,
                                                    boolean fromReportDesigner,
                                                    quadbase.common.util.internal.FileInMemTable subFilesTable,
                                                    boolean writeToFileSystem)
                                             throws java.lang.Exception
internal use only

Throws:
java.lang.Exception

createSubReportObject

public static SubReportObject createSubReportObject(java.io.DataInput in,
                                                    int version,
                                                    boolean pack,
                                                    boolean fromReportDesigner,
                                                    quadbase.common.util.internal.FileInMemTable subFilesTable,
                                                    boolean writeToFileSystem,
                                                    java.lang.String domainPath)
                                             throws java.lang.Exception
internal use only

Throws:
java.lang.Exception

createSubReportObject

public static SubReportObject createSubReportObject(java.io.DataInput in,
                                                    int version,
                                                    boolean pack,
                                                    boolean fromReportDesigner,
                                                    quadbase.common.util.internal.FileInMemTable subFilesTable,
                                                    boolean writeToFileSystem,
                                                    java.lang.String domainPath,
                                                    boolean loadNewOnly)
                                             throws java.lang.Exception
Throws:
java.lang.Exception

readByteArray

public void readByteArray(java.io.DataInput in,
                          int version,
                          boolean fromReportDesigner,
                          quadbase.common.util.internal.FileInMemTable subFilesTable,
                          boolean write)
                   throws java.lang.Exception
internal use only

Throws:
java.lang.Exception

readByteArray

public void readByteArray(java.io.DataInput in,
                          int version,
                          boolean fromReportDesigner,
                          quadbase.common.util.internal.FileInMemTable subFilesTable,
                          boolean writeToFileSystem,
                          boolean loadNewOnly)
                   throws java.lang.Exception
Throws:
java.lang.Exception

read

public void read(java.io.DataInput in,
                 int version)
          throws java.lang.Exception
For internal use only.

Overrides:
read in class ReportCell
Throws:
java.lang.Exception

getSubReport

public ISubReport getSubReport()
                        throws java.lang.Exception
For internal use only. Developers using the API should use getSubReport(IReport qbreport) instead of this method.

Throws:
java.lang.Exception
See Also:
getSubReport(IReport)

getSubReport

public ISubReport getSubReport(IReport qbreport)
                        throws java.lang.Exception
Returns the contained ISubReport object, which can be class-casted to a SubReport object.

Parameters:
qbreport - the parent QbReport object.
Throws:
java.lang.Exception

getSubReport

@Deprecated
public ISubReport getSubReport(boolean isEnterpriseServer,
                                          boolean optimizeMemory,
                                          boolean useBackupData)
                        throws java.lang.Exception
Deprecated. Use getSubReport(boolean isEnterpriseServer, boolean optimizeMemory, boolean useBackupData, IReport qbreport) instead of this method.

Throws:
java.lang.Exception
See Also:
getSubReport(boolean isEnterpriseServer, boolean optimizeMemory, boolean useBackupData, IReport qbreport)

getSubReport

public ISubReport getSubReport(boolean isEnterpriseServer,
                               boolean optimizeMemory,
                               boolean useBackupData,
                               IReport ireport)
                        throws java.lang.Exception
Returns the contained ISubReport object, which can be class-casted to a SubReport object.

Parameters:
isEnterpriseServer - whether to prompt parameter value on clientside
optimizeMemory - whether to get data in packets to save memory resource
useBackupData - if true, the returned SubReport object would contain only the 2 rows of backup data. Otherwise, refresh data.
ireport - the parent QbReport object.
Throws:
java.lang.Exception

hasUsableReport

public boolean hasUsableReport()
For internal use only


setParameterMap

public void setParameterMap(java.lang.String[] p)
For parameterized SubReport only, sets the specified String array as CELL_ID.


getParameterMap

public java.lang.String[] getParameterMap()
For parameterized SubReport only, returns a String array of CELL_ID


loadReport

public quadbase.reportdesigner.report.Report loadReport(quadbase.reportdesigner.report.Report mainreport,
                                                        ReportTable tbl)
                                                 throws java.lang.Exception
For internal use only This method is used when the user loads a report directly from a file and the 'SubReportObject' object has no temporary reference to a 'Report' object. This method will load a report from file using the appropriate parameters from the main report.

Throws:
java.lang.Exception

loadReport

public quadbase.reportdesigner.report.Report loadReport(quadbase.reportdesigner.report.Report mainreport,
                                                        ReportTable tbl,
                                                        boolean useDefaultParamValue)
                                                 throws java.lang.Exception
Throws:
java.lang.Exception

reloadReportWithParameters

public quadbase.reportdesigner.report.Report reloadReportWithParameters(quadbase.reportdesigner.report.Report subreport,
                                                                        quadbase.reportdesigner.report.Report mainreport,
                                                                        ReportTable tbl)
                                                                 throws java.lang.Exception
Throws:
java.lang.Exception

loadReport_std

public quadbase.reportdesigner.report.Report loadReport_std(quadbase.reportdesigner.report.Report mainreport,
                                                            ReportTable tbl,
                                                            boolean useDefaultParamValue)
                                                     throws java.lang.Exception
internal use only

Throws:
java.lang.Exception

reloadReportWithParameters_std

public quadbase.reportdesigner.report.Report reloadReportWithParameters_std(quadbase.reportdesigner.report.Report subreport,
                                                                            quadbase.reportdesigner.report.Report mainreport,
                                                                            ReportTable tbl)
                                                                     throws java.lang.Exception
For internal use only This method is called when the 'SubReportObject' object has a temporary referecne to a 'Report' object. In which case the report object has to be refreshed to reflect any changes made to the main report parameters.

Throws:
java.lang.Exception

setBytes

public void setBytes(byte[] barray)
              throws java.lang.Exception
Set the contained SubReport object. Warning: this method should not be used. Instead, use the SubReport.createSubReport(parentObject, barray) method.

Parameters:
barray - the new SubReport object in the byte array format
Throws:
java.lang.Exception

getBytes

public byte[] getBytes()
                throws java.lang.Exception
Returns the contained SubReport as a byte array

Throws:
java.lang.Exception

clearReportCache

public void clearReportCache()
For internal use only


clearReportCache

public void clearReportCache(double percent)
For internal use only


getCacheSize

public int getCacheSize()
return the number of SubReport that will be cached


setCacheSize

public void setCacheSize(int size)
Set the size of the cache for parameterized sub-reports. The size of the cache cannot be less than 1. If the argument is less than 1, then 1 will be used.


setHTMLParameters

public void setHTMLParameters(java.lang.String dirLocation,
                              java.lang.String url,
                              java.lang.String fileName)
Not used. Please call this method from the parent QbReport


setChartPath

@Deprecated
public void setChartPath(java.lang.String path)
Deprecated. use setChartPath from the QbReport object.


setImagePath

@Deprecated
public void setImagePath(java.lang.String path)
Deprecated. call this method from the parent QbReport


getChartPath

@Deprecated
public java.lang.String getChartPath()
Deprecated. call this method from the parent QbReport


getImagePath

@Deprecated
public java.lang.String getImagePath()
Deprecated. call this method from the parent QbReport


setByteArray

public void setByteArray(byte[] barray)
internal use only


getByteArray

public byte[] getByteArray()
internal use only


setSubReport

public void setSubReport(ISubReport report)
For internal use only. DO NOT USE THIS METHOD. This method is called as a consequence of the getSubReport method. This is used only in the API to the report reference for idectial subreport objects.


getText

public java.lang.String getText()
gets the filename of the sub report

Overrides:
getText in class ReportElement
Returns:
the text of this element

getText

public java.lang.String getText(quadbase.common.util.internal.FileInMemTable subFilesTable)

isResizeWidth

public boolean isResizeWidth()
Whether this SubReportObject resizes its width automatically to fit its contents.


setResizeWidth

public void setResizeWidth(boolean b)
Sets whether this SubReportObject resizes its width automatically to fit its contents.


getCachedSubReport

public ISubReport getCachedSubReport()
internal use only


deleteSubReportColDataFiles

public void deleteSubReportColDataFiles()

refreshColData

public void refreshColData()

isColDataPopulated

public boolean isColDataPopulated()

setDomainPath

public void setDomainPath(java.lang.String path)

setDomainAndCheckForUniqueFileName

public void setDomainAndCheckForUniqueFileName(java.lang.String path)

getDomainPath

public java.lang.String getDomainPath()

setCustomerQueryForLinkedSubReport

public void setCustomerQueryForLinkedSubReport(java.lang.String query)

getCustomerQueryForLinkedSubReport

public java.lang.String getCustomerQueryForLinkedSubReport()

EspressReport 6.6