|
libbio
|
| bool bio::chemical::base_data::ArrayAppend | ( | Symmetry & | symmetry, |
| Pointer< physical::Symmetry > | child | ||
| ) |
Append an already-constructed child symmetry to an Array. Assigns the canonical positional name ("0", "1", ...) to the child based on current size. Takes ownership of child.
| Pointer< const physical::Symmetry > bio::chemical::base_data::ArrayAt | ( | const Symmetry & | symmetry, |
| std::size_t | index | ||
| ) |
| Pointer< physical::Symmetry > bio::chemical::base_data::ArrayAt | ( | Symmetry & | symmetry, |
| std::size_t | index | ||
| ) |
Get the child at the given positional index.
Delete and remove all child symmetries owned by *symmetry. Leaves the SymmetryType and scalar value untouched.
Initialize (or reset) *symmetry as a canonical Array. Sets the SymmetryType to Array and does not touch any existing children. Use ClearChildren first if you want to start empty.
Initialize (or reset) *symmetry as a canonical Tag with the given tag number. Stores the tag number as ByteStream(uint64_t) on *symmetry's own value slot. Does not touch any existing "value" child.
Canonical structural base-data helpers for chemical::Symmetry.
These helpers enforce the child-name and child-count contracts for the structural kinds:
Array -> ordered child symmetries with positional names ("0", "1", ...) Map -> ordered MapEntry children with positional names MapEntry -> exactly two children named "key" and "value" Tag -> ByteStream(uint64_t) tag number + exactly one child named "value"
Unlike the physical scalar helpers, these operate on chemical::Symmetry because children are only introduced at the chemical layer (via LinearMotif< physical::Symmetry >).
All Append/Set helpers take ownership of the child symmetries passed in, matching the existing LinearMotif< physical::Symmetry > semantics used throughout Atom.cpp.
| Pointer< Symmetry > bio::chemical::base_data::MakeMapEntry | ( | Pointer< physical::Symmetry > | key, |
| Pointer< physical::Symmetry > | value | ||
| ) |
Create a fresh MapEntry symmetry containing the given key and value children. Takes ownership of key and value. The returned symmetry is heap-allocated and should be appended to a Map via MapAppend (which transfers ownership).
Append a MapEntry to a Map. Assigns the canonical positional name. Takes ownership of entry.
| Pointer< const Symmetry > bio::chemical::base_data::MapEntryAt | ( | const Symmetry & | symmetry, |
| std::size_t | index | ||
| ) |
Get the MapEntry at the given positional index.
| Pointer< const physical::Symmetry > bio::chemical::base_data::MapEntryKey | ( | const Symmetry & | entry | ) |
| Pointer< physical::Symmetry > bio::chemical::base_data::MapEntryKey | ( | Symmetry & | entry | ) |
Retrieve the key/value children of a MapEntry.
| Pointer< const physical::Symmetry > bio::chemical::base_data::MapEntryValue | ( | const Symmetry & | entry | ) |
| Pointer< physical::Symmetry > bio::chemical::base_data::MapEntryValue | ( | Symmetry & | entry | ) |
| bool bio::chemical::base_data::TagSetValue | ( | Symmetry & | symmetry, |
| Pointer< physical::Symmetry > | value | ||
| ) |
Set the wrapped value child of a Tag. Replaces any existing "value" child. Takes ownership of value.
| Pointer< const physical::Symmetry > bio::chemical::base_data::TagValue | ( | const Symmetry & | symmetry | ) |
| Pointer< physical::Symmetry > bio::chemical::base_data::TagValue | ( | Symmetry & | symmetry | ) |
Get the wrapped value child of a Tag.