Top Description Fields Constructors Methods
org.apache.poi.ddf

public Class EscherSpRecord

extends EscherRecord
Class Inheritance
Static Imports
org.apache.poi.util.GenericRecordUtil.getBitsAsString

Together the EscherOptRecord this record defines some of the basic properties of a shape.

Field Summary

Modifier and TypeField and Description
private int
private int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
private static final int[]
private static final String[]
public static final short

Constructor Summary

AccessConstructor and Description
public
public

Method Summary

Modifier and TypeMethod and Description
public EscherSpRecord
private String
decodeFlags(int flags)

Converts the shape flags into a more descriptive name.

public int
fillFields(byte[]
The byte array containing the serialized escher records.
data
,
int
The offset into the byte array.
offset
,
EscherRecordFactory
A factory for creating new escher records.
recordFactory
)

Implements abstract org.apache.poi.ddf.EscherRecord.fillFields.

The contract of this method is to deserialize an escher record including its children.

public int

Returns:

the flags
getFlags
()

The flags that apply to this shape.

public Map<String, Supplier<?>>
public Enum<E extends Enum<E>>
public short
getRecordId()

Overrides org.apache.poi.ddf.EscherRecord.getRecordId.

Return the current record id.

public String
getRecordName()

Implements abstract org.apache.poi.ddf.EscherRecord.getRecordName.

Subclasses should return the short name for this escher record.

public int
getRecordSize()

Implements abstract org.apache.poi.ddf.EscherRecord.getRecordSize.

Subclasses should effeciently return the number of bytes required to serialize the record.

public int

Returns:

A number that identifies this shape
getShapeId
()

public short

Returns:

shape type
getShapeType
()

Returns shape type.

public int

Returns:

The number of bytes written.
serialize
(int
The offset into data to start writing the record data to.
offset
,
byte[]
The byte array to serialize to.
data
,
EscherSerializationListener
A listener to retrieve start and end callbacks. Use a NullEscherSerailizationListener to ignore these events.
listener
)

Implements abstract org.apache.poi.ddf.EscherRecord.serialize.

This method serializes this escher record into a byte array.

public void
setFlags(int
the flags
field_2_flags
)

The flags that apply to this shape.

public void
setShapeId(int
the shape id
field_1_shapeId
)

Sets a number that identifies this shape.

public void
setShapeType(short
new shape type
value
)

Sets shape type.

Inherited from org.apache.poi.ddf.EscherRecord:
displayfillFieldsgetChildgetChildRecordsgetGenericChildrengetInstancegetOptionsgetVersionisContainerRecordreadHeaderreadInstanceserializeserializesetChildRecordssetInstancesetOptionssetRecordIdsetVersiontoStringtoXmltoXml

Field Detail

field_1_shapeIdback to summary
private int field_1_shapeId
field_2_flagsback to summary
private int field_2_flags
FLAG_BACKGROUNDback to summary
public static final int FLAG_BACKGROUND
FLAG_CHILDback to summary
public static final int FLAG_CHILD
FLAG_CONNECTORback to summary
public static final int FLAG_CONNECTOR
FLAG_DELETEDback to summary
public static final int FLAG_DELETED
FLAG_FLIPHORIZback to summary
public static final int FLAG_FLIPHORIZ
FLAG_FLIPVERTback to summary
public static final int FLAG_FLIPVERT
FLAG_GROUPback to summary
public static final int FLAG_GROUP
FLAG_HASSHAPETYPEback to summary
public static final int FLAG_HASSHAPETYPE
FLAG_HAVEANCHORback to summary
public static final int FLAG_HAVEANCHOR
FLAG_HAVEMASTERback to summary
public static final int FLAG_HAVEMASTER
FLAG_OLESHAPEback to summary
public static final int FLAG_OLESHAPE
FLAG_PATRIARCHback to summary
public static final int FLAG_PATRIARCH
FLAGS_MASKSback to summary
private static final int[] FLAGS_MASKS
FLAGS_NAMESback to summary
private static final String[] FLAGS_NAMES
RECORD_IDback to summary
public static final short RECORD_ID

Constructor Detail

EscherSpRecordback to summary
public EscherSpRecord()
EscherSpRecordback to summary
public EscherSpRecord(EscherSpRecord other)

Method Detail

copyback to summary
public EscherSpRecord copy()

Implements abstract org.apache.poi.ddf.EscherRecord.copy.

Implements org.apache.poi.common.Duplicatable.copy.

