ddc
Public Member Functions | Public Attributes | List of all members
TxChain Class Reference

#include <TermExpander.h>

Inheritance diagram for TxChain:
Inheritance graph
[legend]
Collaboration diagram for TxChain:
Collaboration graph
[legend]

Public Member Functions

 TxChain (const string &label=string("Chain"), const string &param=string(""))
 default constructor More...
 
virtual CTermExpanderclone (map< CTermExpander *, CTermExpander *> &xlate) const
 clone constructor More...
 
virtual ~TxChain (void)
 Destructor: sub-expanders are NOT implicitly destroyed! More...
 
void append (TxList &txl)
 append a TxList More...
 
void append (TxChain &txc)
 append contents of another chain (explicit un-nesting) More...
 
void append (CTermExpander *tx)
 append contents of another dispatcher, implicitly un-nesting chains More...
 
string chainString (const string &joinstr=string("|"))
 stringification for query canonicalization: joins chained labels on joinstr More...
 
virtual void expand (const set< string > &src, set< string > &dst)
 expand() calls each chained expander on the output of the previous expander More...
 
- Public Member Functions inherited from CTermExpander
 CTermExpander (const string &cls, const string &label, const string &param)
 Full constructor (abstract base classes only) More...
 
 CTermExpander (const string &label=string("NoLabel"), const string &param=string(""))
 Default constructor, to be overridden by subclasses. More...
 
virtual CTermExpandermapClone (map< CTermExpander *, CTermExpander *> &xlate) const
 clone constructor, handles sub-object cloning according to xlate map */ More...
 
virtual ~CTermExpander (void)
 Default destructor. More...
 
virtual void compile (void)
 set up object based on label and/or parameter string; default implementation does nothing More...
 
virtual string configString (void) const
 String form of this expander. Default is m_Class + " " + m_Label + " " + m_Param. More...
 
virtual void expand (const string &src, set< string > &dst)
 Expand a single term term to a set of terms dst. More...
 

Public Attributes

TxList m_Chain
 chain of sub-expanders; these must be explicitly freed More...
 
- Public Attributes inherited from CTermExpander
string m_Class
 class name for this expander More...
 
string m_Label
 unique name for this expander More...
 
string m_Param
 string argument(s) for this expander (parameters, for stringification) More...
 

Constructor & Destructor Documentation

◆ TxChain()

TxChain::TxChain ( const string &  label = string("Chain"),
const string &  param = string("") 
)
inline

default constructor

References CTermExpander::clone().

Here is the call graph for this function:

◆ ~TxChain()

virtual TxChain::~TxChain ( void  )
inlinevirtual

Destructor: sub-expanders are NOT implicitly destroyed!

References CTermExpander::expand().

Here is the call graph for this function:

Member Function Documentation

◆ clone()

CTermExpander * TxChain::clone ( map< CTermExpander *, CTermExpander *> &  xlate) const
virtual

clone constructor

Reimplemented from CTermExpander.

References m_Chain, CTermExpander::m_Label, and CTermExpander::m_Param.

◆ append() [1/3]

void TxChain::append ( TxList txl)

append a TxList

Referenced by TxDispatcher::ensureDefaultExpanders(), and TxDispatcher::getChain().

Here is the caller graph for this function:

◆ append() [2/3]

void TxChain::append ( TxChain txc)
inline

append contents of another chain (explicit un-nesting)

References m_Chain.

◆ append() [3/3]

void TxChain::append ( CTermExpander tx)

append contents of another dispatcher, implicitly un-nesting chains

References CTermExpander::m_Class.

◆ chainString()

string TxChain::chainString ( const string &  joinstr = string("|"))

stringification for query canonicalization: joins chained labels on joinstr

Referenced by TxDispatcher::getChain().

Here is the caller graph for this function:

◆ expand()

void TxChain::expand ( const set< string > &  src,
set< string > &  dst 
)
virtual

expand() calls each chained expander on the output of the previous expander

Reimplemented from CTermExpander.

Referenced by CDDCLeafServer::handle__expand_terms().

Here is the caller graph for this function:

Member Data Documentation

◆ m_Chain

TxList TxChain::m_Chain

chain of sub-expanders; these must be explicitly freed

Referenced by append(), clone(), and TxDispatcher::getChain().


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