CustomSerializer

Type to use when defining custom

struct CustomSerializer (
_T
_Rep
alias _ser
alias _deser
alias _check
) if (
is(typeof(_ser(_T.init)) == _Rep) &&
is(typeof(_deser(_Rep.init)) == _T)
&&
is(typeof(_check(_Rep.init)) == bool)
) {}

Members

Aliases

Rep
alias Rep = _Rep

The serialized representation

T
alias T = _T

The type being serialized

check
alias check = _check

Function called to ensure the representation is valid

deserialize
alias deserialize = _deser

Function to convert the rep to the type

serialize
alias serialize = _ser

Function to convert the type to its rep

Meta