Top Description Inners Fields Constructors Methods
org.lwjgl.util.freetype

public Class FT_Stream

extends Struct<FT_Stream>
implements NativeResource
Class Inheritance
All Implemented Interfaces
org.lwjgl.system.NativeResource, java.lang.AutoCloseable
Annotations
@NativeType:struct FT_StreamRec
Imports
javax.annotation.*, java.nio.*, org.lwjgl.*, org.lwjgl.system.*

A structure used to describe an input stream.

Layout


struct FT_StreamRec {
    unsigned char * base;
    unsigned long size;
    unsigned long pos;
    FT_StreamDesc descriptor;
    FT_StreamDesc pathname;
    FT_Stream_IoFunc read;
    FT_Stream_CloseFunc close;
    FT_Memory memory;
    unsigned char * cursor;
    unsigned char * limit;
}

Nested and Inner Type Summary

Modifier and TypeClass and Description
public static class
FT_Stream.Buffer

An array of FT_Stream structs.

Field Summary

Modifier and TypeField and Description
public static final int
ALIGNOF

The struct alignment in bytes.

public static final int
BASE

The struct member offsets.

public static final int
CLOSE

The struct member offsets.

public static final int
CURSOR

The struct member offsets.

public static final int
DESCRIPTOR

The struct member offsets.

public static final int
LIMIT

The struct member offsets.

public static final int
MEMORY

The struct member offsets.

public static final int
PATHNAME

The struct member offsets.

public static final int
POS

The struct member offsets.

public static final int
READ

The struct member offsets.

public static final int
SIZE

The struct member offsets.

public static final int
SIZEOF

The struct size in bytes.

Inherited from org.lwjgl.system.Struct:
containerDEFAULT_ALIGN_ASDEFAULT_PACK_ALIGNMENT

Constructor Summary

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

public
FT_Stream(ByteBuffer container)

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

Method Summary

Modifier and TypeMethod and Description
public ByteBuffer

Returns:

a ByteBuffer view of the data pointed to by the base field.
base
()

public FT_Stream
base(ByteBuffer value)

Sets the address of the specified ByteBuffer to the base field.

public static FT_Stream
calloc()

Returns a new FT_Stream instance allocated with memCalloc.

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

Returns a new FT_Stream.Buffer instance allocated with memCalloc.

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

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

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

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

public FT_Stream_CloseFunc

Returns:

the value of the close field.
close$
()

public FT_Stream
close$(FT_Stream_CloseFuncI value)

Sets the specified value to the close field.

protected FT_Stream
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 FT_Stream
create()

Returns a new FT_Stream instance allocated with BufferUtils.

public static FT_Stream
create(long address)

Returns a new FT_Stream instance for the specified memory address.

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

Returns a new FT_Stream.Buffer instance allocated with BufferUtils.

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

Create a FT_Stream.Buffer instance at the specified memory.

public static FT_Stream
createSafe(long address)

Like create, but returns null if address is NULL.

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

Like create, but returns null if address is NULL.

public FT_StreamDesc

Returns:

a FT_StreamDesc view of the descriptor field.
descriptor
()

public FT_Stream
descriptor(FT_StreamDesc value)

Copies the specified FT_StreamDesc to the descriptor field.

public FT_Stream
descriptor(Consumer<FT_StreamDesc> consumer)

Passes the descriptor field to the specified Consumer.

public static FT_Stream
malloc()

Returns a new FT_Stream instance allocated with memAlloc.

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

Returns a new FT_Stream.Buffer instance allocated with memAlloc.

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

Returns a new FT_Stream instance allocated on the specified MemoryStack.

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

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

public static ByteBuffer
nbase(long struct)

Unsafe version of base.

public static void
nbase(long struct, ByteBuffer value)

Unsafe version of base.

public static FT_Stream_CloseFunc
nclose$(long struct)

Unsafe version of close$.

public static void
nclose$(long struct, FT_Stream_CloseFuncI value)

Unsafe version of close$.

public static ByteBuffer
ncursor(long struct, int capacity)

public static void
ncursor(long struct, ByteBuffer value)

public static FT_StreamDesc
ndescriptor(long struct)

Unsafe version of descriptor.

public static void
ndescriptor(long struct, FT_StreamDesc value)

Unsafe version of descriptor.

public static ByteBuffer
nlimit$(long struct, int capacity)

public static void
nlimit$(long struct, ByteBuffer value)

public static FT_Memory
nmemory(long struct)

public static void
nmemory(long struct, FT_Memory value)

public static FT_StreamDesc
npathname(long struct)

