org.apache.poi.ddf
Class EscherSpgrRecord
- java.lang.Object
-
- org.apache.poi.ddf.EscherRecord
-
- org.apache.poi.ddf.EscherSpgrRecord
-
public class EscherSpgrRecord extends EscherRecord
The spgr record defines information about a shape group. Groups in escher are simply another form of shape that you can't physically see.
-
-
Field Summary
Fields Modifier and Type Field and Description static java.lang.StringRECORD_DESCRIPTIONstatic shortRECORD_ID
-
Constructor Summary
Constructors Constructor and Description EscherSpgrRecord()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method and Description intfillFields(byte[] data, int offset, EscherRecordFactory recordFactory)The contract of this method is to deserialize an escher record including it's children.shortgetRecordId()Return the current record id.java.lang.StringgetRecordName()Subclasses should return the short name for this escher record.intgetRecordSize()Subclasses should effeciently return the number of bytes required to serialize the record.intgetRectX1()The starting top-left coordinate of child records.intgetRectX2()The starting bottom-right coordinate of child records.intgetRectY1()The starting top-left coordinate of child records.intgetRectY2()The starting bottom-right coordinate of child records.intserialize(int offset, byte[] data, EscherSerializationListener listener)Serializes the record to an existing byte array.voidsetRectX1(int x1)The starting top-left coordinate of child records.voidsetRectX2(int x2)The starting bottom-right coordinate of child records.voidsetRectY1(int y1)The starting top-left coordinate of child records.voidsetRectY2(int rectY2)The starting bottom-right coordinate of child records.java.lang.StringtoString()java.lang.StringtoXml(java.lang.String tab)-
Methods inherited from class org.apache.poi.ddf.EscherRecord
clone, display, getChild, getChildRecords, getInstance, getOptions, getVersion, isContainerRecord, serialize, serialize, setChildRecords, setInstance, setOptions, setRecordId, setVersion, toXml
-
-
-
-
Field Detail
-
RECORD_ID
public static final short RECORD_ID
- See Also:
- Constant Field Values
-
RECORD_DESCRIPTION
public static final java.lang.String RECORD_DESCRIPTION
- See Also:
- Constant Field Values
-
-
Method Detail
-
fillFields
public int fillFields(byte[] data, int offset, EscherRecordFactory recordFactory)Description copied from class:EscherRecordThe contract of this method is to deserialize an escher record including it's children.- Specified by:
fillFieldsin classEscherRecord- Parameters:
data- The byte array containing the serialized escher records.offset- The offset into the byte array.recordFactory- A factory for creating new escher records.- Returns:
- The number of bytes written.
-
serialize
public int serialize(int offset, byte[] data, EscherSerializationListener listener)Description copied from class:EscherRecordSerializes the record to an existing byte array.- Specified by:
serializein classEscherRecord- Parameters:
offset- the offset within the byte arraydata- the data array to serialize tolistener- a listener for begin and end serialization events. This is useful because the serialization is hierarchical/recursive and sometimes you need to be able break into that.- Returns:
- the number of bytes written.
-
getRecordSize
public int getRecordSize()
Description copied from class:EscherRecordSubclasses should effeciently return the number of bytes required to serialize the record.- Specified by:
getRecordSizein classEscherRecord- Returns:
- number of bytes
-
getRecordId
public short getRecordId()
Description copied from class:EscherRecordReturn the current record id.- Overrides:
getRecordIdin classEscherRecord- Returns:
- The 16 bit record id.
-
getRecordName
public java.lang.String getRecordName()
Description copied from class:EscherRecordSubclasses should return the short name for this escher record.- Specified by:
getRecordNamein classEscherRecord
-
toString
public java.lang.String toString()
- Overrides:
toStringin classjava.lang.Object- Returns:
- the string representation of this record.
-
toXml
public java.lang.String toXml(java.lang.String tab)
- Overrides:
toXmlin classEscherRecord- Parameters:
tab- - each children must be a right of his parent- Returns:
- xml representation of this record
-
getRectX1
public int getRectX1()
The starting top-left coordinate of child records.
-
setRectX1
public void setRectX1(int x1)
The starting top-left coordinate of child records.
-
getRectY1
public int getRectY1()
The starting top-left coordinate of child records.
-
setRectY1
public void setRectY1(int y1)
The starting top-left coordinate of child records.
-
getRectX2
public int getRectX2()
The starting bottom-right coordinate of child records.
-
setRectX2
public void setRectX2(int x2)
The starting bottom-right coordinate of child records.
-
getRectY2
public int getRectY2()
The starting bottom-right coordinate of child records.
-
setRectY2
public void setRectY2(int rectY2)
The starting bottom-right coordinate of child records.
-
-
DataMelt 3.0 © DataMelt by jWork.ORG