Top Description Inners Fields Constructors Methods
org.lwjgl.cuda

public Class CUlaunchAttribute

extends Struct<CUlaunchAttribute>
implements NativeResource
Class Inheritance
All Implemented Interfaces
org.lwjgl.system.NativeResource, java.lang.AutoCloseable
Imports
javax.annotation.*, java.nio.*, org.lwjgl.*, org.lwjgl.system.*

Layout


struct CUlaunchAttribute {
    CUlaunchAttributeID id;
    char pad[4];
    CUlaunchAttributeValue value;
}

Nested and Inner Type Summary

Modifier and TypeClass and Description
public static class

Field Summary

Modifier and TypeField and Description
public static final int
ALIGNOF

The struct alignment in bytes.

public static final int
ID

The struct member offsets.

public static final int
PAD

The struct member offsets.

public static final int
SIZEOF

The struct size in bytes.

public static final int
VALUE

The struct member offsets.

Inherited from org.lwjgl.system.Struct:
containerDEFAULT_ALIGN_ASDEFAULT_PACK_ALIGNMENT

Constructor Summary

AccessConstructor and Description
protected
CUlaunchAttribute(long address, ByteBuffer container)

public
CUlaunchAttribute(ByteBuffer container)

Creates a CUlaunchAttribute instance at the current position of the specified ByteBuffer container.

Method Summary

Modifier and TypeMethod and Description
public static CUlaunchAttribute
calloc()

Returns a new CUlaunchAttribute instance allocated with memCalloc.

public static CUlaunchAttribute.Buffer
calloc(int
the buffer capacity
capacity
)

Returns a new CUlaunchAttribute.Buffer instance allocated with memCalloc.

public static CUlaunchAttribute
calloc(MemoryStack
the stack from which to allocate
stack
)

Returns a new CUlaunchAttribute instance allocated on the specified MemoryStack and initializes all its bits to zero.

public static CUlaunchAttribute.Buffer
calloc(int
the buffer capacity
capacity
,
MemoryStack
the stack from which to allocate
stack
)

Returns a new CUlaunchAttribute.Buffer instance allocated on the specified MemoryStack and initializes all its bits to zero.

protected CUlaunchAttribute
create(long
the struct memory address
address
,
ByteBuffer
an optional container buffer, to be referenced strongly by the struct instance.
container
)

Implements abstract org.lwjgl.system.Struct.create.

Similar to the constructor, but returns the exact type of the Struct subclass.
public static CUlaunchAttribute
create()

Returns a new CUlaunchAttribute instance allocated with BufferUtils.

public static CUlaunchAttribute
create(long address)

Returns a new CUlaunchAttribute instance for the specified memory address.

public static CUlaunchAttribute.Buffer
create(int
the buffer capacity
capacity
)

Returns a new CUlaunchAttribute.Buffer instance allocated with BufferUtils.

public static CUlaunchAttribute.Buffer
create(long
the memory address
address
,
int
the buffer capacity
capacity
)

Create a CUlaunchAttribute.Buffer instance at the specified memory.

public static CUlaunchAttribute
createSafe(long address)

Like create, but returns null if address is NULL.

public static CUlaunchAttribute.Buffer
createSafe(long address, int capacity)

Like create, but returns null if address is NULL.

public int

Returns:

the value of the id field.
id
()

public CUlaunchAttribute
id(int value)

Sets the specified value to the id field.

public static CUlaunchAttribute
malloc()

Returns a new CUlaunchAttribute instance allocated with memAlloc.

public static CUlaunchAttribute.Buffer
malloc(int
the buffer capacity
capacity
)

Returns a new CUlaunchAttribute.Buffer instance allocated with memAlloc.

public static CUlaunchAttribute
malloc(MemoryStack
the stack from which to allocate
stack
)

Returns a new CUlaunchAttribute instance allocated on the specified MemoryStack.

public static CUlaunchAttribute.Buffer
malloc(int
the buffer capacity
capacity
,
MemoryStack
the stack from which to allocate
stack
)

Returns a new CUlaunchAttribute.Buffer instance allocated on the specified MemoryStack.

public static int
nid(long struct)

Unsafe version of id.

public static void
nid(long struct, int value)

Unsafe version of id.

public static ByteBuffer
npad(long struct)

Unsafe version of pad.

