Slice

Holds a pointer returned from leveldb, or passed to leveldb.

Leveldb memory is freed on destruction.

Constructors

this
this(void* p, size_t l, bool free)

Used by DB class to hold leveldb raw pointers

this
this(P p)

Takes reference

this
this(P p)
Undocumented in source.
this
this(P p, size_t l)

Takes reference

Destructor

~this
~this()

Calles free on leveldb raw memory

Members

Aliases

_lib_obj_ptr__
alias _lib_obj_ptr__ = ptr!(const(char*))
Undocumented in source.
_lib_obj_size__
alias _lib_obj_size__ = length
Undocumented in source.
to
alias to = as
Undocumented in source.

Functions

opCast
inout(T) opCast()

Slice casting

Properties

as
inout(T) as [@property getter]

Get slice as a data type

length
size_t length [@property getter]

length or size of slice

ok
bool ok [@property getter]

Test is slice is valid

ptr
inout(T) ptr [@property getter]

Get slice pointer

Static functions

Ref
Slice Ref(T t)

Create a safe refrence for slicing, good for primitive type constants

Meta