Unsafe version of pathname.

public static void
npathname(long struct, FT_StreamDesc value)

Unsafe version of pathname.

public static long
npos(long struct)

Unsafe version of pos.

public static void
npos(long struct, long value)

Unsafe version of pos.

public static FT_Stream_IoFunc
nread(long struct)

Unsafe version of read.

public static void
nread(long struct, FT_Stream_IoFuncI value)

Unsafe version of read.

public static long
nsize(long struct)

Unsafe version of size.

public static void
nsize(long struct, long value)

Sets the specified value to the size field of the specified struct.

public FT_StreamDesc

Returns:

a FT_StreamDesc view of the pathname field.
pathname
()

public FT_Stream
pathname(FT_StreamDesc value)

Copies the specified FT_StreamDesc to the pathname field.

public FT_Stream
pathname(Consumer<FT_StreamDesc> consumer)

Passes the pathname field to the specified Consumer.

public long

Returns:

the value of the pos field.
pos
()

public FT_Stream
pos(long value)

Sets the specified value to the pos field.

public FT_Stream_IoFunc

Returns:

the value of the read field.
read
()

public FT_Stream
read(FT_Stream_IoFuncI value)

Sets the specified value to the read field.

public FT_Stream
set(ByteBuffer base, long size, long pos, FT_StreamDesc descriptor, FT_StreamDesc pathname, FT_Stream_IoFuncI read, FT_Stream_CloseFuncI close$)

Initializes this struct with the specified values.

public FT_Stream

Returns:

this struct
set
(FT_Stream
the source struct
src
)

Copies the specified struct data to this struct.

public long

Returns:

the value of the size field.
size
()

public FT_Stream
size(long value)

Sets the specified value to the size field.

public int
sizeof()

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

Returns sizeof(struct).
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.

BASEback to summary
public static final int BASE

The struct member offsets.

CLOSEback to summary
public static final int CLOSE

The struct member offsets.

CURSORback to summary
public static final int CURSOR

The struct member offsets.

DESCRIPTORback to summary
public static final int DESCRIPTOR

The struct member offsets.

LIMITback to summary
public static final int LIMIT

The struct member offsets.

MEMORYback to summary
public static final int MEMORY

The struct member offsets.

PATHNAMEback to summary
public static final int PATHNAME

The struct member offsets.

POSback to summary
public static final int POS

The struct member offsets.

READback to summary
public static final int READ

The struct member offsets.

SIZEback to summary
public static final int SIZE

The struct member offsets.

SIZEOFback to summary
public static final int SIZEOF

The struct size in bytes.

Constructor Detail

FT_Streamback to summary
protected FT_Stream(long address, ByteBuffer container)
FT_Streamback to summary
public FT_Stream(ByteBuffer container)

Creates a FT_Stream 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

baseback to summary
public ByteBuffer base()
Returns:ByteBuffer

a ByteBuffer view of the data pointed to by the base field.

Annotations
@Nullable
@NativeType:unsigned char *
baseback to summary
public FT_Stream base(ByteBuffer value)

Sets the address of the specified ByteBuffer to the base field.

callocback to summary
public static FT_Stream calloc()

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

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

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

Parameters
capacity:int

the buffer capacity

callocback to summary
public static FT_Stream calloc(MemoryStack stack)

Returns a new FT_Stream 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 FT_Stream.Buffer calloc(int capacity, MemoryStack stack)

Returns a new FT_Stream.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

close$back to summary
public FT_Stream_CloseFunc close$()
Returns:FT_Stream_CloseFunc

the value of the close field.

Annotations
@Nullable
close$back to summary
public FT_Stream close$(FT_Stream_CloseFuncI value)

Sets the specified value to the close field.

createback to summary
protected FT_Stream 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 FT_Stream create()

Returns a new FT_Stream instance allocated with BufferUtils.

createback to summary
public static FT_Stream create(long address)

Returns a new FT_Stream instance for the specified memory address.

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

Returns a new FT_Stream.Buffer instance allocated with BufferUtils.

Parameters
capacity:int

the buffer capacity

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

Create a FT_Stream.Buffer instance at the specified memory.

Parameters
address:long

the memory address

capacity:int

the buffer capacity

createSafeback to summary
public static FT_Stream createSafe(long address)

Like create, but returns null if address is NULL.

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

Like create, but returns null if address is NULL.

Annotations
@Nullable
descriptorback to summary
public FT_StreamDesc descriptor()
Returns:FT_StreamDesc

a FT_StreamDesc view of the descriptor field.

descriptorback to summary
public FT_Stream descriptor(FT_StreamDesc value)

