Ocean
Loading...
Searching...
No Matches
Ocean::Maintenance::Element Class Reference

This class implements a maintenance data element. More...

#include <Maintenance.h>

Public Member Functions

 Element ()=default
 Creates a new empty element.
 
 Element (const Element &element)=default
 Copy constructor.
 
 Element (Element &&element)=default
 Move constructor.
 
 Element (const std::string &name, const uint64_t id, const Timestamp timestamp, const std::string &tag, const Buffer &buffer)
 Creates a new maintenance element.
 
 Element (const std::string &name, const uint64_t id, const Timestamp timestamp, const std::string &tag, Buffer &&buffer)
 Creates a new maintenance element.
 
const std::string & name () const
 Returns the name of the maintenance manager to which the maintenance of this element data has been sent.
 
std::string & name ()
 Returns the name of the maintenance manager to which the maintenance of this element data has been sent.
 
uint64_t id () const
 Return sthe id of the maintenance manager to which the maintenance data of this element has been sent.
 
Timestamp timestamp () const
 The timestamp of the maintenance data of this element.
 
const std::string & tag () const
 Returns the tag of the maintenance data of this element.
 
std::string & tag ()
 Returns the tag of the maintenance data of this element.
 
const Bufferbuffer () const
 Returns the buffer of the maintenance data of this element.
 
Bufferbuffer ()
 Returns the buffer of the maintenance data of this element.
 
Elementoperator= (const Element &element)=default
 Assign operator.
 
Elementoperator= (Element &&element)=default
 Assign operator.
 

Protected Attributes

std::string name_
 The name of the manager to which the data has been sent.
 
uint64_t id_ = 0ull
 The id of the manager to which the data has been sent.
 
Timestamp timestamp_ = Timestamp(false)
 The timestamp of the data.
 
std::string tag_
 The tag of the data.
 
Buffer buffer_
 The buffer of the data.
 

Detailed Description

This class implements a maintenance data element.

Constructor & Destructor Documentation

◆ Element() [1/5]

Ocean::Maintenance::Element::Element ( )
default

Creates a new empty element.

◆ Element() [2/5]

Ocean::Maintenance::Element::Element ( const Element element)
default

Copy constructor.

Parameters
elementThe element to be copied

◆ Element() [3/5]

Ocean::Maintenance::Element::Element ( Element &&  element)
default

Move constructor.

Parameters
elementThe element to be moved

◆ Element() [4/5]

Ocean::Maintenance::Element::Element ( const std::string &  name,
const uint64_t  id,
const Timestamp  timestamp,
const std::string &  tag,
const Buffer buffer 
)
inline

Creates a new maintenance element.

Parameters
nameThe name of the maintenance manager to which the data has been sent
idThe id of the maintenance manager to which the data has been set
timestampThe timestamp of the maintenance data
tagThe tag of the maintenance data
bufferThe maintenance data as buffer

◆ Element() [5/5]

Ocean::Maintenance::Element::Element ( const std::string &  name,
const uint64_t  id,
const Timestamp  timestamp,
const std::string &  tag,
Buffer &&  buffer 
)
inline

Creates a new maintenance element.

Parameters
nameThe name of the maintenance manager to which the data has been sent
idThe id of the maintenance manager to which the data has been set
timestampThe timestamp of the maintenance data
tagThe tag of the maintenance data
bufferThe maintenance data as buffer, will be moved

Member Function Documentation

◆ buffer() [1/2]

Maintenance::Buffer & Ocean::Maintenance::Element::buffer ( )
inline

Returns the buffer of the maintenance data of this element.

Returns
The buffer of the maintenance data

◆ buffer() [2/2]

const Maintenance::Buffer & Ocean::Maintenance::Element::buffer ( ) const
inline

Returns the buffer of the maintenance data of this element.

Returns
The buffer of the maintenance data

◆ id()

uint64_t Ocean::Maintenance::Element::id ( ) const
inline

Return sthe id of the maintenance manager to which the maintenance data of this element has been sent.

Returns
The id of the maintenance manager

◆ name() [1/2]

std::string & Ocean::Maintenance::Element::name ( )
inline

Returns the name of the maintenance manager to which the maintenance of this element data has been sent.

Returns
The readable name of the maintenance manager

◆ name() [2/2]

const std::string & Ocean::Maintenance::Element::name ( ) const
inline

Returns the name of the maintenance manager to which the maintenance of this element data has been sent.

Returns
The readable name of the maintenance manager

◆ operator=() [1/2]

Element & Ocean::Maintenance::Element::operator= ( const Element element)
default

Assign operator.

Parameters
elementThe second element to be copied
Returns
Reference to this element

◆ operator=() [2/2]

Element & Ocean::Maintenance::Element::operator= ( Element &&  element)
default

Assign operator.

Parameters
elementThe second element to be moved
Returns
Reference to this element

◆ tag() [1/2]

std::string & Ocean::Maintenance::Element::tag ( )
inline

Returns the tag of the maintenance data of this element.

Returns
The tag of the maintenance data

◆ tag() [2/2]

const std::string & Ocean::Maintenance::Element::tag ( ) const
inline

Returns the tag of the maintenance data of this element.

Returns
The tag of the maintenance data

◆ timestamp()

Timestamp Ocean::Maintenance::Element::timestamp ( ) const
inline

The timestamp of the maintenance data of this element.

Returns
The timestamp of the maintenance data

Field Documentation

◆ buffer_

Buffer Ocean::Maintenance::Element::buffer_
protected

The buffer of the data.

◆ id_

uint64_t Ocean::Maintenance::Element::id_ = 0ull
protected

The id of the manager to which the data has been sent.

◆ name_

std::string Ocean::Maintenance::Element::name_
protected

The name of the manager to which the data has been sent.

◆ tag_

std::string Ocean::Maintenance::Element::tag_
protected

The tag of the data.

◆ timestamp_

Timestamp Ocean::Maintenance::Element::timestamp_ = Timestamp(false)
protected

The timestamp of the data.


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