public interface IField
Database. Holds metadata for that field
and permits laziy initialization of the field offset. Fields are normally instantiated as static
variables. Collectively, they describe the database schema but they are not associated with any
particular instance of data in the database.
Fields are temporarily mutable. On construction, a number of attributes (such as offset) are
computed in a second pass or are initialized as other fields are constructed. Generally such
attributes can't be computed in the constructor since they depend on knowledge of other fields
that must be instantiated first. However, once StructDef.done() has been called on the
last StructDef, fields are immutable and should not ever be modified again.
| Modifier and Type | Method and Description |
|---|---|
default int |
getAlignment()
Returns the required byte alignment for the field.
|
java.lang.String |
getFieldName()
Returns the name of the field.
|
int |
getOffset()
Returns the field offset, in bytes from the start of the struct.
|
int |
getRecordSize()
Returns the size of the field, in bytes.
|
void |
setOffset(int offset)
Sets the field offset (bytes from the start of the struct).
|
void setOffset(int offset)
int getRecordSize()
default int getAlignment()
java.lang.String getFieldName()
int getOffset()