public class SQL_NUMERIC_STRUCT
extends org.lwjgl.system.Struct
implements org.lwjgl.system.NativeResource
struct SQL_NUMERIC_STRUCT {
SQLCHAR precision;
SQLSCHAR scale;
SQLCHAR sign;
SQLCHAR val[SQL_MAX_NUMERIC_LEN];
}| Modifier and Type | Class and Description |
|---|---|
static class |
SQL_NUMERIC_STRUCT.Buffer
An array of
SQL_NUMERIC_STRUCT structs. |
| Modifier and Type | Field and Description |
|---|---|
static int |
ALIGNOF
The struct alignment in bytes.
|
static int |
PRECISION
The struct member offsets.
|
static int |
SCALE
The struct member offsets.
|
static int |
SIGN
The struct member offsets.
|
static int |
SIZEOF
The struct size in bytes.
|
static int |
VAL
The struct member offsets.
|
| Constructor and Description |
|---|
SQL_NUMERIC_STRUCT(java.nio.ByteBuffer container)
Creates a
SQL_NUMERIC_STRUCT instance at the current position of the specified ByteBuffer container. |
| Modifier and Type | Method and Description |
|---|---|
static SQL_NUMERIC_STRUCT |
calloc()
Returns a new
SQL_NUMERIC_STRUCT instance allocated with memCalloc. |
static SQL_NUMERIC_STRUCT.Buffer |
calloc(int capacity)
Returns a new
SQL_NUMERIC_STRUCT.Buffer instance allocated with memCalloc. |
static SQL_NUMERIC_STRUCT |
callocStack()
Returns a new
SQL_NUMERIC_STRUCT instance allocated on the thread-local MemoryStack and initializes all its bits to zero. |
static SQL_NUMERIC_STRUCT.Buffer |
callocStack(int capacity)
Returns a new
SQL_NUMERIC_STRUCT.Buffer instance allocated on the thread-local MemoryStack and initializes all its bits to zero. |
static SQL_NUMERIC_STRUCT.Buffer |
callocStack(int capacity,
org.lwjgl.system.MemoryStack stack)
Returns a new
SQL_NUMERIC_STRUCT.Buffer instance allocated on the specified MemoryStack and initializes all its bits to zero. |
static SQL_NUMERIC_STRUCT |
callocStack(org.lwjgl.system.MemoryStack stack)
Returns a new
SQL_NUMERIC_STRUCT instance allocated on the specified MemoryStack and initializes all its bits to zero. |
static SQL_NUMERIC_STRUCT |
create()
Returns a new
SQL_NUMERIC_STRUCT instance allocated with BufferUtils. |
static SQL_NUMERIC_STRUCT.Buffer |
create(int capacity)
Returns a new
SQL_NUMERIC_STRUCT.Buffer instance allocated with BufferUtils. |
static SQL_NUMERIC_STRUCT |
create(long address)
Returns a new
SQL_NUMERIC_STRUCT instance for the specified memory address. |
static SQL_NUMERIC_STRUCT.Buffer |
create(long address,
int capacity)
Create a
SQL_NUMERIC_STRUCT.Buffer instance at the specified memory. |
static SQL_NUMERIC_STRUCT |
createSafe(long address)
|
static SQL_NUMERIC_STRUCT.Buffer |
createSafe(long address,
int capacity)
|
static SQL_NUMERIC_STRUCT |
malloc()
Returns a new
SQL_NUMERIC_STRUCT instance allocated with memAlloc. |
static SQL_NUMERIC_STRUCT.Buffer |
malloc(int capacity)
Returns a new
SQL_NUMERIC_STRUCT.Buffer instance allocated with memAlloc. |
static SQL_NUMERIC_STRUCT |
mallocStack()
Returns a new
SQL_NUMERIC_STRUCT instance allocated on the thread-local MemoryStack. |
static SQL_NUMERIC_STRUCT.Buffer |
mallocStack(int capacity)
Returns a new
SQL_NUMERIC_STRUCT.Buffer instance allocated on the thread-local MemoryStack. |
static SQL_NUMERIC_STRUCT.Buffer |
mallocStack(int capacity,
org.lwjgl.system.MemoryStack stack)
Returns a new
SQL_NUMERIC_STRUCT.Buffer instance allocated on the specified MemoryStack. |
static SQL_NUMERIC_STRUCT |
mallocStack(org.lwjgl.system.MemoryStack stack)
Returns a new
SQL_NUMERIC_STRUCT instance allocated on the specified MemoryStack. |
static byte |
nprecision(long struct)
Unsafe version of
precision(). |
static void |
nprecision(long struct,
byte value)
Unsafe version of
precision. |
static byte |
nscale(long struct)
Unsafe version of
scale(). |
static void |
nscale(long struct,
byte value)
Unsafe version of
scale. |
static byte |
nsign(long struct)
Unsafe version of
sign(). |
static void |
nsign(long struct,
byte value)
Unsafe version of
sign. |
static java.nio.ByteBuffer |
nval(long struct)
Unsafe version of
val(). |
static void |
nval(long struct,
java.nio.ByteBuffer value)
Unsafe version of
val. |
static byte |
nval(long struct,
int index)
Unsafe version of
val. |
static void |
nval(long struct,
int index,
byte value)
Unsafe version of
val. |
byte |
precision()
Returns the value of the
precision field. |
SQL_NUMERIC_STRUCT |
precision(byte value)
Sets the specified value to the
precision field. |
byte |
scale()
Returns the value of the
scale field. |
SQL_NUMERIC_STRUCT |
scale(byte value)
Sets the specified value to the
scale field. |
SQL_NUMERIC_STRUCT |
set(byte precision,
byte scale,
byte sign,
java.nio.ByteBuffer val)
Initializes this struct with the specified values.
|
SQL_NUMERIC_STRUCT |
set(SQL_NUMERIC_STRUCT src)
Copies the specified struct data to this struct.
|
byte |
sign()
Returns the value of the
sign field. |
SQL_NUMERIC_STRUCT |
sign(byte value)
Sets the specified value to the
sign field. |
int |
sizeof() |
java.nio.ByteBuffer |
val()
Returns a
ByteBuffer view of the val field. |
SQL_NUMERIC_STRUCT |
val(java.nio.ByteBuffer value)
Copies the specified
ByteBuffer to the val field. |
byte |
val(int index)
Returns the value at the specified index of the
val field. |
SQL_NUMERIC_STRUCT |
val(int index,
byte value)
Sets the specified value at the specified index of the
val field. |
public static final int SIZEOF
public static final int ALIGNOF
public static final int PRECISION
public static final int SCALE
public static final int SIGN
public static final int VAL
public SQL_NUMERIC_STRUCT(java.nio.ByteBuffer container)
SQL_NUMERIC_STRUCT 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.
public int sizeof()
sizeof in class org.lwjgl.system.Structpublic byte precision()
precision field.public byte scale()
scale field.public byte sign()
sign field.public java.nio.ByteBuffer val()
ByteBuffer view of the val field.public byte val(int index)
val field.public SQL_NUMERIC_STRUCT precision(byte value)
precision field.public SQL_NUMERIC_STRUCT scale(byte value)
scale field.public SQL_NUMERIC_STRUCT sign(byte value)
sign field.public SQL_NUMERIC_STRUCT val(java.nio.ByteBuffer value)
ByteBuffer to the val field.public SQL_NUMERIC_STRUCT val(int index, byte value)
val field.public SQL_NUMERIC_STRUCT set(byte precision, byte scale, byte sign, java.nio.ByteBuffer val)
public SQL_NUMERIC_STRUCT set(SQL_NUMERIC_STRUCT src)
src - the source structpublic static SQL_NUMERIC_STRUCT malloc()
SQL_NUMERIC_STRUCT instance allocated with memAlloc. The instance must be explicitly freed.public static SQL_NUMERIC_STRUCT calloc()
SQL_NUMERIC_STRUCT instance allocated with memCalloc. The instance must be explicitly freed.public static SQL_NUMERIC_STRUCT create()
SQL_NUMERIC_STRUCT instance allocated with BufferUtils.public static SQL_NUMERIC_STRUCT create(long address)
SQL_NUMERIC_STRUCT instance for the specified memory address.@Nullable public static SQL_NUMERIC_STRUCT createSafe(long address)
public static SQL_NUMERIC_STRUCT.Buffer malloc(int capacity)
SQL_NUMERIC_STRUCT.Buffer instance allocated with memAlloc. The instance must be explicitly freed.capacity - the buffer capacitypublic static SQL_NUMERIC_STRUCT.Buffer calloc(int capacity)
SQL_NUMERIC_STRUCT.Buffer instance allocated with memCalloc. The instance must be explicitly freed.capacity - the buffer capacitypublic static SQL_NUMERIC_STRUCT.Buffer create(int capacity)
SQL_NUMERIC_STRUCT.Buffer instance allocated with BufferUtils.capacity - the buffer capacitypublic static SQL_NUMERIC_STRUCT.Buffer create(long address, int capacity)
SQL_NUMERIC_STRUCT.Buffer instance at the specified memory.address - the memory addresscapacity - the buffer capacity@Nullable public static SQL_NUMERIC_STRUCT.Buffer createSafe(long address, int capacity)
public static SQL_NUMERIC_STRUCT mallocStack()
SQL_NUMERIC_STRUCT instance allocated on the thread-local MemoryStack.public static SQL_NUMERIC_STRUCT callocStack()
SQL_NUMERIC_STRUCT instance allocated on the thread-local MemoryStack and initializes all its bits to zero.public static SQL_NUMERIC_STRUCT mallocStack(org.lwjgl.system.MemoryStack stack)
SQL_NUMERIC_STRUCT instance allocated on the specified MemoryStack.stack - the stack from which to allocatepublic static SQL_NUMERIC_STRUCT callocStack(org.lwjgl.system.MemoryStack stack)
SQL_NUMERIC_STRUCT instance allocated on the specified MemoryStack and initializes all its bits to zero.stack - the stack from which to allocatepublic static SQL_NUMERIC_STRUCT.Buffer mallocStack(int capacity)
SQL_NUMERIC_STRUCT.Buffer instance allocated on the thread-local MemoryStack.capacity - the buffer capacitypublic static SQL_NUMERIC_STRUCT.Buffer callocStack(int capacity)
SQL_NUMERIC_STRUCT.Buffer instance allocated on the thread-local MemoryStack and initializes all its bits to zero.capacity - the buffer capacitypublic static SQL_NUMERIC_STRUCT.Buffer mallocStack(int capacity, org.lwjgl.system.MemoryStack stack)
SQL_NUMERIC_STRUCT.Buffer instance allocated on the specified MemoryStack.stack - the stack from which to allocatecapacity - the buffer capacitypublic static SQL_NUMERIC_STRUCT.Buffer callocStack(int capacity, org.lwjgl.system.MemoryStack stack)
SQL_NUMERIC_STRUCT.Buffer instance allocated on the specified MemoryStack and initializes all its bits to zero.stack - the stack from which to allocatecapacity - the buffer capacitypublic static byte nprecision(long struct)
precision().public static byte nscale(long struct)
scale().public static byte nsign(long struct)
sign().public static java.nio.ByteBuffer nval(long struct)
val().public static byte nval(long struct,
int index)
val.public static void nprecision(long struct,
byte value)
precision.public static void nscale(long struct,
byte value)
scale.public static void nsign(long struct,
byte value)
sign.public static void nval(long struct,
java.nio.ByteBuffer value)
val.public static void nval(long struct,
int index,
byte value)
val.Copyright LWJGL. All Rights Reserved. License terms.