Compounds | |
class | LcgInfo::LcgInfoException |
This class is used for exceptions when using the LcgInfoInterface class. More... | |
class | LcgInfo::LcgInfoInterface |
Main class of the generic API to the LCG Information System. More... | |
class | LcgInfo::PredicateTree |
This class implements a binary tree of nodes that stores a logical predicate composed of boolean and comparison operators, and leaf elements. More... | |
class | LcgInfo::Querier |
This class (actually, extending ones, since this is not instantiable) is used to pose a query expressed in terms of the canonical schema, to the desired implementation specific information system. More... | |
class | LcgInfo::QueryTranslationException |
This class is used for exceptions when translating. More... | |
class | LcgInfo::QueryTranslator |
This class (actually, extending ones, since this is not instantiable) is used to translate a query posed to a canonical relational schema into a new query that can be posed to an equivalent schema (i.e.: containing the same actual information), in order to retrieve the same information. More... | |
class | LcgInfo::SQLPredicateTree |
This class is the base for those implementing a binary tree of nodes that stores a SQL "WHERE predicate". More... | |
class | LcgInfo::SQLQueryTranslator |
This class (actually, extending ones, since this is not instantiable) is used to translate a query posed to a canonical relational schema into a new query that can be posed to an equivalent schema (i.e.: containing the same actual information), in order to retrieve the same information. More... | |
class | LcgInfo::SQLtoLDAPPredicateTree |
This class implements a binary tree of nodes that stores a SQL "WHERE predicate". More... | |
class | LcgInfo::SQLtoLDAPQuerier |
This class is used to pose a SQL query expressed in terms of the canonical schema, to the implementated LDAP information system. More... | |
class | LcgInfo::SQLtoLDAPQueryTranslator |
This class implements the translation from a original SQL query to a LDAP one. More... | |
class | LcgInfo::SQLtoSQLPredicateTree |
This class implements a binary tree of nodes that stores a SQL "WHERE predicate", that can translate it to a new schema, and that can evaluate it, outputing a SQL string. More... | |
class | LcgInfo::SQLtoSQLQuerier |
This class is used to pose a SQL query expressed in terms of the canonical schema, to the implementated SQL information system. More... | |
class | LcgInfo::SQLtoSQLQueryTranslator |
This class is used to translate an SQL query posed to a canonical relational schema into a new SQL query that can be posed to an equivalent schema (i.e.: containing the same actual information), in order to retrieve the same information. More... | |
class | LcgInfo::TableRowTranslator |
This class is used to map canonical GLUE table and row names to implementation specific table and row names. More... | |
Typedefs | |
typedef Querier * | create_Querier () |
A function returning a pointer to a Querier object. More... | |
typedef void | destroy_Querier (Querier *) |
A function accepting a pointer to a Querier object and returning nothing. More... | |
Functions | |
void | tokenizeStr (std::string const &pStr, std::vector< std::string > &pTokens, std::string const &pDelimiters="\t") |
Splits pStr into tokens delimited by the characters contained in the pDelimiters string. More... | |
void | tokenizeStrWithIndices (std::string const &pStr, std::vector< std::string > &pTokens, std::vector< short int > &pIndices, std::string const &pDelimiters="\t") |
Splits pStr into tokens delimited by the characters contained in the pDelimiters string. More... | |
void | delLeadingChars (std::string &pStr, std::string const &pChars="\t") |
Erases all the characters until the first character of pStr that is not contained in the pChars string. More... | |
void | delEndingChars (std::string &pStr, std::string const &pChars="\t") |
Erases the last characters of pStr that are contained in the pChars string, until the first that is not contained. More... | |
void | delSurroundingChars (std::string &pStr, std::string const &pChars="\t") |
Erases the first and last characters of pStr that are contained in the pChars string, until the first (and last) that is not contained. More... | |
bool | nocaseCompare (std::string const &pStr1, std::string const &pStr2) |
Compares two strings ignoring the case of their letters, and returns true if they are equal and false otherwise. More... | |
bool | isNumber (std::string const &pStr) |
Checks if the specified string is a well-formed number. More... | |
bool | isLiteral (std::string const &pStr) |
Checks if the specified string is a literal; i.e. More... | |
std::string | int2str (int const &pVal) |
Returns a string representing the specified int value. More... | |
int | str2int (std::string const &pStr) |
Returns an int for which the specified string is a representation. More... | |
void | escapeLiterals (std::string &pStr, std::string const &pChars="\t", char const &pEscape='\\', char const &pDelimiter='\'') |
Looks for literals (substrings delimited by pDelimiter) in pStr, and inside them, escapes the specified pChars by adding the pEscape char before them. | |
void | unescapeLiterals (std::string &pStr, std::string const &pChars="\t", char const &pEscape='\\', char const &pDelimiter='\'') |
Looks for literals (substrings delimited by pDelimiter) in pStr, and inside them, findes the specified pChars that are escaped by the pEscape char, and delete that pEscape char (unescapes them). | |
std::string | extractTable (std::string const &pStr) |
Extracts the table name of the specified table.row string. More... | |
std::string | extractRow (std::string const &pStr) |
Extracts the row name of the specified table.row string. More... |
The main class is the LcgInfoInterface which uses the libfactory::LibFactory class to load the appropriate Querier object (actually a class extending that abstract one) from a dynamic library. The Querier objects contain QueryTranslator objects and interfaces. The first translate the original query (created to be posed against a canonical view of the information schema of the system) to one that can be posed to the implementation specific information system (can be LDAP, SQL...). The interface effectively poses the queries. These classes (and some auxiliary ones) are all under the LcgInfo namespace. The LcgConfigBuffer::ConfigBuffer class is also used as the reader and container of the configuration information.
|
A function returning a pointer to a Querier object. This is the type of the method that creates the actual Querier object (of an extending class), and that has to be implemented as external to make it loadable by libfactory::LibFactory Definition at line 83 of file Querier.h. Referenced by LcgInfo::LcgInfoInterface::connect. |
|
A function accepting a pointer to a Querier object and returning nothing. This is the type of the method that destroy a Querier object (of an extending class), and that has to be implemented as external to make it loadable by libfactory::LibFactory Definition at line 91 of file Querier.h. Referenced by LcgInfo::LcgInfoInterface::connect. |
|
Erases the last characters of pStr that are contained in the pChars string, until the first that is not contained.
Definition at line 58 of file TranslatorsUtils.cpp. |
|
Erases all the characters until the first character of pStr that is not contained in the pChars string.
Definition at line 53 of file TranslatorsUtils.cpp. |
|
Erases the first and last characters of pStr that are contained in the pChars string, until the first (and last) that is not contained.
Definition at line 64 of file TranslatorsUtils.cpp. Referenced by LcgInfo::SQLPredicateTree::insertPredicate, and LcgInfo::TableRowTranslator::mapTableRow. |
|
Extracts the row name of the specified table.row string. It just returns the part that is after the last point of the string. Definition at line 177 of file TranslatorsUtils.cpp. Referenced by LcgInfo::SQLtoLDAPQueryTranslator::translateQuery. |
|
Extracts the table name of the specified table.row string. It just removes the part that is after the last point of the string, and that last point itself. Definition at line 171 of file TranslatorsUtils.cpp. Referenced by LcgInfo::PredicateTree::addAndPredicate, LcgInfo::PredicateTree::translate, LcgInfo::SQLtoLDAPQueryTranslator::translateQuery, and LcgInfo::SQLQueryTranslator::translateSemantic. |
|
Returns a string representing the specified int value.
Definition at line 101 of file TranslatorsUtils.cpp. Referenced by LcgInfo::LcgInfoInterface::connect, LcgInfo::SQLtoSQLPredicateTree::evaluate, LcgInfo::SQLtoLDAPPredicateTree::evaluate, LcgInfo::SQLtoSQLQuerier::query, LcgInfo::SQLtoLDAPQuerier::query, LcgInfo::QueryTranslator::QueryTranslator, LcgInfo::SQLtoSQLQuerier::setConfig, LcgInfo::SQLtoLDAPQuerier::setConfig, LcgInfo::TableRowTranslator::TableRowTranslator, LcgInfo::PredicateTree::translate, LcgInfo::SQLtoLDAPQueryTranslator::translateQuery, and LcgInfo::SQLQueryTranslator::translateSemantic. |
|
Checks if the specified string is a literal; i.e. it is a string between double commas ("), possibly preceded and followed by some spaces or tabs.
Definition at line 93 of file TranslatorsUtils.cpp. Referenced by LcgInfo::PredicateTree::addAndPredicate, LcgInfo::SQLtoLDAPPredicateTree::evaluate, LcgInfo::PredicateTree::relatesTables, and LcgInfo::PredicateTree::translate. |
|
Checks if the specified string is a well-formed number.
Definition at line 85 of file TranslatorsUtils.cpp. Referenced by LcgInfo::PredicateTree::addAndPredicate, LcgInfo::SQLtoLDAPPredicateTree::evaluate, LcgInfo::PredicateTree::relatesTables, and LcgInfo::PredicateTree::translate. |
|
Compares two strings ignoring the case of their letters, and returns true if they are equal and false otherwise.
Definition at line 69 of file TranslatorsUtils.cpp. Referenced by LcgInfo::SQLtoSQLPredicateTree::evaluate, LcgInfo::SQLtoLDAPPredicateTree::evaluate, LcgInfo::PredicateTree::isBooleanOp, and LcgInfo::SQLQueryTranslator::translateSemantic. |
|
Returns an int for which the specified string is a representation.
Definition at line 107 of file TranslatorsUtils.cpp. Referenced by LcgInfo::SQLtoLDAPQuerier::query. |
|
Splits pStr into tokens delimited by the characters contained in the pDelimiters string. The result is returned as a vector of strings, whose elements are the tokens.
Referenced by LcgInfo::PredicateTree::addAndPredicate, LcgInfo::TableRowTranslator::mapTableRow, and LcgInfo::SQLtoLDAPQuerier::query. |
|
Splits pStr into tokens delimited by the characters contained in the pDelimiters string. The result is returned as a vector of strings, whose elements are the tokens, and a vectors of string:size_type variables, whose elements indicate the position of each of this tokens in the original string.
Referenced by LcgInfo::SQLtoLDAPQueryTranslator::translateQuery, and LcgInfo::SQLQueryTranslator::translateSemantic. |