DynamicMemory

Some form of dynamically-allocated memory. Implementation is provided by the Allocator parameter.

Constructors

this
this(size_t size, size_t capacity)

Create a new instance with given capacity.

Destructor

~this
~this()

Destructor - destroys the wrapped data.

Members

Aliases

allocatedThreshold
deprecated alias allocatedThreshold = .allocatedThreshold
Undocumented in source.
collectThreshold
deprecated alias collectThreshold = .collectThreshold
Undocumented in source.

Functions

setSize
void setSize(size_t newSize)
Undocumented in source. Be warned that the author may not have intended to support it.

Properties

capacity
size_t capacity [@property getter]
Undocumented in source. Be warned that the author may not have intended to support it.
contents
inout(ubyte)[] contents [@property getter]
Undocumented in source. Be warned that the author may not have intended to support it.
size
size_t size [@property getter]
Undocumented in source. Be warned that the author may not have intended to support it.

Variables

_capacity
size_t _capacity;

Allocated capacity.

_size
size_t _size;

Used size. Needed for safe appends.

data
ubyte* data;

Pointer to actual data.

Inherited Members

From Memory

referenceCount
sizediff_t referenceCount;

Reference count.

contents
inout(ubyte)[] contents [@property getter]
Undocumented in source.
size
size_t size [@property getter]
Undocumented in source.
setSize
void setSize(size_t newSize)
Undocumented in source.
capacity
size_t capacity [@property getter]
Undocumented in source.
~this
~this()
Undocumented in source.

Meta