A flexible data format for holding a bunch of numbers and strings. More...
#include <yarp/os/impl/BottleImpl.h>
Public Types | |
using | size_type = size_t |
Public Member Functions | |
BottleImpl () | |
BottleImpl (Searchable *parent) | |
virtual | ~BottleImpl () |
bool | isInt8 (int index) |
bool | isInt16 (int index) |
bool | isInt32 (int index) |
bool | isInt64 (int index) |
bool | isFloat32 (int index) |
bool | isFloat64 (int index) |
bool | isString (int index) |
bool | isList (int index) |
Storable * | pop () |
Storable & | get (size_type index) const |
void | addInt8 (std::int8_t x) |
void | addInt16 (std::int16_t x) |
void | addInt32 (std::int32_t x) |
void | addInt64 (std::int64_t x) |
void | addFloat32 (yarp::conf::float32_t x) |
void | addFloat64 (yarp::conf::float64_t x) |
void | addVocab32 (yarp::conf::vocab32_t x) |
void | addString (const std::string &text) |
yarp::os::Bottle & | addList () |
yarp::os::Property & | addDict () |
void | clear () |
void | fromString (const std::string &line) |
std::string | toString () const |
size_type | size () const |
bool | read (ConnectionReader &reader) |
bool | write (ConnectionWriter &writer) const |
void | onCommencement () |
const char * | getBytes () const |
size_t | byteCount () const |
void | copyRange (const BottleImpl *alt, size_type first=0, size_type len=npos) |
bool | fromBytes (const yarp::os::Bytes &data) |
void | toBytes (yarp::os::Bytes &data) |
bool | fromBytes (yarp::os::ConnectionReader &reader) |
void | fromBinary (const char *text, size_t len) |
void | specialize (std::int32_t subCode) |
int | getSpecialization () |
void | setNested (bool nested) |
std::int32_t | subCode () |
void | addBit (yarp::os::Value *bit) |
void | addBit (const yarp::os::Value &bit) |
yarp::os::Value & | addBit (const char *str) |
void | hasChanged () |
bool | checkIndex (size_type index) const |
void | edit () |
Value & | findGroupBit (const std::string &key) const |
Value & | findBit (const std::string &key) const |
Static Public Member Functions | |
static StoreNull & | getNull () |
static bool | isComplete (const char *txt) |
Public Attributes | |
Searchable * | parent |
bool | invalid |
bool | ro |
Static Public Attributes | |
static constexpr size_type | npos = static_cast<size_type>(-1) |
A flexible data format for holding a bunch of numbers and strings.
Handy to use until you work out how to make your own more efficient formats for transmission.
Definition at line 32 of file BottleImpl.h.
using yarp::os::impl::BottleImpl::size_type = size_t |
Definition at line 35 of file BottleImpl.h.
BottleImpl::BottleImpl | ( | ) |
Definition at line 33 of file BottleImpl.cpp.
BottleImpl::BottleImpl | ( | Searchable * | parent | ) |
Definition at line 43 of file BottleImpl.cpp.
|
virtual |
Definition at line 54 of file BottleImpl.cpp.
|
inline |
Definition at line 144 of file BottleImpl.h.
|
inline |
Definition at line 136 of file BottleImpl.h.
|
inline |
Definition at line 130 of file BottleImpl.h.
yarp::os::Property & BottleImpl::addDict | ( | ) |
Definition at line 651 of file BottleImpl.cpp.
|
inline |
Definition at line 77 of file BottleImpl.h.
|
inline |
Definition at line 82 of file BottleImpl.h.
|
inline |
Definition at line 62 of file BottleImpl.h.
|
inline |
Definition at line 67 of file BottleImpl.h.
|
inline |
Definition at line 72 of file BottleImpl.h.
|
inline |
Definition at line 57 of file BottleImpl.h.
yarp::os::Bottle & BottleImpl::addList | ( | ) |
Definition at line 644 of file BottleImpl.cpp.
|
inline |
Definition at line 92 of file BottleImpl.h.
|
inline |
Definition at line 87 of file BottleImpl.h.
size_t BottleImpl::byteCount | ( | ) | const |
Definition at line 423 of file BottleImpl.cpp.
bool BottleImpl::checkIndex | ( | size_type | index | ) | const |
Definition at line 580 of file BottleImpl.cpp.
void BottleImpl::clear | ( | ) |
Definition at line 67 of file BottleImpl.cpp.
void BottleImpl::copyRange | ( | const BottleImpl * | alt, |
size_type | first = 0 , |
||
size_type | len = npos |
||
) |
Definition at line 658 of file BottleImpl.cpp.
void BottleImpl::edit | ( | ) |
Definition at line 682 of file BottleImpl.cpp.
Value & BottleImpl::findBit | ( | const std::string & | key | ) | const |
Definition at line 708 of file BottleImpl.cpp.
Value & BottleImpl::findGroupBit | ( | const std::string & | key | ) | const |
Definition at line 692 of file BottleImpl.cpp.
void BottleImpl::fromBinary | ( | const char * | text, |
size_t | len | ||
) |
Definition at line 355 of file BottleImpl.cpp.
bool BottleImpl::fromBytes | ( | const yarp::os::Bytes & | data | ) |
Definition at line 367 of file BottleImpl.cpp.
bool BottleImpl::fromBytes | ( | yarp::os::ConnectionReader & | reader | ) |
Definition at line 331 of file BottleImpl.cpp.
void BottleImpl::fromString | ( | const std::string & | line | ) |
Definition at line 190 of file BottleImpl.cpp.
Definition at line 639 of file BottleImpl.cpp.
const char * BottleImpl::getBytes | ( | ) | const |
Definition at line 416 of file BottleImpl.cpp.
|
inlinestatic |
Definition at line 155 of file BottleImpl.h.
int BottleImpl::getSpecialization | ( | ) |
Definition at line 564 of file BottleImpl.cpp.
|
inline |
Definition at line 164 of file BottleImpl.h.
|
static |
Definition at line 255 of file BottleImpl.cpp.
bool BottleImpl::isFloat32 | ( | int | index | ) |
Definition at line 605 of file BottleImpl.cpp.
bool BottleImpl::isFloat64 | ( | int | index | ) |
Definition at line 610 of file BottleImpl.cpp.
bool BottleImpl::isInt16 | ( | int | index | ) |
Definition at line 590 of file BottleImpl.cpp.
bool BottleImpl::isInt32 | ( | int | index | ) |
Definition at line 595 of file BottleImpl.cpp.
bool BottleImpl::isInt64 | ( | int | index | ) |
Definition at line 600 of file BottleImpl.cpp.
bool BottleImpl::isInt8 | ( | int | index | ) |
Definition at line 585 of file BottleImpl.cpp.
bool BottleImpl::isList | ( | int | index | ) |
Definition at line 620 of file BottleImpl.cpp.
bool BottleImpl::isString | ( | int | index | ) |
Definition at line 615 of file BottleImpl.cpp.
void BottleImpl::onCommencement | ( | ) |
Definition at line 429 of file BottleImpl.cpp.
Storable * BottleImpl::pop | ( | ) |
Definition at line 625 of file BottleImpl.cpp.
bool BottleImpl::read | ( | ConnectionReader & | reader | ) |
Definition at line 447 of file BottleImpl.cpp.
void BottleImpl::setNested | ( | bool | nested | ) |
Definition at line 569 of file BottleImpl.cpp.
BottleImpl::size_type BottleImpl::size | ( | ) | const |
Definition at line 325 of file BottleImpl.cpp.
void BottleImpl::specialize | ( | std::int32_t | subCode | ) |
Definition at line 558 of file BottleImpl.cpp.
std::int32_t BottleImpl::subCode | ( | ) |
Definition at line 575 of file BottleImpl.cpp.
void BottleImpl::toBytes | ( | yarp::os::Bytes & | data | ) |
Definition at line 408 of file BottleImpl.cpp.
std::string BottleImpl::toString | ( | ) | const |
Definition at line 312 of file BottleImpl.cpp.
bool BottleImpl::write | ( | ConnectionWriter & | writer | ) | const |
Definition at line 434 of file BottleImpl.cpp.
bool yarp::os::impl::BottleImpl::invalid |
Definition at line 171 of file BottleImpl.h.
Definition at line 36 of file BottleImpl.h.
Searchable* yarp::os::impl::BottleImpl::parent |
Definition at line 42 of file BottleImpl.h.
bool yarp::os::impl::BottleImpl::ro |
Definition at line 172 of file BottleImpl.h.