69 accessor_->reset(binary_);
84 return accessor_->field(binary_, tag);
97 accessor_->setField(binary_, tag,
field);
115 accessor_->resetField(binary_, tag);
132 return this->
field(tag);
296 template <
typename Enumeration>
299 return field(tag).cast<Enumeration>();
311 template <
typename BitSet>
314 return BitSet(
field(tag).cast<typename BitSet::Bits>());
330 template <
typename BitSet>
333 return set(tag, value.bits());
479 BinaryBlockBase& binary,
500 BinaryBlockBase& binary_;
544 this->binary_ = r.binary_;
606 return binary_.size();
614 assert(binary_.valid());
616 return GroupEntry(binary_[index], *accessor_);
623 , accessor_(&accessor)
685 this->binary_ = r.binary_;
693 return accessor()->type();
702 assert(binary_.valid());
704 return accessor()->group(binary_, tag);
714 assert(binary_.valid());
716 return accessor()->group(binary_, tag, size);
757 assert(binary_.valid());
759 return accessor()->calculateBinarySize(binary_);
765 accessor()->toFix(str, binary_);
771 return accessor()->toFix(binary_, delimiter);
777 return accessor()->toFix(binary_,
'|');
789 assert(binary_.valid());
791 return binary_.version();
803 assert(binary_.valid());
805 return binary_.templateId();
823 assert(parentAccessor);
#define ONIXS_ILINK3_LTWT_CLASS_DECL(name)
#define ONIXS_ILINK3_LTWT_CLASS
#define ONIXS_ILINK3_MESSAGING_TAGBASED_NAMESPACE_END
#define ONIXS_ILINK3_MESSAGING_TAGBASED_NAMESPACE_BEGIN
#define ONIXS_ILINK3_EXPORTED_STRUCT
#define ONIXS_ILINK3_EXPLICIT
#define ONIXS_ILINK3_NODISCARD
#define ONIXS_ILINK3_NULLPTR
#define ONIXS_ILINK3_DEFAULT
#define ONIXS_ILINK3_NOTHROW
Operations over SBE-encoded repeating group entries.
Operations over a repeating group instance.
A field in a tag-based message.
Provides a tag-based access to fields stored in an SBE-encoded repeating group.
GroupEntry(const GroupEntry &r) noexcept
Initializes the instance as the copy of the given one.
GroupEntry(const GroupEntrySource &binary, const GroupEntryAccessor &accessor) noexcept
Full-initialized instances are constructed through descendants.
GroupEntry() noexcept
Initializes the instance which refers to nothing and thus represents a null instance.
Implements a tag-based repeating group over an SBE-encoded binary data.
Group()
Initializes the instance which refers to nothing and thus represent a null instance.
Group(const GroupEntriesSource &binary, const GroupEntryAccessor &accessor) noexcept
Initializes the instance over the binary data.
Size size() const noexcept
Number of entries in the repeating group being referred by the given instance.
GroupEntriesSource::Size Size
Number of repeating group entries.
Implements a tag-based interface over an SBE-encoded message.
std::string toFix(Char delimiter='\x1') const
SchemaVersion version() const
std::string toString() const
Builds a human-readable tag=value representation.
Message(SbeMessage binary, const MessageAccessor &accessor) noexcept
Initializes the instance from an SBE-encoded message.
Message() noexcept
Initializes the message which refers to nothing and thus being a null-instance.
Group group(Tag tag, MessageSize size)
by its tag.
Message & setVarData(Tag tag, StrRef value)
Sets a variable-length field value.
StrRef type() const noexcept
MessageTemplateId templateId() const
StrRef getVarData(Tag tag) const
MessageSize calculateBinarySize() const noexcept
void toFix(std::string &str) const
Builds a tag=value representation.
Group group(Tag tag) const noexcept
Message(const Message &r) noexcept
Initializes the instance as the copy of the given one.
The time point without the time-zone information.
UInt32 Tag
The type whose values are used to locate fields in tag-based messages.
std::ostream & operator<<(std::ostream &stream, const Field &field)
Serializes into the given stream.
void toStr(std::string &str, const Message &message)
Serializes into a tag=value format.
SbeGroupEntries< GroupEntrySource, MessageSize, MessageSize, MessageSize > GroupEntriesSource
SbeGroupEntry< MessageSize > GroupEntrySource
FloatingPointDecimal< Int64, Int32 > Decimal
Universal decimal type.
MessageHeader::Version SchemaVersion
SBE-encoded data version type.
char Char
Character type alias.
UInt16 MessageSize
Message length type.
std::basic_string_view< Char > StrRef
MessageHeader::TemplateId MessageTemplateId
Message type (template) identification.
Provides a tag-based access to fields stored in an SBE-encoded block.
virtual Field field(const BinaryBlockBase &, Tag) const noexcept=0
virtual void setField(BinaryBlockBase &, Tag, const Field &) const =0
Sets a field value by its tag.
virtual void resetField(BinaryBlockBase &, Tag) const =0
Resets a field value by its tag.
virtual void reset(BinaryBlockBase &) const noexcept=0
Resets all variable-length and optional fields.
UInt32 getUInt32(Tag tag) const
UInt8 getUInt8(Tag tag) const
Timestamp getTimestamp(Tag tag) const
FieldSet & set(Tag tag, Int16 value)
Assigns a given value.
FieldSet & set(Tag tag, const Field &field)
Assigns a given value.
UInt16 getUInt16(Tag tag) const
Enumeration::Enum getEnumeration(Tag tag) const
Int32 getInt32(Tag tag) const
FieldSet & setField(Tag tag, const Field &field)
Assigns the field by its tag.
FieldSet & set(Tag tag, const MaturityMonthYear &value)
Assigns a given value.
MaturityMonthYear getMaturityMonthYear(Tag tag) const
FieldSet(BinaryBlockBase &binary, const FieldAccessor *accessor) noexcept
Initializes the instance over the binary data.
FieldSet & set(Tag tag, UInt64 value)
Assigns a given value.
FieldSet & resetField(Tag tag)
Resets the field by its tag.
FieldSet & set(Tag tag, UInt32 value)
Assigns a given value.
FieldSet & reset() noexcept
Resets all variable-length and optional fields.
FieldSet & set(Tag tag, Int32 value)
Assigns a given value.
FieldSet & set(Tag tag, Char value)
Assigns a given value.
FieldSet & set(Tag tag, Int64 value)
Assigns a given value.
const FieldAccessor * accessor() const noexcept
FieldSet & set(Tag tag, Int8 value)
Assigns a given value.
FieldSet & set(Tag tag, BitSet value, typename BitSet::Bits *=nullptr)
Assigns a given value as a set.
void setAccessor(const FieldAccessor *obj) noexcept
Sets the FieldAccessor.
Decimal getDecimal(Tag tag) const
UInt64 getUInt64(Tag tag) const
Int16 getInt16(Tag tag) const
FieldSet & set(Tag tag, Timestamp value)
Assigns a given value.
FieldSet & set(Tag tag, StrRef value)
Assigns a given value.
bool contain(Tag tag) const noexcept
FieldSet & set(Tag tag, UInt16 value)
Assigns a given value.
StrRef getStringRef(Tag tag) const
BitSet getBitSet(Tag tag) const
FieldSet & set(Tag tag, UInt8 value)
Assigns a given value.
Int64 getInt64(Tag tag) const
Int8 getInt8(Tag tag) const
Field field(Tag tag) const noexcept
Char getChar(Tag tag) const
FieldSet & set(Tag tag, const Decimal &value)
Assigns a given value.
Provides a tag-based access to fields stored in an SBE-encoded repeating group.
~GroupEntryAccessor()=default
Implements tag-based services for an SBE-encoded message.
virtual StrRef type() const noexcept=0
virtual MessageSize calculateBinarySize(const SbeMessage &) const noexcept=0
virtual void toFix(std::string &, const SbeMessage &) const =0
Serializes the given message into the tag=value presentation.
virtual Group group(const SbeMessage &, Tag) const noexcept=0