| helics 3.6.1

Public Member Functions | List of all members
helicscpp::Publication Class Reference

`#include <Publication.hpp>`

## Public Member Functions
| Publication (HelicsPublication hpub) HELICS_NOTHROW
| Publication () HELICS_NOTHROW
| Publication (const Publication &publication)
Publication & | operator= (const Publication &publication)
| operator HelicsPublication () const
HelicsPublication | baseObject () const
bool | isValid () const
void | publish (const char *data, int len)
void | publish (const char *str)
void | publish (const std::string &str)
void | publish (int64_t val)
void | publish (double val)
void | publish (std::complex< double > cmplx)
void | publish (const std::vector< double > &data)
void | publish (const double *data, int length)
void | publish (const std::vector< std::complex< double > > &data)
void | publishComplex (const double *data, int length)
void | publish (const std::string &name, double val)
void | publish (bool val)
void | publish (DataBuffer &buffer)
const char * | getName () const
const char * | getUnits () const
const char * | getType () const
const char * | getInfo () const
void | setInfo (const std::string &info)
const char * | getTag (const std::string &tagname) const
void | setTag (const std::string &tagname, const std::string &tagvalue)
void | setOption (int32_t option, int32_t value=1)
int32_t | getOption (int32_t option)

## Detailed Description

C++98 interface for a publication object

## Constructor & Destructor Documentation

## ◆ Publication() [1/3]

helicscpp::Publication::Publication | ( | HelicsPublication | hpub | ) |
| inline explicit

construct from a HelicsPublication

## ◆ Publication() [2/3]

helicscpp::Publication::Publication | ( |  | ) |
| inline

default constructor

## ◆ Publication() [3/3]

helicscpp::Publication::Publication | ( | const Publication & | publication | ) |
| inline

copy constructor

## Member Function Documentation

## ◆ baseObject()

HelicsPublication helicscpp::Publication::baseObject | ( |  | ) | const
| inline

return the underlying HelicsPublication object

## ◆ getInfo()

const char* helicscpp::Publication::getInfo | ( |  | ) | const
| inline

get the interface information field of the publication

References helicsPublicationGetInfo().

## ◆ getName()

const char* helicscpp::Publication::getName | ( |  | ) | const
| inline

get the name of the publication

References helicsPublicationGetName().

## ◆ getTag()

const char* helicscpp::Publication::getTag | ( | const std::string & | tagname | ) | const
| inline

get the value of a tag for the publication

References helicsPublicationGetTag().

## ◆ getType()

const char* helicscpp::Publication::getType | ( |  | ) | const
| inline

get the type for the publication

References helicsPublicationGetType().

## ◆ getUnits()

const char* helicscpp::Publication::getUnits | ( |  | ) | const
| inline

get the units of the publication

References helicsPublicationGetUnits().

## ◆ isValid()

bool helicscpp::Publication::isValid | ( |  | ) | const
| inline

check if the publication is valid

References HELICS_TRUE, and helicsPublicationIsValid().

## ◆ operator HelicsPublication()

helicscpp::Publication::operator HelicsPublication | ( |  | ) | const
| inline

cast operator to the underlying HelicsPublication object

## ◆ operator=()

Publication& helicscpp::Publication::operator= | ( | const Publication & | publication | ) |
| inline

copy assignment

## ◆ publish() [1/12]

void helicscpp::Publication::publish | ( | bool | val | ) |
| inline

publish a boolean value

References HELICS_FALSE, HELICS_TRUE, and helicsPublicationPublishBoolean().

## ◆ publish() [2/12]

void helicscpp::Publication::publish | ( | const char * | data,
|  | int | len
| ) |  |
| inline

Methods to publish values publish raw data from a pointer and length

References helicsPublicationPublishBytes().

## ◆ publish() [3/12]

void helicscpp::Publication::publish | ( | const char * | str | ) |
| inline

publish a string from a char *

References helicsPublicationPublishString().

## ◆ publish() [4/12]

void helicscpp::Publication::publish | ( | const double * | data,
|  | int | length
| ) |  |
| inline

publish a vector of doubles

References helicsPublicationPublishVector().

## ◆ publish() [5/12]

void helicscpp::Publication::publish | ( | const std::string & | name,
|  | double | val
| ) |  |
| inline

publish a named point with a string and double

References helicsPublicationPublishNamedPoint().

## ◆ publish() [6/12]

void helicscpp::Publication::publish | ( | const std::string & | str | ) |
| inline

publish a string value

References helicsPublicationPublishString().

## ◆ publish() [7/12]

void helicscpp::Publication::publish | ( | const std::vector< double > & | data | ) |
| inline

publish a vector of doubles

References helicsPublicationPublishVector().

## ◆ publish() [8/12]

void helicscpp::Publication::publish | ( | const std::vector< std::complex< double > > & | data | ) |
| inline

publish a vector of doubles

References helicsPublicationPublishComplexVector().

## ◆ publish() [9/12]

void helicscpp::Publication::publish | ( | DataBuffer & | buffer | ) |
| inline

publish a data buffer value

References helicscpp::DataBuffer::getHelicsDataBuffer(), and helicsPublicationPublishDataBuffer().

## ◆ publish() [10/12]

void helicscpp::Publication::publish | ( | double | val | ) |
| inline

publish a double

References helicsPublicationPublishDouble().

## ◆ publish() [11/12]

void helicscpp::Publication::publish | ( | int64_t | val | ) |
| inline

publish an int64_t value

References helicsPublicationPublishInteger().

## ◆ publish() [12/12]

void helicscpp::Publication::publish | ( | std::complex< double > | cmplx | ) |
| inline

publish a complex number

References helicsPublicationPublishComplex().

## ◆ publishComplex()

void helicscpp::Publication::publishComplex | ( | const double * | data,
|  | int | length
| ) |  |
| inline

publish a vector of doubles with adjacent elements making up the real and imaginary parts of a complex number

References helicsPublicationPublishComplexVector().

## ◆ setInfo()

void helicscpp::Publication::setInfo | ( | const std::string & | info | ) |
| inline

set the interface information field of the publication

References helicsPublicationSetInfo().

## ◆ setTag()

void helicscpp::Publication::setTag | ( | const std::string & | tagname,
|  | const std::string & | tagvalue
| ) |  |
| inline

set the value of a tag for the publication

References helicsPublicationSetTag().

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

- Publication.hpp