PhoenixSwarm  3.5.0
Library to ease communication between daemons
Loading...
Searching...
No Matches
CheckStream< Function > Struct Reference

Generic Function Check function. More...

#include <Representation.h>

Static Public Member Functions

static bool check_stream (const std::string &fieldDescription, const Function &data, const Function &reference, std::ostream &out)
 Check Stream for a Function.
 

Detailed Description

Generic Function Check function.

Definition at line 159 of file Representation.h.

Member Function Documentation

◆ check_stream()

bool CheckStream< Function >::check_stream ( const std::string & fieldDescription,
const Function & data,
const Function & reference,
std::ostream & out )
static

Check Stream for a Function.

Parameters
fieldDescription: description of the field to be checked
data: data to be checked
reference: reference of the check
out: ostream used to collect feed back in case of error (std::cerr or a logger)
Returns
true on success, false otherwise

Definition at line 177 of file Representation.cpp.

177 {
178 bool b(true);
179 b &= CheckStream<PString>::check_stream(fieldDescription + "\n- Function::name", data.getName(), reference.getName(), out);
180 b &= CheckStream<PString>::check_stream(fieldDescription + "\n- Function::description", data.getDescription(), reference.getDescription(), out);
181 b &= CheckStream<std::vector<Data>>::check_stream(fieldDescription + "\n- Function::vecParam", data.getVecParam(), reference.getVecParam(), out);
182 b &= CheckStream<Data>::check_stream(fieldDescription + "\n- Function::returnValue", data.getReturnValue(), reference.getReturnValue(), out);
183 return b;
184}
const std::vector< Data > & getVecParam() const
Gets the vecParam of the Function.
const PString & getName() const
Gets the name of the Function.
const Data & getReturnValue() const
Gets the returnValue of the Function.
const PString & getDescription() const
Gets the description of the Function.
static bool check_stream(const std::string &fieldDescription, const Data &data, const Data &reference, std::ostream &out)
Check Stream for a Data.
static bool check_stream(const std::string &fieldDescription, const Function &data, const Function &reference, std::ostream &out)
Check Stream for a Function.

References CheckStream< Data >::check_stream(), check_stream(), Function::getDescription(), Function::getName(), Function::getReturnValue(), and Function::getVecParam().

Referenced by check_stream().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

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