Package org.lwjgl.system.macosx
Class ObjCPropertyAttribute
- java.lang.Object
-
- org.lwjgl.system.Pointer.Default
-
- org.lwjgl.system.Struct
-
- org.lwjgl.system.macosx.ObjCPropertyAttribute
-
- All Implemented Interfaces:
java.lang.AutoCloseable,NativeResource,Pointer
public class ObjCPropertyAttribute extends Struct implements NativeResource
Defines a property attribute.Member documentation
name– the name of the attributevalue– the value of the attribute (usually empty)
Layout
struct objc_property_attribute_t { char * name; char * value; }
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classObjCPropertyAttribute.BufferAn array ofObjCPropertyAttributestructs.-
Nested classes/interfaces inherited from interface org.lwjgl.system.Pointer
Pointer.Default
-
-
Field Summary
Fields Modifier and Type Field Description static intALIGNOFThe struct alignment in bytes.static intNAMEThe struct member offsets.static intSIZEOFThe struct size in bytes.static intVALUEThe struct member offsets.-
Fields inherited from interface org.lwjgl.system.Pointer
BITS32, BITS64, CLONG_SHIFT, CLONG_SIZE, POINTER_SHIFT, POINTER_SIZE
-
-
Constructor Summary
Constructors Constructor Description ObjCPropertyAttribute(java.nio.ByteBuffer container)Creates aObjCPropertyAttributeinstance at the current position of the specifiedByteBuffercontainer.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static ObjCPropertyAttributecalloc()Returns a newObjCPropertyAttributeinstance allocated withmemCalloc.static ObjCPropertyAttribute.Buffercalloc(int capacity)Returns a newObjCPropertyAttribute.Bufferinstance allocated withmemCalloc.static ObjCPropertyAttributecallocStack()Returns a newObjCPropertyAttributeinstance allocated on the thread-localMemoryStackand initializes all its bits to zero.static ObjCPropertyAttribute.BuffercallocStack(int capacity)Returns a newObjCPropertyAttribute.Bufferinstance allocated on the thread-localMemoryStackand initializes all its bits to zero.static ObjCPropertyAttribute.BuffercallocStack(int capacity, MemoryStack stack)Returns a newObjCPropertyAttribute.Bufferinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.static ObjCPropertyAttributecallocStack(MemoryStack stack)Returns a newObjCPropertyAttributeinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.static ObjCPropertyAttributecreate()Returns a newObjCPropertyAttributeinstance allocated withBufferUtils.static ObjCPropertyAttribute.Buffercreate(int capacity)Returns a newObjCPropertyAttribute.Bufferinstance allocated withBufferUtils.static ObjCPropertyAttributecreate(long address)Returns a newObjCPropertyAttributeinstance for the specified memory address.static ObjCPropertyAttribute.Buffercreate(long address, int capacity)Create aObjCPropertyAttribute.Bufferinstance at the specified memory.static ObjCPropertyAttributecreateSafe(long address)static ObjCPropertyAttribute.BuffercreateSafe(long address, int capacity)static ObjCPropertyAttributemalloc()Returns a newObjCPropertyAttributeinstance allocated withmemAlloc.static ObjCPropertyAttribute.Buffermalloc(int capacity)Returns a newObjCPropertyAttribute.Bufferinstance allocated withmemAlloc.static ObjCPropertyAttributemallocStack()Returns a newObjCPropertyAttributeinstance allocated on the thread-localMemoryStack.static ObjCPropertyAttribute.BuffermallocStack(int capacity)Returns a newObjCPropertyAttribute.Bufferinstance allocated on the thread-localMemoryStack.static ObjCPropertyAttribute.BuffermallocStack(int capacity, MemoryStack stack)Returns a newObjCPropertyAttribute.Bufferinstance allocated on the specifiedMemoryStack.static ObjCPropertyAttributemallocStack(MemoryStack stack)Returns a newObjCPropertyAttributeinstance allocated on the specifiedMemoryStack.java.nio.ByteBuffername()Returns aByteBufferview of the null-terminated string pointed to by thenamefield.ObjCPropertyAttributename(java.nio.ByteBuffer value)Sets the address of the specified encoded string to thenamefield.java.lang.StringnameString()Decodes the null-terminated string pointed to by thenamefield.static java.nio.ByteBuffernname(long struct)Unsafe version ofname().static voidnname(long struct, java.nio.ByteBuffer value)Unsafe version ofname.static java.lang.StringnnameString(long struct)Unsafe version ofnameString().static java.nio.ByteBuffernvalue(long struct)Unsafe version ofvalue().static voidnvalue(long struct, java.nio.ByteBuffer value)Unsafe version ofvalue.static java.lang.StringnvalueString(long struct)Unsafe version ofvalueString().ObjCPropertyAttributeset(java.nio.ByteBuffer name, java.nio.ByteBuffer value)Initializes this struct with the specified values.ObjCPropertyAttributeset(ObjCPropertyAttribute src)Copies the specified struct data to this struct.intsizeof()Returnssizeof(struct).static voidvalidate(long struct)Validates pointer members that should not beNULL.static voidvalidate(long array, int count)Callsvalidate(long)for each struct contained in the specified struct array.java.nio.ByteBuffervalue()Returns aByteBufferview of the null-terminated string pointed to by thevaluefield.ObjCPropertyAttributevalue(java.nio.ByteBuffer value)Sets the address of the specified encoded string to thevaluefield.java.lang.StringvalueString()Decodes the null-terminated string pointed to by thevaluefield.-
Methods inherited from interface org.lwjgl.system.NativeResource
close, free
-
Methods inherited from class org.lwjgl.system.Pointer.Default
address, equals, hashCode, toString
-
-
-
-
Constructor Detail
-
ObjCPropertyAttribute
public ObjCPropertyAttribute(java.nio.ByteBuffer container)
Creates aObjCPropertyAttributeinstance at the current position of the specifiedByteBuffercontainer. Changes to the buffer's content will be visible to the struct instance and vice versa.The created instance holds a strong reference to the container object.
-
-
Method Detail
-
sizeof
public int sizeof()
Description copied from class:StructReturnssizeof(struct).
-
name
public java.nio.ByteBuffer name()
Returns aByteBufferview of the null-terminated string pointed to by thenamefield.
-
nameString
public java.lang.String nameString()
Decodes the null-terminated string pointed to by thenamefield.
-
value
public java.nio.ByteBuffer value()
Returns aByteBufferview of the null-terminated string pointed to by thevaluefield.
-
valueString
public java.lang.String valueString()
Decodes the null-terminated string pointed to by thevaluefield.
-
name
public ObjCPropertyAttribute name(java.nio.ByteBuffer value)
Sets the address of the specified encoded string to thenamefield.
-
value
public ObjCPropertyAttribute value(java.nio.ByteBuffer value)
Sets the address of the specified encoded string to thevaluefield.
-
set
public ObjCPropertyAttribute set(java.nio.ByteBuffer name, java.nio.ByteBuffer value)
Initializes this struct with the specified values.
-
set
public ObjCPropertyAttribute set(ObjCPropertyAttribute src)
Copies the specified struct data to this struct.- Parameters:
src- the source struct- Returns:
- this struct
-
malloc
public static ObjCPropertyAttribute malloc()
Returns a newObjCPropertyAttributeinstance allocated withmemAlloc. The instance must be explicitly freed.
-
calloc
public static ObjCPropertyAttribute calloc()
Returns a newObjCPropertyAttributeinstance allocated withmemCalloc. The instance must be explicitly freed.
-
create
public static ObjCPropertyAttribute create()
Returns a newObjCPropertyAttributeinstance allocated withBufferUtils.
-
create
public static ObjCPropertyAttribute create(long address)
Returns a newObjCPropertyAttributeinstance for the specified memory address.
-
createSafe
@Nullable public static ObjCPropertyAttribute createSafe(long address)
-
malloc
public static ObjCPropertyAttribute.Buffer malloc(int capacity)
Returns a newObjCPropertyAttribute.Bufferinstance allocated withmemAlloc. The instance must be explicitly freed.- Parameters:
capacity- the buffer capacity
-
calloc
public static ObjCPropertyAttribute.Buffer calloc(int capacity)
Returns a newObjCPropertyAttribute.Bufferinstance allocated withmemCalloc. The instance must be explicitly freed.- Parameters:
capacity- the buffer capacity
-
create
public static ObjCPropertyAttribute.Buffer create(int capacity)
Returns a newObjCPropertyAttribute.Bufferinstance allocated withBufferUtils.- Parameters:
capacity- the buffer capacity
-
create
public static ObjCPropertyAttribute.Buffer create(long address, int capacity)
Create aObjCPropertyAttribute.Bufferinstance at the specified memory.- Parameters:
address- the memory addresscapacity- the buffer capacity
-
createSafe
@Nullable public static ObjCPropertyAttribute.Buffer createSafe(long address, int capacity)
-
mallocStack
public static ObjCPropertyAttribute mallocStack()
Returns a newObjCPropertyAttributeinstance allocated on the thread-localMemoryStack.
-
callocStack
public static ObjCPropertyAttribute callocStack()
Returns a newObjCPropertyAttributeinstance allocated on the thread-localMemoryStackand initializes all its bits to zero.
-
mallocStack
public static ObjCPropertyAttribute mallocStack(MemoryStack stack)
Returns a newObjCPropertyAttributeinstance allocated on the specifiedMemoryStack.- Parameters:
stack- the stack from which to allocate
-
callocStack
public static ObjCPropertyAttribute callocStack(MemoryStack stack)
Returns a newObjCPropertyAttributeinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.- Parameters:
stack- the stack from which to allocate
-
mallocStack
public static ObjCPropertyAttribute.Buffer mallocStack(int capacity)
Returns a newObjCPropertyAttribute.Bufferinstance allocated on the thread-localMemoryStack.- Parameters:
capacity- the buffer capacity
-
callocStack
public static ObjCPropertyAttribute.Buffer callocStack(int capacity)
Returns a newObjCPropertyAttribute.Bufferinstance allocated on the thread-localMemoryStackand initializes all its bits to zero.- Parameters:
capacity- the buffer capacity
-
mallocStack
public static ObjCPropertyAttribute.Buffer mallocStack(int capacity, MemoryStack stack)
Returns a newObjCPropertyAttribute.Bufferinstance allocated on the specifiedMemoryStack.- Parameters:
stack- the stack from which to allocatecapacity- the buffer capacity
-
callocStack
public static ObjCPropertyAttribute.Buffer callocStack(int capacity, MemoryStack stack)
Returns a newObjCPropertyAttribute.Bufferinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.- Parameters:
stack- the stack from which to allocatecapacity- the buffer capacity
-
nname
public static java.nio.ByteBuffer nname(long struct)
Unsafe version ofname().
-
nnameString
public static java.lang.String nnameString(long struct)
Unsafe version ofnameString().
-
nvalue
public static java.nio.ByteBuffer nvalue(long struct)
Unsafe version ofvalue().
-
nvalueString
public static java.lang.String nvalueString(long struct)
Unsafe version ofvalueString().
-
nname
public static void nname(long struct, java.nio.ByteBuffer value)Unsafe version ofname.
-
nvalue
public static void nvalue(long struct, java.nio.ByteBuffer value)Unsafe version ofvalue.
-
validate
public static void validate(long struct)
Validates pointer members that should not beNULL.- Parameters:
struct- the struct to validate
-
validate
public static void validate(long array, int count)Callsvalidate(long)for each struct contained in the specified struct array.- Parameters:
array- the struct array to validatecount- the number of structs inarray
-
-