public static byte
npad(long struct, int index)

Unsafe version of pad.

public static void
npad(long struct, ByteBuffer value)

Unsafe version of pad.

public static void
npad(long struct, int index, byte value)

Unsafe version of pad.

public static CUlaunchAttributeValue
nvalue(long struct)

Unsafe version of value.

public static void
nvalue(long struct, CUlaunchAttributeValue value)

Unsafe version of value.

public ByteBuffer

Returns:

a ByteBuffer view of the pad field.
pad
()

public byte

Returns:

the value at the specified index of the pad field.
pad
(int index)

public CUlaunchAttribute
pad(ByteBuffer value)

Copies the specified ByteBuffer to the pad field.

public CUlaunchAttribute
pad(int index, byte value)

Sets the specified value at the specified index of the pad field.

public CUlaunchAttribute
set(int id, ByteBuffer pad, CUlaunchAttributeValue value)

Initializes this struct with the specified values.

public CUlaunchAttribute

Returns:

this struct
set
(CUlaunchAttribute
the source struct
src
)

Copies the specified struct data to this struct.

public int
sizeof()

Implements abstract org.lwjgl.system.Struct.sizeof.

Returns sizeof(struct).
public CUlaunchAttributeValue

Returns:

a CUlaunchAttributeValue view of the value field.
value
()

public CUlaunchAttribute
value(CUlaunchAttributeValue value)

Copies the specified CUlaunchAttributeValue to the value field.

public CUlaunchAttribute
value(Consumer<CUlaunchAttributeValue> consumer)

Passes the value field to the specified Consumer.

Inherited from org.lwjgl.system.Struct:
__array__array__array__checkContainer__checkMalloc__create__getContainer__getContainer__member__member__member__padding__padding__struct__struct__union__unionclearfreeisNullvalidate

Field Detail

ALIGNOFback to summary
public static final int ALIGNOF

The struct alignment in bytes.

IDback to summary
public static final int ID

The struct member offsets.

PADback to summary
public static final int PAD

The struct member offsets.

SIZEOFback to summary
public static final int SIZEOF

The struct size in bytes.

VALUEback to summary
public static final int VALUE

The struct member offsets.

Constructor Detail

CUlaunchAttributeback to summary
protected CUlaunchAttribute(long address, ByteBuffer container)
CUlaunchAttributeback to summary
public CUlaunchAttribute(ByteBuffer container)

Creates a CUlaunchAttribute instance at the current position of the specified ByteBuffer container. 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

callocback to summary
public static CUlaunchAttribute calloc()

Returns a new CUlaunchAttribute instance allocated with memCalloc. The instance must be explicitly freed.

callocback to summary
public static CUlaunchAttribute.Buffer calloc(int capacity)

Returns a new CUlaunchAttribute.Buffer instance allocated with memCalloc. The instance must be explicitly freed.

Parameters
capacity:int

the buffer capacity

callocback to summary
public static CUlaunchAttribute calloc(MemoryStack stack)

Returns a new CUlaunchAttribute instance allocated on the specified MemoryStack and initializes all its bits to zero.

Parameters
stack:MemoryStack

the stack from which to allocate

callocback to summary
public static CUlaunchAttribute.Buffer calloc(int capacity, MemoryStack stack)

Returns a new CUlaunchAttribute.Buffer instance allocated on the specified MemoryStack and initializes all its bits to zero.

Parameters
capacity:int

the buffer capacity

stack:MemoryStack

the stack from which to allocate

createback to summary
protected CUlaunchAttribute create(long address, ByteBuffer container)

Implements abstract org.lwjgl.system.Struct.create.

Doc from org.lwjgl.system.Struct.create.

Similar to the constructor, but returns the exact type of the Struct subclass.

Effectively, every Struct instance is a factory for more instances of the same type. This is used by StructBuffer.

Parameters
address:long

the struct memory address

container:ByteBuffer

an optional container buffer, to be referenced strongly by the struct instance.

Annotations
@Override
createback to summary
public static CUlaunchAttribute create()

Returns a new CUlaunchAttribute instance allocated with BufferUtils.

createback to summary
public static CUlaunchAttribute create(long address)

Returns a new CUlaunchAttribute instance for the specified memory address.

createback to summary
public static CUlaunchAttribute.Buffer create(int capacity)