Copies the specified FT_StreamDesc to the descriptor field.

descriptorback to summary
public FT_Stream descriptor(Consumer<FT_StreamDesc> consumer)

Passes the descriptor field to the specified Consumer.

mallocback to summary
public static FT_Stream malloc()

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

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

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

Parameters
capacity:int

the buffer capacity

mallocback to summary
public static FT_Stream malloc(MemoryStack stack)

Returns a new FT_Stream instance allocated on the specified MemoryStack.

Parameters
stack:MemoryStack

the stack from which to allocate

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

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

Parameters
capacity:int

the buffer capacity

stack:MemoryStack

the stack from which to allocate

nbaseback to summary
public static ByteBuffer nbase(long struct)

Unsafe version of base.

Annotations
@Nullable
nbaseback to summary
public static void nbase(long struct, ByteBuffer value)

Unsafe version of base.

nclose$back to summary
public static FT_Stream_CloseFunc nclose$(long struct)

Unsafe version of close$.

Annotations
@Nullable
nclose$back to summary
public static void nclose$(long struct, FT_Stream_CloseFuncI value)

Unsafe version of close$.

ncursorback to summary
public static ByteBuffer ncursor(long struct, int capacity)
Annotations
@Nullable
ncursorback to summary
public static void ncursor(long struct, ByteBuffer value)
ndescriptorback to summary
public static FT_StreamDesc ndescriptor(long struct)

Unsafe version of descriptor.

ndescriptorback to summary
public static void ndescriptor(long struct, FT_StreamDesc value)

Unsafe version of descriptor.

nlimit$back to summary
public static ByteBuffer nlimit$(long struct, int capacity)
Annotations
@Nullable
nlimit$back to summary
public static void nlimit$(long struct, ByteBuffer value)
nmemoryback to summary
public static FT_Memory nmemory(long struct)
Annotations
@Nullable
nmemoryback to summary
public static void nmemory(long struct, FT_Memory value)
npathnameback to summary
public static FT_StreamDesc npathname(long struct)

Unsafe version of pathname.

npathnameback to summary
public static void npathname(long struct, FT_StreamDesc value)

Unsafe version of pathname.

nposback to summary
public static long npos(long struct)

Unsafe version of pos.

nposback to summary
public static void npos(long struct, long value)

Unsafe version of pos.

nreadback to summary
public static FT_Stream_IoFunc nread(long struct)

Unsafe version of read.

Annotations
@Nullable
nreadback to summary
public static void nread(long struct, FT_Stream_IoFuncI value)

Unsafe version of read.

nsizeback to summary
public static long nsize(long struct)

Unsafe version of size.

nsizeback to summary
public static void nsize(long struct, long value)

Sets the specified value to the size field of the specified struct.

pathnameback to summary
public FT_StreamDesc pathname()
Returns:FT_StreamDesc

a FT_StreamDesc view of the pathname field.

pathnameback to summary
public FT_Stream pathname(FT_StreamDesc value)

Copies the specified FT_StreamDesc to the pathname field.

pathnameback to summary
public FT_Stream pathname(Consumer<FT_StreamDesc> consumer)

Passes the pathname field to the specified Consumer.

posback to summary
public long pos()
Returns:long

the value of the pos field.

Annotations
@NativeType:unsigned long
posback to summary
public FT_Stream pos(long value)

Sets the specified value to the pos field.

readback to summary
public FT_Stream_IoFunc read()
Returns:FT_Stream_IoFunc

the value of the read field.

Annotations
@Nullable
readback to summary
public FT_Stream read(FT_Stream_IoFuncI value)

Sets the specified value to the read field.

setback to summary
public FT_Stream set(ByteBuffer base, long size, long pos, FT_StreamDesc descriptor, FT_StreamDesc pathname, FT_Stream_IoFuncI read, FT_Stream_CloseFuncI close$)

Initializes this struct with the specified values.

setback to summary
public FT_Stream set(FT_Stream src)

Copies the specified struct data to this struct.

Parameters
src:FT_Stream

the source struct

Returns:FT_Stream

this struct

sizeback to summary
public long size()
Returns:long

the value of the size field.

Annotations
@NativeType:unsigned long
sizeback to summary
public FT_Stream size(long value)

Sets the specified value to the size field.

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
org.lwjgl.util.freetype back to summary

public Class FT_Stream.Buffer

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

An array of FT_Stream structs.

Field Summary

Modifier and TypeField and Description
private static final FT_Stream

Constructor Summary

AccessConstructor and Description
public
Buffer(ByteBuffer container)

