public interface SimpleElementContainer
Modifier and Type | Method and Description |
---|---|
Box |
addBox(int boxX,
int boxY,
int boxWidth,
int boxHeight)
Adds a new box to the container and returns it.
|
DatabasePicture |
addDatabasePicture(Field field,
int pictureX,
int pictureY,
int pictureWidth,
int pictureHeight)
Adds a new DatabasePicture to the container and returns it.
|
FieldElement |
addFieldElement(Field field,
int fieldX,
int fieldY,
int fieldWidth,
int fieldHeight)
Adds a new FieldElement (a dynamic text element based on a
Field ) to this container and returns it. |
Line |
addHorizontalLine(int xpos,
int ypos,
int objwidth)
Adds a new horizontal line to the container and returns it.
|
JavaBean |
addJavaBean(java.lang.String className,
int xpos,
int ypos,
int objwidth,
int objheight)
Add a new JavaBean to the container.
|
Picture |
addPicture(int xpos,
int ypos,
int objwidth,
int objheight,
java.awt.image.BufferedImage im)
Adds a new picture element to the container and returns it.
|
Picture |
addPicture(int xpos,
int ypos,
int objwidth,
int objheight,
java.lang.String fileName)
Adds a new picture element to the container and returns it.
|
Picture |
addPicture(int xpos,
int ypos,
int objwidth,
int objheight,
byte[] buffer)
Adds a new picture element to the container and returns it.
|
Picture |
addPicture(int xpos,
int ypos,
int objwidth,
int objheight,
java.io.File file)
Adds a new picture element to the container and returns it.
|
Picture |
addPicture(int xpos,
int ypos,
int objwidth,
int objheight,
int[] buffer)
Adds a new picture element to the container and returns it.
|
Text |
addText(int xpos,
int ypos,
int objwidth,
int objheight)
Adds a new text element to the container.
|
Line |
addVerticalLine(int xpos,
int ypos,
int length)
Adds a new vertical line to the container and returns it.
|
Element[] |
getElements()
Returns an array containing all elements of this container.
|
java.util.Vector<Element> |
getElementsV()
Deprecated.
As of i-net Clear Reports 15.0, use
getElements() instead |
Element |
getReportElement(int idx)
Get a report Element.
|
int |
getReportElementsCount()
Counts the number of Report Elements in this container and returns it.
|
void |
remove(Element elem)
Removes the given report element from the container.
|
Box addBox(int boxX, int boxY, int boxWidth, int boxHeight)
boxX
- The horizontal offset in twips.boxY
- The vertical offset in twips.boxWidth
- The width of the box in twips.boxHeight
- The height of the box in twips.null
if the creation was not successfuljava.lang.IllegalArgumentException
- If the parameter width or height are negative.DatabasePicture addDatabasePicture(Field field, int pictureX, int pictureY, int pictureWidth, int pictureHeight)
field
- Field which value type is Field.BINARY and that should be
added to the container. This can be a database field, a formula field, a prompt field or a
SQL field.pictureX
- x-coordinate of the upper left corner in twips.pictureY
- y-coordinate of the upper left corner in twips.pictureWidth
- Width of the new fieldElement in twips.pictureHeight
- Height of the new fieldElement in twips.FieldElement addFieldElement(Field field, int fieldX, int fieldY, int fieldWidth, int fieldHeight) throws ReportException
Field
) to this container and returns it.
Note that for binary fields you need to use the method addDatabasePicture(Field, int, int, int, int)
, since picture
fields are not FieldElements.field
- The field that should added into container. May not be null.fieldX
- The x-coordinate of the upper left corner in twips.fieldY
- The y-coordinate of the upper left corner in twips.fieldWidth
- The width of the new fieldElement in twips.fieldHeight
- The height of the new fieldElement in twips.null
if the creation was not successful.ReportException
- if the value type of the field is binary - use addDatabasePicture(Field, int, int, int, int)
instead.java.lang.IllegalArgumentException
- if the parameters x, y, width or height are negativejava.lang.NullPointerException
- if the field is nullDatabaseField
,
FormulaField
,
PromptField
,
SummaryField
,
SQLField
,
GroupField
JavaBean addJavaBean(java.lang.String className, int xpos, int ypos, int objwidth, int objheight) throws ReportException
className
- The class name of the Java Bean.xpos
- The x-coordinate of the upper left corner in twips.ypos
- The y-coordinate of the upper left corner in twips.objwidth
- The width of the new fieldElement in twips.objheight
- The height of the new fieldElement in twips.java.lang.IllegalArgumentException
- if the parameters x, y, width or height are negative.ReportException
- if the Java Bean cannot created.Line addHorizontalLine(int xpos, int ypos, int objwidth)
xpos
- the horizontal offset of the start point in twips.ypos
- the vertical offset of the start point in twips.objwidth
- the width of the line in twips.java.lang.IllegalArgumentException
- if some parameter is negative.Line addVerticalLine(int xpos, int ypos, int length)
xpos
- the horizontal offset of the start point in twips.ypos
- the vertical offset of the start point in twips.length
- the height of the line in twips.java.lang.IllegalArgumentException
- if the parameters x, y or height are negativePicture addPicture(int xpos, int ypos, int objwidth, int objheight, java.awt.image.BufferedImage im) throws ReportException
xpos
- The horizontal offset of the start point in twips.ypos
- The vertical offset of the start point in twips.objwidth
- The width of the picture in twips.objheight
- The height of the picture in twips.im
- The image object.ReportException
- ReportException will thrown if im
is an unknown picture format.addPicture(int, int, int, int, String)
,
addPicture(int,int,int,int,java.io.File)
,
addPicture(int,int,int,int,byte[])
,
addPicture(int, int, int, int, int[])
Picture addPicture(int xpos, int ypos, int objwidth, int objheight, java.lang.String fileName) throws ReportException
xpos
- The horizontal offset of the start point in twips.ypos
- The vertical offset of the start point in twips.objwidth
- The width of the picture in twipsobjheight
- The height of the picture in twips.fileName
- The absolute or relative to working directory path to the image.ReportException
- will thrown if file
is an unknown picture format.addPicture(int,int,int,int,java.awt.image.BufferedImage)
,
addPicture(int,int,int,int,java.io.File)
,
addPicture(int,int,int,int,byte[])
,
addPicture(int, int, int, int, int[])
Picture addPicture(int xpos, int ypos, int objwidth, int objheight, byte[] buffer) throws ReportException
xpos
- The horizontal offset of the start point in twips.ypos
- The vertical offset of the start point in twips.objwidth
- The width of the picture in twips.objheight
- The height of the picture in twips.buffer
- A byte[] with image header and data.ReportException
- ReportException will thrown if buffer
is an unknown picture format.ReportException
- if buffer
is an unknown picture format.addPicture(int,int,int,int,java.awt.image.BufferedImage)
,
addPicture(int, int, int, int, String)
,
addPicture(int,int,int,int,java.io.File)
,
addPicture(int, int, int, int, int[])
Picture addPicture(int xpos, int ypos, int objwidth, int objheight, java.io.File file) throws ReportException
xpos
- The horizontal offset of the start point in twips.ypos
- The vertical offset of the start point in twips.objwidth
- The width of the picture in twips.objheight
- The height of the picture in twips.file
- The file object to the image.ReportException
- will thrown if file
is an unknown picture format.addPicture(int, int, int, int, BufferedImage)
,
addPicture(int, int, int, int, String)
,
addPicture(int, int, int, int, byte[])
,
addPicture(int, int, int, int, int[])
Picture addPicture(int xpos, int ypos, int objwidth, int objheight, int[] buffer) throws ReportException
xpos
- The horizontal offset of the start point in twips.ypos
- The vertical offset of the start point in twips.objwidth
- The width of the picture in twips.objheight
- The height of the picture in twips.buffer
- A int[] with image header and data.ReportException
- ReportException will thrown if buffer
is an unknown picture format.addPicture(int, int, int, int, java.awt.image.BufferedImage)
,
addPicture(int, int, int, int, String)
,
addPicture(int, int, int, int, byte[])
,
addPicture(int, int, int, int, File)
,
addPicture(int,int,int,int,java.io.File)
,
addPicture(int,int,int,int,String)
Text addText(int xpos, int ypos, int objwidth, int objheight) throws java.lang.IllegalArgumentException
addParagraph
method.
The returned text element is empty, that means it contains no paragraph object.xpos
- the x offset of the text elementypos
- the y offset of the text elementobjwidth
- the width of the text elementobjheight
- the height of the text elementjava.lang.IllegalArgumentException
- if the parameters x, y, width or height are negativeElement[] getElements()
getElementsV()
,
Element
@Deprecated java.util.Vector<Element> getElementsV()
getElements()
insteadgetElements()
,
Element
Element getReportElement(int idx)
idx
- The 0-based index of the element, which should be returned.int getReportElementsCount()
void remove(Element elem)
elem
- The Report Element which should be removed from the container (null
is not permitted).java.lang.IllegalArgumentException
- if the parameter elem
is null.Copyright © 1999-2020 by i-net software GmbH