Luiza  v03-01
Public Member Functions | List of all members
luiza::LuizaSteerCheck Class Reference

#include <LuizaSteerCheck.h>

Public Member Functions

CMProcessorgetMProcs ()
 
ProcVec & getAProcs ()
 
ProcVec & getIProcs ()
 
int existsProcessor (const std::string &type, const std::string &name="")
 
ColVec & getGLORIACols () const
 
StringVec & getGLORIAFiles ()
 
sSet & getColsSet (const std::string &type, const std::string &name, CCProcessor *proc)
 
StringParameters * getGlobalParameters ()
 
void dumpColErrors (unsigned int i, std::ostream &stream, bool separators=false)
 
int addGLORIAFile (const std::string &file)
 
void remGLORIAFile (const std::string &file)
 
void changeGLORIAFilePos (unsigned int pos, unsigned int newPos)
 
void addProcessor (bool status, const std::string &name, const std::string &type, StringParameters *p=NULL)
 
void remProcessor (unsigned int index, bool status)
 
void activateProcessor (unsigned int index)
 
void deactivateProcessor (unsigned int index)
 
void changeProcessorPos (unsigned int pos, unsigned int newPos)
 
void consistencyCheck ()
 
bool saveAsXMLFile (const std::string &file)
 
void dump_information ()
 
sSet & getErrors ()
 
sSet & getPConditions ()
 
const std::string getCondition (unsigned int index)
 
void addCondition (const std::string &condition)
 
void repCondition (const std::string &oldCond, const std::string &newCond)
 
void remCondition (const std::string &condition)
 
bool saveAsDOTFile (const std::string &file)
 

Detailed Description

this class is a Marlin Steering File consistency check Tool. It can parse XML steering files using the marlin parser and search the gloria file(s) specified at the global section for available collections. Together with the active and inactive processors specified in the steering file and their respective collections it can perform a full consistency check and check for unavailable collections. The Program checks if an adequate available collection exists for every input collection of a processor.

(where input collection means a collection the processor requires as input, and output collections mean a collection that is created in the processor and marked as available for the upcoming processors)

Information about the consistency check can be dumped.

Author
Jan Engels, Benjamin Eberhardt, DESY
Version
Id
MarlinSteerCheck.h,v 1.32 2007-04-23 16:21:01 gaede Exp

Member Function Documentation

void luiza::LuizaSteerCheck::activateProcessor ( unsigned int  index)

Activate processor at the given index

References consistencyCheck().

void luiza::LuizaSteerCheck::addCondition ( const std::string &  condition)

Add a new Condition

int luiza::LuizaSteerCheck::addGLORIAFile ( const std::string &  file)

Add GLORIA file and read all collections inside it

void luiza::LuizaSteerCheck::addProcessor ( bool  status,
const std::string &  name,
const std::string &  type,
StringParameters *  p = NULL 
)

Add a new processor

References consistencyCheck().

void luiza::LuizaSteerCheck::changeGLORIAFilePos ( unsigned int  pos,
unsigned int  newPos 
)

Change the GLORIA File at the given index to the new given position

void luiza::LuizaSteerCheck::changeProcessorPos ( unsigned int  pos,
unsigned int  newPos 
)

Change the active processor at the given index to the new given position

References consistencyCheck().

void luiza::LuizaSteerCheck::consistencyCheck ( )

Performs a check at all active processors to search for unavailable collections

References getGLORIACols().

Referenced by activateProcessor(), addProcessor(), changeProcessorPos(), deactivateProcessor(), and remProcessor().

void luiza::LuizaSteerCheck::deactivateProcessor ( unsigned int  index)

Deactivate processor at the given index

References consistencyCheck().

void luiza::LuizaSteerCheck::dump_information ( )

Dumps all information read from the steering file to stdout

References dumpColErrors().

void luiza::LuizaSteerCheck::dumpColErrors ( unsigned int  i,
std::ostream &  stream,
bool  separators = false 
)

Writes the collection errors for the active processor with given index to the given stream

References getGLORIACols().

Referenced by dump_information().

int luiza::LuizaSteerCheck::existsProcessor ( const std::string &  type,
const std::string &  name = "" 
)

Check if a processor of the given type with the given name already exists Returns 0 if the processor does not exist Returns 1 if the processor exists and is active Returns 2 if the processor exists and is inactive

ProcVec& luiza::LuizaSteerCheck::getAProcs ( )
inline

Returns the Active Processors

sSet & luiza::LuizaSteerCheck::getColsSet ( const std::string &  type,
const std::string &  name,
CCProcessor proc 
)

Returns a list of all available Collections for a given type, name and processor (to use in a ComboBox)

References luiza::CCProcessor::getCols(), getGLORIACols(), and luiza::CCProcessor::isActive().

const string luiza::LuizaSteerCheck::getCondition ( unsigned int  index)

Returns the condition for a given index

sSet& luiza::LuizaSteerCheck::getErrors ( )
inline

Returns a set with all the errors found after performing a consistency check

StringParameters* luiza::LuizaSteerCheck::getGlobalParameters ( )
inline

Returns the Global Parameters

ColVec & luiza::LuizaSteerCheck::getGLORIACols ( ) const

Returns the collections read from GLORIA files

Referenced by consistencyCheck(), dumpColErrors(), getColsSet(), and saveAsDOTFile().

StringVec& luiza::LuizaSteerCheck::getGLORIAFiles ( )
inline

Returns the names of the GLORIA files found in the global section

Referenced by saveAsDOTFile().

ProcVec& luiza::LuizaSteerCheck::getIProcs ( )
inline

Returns the Inactive Processors

CMProcessor* luiza::LuizaSteerCheck::getMProcs ( )
inline

Returns the Luiza Processors

sSet& luiza::LuizaSteerCheck::getPConditions ( )
inline

Returns a set with all the processor's conditions

void luiza::LuizaSteerCheck::remCondition ( const std::string &  condition)

Removes the given condition

void luiza::LuizaSteerCheck::remGLORIAFile ( const std::string &  file)

Remove GLORIA file and all collections associated to it

void luiza::LuizaSteerCheck::remProcessor ( unsigned int  index,
bool  status 
)

Remove processor with the given status at the given index

References consistencyCheck().

void luiza::LuizaSteerCheck::repCondition ( const std::string &  oldCond,
const std::string &  newCond 
)

Replace a Condition

bool luiza::LuizaSteerCheck::saveAsDOTFile ( const std::string &  file)

Saves steering file in dot format

References getGLORIACols(), and getGLORIAFiles().

bool luiza::LuizaSteerCheck::saveAsXMLFile ( const std::string &  file)

Saves the data to an XML file with the given name Returns false if error occured


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