YARP
Yet Another Robot Platform
yarp::os::Bytes Class Reference

A simple abstraction for a block of bytes. More...

#include <yarp/os/Bytes.h>

Detailed Description

A simple abstraction for a block of bytes.

This class is not responsible for allocating or destroying those bytes, just recording their location.

Definition at line 27 of file Bytes.h.

Public Member Functions

 Bytes ()
 Default constructor. More...
 
 Bytes (char *data, size_t len)
 Constructor. More...
 
size_t length () const
 
const char * get () const
 
char * get ()
 

Constructor & Destructor Documentation

◆ Bytes() [1/2]

yarp::os::Bytes::Bytes ( )
explicit

Default constructor.

No data present.

Definition at line 13 of file Bytes.cpp.

◆ Bytes() [2/2]

yarp::os::Bytes::Bytes ( char *  data,
size_t  len 
)

Constructor.

Parameters
dataaddress of data block
lenlength of data block

Definition at line 19 of file Bytes.cpp.

Member Function Documentation

◆ get() [1/2]

char * yarp::os::Bytes::get ( )
Returns
address of data block.

Definition at line 35 of file Bytes.cpp.

◆ get() [2/2]

const char * yarp::os::Bytes::get ( ) const
Returns
address of data block. Const version.

Definition at line 30 of file Bytes.cpp.

◆ length()

size_t yarp::os::Bytes::length ( ) const
Returns
length of data block

Definition at line 25 of file Bytes.cpp.


The documentation for this class was generated from the following files: