Pothos  0.5.0-ga4964040
The Pothos dataflow programming software suite
Public Member Functions | List of all members
Pothos::Util::BlockDescriptionParser Class Reference

#include <BlockDescription.hpp>

Public Member Functions

 BlockDescriptionParser (void)
 Create an empty block description parser. More...
 
void feedStream (std::istream &is)
 
void feedFilePath (const std::string &filePath)
 
std::vector< std::string > listFactories (void) const
 
std::string getJSONArray (const size_t indent=0) const
 
std::string getJSONObject (const std::string &factoryPath, const size_t indent=0) const
 

Detailed Description

Parse multiple sources for block description markup and manages the resulting JSON descriptions.

Constructor & Destructor Documentation

Pothos::Util::BlockDescriptionParser::BlockDescriptionParser ( void  )

Create an empty block description parser.

Member Function Documentation

void Pothos::Util::BlockDescriptionParser::feedFilePath ( const std::string &  filePath)

Feed the parser a source file with embedded markup.

Parameters
filePaththe path to a source file
Exceptions
SyntaxExceptionif the parsing failed
FileExceptionfor file access errors
void Pothos::Util::BlockDescriptionParser::feedStream ( std::istream &  is)

Feed the parser a source file with embedded markup.

Parameters
isan input stream like an open file
Exceptions
SyntaxExceptionif the parsing failed
std::string Pothos::Util::BlockDescriptionParser::getJSONArray ( const size_t  indent = 0) const

Get a JSON array containing all block descriptions.

Returns
a string containing a JSON array
std::string Pothos::Util::BlockDescriptionParser::getJSONObject ( const std::string &  factoryPath,
const size_t  indent = 0 
) const

Get a JSON object for a single block description.

Parameters
factoryPatha discovered factory path
Returns
a string containing a JSON object
std::vector<std::string> Pothos::Util::BlockDescriptionParser::listFactories ( void  ) const

Get all factories that were discovered when parsing.


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