Awkward Array: BitMaskedArrayBuilder< T, I > Class Template Reference

Loading...
Searching...
No Matches
Public Member Functions | List of all members
BitMaskedArrayBuilder< T, I > Class Template Reference

BitMaskedArray builder from a Bit Masked JSON Form. More...

`#include <BitMaskedArrayBuilder.h>`

Inheritance diagram for BitMaskedArrayBuilder< T, I >:

## Public Member Functions
| 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.
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.
Public Member Functions inherited from FormBuilder< T, I >
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 &parameters) const
| FIXME: find if it's already implemented in utils.

## Detailed Description

template<typename T, typename I>
class awkward::BitMaskedArrayBuilder< T, I >

BitMaskedArray builder from a Bit Masked JSON Form.

## Constructor & Destructor Documentation

## ◆ BitMaskedArrayBuilder()

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.

## Member Function Documentation

## ◆ begin_list()

void begin_list | ( | LayoutBuilderPtr< T, I > | builder | ) |
| overridevirtual

Begins building a nested list.

Reimplemented from FormBuilder< T, I >.

## ◆ boolean()

void boolean | ( | bool | x,
|  | LayoutBuilderPtr< T, I > | builder
| ) |  |
| overridevirtual

Adds a boolean value `x` to the accumulated data.

Reimplemented from FormBuilder< T, I >.

## ◆ bytestring()

void bytestring | ( | const std::string & | x,
|  | LayoutBuilderPtr< T, I > | builder
| ) |  |
| overridevirtual

Adds an unencoded bytestring `x` in STL format to the accumulated data.

Reimplemented from FormBuilder< T, I >.

## ◆ classname()

const std::string classname | ( |  | ) | const
| overridevirtual

User-friendly name of this class.

Implements FormBuilder< T, I >.

## ◆ complex()

void complex | ( | std::complex< double > | x,
|  | LayoutBuilderPtr< T, I > | builder
| ) |  |
| overridevirtual

Adds a complex value `x` to the accumulated data.

Reimplemented from FormBuilder< T, I >.

## ◆ content()

const FormBuilderPtr< T, I > content | ( |  | ) | const
| inline

Returns this Form content builder.

## ◆ end_list()

void end_list | ( | LayoutBuilderPtr< T, I > | builder | ) |
| overridevirtual

Ends a nested list.

Reimplemented from FormBuilder< T, I >.

## ◆ float64()

void float64 | ( | double | x,
|  | LayoutBuilderPtr< T, I > | builder
| ) |  |
| overridevirtual

Adds a real value `x` to the accumulated data.

Reimplemented from FormBuilder< T, I >.

## ◆ form_parameters()

const util::Parameters & form_parameters | ( |  | ) | const
| 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\""`.

## ◆ int64()

void int64 | ( | int64_t | x,
|  | LayoutBuilderPtr< T, I > | builder
| ) |  |
| overridevirtual

Adds an integer value `x` to the accumulated data.

Reimplemented from FormBuilder< T, I >.

## ◆ len()

ssize_t len | ( | const ForthOutputBufferMap & | outputs | ) | const
| inlineoverridevirtual

The builder's output buffer length.

Implements FormBuilder< T, I >.

## ◆ string()

void string | ( | const std::string & | x,
|  | LayoutBuilderPtr< T, I > | builder
| ) |  |
| overridevirtual

Adds a UTF-8 encoded bytestring `x` in STL format to the accumulated data.

Reimplemented from FormBuilder< T, I >.

## ◆ to_buffers()

const std::string to_buffers | ( | BuffersContainer & | container,
|  | const ForthOutputBufferMap & | outputs
| ) |  | const
| overridevirtual

Copy the current snapshot into the BuffersContainer and return a Form as a std::string (JSON).

Implements FormBuilder< T, I >.

## ◆ vm_error()

const std::string vm_error | ( |  | ) | const
| overridevirtual

Error messages in the AwkwardForth virtual machine instructions.

Implements FormBuilder< T, I >.

## ◆ vm_from_stack()

const std::string vm_from_stack | ( |  | ) | const
| overridevirtual

AwkwardForth virtual machine instructions to retrieve the data from the VM stack.

Implements FormBuilder< T, I >.

## ◆ vm_func()

const std::string vm_func | ( |  | ) | const
| overridevirtual

AwkwardForth virtual machine instructions of the array builder function.

Implements FormBuilder< T, I >.

## ◆ vm_func_name()

const std::string vm_func_name | ( |  | ) | const
| overridevirtual

The array builder VM function name.

Implements FormBuilder< T, I >.

## ◆ vm_func_type()

const std::string vm_func_type | ( |  | ) | const
| overridevirtual

The array builder VM function type.

Implements FormBuilder< T, I >.

## ◆ vm_output()

const std::string vm_output | ( |  | ) | const
| overridevirtual

AwkwardForth virtual machine instructions of the data outputs.

Implements FormBuilder< T, I >.

## ◆ vm_output_data()

const std::string vm_output_data | ( |  | ) | const
| overridevirtual

AwkwardForth virtual machine data output key.

Implements FormBuilder< T, I >.

The documentation for this class was generated from the following file:

- include/awkward/layoutbuilder/BitMaskedArrayBuilder.h