public abstract class ResourceBlock extends Object
The resource block.
Modifier and Type | Class and Description |
---|---|
static class |
ResourceBlock.ResourceBlockState
Represents resource block state.
|
Modifier and Type | Field and Description |
---|---|
static int |
RESOUCE_BLOCK_SIGNATURE
The resource signature.
|
Constructor and Description |
---|
ResourceBlock() |
Modifier and Type | Method and Description |
---|---|
abstract int |
getDataSize()
Gets the resource data size in bytes.
|
short |
getID()
Gets or sets the unique identifier for the resource.
|
abstract int |
getMinimalVersion()
Gets the minimal required PSD version.
|
String |
getName()
Gets or sets the resource name.
|
int |
getSignature()
Gets the resource signature.
|
int |
getSize()
Gets the resource block size in bytes including its data.
|
void |
save(com.aspose.cad.StreamContainer stream)
Saves the resource block to the specified stream.
|
void |
setID(short value)
Gets or sets the unique identifier for the resource.
|
void |
setName(String value)
Gets or sets the resource name.
|
void |
validateValues()
Validates the resource values.
|
public static final int RESOUCE_BLOCK_SIGNATURE
The resource signature.
public int getSignature()
Gets the resource signature. Should be always '8BIM'.
public short getID()
Gets or sets the unique identifier for the resource.
public void setID(short value)
Gets or sets the unique identifier for the resource.
value
- The unique identifier for the resource.public String getName()
Gets or sets the resource name. Pascal string, padded to make the size even (a null name consists of two bytes of 0).
public void setName(String value)
Gets or sets the resource name. Pascal string, padded to make the size even (a null name consists of two bytes of 0).
value
- The resource name.public abstract int getDataSize()
Gets the resource data size in bytes.
public int getSize()
Gets the resource block size in bytes including its data.
public abstract int getMinimalVersion()
Gets the minimal required PSD version.
public void save(com.aspose.cad.StreamContainer stream)
Saves the resource block to the specified stream.
stream
- The stream to save the resource block to.public void validateValues()
Validates the resource values.