BitMaskedArray builder from a Bit Masked JSON Form. More...
#include <BitMaskedArrayBuilder.h>
Public Member Functions | |
BitMaskedArrayBuilder (const FormBuilderPtr< T, I > content, const util::Parameters ¶meters, const std::string &form_key, const std::string attribute="mask", const std::string partition="0") | |
Creates a BitMaskedArrayBuilder from a full set of parameters. | |
const std::string | classname () const override |
User-friendly name of this class. | |
const std::string | to_buffers (BuffersContainer &container, const ForthOutputBufferMap &outputs) const override |
Copy the current snapshot into the BuffersContainer and return a Form as a std::string (JSON). | |
const std::string | vm_output () const override |
AwkwardForth virtual machine instructions of the data outputs. | |
const std::string | vm_output_data () const override |
AwkwardForth virtual machine data output key. | |
const std::string | vm_func () const override |
AwkwardForth virtual machine instructions of the array builder function. | |
const std::string | vm_func_name () const override |
The array builder VM function name. | |
const std::string | vm_func_type () const override |
The array builder VM function type. | |
const std::string | vm_from_stack () const override |
AwkwardForth virtual machine instructions to retrieve the data from the VM stack. | |
const std::string | vm_error () const override |
Error messages in the AwkwardForth virtual machine instructions. | |
void | boolean (bool x, LayoutBuilderPtr< T, I > builder) override |
Adds a boolean value x to the accumulated data. | |
void | int64 (int64_t x, LayoutBuilderPtr< T, I > builder) override |
Adds an integer value x to the accumulated data. | |
void | float64 (double x, LayoutBuilderPtr< T, I > builder) override |
Adds a real value x to the accumulated data. | |
void | complex (std::complex< double > x, LayoutBuilderPtr< T, I > builder) override |
Adds a complex value x to the accumulated data. | |
void | bytestring (const std::string &x, LayoutBuilderPtr< T, I > builder) override |
Adds an unencoded bytestring x in STL format to the accumulated data. | |
void | string (const std::string &x, LayoutBuilderPtr< T, I > builder) override |
Adds a UTF-8 encoded bytestring x in STL format to the accumulated data. | |
void | begin_list (LayoutBuilderPtr< T, I > builder) override |
Begins building a nested list. | |
void | end_list (LayoutBuilderPtr< T, I > builder) override |
Ends a nested list. | |
const FormBuilderPtr< T, I > | content () const |
Returns this Form content builder. | |
const util::Parameters & | form_parameters () const |
String-to-JSON map that augments the meaning of this builder Form. | |
ssize_t | len (const ForthOutputBufferMap &outputs) const override |
The builder's output buffer length. | |
![]() | |
virtual | ~FormBuilder () |
Virtual destructor acts as a first non-inline virtual function that determines a specific translation unit in which vtable shall be emitted. | |
virtual const std::string | classname () const =0 |
User-friendly name of this class. | |
virtual const std::string | to_buffers (BuffersContainer &container, const ForthOutputBufferMap &outputs) const =0 |
Copy the current snapshot into the BuffersContainer and return a Form as a std::string (JSON). | |
virtual ssize_t | len (const ForthOutputBufferMap &outputs) const =0 |
The builder's output buffer length. | |
virtual bool | is_complex () const |
virtual const std::string | vm_output () const =0 |
AwkwardForth virtual machine instructions of the data outputs. | |
virtual const std::string | vm_output_data () const =0 |
AwkwardForth virtual machine data output key. | |
virtual const std::string | vm_func () const =0 |
AwkwardForth virtual machine instructions of the array builder function. | |
virtual const std::string | vm_func_name () const =0 |
The array builder VM function name. | |
virtual const std::string | vm_func_type () const =0 |
The array builder VM function type. | |
virtual const std::string | vm_from_stack () const =0 |
AwkwardForth virtual machine instructions to retrieve the data from the VM stack. | |
virtual const std::string | vm_error () const =0 |
Error messages in the AwkwardForth virtual machine instructions. | |
virtual void | tag (int8_t x) |
Adds an integer value x to the accumulated data. | |
virtual void | boolean (bool x, LayoutBuilderPtr< T, I > builder) |
Adds a boolean value x to the accumulated data. | |
virtual void | int64 (int64_t x, LayoutBuilderPtr< T, I > builder) |
Adds an integer value x to the accumulated data. | |
virtual void | float64 (double x, LayoutBuilderPtr< T, I > builder) |
Adds a real value x to the accumulated data. | |
virtual void | complex (std::complex< double > x, LayoutBuilderPtr< T, I > builder) |
Adds a complex value x to the accumulated data. | |
virtual void | bytestring (const std::string &x, LayoutBuilderPtr< T, I > builder) |
Adds an unencoded bytestring x in STL format to the accumulated data. | |
virtual void | string (const std::string &x, LayoutBuilderPtr< T, I > builder) |
Adds a UTF-8 encoded bytestring x in STL format to the accumulated data. | |
virtual void | begin_list (LayoutBuilderPtr< T, I > builder) |
Begins building a nested list. | |
virtual void | end_list (LayoutBuilderPtr< T, I > builder) |
Ends a nested list. | |
virtual bool | active () |
If true , this node has started but has not finished a multi-step command (e.g. begin_list ... end_list ). | |
virtual std::string | parameters_as_string (const util::Parameters ¶meters) const |
FIXME: find if it's already implemented in utils. | |
BitMaskedArray builder from a Bit Masked JSON Form.
BitMaskedArrayBuilder | ( | const FormBuilderPtr< T, I > | content, |
const util::Parameters & | parameters, | ||
const std::string & | form_key, | ||
const std::string | attribute = "mask" , |
||
const std::string | partition = "0" |
||
) |
Creates a BitMaskedArrayBuilder from a full set of parameters.
|
overridevirtual |
Begins building a nested list.
Reimplemented from FormBuilder< T, I >.
|
overridevirtual |
Adds a boolean value x
to the accumulated data.
Reimplemented from FormBuilder< T, I >.
|
overridevirtual |
Adds an unencoded bytestring x
in STL format to the accumulated data.
Reimplemented from FormBuilder< T, I >.
|
overridevirtual |
User-friendly name of this class.
Implements FormBuilder< T, I >.
|
overridevirtual |
Adds a complex value x
to the accumulated data.
Reimplemented from FormBuilder< T, I >.
|
inline |
Returns this Form content builder.
|
overridevirtual |
Ends a nested list.
Reimplemented from FormBuilder< T, I >.
|
overridevirtual |
Adds a real value x
to the accumulated data.
Reimplemented from FormBuilder< T, I >.
|
inline |
String-to-JSON map that augments the meaning of this builder Form.
Keys are simple strings, but values are JSON-encoded strings. For this reason, values that represent single strings are double-quoted: e.g. "\"actual_value\""
.
|
overridevirtual |
Adds an integer value x
to the accumulated data.
Reimplemented from FormBuilder< T, I >.
|
inlineoverridevirtual |
The builder's output buffer length.
Implements FormBuilder< T, I >.
|
overridevirtual |
Adds a UTF-8 encoded bytestring x
in STL format to the accumulated data.
Reimplemented from FormBuilder< T, I >.
|
overridevirtual |
Copy the current snapshot into the BuffersContainer and return a Form as a std::string (JSON).
Implements FormBuilder< T, I >.
|
overridevirtual |
Error messages in the AwkwardForth virtual machine instructions.
Implements FormBuilder< T, I >.
|
overridevirtual |
AwkwardForth virtual machine instructions to retrieve the data from the VM stack.
Implements FormBuilder< T, I >.
|
overridevirtual |
AwkwardForth virtual machine instructions of the array builder function.
Implements FormBuilder< T, I >.
|
overridevirtual |
The array builder VM function name.
Implements FormBuilder< T, I >.
|
overridevirtual |
The array builder VM function type.
Implements FormBuilder< T, I >.
|
overridevirtual |
AwkwardForth virtual machine instructions of the data outputs.
Implements FormBuilder< T, I >.
|
overridevirtual |
AwkwardForth virtual machine data output key.
Implements FormBuilder< T, I >.