Package org.lwjgl.llvm
Class CXSourceRange
- java.lang.Object
-
- org.lwjgl.system.Pointer.Default
-
- org.lwjgl.system.Struct
-
- org.lwjgl.llvm.CXSourceRange
-
- All Implemented Interfaces:
java.lang.AutoCloseable
,org.lwjgl.system.NativeResource
,org.lwjgl.system.Pointer
public class CXSourceRange extends org.lwjgl.system.Struct implements org.lwjgl.system.NativeResource
Identifies a half-open character range in the source code.Use
getRangeStart
andgetRangeEnd
to retrieve the starting and end locations from a source range, respectively.Layout
struct CXSourceRange { void const * ptr_data[2]; unsigned begin_int_data; unsigned end_int_data; }
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
CXSourceRange.Buffer
An array ofCXSourceRange
structs.
-
Field Summary
Fields Modifier and Type Field Description static int
ALIGNOF
The struct alignment in bytes.static int
BEGIN_INT_DATA
END_INT_DATA
PTR_DATAThe struct member offsets.static int
SIZEOF
The struct size in bytes.
-
Constructor Summary
Constructors Constructor Description CXSourceRange(java.nio.ByteBuffer container)
Creates aCXSourceRange
instance at the current position of the specifiedByteBuffer
container.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description int
begin_int_data()
Returns the value of thebegin_int_data
field.static CXSourceRange
calloc()
Returns a newCXSourceRange
instance allocated withmemCalloc
.static CXSourceRange.Buffer
calloc(int capacity)
Returns a newCXSourceRange.Buffer
instance allocated withmemCalloc
.static CXSourceRange
callocStack()
Returns a newCXSourceRange
instance allocated on the thread-localMemoryStack
and initializes all its bits to zero.static CXSourceRange.Buffer
callocStack(int capacity)
Returns a newCXSourceRange.Buffer
instance allocated on the thread-localMemoryStack
and initializes all its bits to zero.static CXSourceRange.Buffer
callocStack(int capacity, org.lwjgl.system.MemoryStack stack)
Returns a newCXSourceRange.Buffer
instance allocated on the specifiedMemoryStack
and initializes all its bits to zero.static CXSourceRange
callocStack(org.lwjgl.system.MemoryStack stack)
Returns a newCXSourceRange
instance allocated on the specifiedMemoryStack
and initializes all its bits to zero.static CXSourceRange
create()
Returns a newCXSourceRange
instance allocated withBufferUtils
.static CXSourceRange.Buffer
create(int capacity)
Returns a newCXSourceRange.Buffer
instance allocated withBufferUtils
.static CXSourceRange
create(long address)
Returns a newCXSourceRange
instance for the specified memory address.static CXSourceRange.Buffer
create(long address, int capacity)
Create aCXSourceRange.Buffer
instance at the specified memory.static CXSourceRange
createSafe(long address)
static CXSourceRange.Buffer
createSafe(long address, int capacity)
int
end_int_data()
Returns the value of theend_int_data
field.static CXSourceRange
malloc()
Returns a newCXSourceRange
instance allocated withmemAlloc
.static CXSourceRange.Buffer
malloc(int capacity)
Returns a newCXSourceRange.Buffer
instance allocated withmemAlloc
.static CXSourceRange
mallocStack()
Returns a newCXSourceRange
instance allocated on the thread-localMemoryStack
.static CXSourceRange.Buffer
mallocStack(int capacity)
Returns a newCXSourceRange.Buffer
instance allocated on the thread-localMemoryStack
.static CXSourceRange.Buffer
mallocStack(int capacity, org.lwjgl.system.MemoryStack stack)
Returns a newCXSourceRange.Buffer
instance allocated on the specifiedMemoryStack
.static CXSourceRange
mallocStack(org.lwjgl.system.MemoryStack stack)
Returns a newCXSourceRange
instance allocated on the specifiedMemoryStack
.static int
nbegin_int_data(long struct)
Unsafe version ofbegin_int_data()
.static int
nend_int_data(long struct)
Unsafe version ofend_int_data()
.static org.lwjgl.PointerBuffer
nptr_data(long struct)
Unsafe version ofptr_data()
.static long
nptr_data(long struct, int index)
Unsafe version ofptr_data
.org.lwjgl.PointerBuffer
ptr_data()
Returns aPointerBuffer
view of theptr_data
field.long
ptr_data(int index)
Returns the value at the specified index of theptr_data
field.int
sizeof()
-
-
-
Constructor Detail
-
CXSourceRange
public CXSourceRange(java.nio.ByteBuffer container)
Creates aCXSourceRange
instance at the current position of the specifiedByteBuffer
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
-
sizeof
public int sizeof()
- Specified by:
sizeof
in classorg.lwjgl.system.Struct
-
ptr_data
public org.lwjgl.PointerBuffer ptr_data()
Returns aPointerBuffer
view of theptr_data
field.
-
ptr_data
public long ptr_data(int index)
Returns the value at the specified index of theptr_data
field.
-
begin_int_data
public int begin_int_data()
Returns the value of thebegin_int_data
field.
-
end_int_data
public int end_int_data()
Returns the value of theend_int_data
field.
-
malloc
public static CXSourceRange malloc()
Returns a newCXSourceRange
instance allocated withmemAlloc
. The instance must be explicitly freed.
-
calloc
public static CXSourceRange calloc()
Returns a newCXSourceRange
instance allocated withmemCalloc
. The instance must be explicitly freed.
-
create
public static CXSourceRange create()
Returns a newCXSourceRange
instance allocated withBufferUtils
.
-
create
public static CXSourceRange create(long address)
Returns a newCXSourceRange
instance for the specified memory address.
-
createSafe
@Nullable public static CXSourceRange createSafe(long address)
-
malloc
public static CXSourceRange.Buffer malloc(int capacity)
Returns a newCXSourceRange.Buffer
instance allocated withmemAlloc
. The instance must be explicitly freed.- Parameters:
capacity
- the buffer capacity
-
calloc
public static CXSourceRange.Buffer calloc(int capacity)
Returns a newCXSourceRange.Buffer
instance allocated withmemCalloc
. The instance must be explicitly freed.- Parameters:
capacity
- the buffer capacity
-
create
public static CXSourceRange.Buffer create(int capacity)
Returns a newCXSourceRange.Buffer
instance allocated withBufferUtils
.- Parameters:
capacity
- the buffer capacity
-
create
public static CXSourceRange.Buffer create(long address, int capacity)
Create aCXSourceRange.Buffer
instance at the specified memory.- Parameters:
address
- the memory addresscapacity
- the buffer capacity
-
createSafe
@Nullable public static CXSourceRange.Buffer createSafe(long address, int capacity)
-
mallocStack
public static CXSourceRange mallocStack()
Returns a newCXSourceRange
instance allocated on the thread-localMemoryStack
.
-
callocStack
public static CXSourceRange callocStack()
Returns a newCXSourceRange
instance allocated on the thread-localMemoryStack
and initializes all its bits to zero.
-
mallocStack
public static CXSourceRange mallocStack(org.lwjgl.system.MemoryStack stack)
Returns a newCXSourceRange
instance allocated on the specifiedMemoryStack
.- Parameters:
stack
- the stack from which to allocate
-
callocStack
public static CXSourceRange callocStack(org.lwjgl.system.MemoryStack stack)
Returns a newCXSourceRange
instance allocated on the specifiedMemoryStack
and initializes all its bits to zero.- Parameters:
stack
- the stack from which to allocate
-
mallocStack
public static CXSourceRange.Buffer mallocStack(int capacity)
Returns a newCXSourceRange.Buffer
instance allocated on the thread-localMemoryStack
.- Parameters:
capacity
- the buffer capacity
-
callocStack
public static CXSourceRange.Buffer callocStack(int capacity)
Returns a newCXSourceRange.Buffer
instance allocated on the thread-localMemoryStack
and initializes all its bits to zero.- Parameters:
capacity
- the buffer capacity
-
mallocStack
public static CXSourceRange.Buffer mallocStack(int capacity, org.lwjgl.system.MemoryStack stack)
Returns a newCXSourceRange.Buffer
instance allocated on the specifiedMemoryStack
.- Parameters:
stack
- the stack from which to allocatecapacity
- the buffer capacity
-
callocStack
public static CXSourceRange.Buffer callocStack(int capacity, org.lwjgl.system.MemoryStack stack)
Returns a newCXSourceRange.Buffer
instance allocated on the specifiedMemoryStack
and initializes all its bits to zero.- Parameters:
stack
- the stack from which to allocatecapacity
- the buffer capacity
-
nptr_data
public static org.lwjgl.PointerBuffer nptr_data(long struct)
Unsafe version ofptr_data()
.
-
nptr_data
public static long nptr_data(long struct, int index)
Unsafe version ofptr_data
.
-
nbegin_int_data
public static int nbegin_int_data(long struct)
Unsafe version ofbegin_int_data()
.
-
nend_int_data
public static int nend_int_data(long struct)
Unsafe version ofend_int_data()
.
-
-