Package com.jogamp.gluegen.cgram.types
Class BitType
- java.lang.Object
-
- com.jogamp.gluegen.cgram.types.Type
-
- com.jogamp.gluegen.cgram.types.PrimitiveType
-
- com.jogamp.gluegen.cgram.types.IntType
-
- com.jogamp.gluegen.cgram.types.BitType
-
- All Implemented Interfaces:
ASTLocusTag.ASTLocusTagProvider
,TypeComparator.SemanticEqualityOp
,Cloneable
public class BitType extends IntType implements Cloneable
Represents a bitfield in a struct.
-
-
Field Summary
-
Fields inherited from class com.jogamp.gluegen.cgram.types.Type
relaxedEqSem
-
-
Constructor Summary
Constructors Constructor Description BitType(IntType underlyingType, int sizeInBits, int lsbOffset, int cvAttributes, ASTLocusTag astLocus)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description BitType
asBit()
Casts this to a BitType or returns null if not a BitType.protected boolean
equalSemanticsImpl(Type arg)
protected boolean
equalsImpl(Type arg)
int
getOffset()
Offset from the least-significant bit (LSB) of the LSB of this typeint
getSizeInBits()
Size in bits of this type.protected int
hashCodeImpl()
protected int
hashCodeSemanticsImpl()
void
visit(TypeVisitor arg)
Traverse thisType
and all of its component types; for example, the return type and argument types of a FunctionType.-
Methods inherited from class com.jogamp.gluegen.cgram.types.IntType
asInt, getCName, isUnsigned, setTypedefName, toString
-
Methods inherited from class com.jogamp.gluegen.cgram.types.PrimitiveType
isPrimitive
-
Methods inherited from class com.jogamp.gluegen.cgram.types.Type
arrayDimension, asArray, asCompound, asDouble, asEnum, asFloat, asFunction, asPointer, asVoid, clearCache, clone, equals, equalSemantics, getArrayBaseOrPointerTargetType, getASTLocusTag, getBaseType, getCName, getCVAttributes, getCVAttributesString, getDebugString, getName, getName, getSignature, getSize, getSize, getTargetFunction, getTargetType, hashCode, hashCodeSemantics, hasSize, isAnon, isArray, isBaseTypeConst, isBit, isCompound, isConst, isDouble, isEnum, isFloat, isFunction, isFunctionPointer, isInt, isPointer, isTypedef, isVoid, isVolatile, newCVVariant, pointerDepth
-
-
-
-
Constructor Detail
-
BitType
public BitType(IntType underlyingType, int sizeInBits, int lsbOffset, int cvAttributes, ASTLocusTag astLocus)
-
-
Method Detail
-
hashCodeImpl
protected int hashCodeImpl()
- Overrides:
hashCodeImpl
in classIntType
-
equalsImpl
protected boolean equalsImpl(Type arg)
- Overrides:
equalsImpl
in classIntType
-
hashCodeSemanticsImpl
protected int hashCodeSemanticsImpl()
- Overrides:
hashCodeSemanticsImpl
in classIntType
-
equalSemanticsImpl
protected boolean equalSemanticsImpl(Type arg)
- Overrides:
equalSemanticsImpl
in classIntType
-
asBit
public BitType asBit()
Description copied from class:Type
Casts this to a BitType or returns null if not a BitType.
-
getSizeInBits
public int getSizeInBits()
Size in bits of this type.
-
getOffset
public int getOffset()
Offset from the least-significant bit (LSB) of the LSB of this type
-
visit
public void visit(TypeVisitor arg)
Description copied from class:Type
Traverse thisType
and all of its component types; for example, the return type and argument types of a FunctionType.
-
-