Class FieldBuilder¶
Defined in File pvIntrospect.h
Inheritance Relationships¶
Base Type¶
public std::tr1::enable_shared_from_this< FieldBuilder >
Class Documentation¶
-
class FieldBuilder : public std::tr1::enable_shared_from_this<FieldBuilder>¶
Interface for in-line creating of introspection interfaces.
One instance can be used to create multiple
Fieldinstances. An instance of this object must not be used concurrently (an object has a state).- Author
mse
Public Functions
-
FieldBuilderPtr setId(std::string const &id)¶
Set ID of an object to be created.
- Parameters
id – id to be set.
- Returns
this instance of a
FieldBuilder.
-
FieldBuilderPtr add(std::string const &name, ScalarType scalarType)¶
Add a
Scalar.- Parameters
name – name of the array.
scalarType – type of a scalar to add.
- Returns
this instance of a
FieldBuilder.
-
StructureConstPtr createStructure()¶
Create a
Structure. This resets this instance state and allows newFieldinstance to be created.- Returns
a new instance of a
Structure.
-
UnionConstPtr createUnion()¶
Create an
Union. This resets this instance state and allows newFieldinstance to be created.- Returns
a new instance of an
Union.
-
FieldBuilderPtr addNestedStructure(std::string const &name)¶
Add new nested
Structure. endNested() method must be called to complete creation of the nestedStructure.See also
- Parameters
name – nested structure name.
- Returns
a new instance of a
FieldBuilderis returned.
-
FieldBuilderPtr addNestedUnion(std::string const &name)¶
Add new nested
Union. endNested() method must be called to complete creation of the nestedUnion.See also
- Parameters
name – nested union name.
- Returns
a new instance of a
FieldBuilderis returned.
-
FieldBuilderPtr addNestedStructureArray(std::string const &name)¶
Add new nested
Structure[]. endNested() method must be called to complete creation of the nestedStructure.See also
- Parameters
name – nested structure name.
- Returns
a new instance of a
FieldBuilderis returned.
-
FieldBuilderPtr addNestedUnionArray(std::string const &name)¶
Add new nested
Union[]. endNested() method must be called to complete creation of the nestedUnion.See also
- Parameters
name – nested union name.
- Returns
a new instance of a
FieldBuilderis returned.
-
FieldBuilderPtr endNested()¶
Complete the creation of a nested object.
- Returns
a previous (parent)
FieldBuilder.
Public Members
- FieldBuilderPtr addBoundedString(std::string const &name, std::size_t maxLength) PVD_DEPRECATED("See https FieldBuilderPtr addArray (std::string const &name, ScalarType scalarType)
Add a
BoundedString.- Param name
name of the array.
- Param maxLength
a string maximum length.
- Param name
name of the array.
- Param field
a field to add.
- Param name
name of the array.
- Param scalarType
type of a scalar element.
- Return
this instance of a
FieldBuilder. Add aField(e.g.Structure,Union).- Return
this instance of a
FieldBuilder. Add variable size array ofScalarelements.- Return
this instance of a
FieldBuilder.
- FieldBuilderPtr addFixedArray(std::string const &name, ScalarType scalarType, std::size_t size) PVD_DEPRECATED("See https FieldBuilderPtr addArray (std::string const &name, FieldConstPtr const &element)
Add fixed-size array of
Scalarelements.- Param name
name of the array.
- Param scalarType
type of a scalar element.
- Param size
Array fixed size.
- Param name
name of the array.
- Param scalarType
type of a scalar element.
- Param bound
Array maximum capacity (size).
- Param name
name of the array.
- Param element
a type of an array element.
- Return
this instance of a
FieldBuilder. Add bounded-size array ofScalarelements.- Return
this instance of a
FieldBuilder. Add array ofFieldelements.- Return
this instance of a
FieldBuilder.
Public Static Functions
-
static FieldBuilderPtr begin()¶
Create a new instance of in-line
Fieldbuilder.- Version
Added after 7.0.0
-
static FieldBuilderPtr begin(StructureConstPtr S)¶
Create a new instance of in-line
Fieldbuilder pre-initialized with and existing Structure.