Creates a new FT_Stream.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
public ByteBuffer

Returns:

a ByteBuffer view of the data pointed to by the base field.
base
()

public FT_Stream.Buffer
base(ByteBuffer value)

Sets the address of the specified ByteBuffer to the base field.

public FT_Stream_CloseFunc

Returns:

the value of the close field.
close$
()

public FT_Stream.Buffer
close$(FT_Stream_CloseFuncI value)

Sets the specified value to the close field.

public FT_StreamDesc

Returns:

a FT_StreamDesc view of the descriptor field.
descriptor
()

public FT_Stream.Buffer
descriptor(FT_StreamDesc value)

Copies the specified FT_StreamDesc to the descriptor field.

public FT_Stream.Buffer
descriptor(Consumer<FT_StreamDesc> consumer)

Passes the descriptor field to the specified Consumer.

protected FT_Stream
public FT_StreamDesc

Returns:

a FT_StreamDesc view of the pathname field.
pathname
()

public FT_Stream.Buffer
pathname(FT_StreamDesc value)

Copies the specified FT_StreamDesc to the pathname field.

public FT_Stream.Buffer
pathname(Consumer<FT_StreamDesc> consumer)

Passes the pathname field to the specified Consumer.

public long

Returns:

the value of the pos field.
pos
()

public FT_Stream.Buffer
pos(long value)

Sets the specified value to the pos field.

public FT_Stream_IoFunc

Returns:

the value of the read field.
read
()

public FT_Stream.Buffer
read(FT_Stream_IoFuncI value)

Sets the specified value to the read field.

protected FT_Stream.Buffer
public long

Returns:

the value of the size field.
size
()

public FT_Stream.Buffer
size(long value)

Sets the specified value to the size field.

Inherited from org.lwjgl.system.StructBuffer:
applyapplyforEachgetgetgetgetiteratorparallelStreamputputsizeofspliteratorstream

Field Detail

ELEMENT_FACTORYback to summary
private static final FT_Stream ELEMENT_FACTORY

Constructor Detail

Bufferback to summary
public Buffer(ByteBuffer container)

Creates a new FT_Stream.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 FT_Stream#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

baseback to summary
public ByteBuffer base()
Returns:ByteBuffer

a ByteBuffer view of the data pointed to by the base field.

Annotations
@Nullable
@NativeType:unsigned char *
baseback to summary
public FT_Stream.Buffer base(ByteBuffer value)

Sets the address of the specified ByteBuffer to the base field.

close$back to summary
public FT_Stream_CloseFunc close$()
Returns:FT_Stream_CloseFunc

the value of the close field.

Annotations
@Nullable
close$back to summary
public FT_Stream.Buffer close$(FT_Stream_CloseFuncI value)

Sets the specified value to the close field.

descriptorback to summary
public FT_StreamDesc descriptor()
Returns:FT_StreamDesc

a FT_StreamDesc view of the descriptor field.

descriptorback to summary
public FT_Stream.Buffer descriptor(FT_StreamDesc value)

Copies the specified FT_StreamDesc to the descriptor field.

descriptorback to summary
public FT_Stream.Buffer descriptor(Consumer<FT_StreamDesc> consumer)

Passes the descriptor field to the specified Consumer.

getElementFactoryback to summary
protected FT_Stream getElementFactory()

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

Annotations
@Override
pathnameback to summary
public FT_StreamDesc pathname()
Returns:FT_StreamDesc

a FT_StreamDesc view of the pathname field.

pathnameback to summary
public FT_Stream.Buffer pathname(FT_StreamDesc value)

Copies the specified FT_StreamDesc to the pathname field.

pathnameback to summary
public FT_Stream.Buffer pathname(Consumer<FT_StreamDesc> consumer)

Passes the pathname field to the specified Consumer.

posback to summary
public long pos()
Returns:long

the value of the pos field.

Annotations
@NativeType:unsigned long
posback to summary
public FT_Stream.Buffer pos(long value)

Sets the specified value to the pos field.

readback to summary
public FT_Stream_IoFunc read()
Returns:FT_Stream_IoFunc

the value of the read field.

Annotations
@Nullable
readback to summary
public FT_Stream.Buffer read(FT_Stream_IoFuncI value)

Sets the specified value to the read field.

selfback to summary
protected FT_Stream.Buffer self()

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

Annotations
@Override
sizeback to summary
public long size()
Returns:long

the value of the size field.

Annotations
@NativeType:unsigned long
sizeback to summary
public FT_Stream.Buffer size(long value)

Sets the specified value to the size field.