BusBoy  2
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
Public Member Functions | Protected Member Functions | List of all members
BUSBOY::Algorithm Class Referenceabstract

Algorithm developers must extend this class to implement an algorithm. More...

#include <Algorithm.h>

Public Member Functions

virtual void executeAlgorithm (AlgorithmData &data, AlgorithmContext &context)=0
 Algorithm developers must implement this method. More...
 
void addInputDataset (const std::string &name)
 equivalent to addInputDataset(name, false, false) More...
 
void addInputDataset (const std::string &name, bool optional)
 equivalent to addInputDataset(name, optional, false) More...
 
void addInputDataset (const std::string &name, bool optional, bool excludeFromKeyspace)
 
void addOutputDataset (const std::string &name)
 
std::set< std::string > getInputDatasets () const
 
std::set< std::string > getRequiredInputDatasets () const
 
std::set< std::string > getOptionalInputDatasets () const
 
std::set< std::string > getExcludedInputDatasets () const
 
std::set< std::string > getOutputDatasets () const
 
bool isInputDatasetOptional (const std::string &name) const
 
bool isInputDatasetExcludedFromKeyspace (const std::string &name) const
 
void addExpectedDimension (const DataKeyDimension &dim)
 Specify an expected dimension in the input data. More...
 
std::set< DataKeyDimensiongetExpectedDimensions () const
 
 ~Algorithm ()
 

Protected Member Functions

 Algorithm ()
 

Detailed Description

Algorithm developers must extend this class to implement an algorithm.

Algorithm objects should be stateless. If a stateful object is needed, this should delegate to another class.

Constructor & Destructor Documentation

BUSBOY::Algorithm::~Algorithm ( )
BUSBOY::Algorithm::Algorithm ( )
protected

Member Function Documentation

void BUSBOY::Algorithm::addExpectedDimension ( const DataKeyDimension dim)

Specify an expected dimension in the input data.

void BUSBOY::Algorithm::addInputDataset ( const std::string &  name)

equivalent to addInputDataset(name, false, false)

void BUSBOY::Algorithm::addInputDataset ( const std::string &  name,
bool  optional 
)

equivalent to addInputDataset(name, optional, false)

void BUSBOY::Algorithm::addInputDataset ( const std::string &  name,
bool  optional,
bool  excludeFromKeyspace 
)
void BUSBOY::Algorithm::addOutputDataset ( const std::string &  name)
virtual void BUSBOY::Algorithm::executeAlgorithm ( AlgorithmData data,
AlgorithmContext context 
)
pure virtual

Algorithm developers must implement this method.

If the algorithm fails, an exception should be thrown. Exceptions should derive from std::exception.

std::set< std::string > BUSBOY::Algorithm::getExcludedInputDatasets ( ) const
std::set< DataKeyDimension > BUSBOY::Algorithm::getExpectedDimensions ( ) const
std::set< std::string > BUSBOY::Algorithm::getInputDatasets ( ) const
std::set< std::string > BUSBOY::Algorithm::getOptionalInputDatasets ( ) const
std::set< std::string > BUSBOY::Algorithm::getOutputDatasets ( ) const
std::set< std::string > BUSBOY::Algorithm::getRequiredInputDatasets ( ) const
bool BUSBOY::Algorithm::isInputDatasetExcludedFromKeyspace ( const std::string &  name) const
bool BUSBOY::Algorithm::isInputDatasetOptional ( const std::string &  name) const

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

Copyright 2014 Google Inc. All rights reserved.