FairMQParts Class Reference

FairMQParts is a lightweight convenience wrapper around a vector of unique pointers to FairMQMessage, used for sending multi-part messages. More...

`#include <FairMQParts.h>`

## Public Types

using | iterator = container::iterator
using | const_iterator = container::const_iterator

## Public Member Functions

| FairMQParts ()
| Default constructor.
| FairMQParts (const FairMQParts &)=delete
| Copy Constructor.
| FairMQParts (FairMQParts &&p)=default
| Move constructor.
FairMQParts & | operator= (const FairMQParts &)=delete
| Assignment operator.
| ~FairMQParts ()
| Default destructor.
void | AddPart (FairMQMessage *msg)
void | AddPart (std::unique_ptr< FairMQMessage > &&msg)
FairMQMessage & | operator[] (const int index)
std::unique_ptr< FairMQMessage > & | At (const int index)
FairMQMessage & | AtRef (const int index)
int | Size () const
auto | begin () -> decltype(fParts.begin())
auto | end () -> decltype(fParts.end())
auto | cbegin () -> decltype(fParts.cbegin())
auto | cend () -> decltype(fParts.cend())

## Public Attributes

container | fParts

## Detailed Description

FairMQParts is a lightweight convenience wrapper around a vector of unique pointers to FairMQMessage, used for sending multi-part messages.

## Member Function Documentation

## AddPart() [1/2]

void FairMQParts::AddPart | ( | FairMQMessage * | msg | ) |

inline

Adds part (FairMQMessage) to the container

Parameters

  msg | message pointer (for example created with NewMessage() method of FairMQDevice)

## AddPart() [2/2]

void FairMQParts::AddPart | ( | std::unique_ptr< FairMQMessage > && | msg | ) |

inline

Adds part (std::unique_ptr<FairMQMessage>&) to the container (move)

Parameters

  msg | unique pointer to FairMQMessage lvalue ref (move not required when passing argument) Adds part (std::unique_ptr<FairMQMessage>&) to the container (move)
  msg | unique pointer to FairMQMessage rvalue ref (move required when passing argument)

## At()

std::unique_ptr<FairMQMessage>& FairMQParts::At | ( | const int | index | ) |

inline

Get reference to unique pointer to part in the container at index (with bounds check)

Parameters

  index | container index

## operator[]()

FairMQMessage& FairMQParts::operator[] | ( | const int | index | ) |

inline

Get reference to part in the container at index (without bounds check)

Parameters

  index | container index

## Size()

int FairMQParts::Size | ( |  | ) | const

inline

Get number of parts in the container

Returns
  number of parts in the container

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

- fairmq/FairMQParts.h

privacy