Returns a new CUlaunchAttribute.Buffer instance allocated with BufferUtils.

Parameters
capacity:int

the buffer capacity

createback to summary
public static CUlaunchAttribute.Buffer create(long address, int capacity)

Create a CUlaunchAttribute.Buffer instance at the specified memory.

Parameters
address:long

the memory address

capacity:int

the buffer capacity

createSafeback to summary
public static CUlaunchAttribute createSafe(long address)

Like create, but returns null if address is NULL.

Annotations
@Nullable
createSafeback to summary
public static CUlaunchAttribute.Buffer createSafe(long address, int capacity)

Like create, but returns null if address is NULL.

Annotations
@Nullable
idback to summary
public int id()
Returns:int

the value of the id field.

Annotations
@NativeType:CUlaunchAttributeID
idback to summary
public CUlaunchAttribute id(int value)

Sets the specified value to the id field.

mallocback to summary
public static CUlaunchAttribute malloc()

Returns a new CUlaunchAttribute instance allocated with memAlloc. The instance must be explicitly freed.

mallocback to summary
public static CUlaunchAttribute.Buffer malloc(int capacity)

Returns a new CUlaunchAttribute.Buffer instance allocated with memAlloc. The instance must be explicitly freed.

Parameters
capacity:int

the buffer capacity

mallocback to summary
public static CUlaunchAttribute malloc(MemoryStack stack)

Returns a new CUlaunchAttribute instance allocated on the specified MemoryStack.

Parameters
stack:MemoryStack

the stack from which to allocate

mallocback to summary
public static CUlaunchAttribute.Buffer malloc(int capacity, MemoryStack stack)

Returns a new CUlaunchAttribute.Buffer instance allocated on the specified MemoryStack.

Parameters
capacity:int

the buffer capacity

stack:MemoryStack

the stack from which to allocate

nidback to summary
public static int nid(long struct)

Unsafe version of id.

nidback to summary
public static void nid(long struct, int value)

Unsafe version of id.

npadback to summary
public static ByteBuffer npad(long struct)

Unsafe version of pad.

npadback to summary
public static byte npad(long struct, int index)

Unsafe version of pad.

npadback to summary
public static void npad(long struct, ByteBuffer value)

Unsafe version of pad.

npadback to summary
public static void npad(long struct, int index, byte value)

Unsafe version of pad.

nvalueback to summary
public static CUlaunchAttributeValue nvalue(long struct)

Unsafe version of value.

nvalueback to summary
public static void nvalue(long struct, CUlaunchAttributeValue value)

Unsafe version of value.

padback to summary
public ByteBuffer pad()
Returns:ByteBuffer

a ByteBuffer view of the pad field.

Annotations
@NativeType:char[4]
padback to summary
public byte pad(int index)
Returns:byte

the value at the specified index of the pad field.

Annotations
@NativeType:char
padback to summary
public CUlaunchAttribute pad(ByteBuffer value)

Copies the specified ByteBuffer to the pad field.

padback to summary
public CUlaunchAttribute pad(int index, byte value)

Sets the specified value at the specified index of the pad field.

setback to summary
public CUlaunchAttribute set(int id, ByteBuffer pad, CUlaunchAttributeValue value)

Initializes this struct with the specified values.

setback to summary
public CUlaunchAttribute set(CUlaunchAttribute src)

Copies the specified struct data to this struct.

Parameters
src:CUlaunchAttribute

the source struct

Returns:CUlaunchAttribute

this struct

sizeofback to summary
public int sizeof()

Implements abstract org.lwjgl.system.Struct.sizeof.

Doc from org.lwjgl.system.Struct.sizeof.

Returns sizeof(struct).

Annotations
@Override
valueback to summary
public CUlaunchAttributeValue value()
Returns:CUlaunchAttributeValue

a CUlaunchAttributeValue view of the value field.

valueback to summary
public CUlaunchAttribute value(CUlaunchAttributeValue value)

Copies the specified CUlaunchAttributeValue to the value field.

valueback to summary
public CUlaunchAttribute value(Consumer<CUlaunchAttributeValue> consumer)

Passes the value field to the specified Consumer.

org.lwjgl.cuda back to summary

public Class CUlaunchAttribute.Buffer

