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 |
ResouceBlockMeSaSignature
The resource signature of ImageReady.
|
static int |
ResouceBlockSignature
The regular Photoshop 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(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 ResouceBlockSignature
The regular Photoshop resource signature.
public static final int ResouceBlockMeSaSignature
The resource signature of ImageReady.
public final int getSignature()
Gets the resource signature. Should be always '8BIM'.
Value: The resource signature.public final short getID()
Gets or sets the unique identifier for the resource.
Value: The unique identifier for the resource.public final void setID(short value)
Gets or sets the unique identifier for the resource.
Value: The unique identifier for the resource.public final 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).
Value: The resource name.public final 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.
Value: The resource data size.public final int getSize()
Gets the resource block size in bytes including its data.
Value: The resource block size.public abstract int getMinimalVersion()
Gets the minimal required PSD version.
Value: The minimal PSD version.public final void save(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.