Returns:EscherSpRecord

Doc from org.apache.poi.common.Duplicatable.copy.

a deep copy of the implementing class / instance

Annotations
@Override
decodeFlagsback to summary
private String decodeFlags(int flags)

Converts the shape flags into a more descriptive name.

fillFieldsback to summary
public int fillFields(byte[] data, int offset, EscherRecordFactory recordFactory)

Implements abstract org.apache.poi.ddf.EscherRecord.fillFields.

Doc from org.apache.poi.ddf.EscherRecord.fillFields.

The contract of this method is to deserialize an escher record including its children.

Parameters
data:byte[]

The byte array containing the serialized escher records.

offset:int

The offset into the byte array.

recordFactory:EscherRecordFactory

A factory for creating new escher records.

Returns:int

The number of bytes written.

Annotations
@Override
getFlagsback to summary
public int getFlags()

The flags that apply to this shape.

Returns:int

the flags

See Also
FLAG_GROUP, FLAG_CHILD, FLAG_PATRIARCH, FLAG_DELETED, FLAG_OLESHAPE, FLAG_HAVEMASTER, FLAG_FLIPHORIZ, FLAG_FLIPVERT, FLAG_CONNECTOR, FLAG_HAVEANCHOR, FLAG_BACKGROUND, FLAG_HASSHAPETYPE
getGenericPropertiesback to summary
public Map<String, Supplier<?>> getGenericProperties()

Overrides org.apache.poi.ddf.EscherRecord.getGenericProperties.

Implements org.apache.poi.common.usermodel.GenericRecord.getGenericProperties.

Annotations
@Override
getGenericRecordTypeback to summary
public Enum<E extends Enum<E>> getGenericRecordType()

Overrides default org.apache.poi.common.usermodel.GenericRecord.getGenericRecordType.

Annotations
@Override
getRecordIdback to summary
public short getRecordId()

Overrides org.apache.poi.ddf.EscherRecord.getRecordId.

Doc from org.apache.poi.ddf.EscherRecord.getRecordId.

Return the current record id.

Returns:short

The 16 bit record id.

Annotations
@Override
getRecordNameback to summary
public String getRecordName()

Implements abstract org.apache.poi.ddf.EscherRecord.getRecordName.

Doc from org.apache.poi.ddf.EscherRecord.getRecordName.

Subclasses should return the short name for this escher record.

Returns:String

the short name for this escher record

Annotations
@Override
getRecordSizeback to summary
public int getRecordSize()

Implements abstract org.apache.poi.ddf.EscherRecord.getRecordSize.

Doc from org.apache.poi.ddf.EscherRecord.getRecordSize.

Subclasses should effeciently return the number of bytes required to serialize the record.

Returns:int

number of bytes

Annotations
@Override
getShapeIdback to summary
public int getShapeId()
Returns:int

A number that identifies this shape

getShapeTypeback to summary
public short getShapeType()

Returns shape type. Must be one of MSOSPT values (see [MS-ODRAW] for details).

Returns:short

shape type

serializeback to summary
public int serialize(int offset, byte[] data, EscherSerializationListener listener)

Implements abstract org.apache.poi.ddf.EscherRecord.serialize.

This method serializes this escher record into a byte array.

Parameters
offset:int

The offset into data to start writing the record data to.

data:byte[]

The byte array to serialize to.

listener:EscherSerializationListener

A listener to retrieve start and end callbacks. Use a NullEscherSerailizationListener to ignore these events.

Returns:int

The number of bytes written.

Annotations
@Override
See Also
NullEscherSerializationListener
setFlagsback to summary
public void setFlags(int field_2_flags)

The flags that apply to this shape.

Parameters
field_2_flags:int

the flags

See Also
FLAG_GROUP, FLAG_CHILD, FLAG_PATRIARCH, FLAG_DELETED, FLAG_OLESHAPE, FLAG_HAVEMASTER, FLAG_FLIPHORIZ, FLAG_FLIPVERT, FLAG_CONNECTOR, FLAG_HAVEANCHOR, FLAG_BACKGROUND, FLAG_HASSHAPETYPE
setShapeIdback to summary
public void setShapeId(int field_1_shapeId)

Sets a number that identifies this shape.

Parameters
field_1_shapeId:int

the shape id

setShapeTypeback to summary
public void setShapeType(short value)

Sets shape type. Must be one of MSOSPT values (see [MS-ODRAW] for details).

Parameters
value:short

new shape type