extends StructBuffer<CUlaunchAttribute, CUlaunchAttribute.Buffer>
implements NativeResource
Class Inheritance
All Implemented Interfaces
org.lwjgl.system.NativeResource, java.lang.AutoCloseable

An array of CUlaunchAttribute structs.

Field Summary

Modifier and TypeField and Description
private static final CUlaunchAttribute

Constructor Summary

AccessConstructor and Description
public
Buffer(ByteBuffer container)

Creates a new CUlaunchAttribute.Buffer instance backed by the specified container.

public
Buffer(long address, int cap)

pack-priv
Buffer(long address, ByteBuffer container, int mark, int pos, int lim, int cap)

Method Summary

Modifier and TypeMethod and Description
protected CUlaunchAttribute
public int

Returns:

the value of the id field.
id
()

public CUlaunchAttribute.Buffer
id(int value)

Sets the specified value to the id field.

public ByteBuffer

Returns:

a ByteBuffer view of the pad field.
pad
()

public byte

Returns:

the value at the specified index of the pad field.
pad
(int index)

public CUlaunchAttribute.Buffer
pad(ByteBuffer value)

Copies the specified ByteBuffer to the pad field.

public CUlaunchAttribute.Buffer
pad(int index, byte value)

Sets the specified value at the specified index of the pad field.

protected CUlaunchAttribute.Buffer
public CUlaunchAttributeValue

Returns:

a CUlaunchAttributeValue view of the value field.
value
()

public CUlaunchAttribute.Buffer
value(CUlaunchAttributeValue value)

Copies the specified CUlaunchAttributeValue to the value field.

public CUlaunchAttribute.Buffer
value(Consumer<CUlaunchAttributeValue> consumer)

Passes the value field to the specified Consumer.

Inherited from org.lwjgl.system.StructBuffer:
applyapplyforEachgetgetgetgetiteratorparallelStreamputputsizeofspliteratorstream

Field Detail

ELEMENT_FACTORYback to summary
private static final CUlaunchAttribute ELEMENT_FACTORY

Constructor Detail

Bufferback to summary
public Buffer(ByteBuffer container)

Creates a new CUlaunchAttribute.Buffer instance backed by the specified container.

Changes to the container's content will be visible to the struct buffer instance and vice versa. The two buffers' position, limit, and mark values will be independent. The new buffer's position will be zero, its capacity and its limit will be the number of bytes remaining in this buffer divided by CUlaunchAttribute#SIZEOF, and its mark will be undefined.

The created buffer instance holds a strong reference to the container object.

Bufferback to summary
public Buffer(long address, int cap)
Bufferback to summary
pack-priv Buffer(long address, ByteBuffer container, int mark, int pos, int lim, int cap)

Method Detail

getElementFactoryback to summary
protected CUlaunchAttribute getElementFactory()

Implements abstract org.lwjgl.system.StructBuffer.getElementFactory.

Annotations
@Override
idback to summary
public int id()
Returns:int

the value of the id field.

Annotations
@NativeType:CUlaunchAttributeID
idback to summary
public CUlaunchAttribute.Buffer id(int value)

Sets the specified value to the id field.

padback to summary
public ByteBuffer pad()
Returns:ByteBuffer

a ByteBuffer view of the pad field.

Annotations
@NativeType:char[4]
padback to summary
public byte pad(int index)
Returns:byte

the value at the specified index of the pad field.

Annotations
@NativeType:char
padback to summary
public CUlaunchAttribute.Buffer pad(ByteBuffer value)

Copies the specified ByteBuffer to the pad field.

padback to summary
public CUlaunchAttribute.Buffer pad(int index, byte value)

Sets the specified value at the specified index of the pad field.

selfback to summary
protected CUlaunchAttribute.Buffer self()

Implements abstract org.lwjgl.system.CustomBuffer.self.

Annotations
@Override
valueback to summary
public CUlaunchAttributeValue value()
Returns:CUlaunchAttributeValue

a CUlaunchAttributeValue view of the value field.

valueback to summary
public CUlaunchAttribute.Buffer value(CUlaunchAttributeValue value)

Copies the specified CUlaunchAttributeValue to the value field.

valueback to summary
public CUlaunchAttribute.Buffer value(Consumer<CUlaunchAttributeValue> consumer)

Passes the value field to the specified Consumer.