|
DUNE-DAQ
DUNE Trigger and Data Acquisition software
|
Struct OKS data. More...
#include <object.hpp>
Classes | |
| union | Data |
Public Types | |
| enum | Type { unknown_type = 0 , s8_int_type = 1 , u8_int_type = 2 , s16_int_type = 3 , u16_int_type = 4 , s32_int_type = 5 , u32_int_type = 6 , s64_int_type = 7 , u64_int_type = 8 , float_type = 9 , double_type = 10 , bool_type = 11 , class_type = 12 , object_type = 13 , date_type = 14 , time_type = 15 , string_type = 16 , list_type = 17 , uid_type = 18 , uid2_type = 19 , enum_type = 20 } |
| typedef std::list< OksData *, boost::fast_pool_allocator< OksData * > > | List |
Public Member Functions | |
| OksData () | |
| OksData (int8_t c) | |
| OksData (uint8_t c) | |
| OksData (int16_t i) | |
| OksData (uint16_t i) | |
| OksData (int32_t i) | |
| OksData (uint32_t i) | |
| OksData (int64_t i) | |
| OksData (uint64_t i) | |
| OksData (const float &f) | |
| OksData (const double &d) | |
| OksData (bool b) | |
| OksData (boost::gregorian::date d) | |
| OksData (boost::posix_time::ptime t) | |
| OksData (OksString *s) | |
| OksData (const char *s) | |
| OksData (const std::string &s) | |
| OksData (const OksString &s) | |
| OksData (const char *s, size_t len, const OksAttribute *a) | |
| OksData (const std::string &s, const OksAttribute *a) | |
| OksData (const OksString &s, const OksAttribute *a) | |
| OksData (const OksClass *c) | |
| OksData (List *l) | |
| OksData (OksObject *o) | |
| OksData (const OksClass *c, const char *o) | |
| OksData (const OksClass *c, const OksString &o) | |
| OksData (const std::string &c, const std::string &o) | |
| ~OksData () | |
| void | Clear () |
| void | Clear2 () |
| void | Set (int8_t c) |
| void | Set (uint8_t c) |
| void | Set (int16_t i) |
| void | Set (uint16_t i) |
| void | Set (int32_t i) |
| void | Set (uint32_t i) |
| void | Set (int64_t i) |
| void | Set (uint64_t i) |
| void | Set (const float &f) |
| void | Set (const double &d) |
| void | Set (bool b) |
| void | SetFast (boost::gregorian::date d) |
| void | SetFast (boost::posix_time::ptime t) |
| void | Set (boost::gregorian::date d) |
| void | Set (boost::posix_time::ptime t) |
| void | Set (OksString *s) |
| void | Set (const char *s) |
| void | Set (const std::string &s) |
| void | Set (const OksString &s) |
| void | Set (const OksClass *c) |
| void | SetE (OksString *s, const OksAttribute *a) |
| void | SetE (const char *s, size_t len, const OksAttribute *a) |
| void | SetE (const std::string &s, const OksAttribute *a) |
| void | SetE (const OksAttribute *a) |
| void | SetE (const OksString &s, const OksAttribute *a) |
| void | Set (List *l) |
| void | Set (OksObject *o) |
| void | Set (const OksClass *c, const OksString &s) |
| void | Set (const OksClass *c, OksString *s) |
| void | Set (const OksString &c, const OksString &s) |
| void | Set (OksString *c, OksString *s) |
| void | ReadFrom (const char *, Type, const OksAttribute *) |
| void | ReadFrom (const std::string &, const OksAttribute *) |
| void | SetNullValue (const OksAttribute *a) |
| void | SetValue (const char *s, const OksAttribute *a) |
| void | SetValues (const char *, const OksAttribute *a) |
| void | ReadFrom (const OksRelationship *) noexcept |
| void | WriteTo (OksXmlOutputStream &, bool) const |
| void | WriteTo (OksXmlOutputStream &) const |
| void | ConvertTo (OksData *, const OksRelationship *) const |
| boost::gregorian::date | date () const noexcept |
| boost::posix_time::ptime | time () const noexcept |
| void | cvt (OksData *to, const OksAttribute *attr) const |
| Convert data to new type. | |
| std::string | str (int base=0) const |
| std::string | str (const OksKernel *) const |
| void | check_range (const OksAttribute *a) const |
| Check range of data. | |
| void | set_init_value (const OksAttribute *attr, bool skip_init) |
| Set value defined by initial value of attribute. | |
| OksData & | operator= (const OksData &d) |
| OksData (const OksData &d) | |
| bool | operator== (const OksData &) const |
| bool | operator!= (const OksData &) const |
| bool | operator<= (const OksData &) const |
| bool | operator>= (const OksData &) const |
| bool | operator< (const OksData &) const |
| bool | operator> (const OksData &) const |
| void * | operator new (size_t) |
| void | operator delete (void *ptr) |
| void | sort (bool ascending=true) |
Static Public Member Functions | |
| static bool | is_object (Type t) |
Public Attributes | |
| enum dunedaq::oks::OksData::Type | type |
| union dunedaq::oks::OksData::Data | data |
Private Member Functions | |
| void | copy (const OksData &) |
| bool | is_le (const OksData &) const noexcept |
| bool | is_ge (const OksData &) const noexcept |
| bool | is_l (const OksData &) const noexcept |
| bool | is_g (const OksData &) const noexcept |
| void | read (const oks::ReadFileParams &, const OksAttribute *, int32_t) |
| private methods which can be used by OksObject class only | |
| void | read (const oks::ReadFileParams &, const OksAttribute *) |
| void | read (const OksAttribute *, const OksXmlValue &) |
| void | read (const OksAttribute *, const oks::ReadFileParams &) |
| void | read (const oks::ReadFileParams &, const OksRelationship *, int32_t) |
| void | read (const oks::ReadFileParams &, const OksRelationship *) |
| void | read (const OksRelationship *, const OksXmlRelValue &) |
| void | read (const OksRelationship *, const oks::ReadFileParams &) |
| OksData (const oks::ReadFileParams ¶ms, const OksAttribute *a, int32_t n) | |
| OksData (const oks::ReadFileParams ¶ms, const OksAttribute *a) | |
| OksData (const OksAttribute *a, const OksXmlValue &value) | |
| OksData (const OksAttribute *a, const oks::ReadFileParams ¶ms) | |
| OksData (const oks::ReadFileParams ¶ms, const OksRelationship *r, int32_t n) | |
| OksData (const oks::ReadFileParams ¶ms, const OksRelationship *r) | |
| OksData (const OksRelationship *r, const OksXmlRelValue &value) | |
| OksData (const OksRelationship *r, const oks::ReadFileParams ¶ms) | |
| void | WriteTo (OksXmlOutputStream &, OksKernel *, OksAliasTable *, bool, bool) const |
| bool | IsConsistent (const OksRelationship *r, const OksObject *o, const char *msg) |
| const std::string & | __oid () const |
| const std::string & | __cn () const |
Friends | |
| class | OksObject |
| class | OksKernel |
| std::ostream & | operator<< (std::ostream &, const OksData &) |
Struct OKS data.
the structure to pass common parameters to various read() methods of OksData and OksObject class
The struct OksData is used to present OKS data types (the type is unknown before run-time) Members: enumeration 'type' is used to define data type in run-time union 'data' is used to represent such type
Definition at line 509 of file object.hpp.
| typedef std::list<OksData*, boost::fast_pool_allocator<OksData*> > dunedaq::oks::OksData::List |
Definition at line 515 of file object.hpp.
Definition at line 517 of file object.hpp.
|
inline |
Definition at line 574 of file object.hpp.
|
inline |
Definition at line 575 of file object.hpp.
|
inline |
Definition at line 580 of file object.hpp.
|
inline |
Definition at line 585 of file object.hpp.
|
inline |
Definition at line 590 of file object.hpp.
|
inline |
Definition at line 595 of file object.hpp.
|
inline |
Definition at line 600 of file object.hpp.
|
inline |
Definition at line 605 of file object.hpp.
|
inline |
Definition at line 610 of file object.hpp.
|
inline |
Definition at line 615 of file object.hpp.
|
inline |
Definition at line 620 of file object.hpp.
|
inline |
Definition at line 625 of file object.hpp.
|
inline |
Definition at line 630 of file object.hpp.
|
inline |
Definition at line 635 of file object.hpp.
|
inline |
Definition at line 640 of file object.hpp.
|
inline |
Definition at line 645 of file object.hpp.
|
inline |
Definition at line 650 of file object.hpp.
|
inline |
Definition at line 655 of file object.hpp.
|
inline |
Definition at line 660 of file object.hpp.
|
inline |
Definition at line 665 of file object.hpp.
|
inline |
Definition at line 670 of file object.hpp.
|
inline |
Definition at line 675 of file object.hpp.
|
inline |
Definition at line 680 of file object.hpp.
|
inline |
Definition at line 685 of file object.hpp.
|
inline |
Definition at line 690 of file object.hpp.
Definition at line 695 of file object.hpp.
|
inline |
Definition at line 700 of file object.hpp.
|
inline |
Definition at line 706 of file object.hpp.
|
inline |
Definition at line 971 of file object.hpp.
|
inlineprivate |
Definition at line 1012 of file object.hpp.
|
inlineprivate |
Definition at line 1017 of file object.hpp.
|
inlineprivate |
Definition at line 1022 of file object.hpp.
|
inlineprivate |
Definition at line 1027 of file object.hpp.
|
inlineprivate |
Definition at line 1033 of file object.hpp.
|
inlineprivate |
Definition at line 1038 of file object.hpp.
|
inlineprivate |
Definition at line 1043 of file object.hpp.
|
inlineprivate |
Definition at line 1048 of file object.hpp.
|
private |
|
private |
| void dunedaq::oks::OksData::check_range | ( | const OksAttribute * | a | ) | const |
Check range of data.
The method checks that the data matches to the range. If the data is out of range, the oks::AttributeRangeError exception is thrown. If definition of range is bad, then the oks::AttributeReadError exception is thrown.
| a | attribute defining the range (UML syntax, e.g. "A,B,C" or "1..10" or "*..99") |
| oks::AttributeRangeError | or oks::AttributeReadError is thrown in case of problems. |
| void dunedaq::oks::OksData::Clear | ( | ) |
|
inline |
Definition at line 709 of file object.hpp.
| void dunedaq::oks::OksData::ConvertTo | ( | OksData * | , |
| const OksRelationship * | ) const |
|
private |
| void dunedaq::oks::OksData::cvt | ( | OksData * | to, |
| const OksAttribute * | attr ) const |
Convert data to new type.
The method converts this data to the new data using type defined by attribute parameter. A single-value can be converted to multi-value conta4ining this single item. A multi-value can be converted to single-value using first item from the multi-value.
If data cannot be converted, then the oks::AttributeReadError exception is thrown.
| to | out parameter (new data containing converted value) |
| attr | pointer to OKS kernel (required to read class_type values) |
| oks::AttributeReadError | is thrown in case of problems. |
|
noexcept |
Definition at line 990 of file object.hpp.
|
private |
|
inline |
Definition at line 986 of file object.hpp.
|
inline |
Definition at line 985 of file object.hpp.
Definition at line 961 of file object.hpp.
|
private |
|
private |
private methods which can be used by OksObject class only
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
|
inline |
Read from string using non multi-value type
| oks::AttributeReadError | is thrown in case of problems. |
Definition at line 1063 of file object.hpp.
|
noexcept |
Create emtpy list or empty uid2
|
inline |
Read from string using non multi-value type
| oks::AttributeReadError | is thrown in case of problems. |
Definition at line 602 of file attribute.hpp.
|
inline |
Definition at line 771 of file object.hpp.
|
inline |
Definition at line 779 of file object.hpp.
|
inline |
|
inline |
Definition at line 797 of file object.hpp.
|
inline |
Definition at line 765 of file object.hpp.
|
inline |
Definition at line 759 of file object.hpp.
|
inline |
Definition at line 815 of file object.hpp.
Definition at line 852 of file object.hpp.
|
inline |
Definition at line 809 of file object.hpp.
|
inline |
Definition at line 803 of file object.hpp.
|
inline |
Definition at line 723 of file object.hpp.
|
inline |
Definition at line 735 of file object.hpp.
|
inline |
Definition at line 747 of file object.hpp.
|
inline |
Definition at line 711 of file object.hpp.
|
inline |
Definition at line 826 of file object.hpp.
|
inline |
Definition at line 832 of file object.hpp.
|
inline |
Definition at line 791 of file object.hpp.
|
inline |
Definition at line 729 of file object.hpp.
|
inline |
Definition at line 741 of file object.hpp.
|
inline |
Definition at line 753 of file object.hpp.
|
inline |
Definition at line 717 of file object.hpp.
| void dunedaq::oks::OksData::set_init_value | ( | const OksAttribute * | attr, |
| bool | skip_init ) |
Set value defined by initial value of attribute.
The method checks that the data matches to the range. If the data is out of range, the oks::AttributeRangeError exception is thrown. If definition of range is bad, then the oks::AttributeReadError exception is thrown.
| attr | the attribute |
| kernel | pointer to OKS kernel (required to read class_type values) |
| skip_init | only required by OksObject::init2() method for optimization |
| oks::AttributeReadError | is thrown in case of problems. |
Definition at line 248 of file object.cpp.
|
inline |
Definition at line 568 of file attribute.hpp.
|
inline |
Definition at line 584 of file attribute.hpp.
|
inline |
Definition at line 592 of file attribute.hpp.
|
inline |
Definition at line 576 of file attribute.hpp.
|
inline |
| void dunedaq::oks::OksData::SetFast | ( | boost::gregorian::date | d | ) |
| void dunedaq::oks::OksData::SetFast | ( | boost::posix_time::ptime | t | ) |
| void dunedaq::oks::OksData::SetNullValue | ( | const OksAttribute * | a | ) |
Read from null string (single-value)
| oks::AttributeReadError | is thrown in case of problems. |
| void dunedaq::oks::OksData::SetValue | ( | const char * | s, |
| const OksAttribute * | a ) |
Read from string (single-value)
| oks::AttributeReadError | is thrown in case of problems. |
| void dunedaq::oks::OksData::SetValues | ( | const char * | , |
| const OksAttribute * | a ) |
Read from string (any type)
| oks::AttributeReadError | is thrown in case of problems. |
| void dunedaq::oks::OksData::sort | ( | bool | ascending = true | ) |
| std::string dunedaq::oks::OksData::str | ( | const OksKernel * | ) | const |
| std::string dunedaq::oks::OksData::str | ( | int | base = 0 | ) | const |
|
noexcept |
| void dunedaq::oks::OksData::WriteTo | ( | OksXmlOutputStream & | ) | const |
| void dunedaq::oks::OksData::WriteTo | ( | OksXmlOutputStream & | , |
| bool | ) const |
|
private |
|
friend |
Definition at line 512 of file object.hpp.
|
friend |
Definition at line 511 of file object.hpp.
|
friend |
| union dunedaq::oks::OksData::Data dunedaq::oks::OksData::data |
| enum dunedaq::oks::OksData::Type dunedaq::oks::OksData::type |