Package com.jogamp.gluegen.cgram.types
Class Field
- java.lang.Object
-
- com.jogamp.gluegen.cgram.types.Field
-
- All Implemented Interfaces:
TypeComparator.SemanticEqualityOp
public class Field extends Object implements TypeComparator.SemanticEqualityOp
Represents a field in a struct or union.
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
equals(Object arg)
boolean
equalSemantics(TypeComparator.SemanticEqualityOp arg)
Semantic equality test for Types exclusive its givenname
.String
getName()
Name of this field in the containing data structure.SizeThunk
getOffset()
SizeThunk computing offset, in bytes, of this field in the containing data structure.long
getOffset(MachineDataInfo machDesc)
Offset, in bytes, of this field in the containing data structure given the specified MachineDataInfo.Type
getType()
Type of this field.int
hashCode()
int
hashCodeSemantics()
Semantic hashcode for Types exclusive its givenname
.void
setOffset(SizeThunk offset)
Sets the offset of this field in the containing data structure.String
toString()
-
-
-
Method Detail
-
hashCodeSemantics
public int hashCodeSemantics()
Description copied from interface:TypeComparator.SemanticEqualityOp
Semantic hashcode for Types exclusive its givenname
.- Specified by:
hashCodeSemantics
in interfaceTypeComparator.SemanticEqualityOp
- See Also:
TypeComparator.SemanticEqualityOp.equalSemantics(SemanticEqualityOp)
-
equalSemantics
public boolean equalSemantics(TypeComparator.SemanticEqualityOp arg)
Description copied from interface:TypeComparator.SemanticEqualityOp
Semantic equality test for Types exclusive its givenname
.- Specified by:
equalSemantics
in interfaceTypeComparator.SemanticEqualityOp
- See Also:
TypeComparator.SemanticEqualityOp.hashCodeSemantics()
-
getName
public String getName()
Name of this field in the containing data structure.
-
getType
public Type getType()
Type of this field.
-
getOffset
public SizeThunk getOffset()
SizeThunk computing offset, in bytes, of this field in the containing data structure.
-
getOffset
public long getOffset(MachineDataInfo machDesc)
Offset, in bytes, of this field in the containing data structure given the specified MachineDataInfo.
-
setOffset
public void setOffset(SizeThunk offset)
Sets the offset of this field in the containing data structure.
-
-