Definition at line 2065 of file filter.h.
OSB_LIB::FilterManager::FilterManager | ( | ) | [private] |
Constructor to avoid multiple instance.
void OSB_LIB::FilterManager::buildFilterVersions | ( | ) | [private] |
Rebuild all the filter versions.
This will rebuild all the filter versions if there is any change in the filter expressions or filter conditions.
Filter::Oid OSB_LIB::FilterManager::creFilter | ( | OSB_DB::Session & | session, | |
std::string & | name, | |||
std::string & | des | |||
) |
This will create a new filter object with the given data and insert it into the database.
session | Database session to use. | |
name | Name of the filter. | |
des | Description for the filter. |
Exception | for the following:
|
FilterCond::Oid OSB_LIB::FilterManager::creFilterCond | ( | OSB_DB::Session & | session, | |
FilterType | ft, | |||
long | targetId, | |||
OperatorType | op | |||
) |
This will create a new filter condition object with the given data and insert it into the database.
session | Database session to use. | |
ft | Type of filter condition. | |
targetId | Target id of the filter condition object. | |
op | Operator to apply to evaluate the filter condition. |
FilterExpr::Oid OSB_LIB::FilterManager::creFilterExpr | ( | OSB_DB::Session & | session, | |
const FilterCond::Oid & | fcId = FilterCond::Oid() , |
|||
const FilterExpr::Oid & | lhsfeId = FilterExpr::Oid() , |
|||
const FilterExpr::Oid & | rhsfeId = FilterExpr::Oid() , |
|||
OperatorType | op = otUnknown | |||
) |
This will create a new filter expression object with the given data and insert it into the database.
session | Database session to use. | |
fcId | Filter Condition id. | |
lhsfeId | Left hand side filter expression id. | |
rhsfeId | Right hand side filter expression id. | |
op | Operator to evaluate this filter expression. |
Exception | for foreign key violation. |
FilterVersion::Oid OSB_LIB::FilterManager::creFilterVersion | ( | OSB_DB::Session & | session, | |
const Filter::Oid & | filtId, | |||
const std::string & | name | |||
) |
This will create a new filter version object with the given data and insert it into the database.
session | Database session to use. | |
filtId | Id of the filter. | |
name | Name of the filter version. |
Exception | for the following:
|
void OSB_LIB::FilterManager::delFilter | ( | OSB_DB::Session & | session, | |
const Filter::Oid & | oid | |||
) |
This will remove the filter.
session | Database session to use. | |
oid | Unique object id to identify the filter. |
Exception | if object not found. |
void OSB_LIB::FilterManager::delFilterCond | ( | OSB_DB::Session & | session, | |
const FilterCond::Oid & | oid | |||
) |
This will remove the filter condition.
session | Database session to use. | |
oid | Unique object id to identify the filter condition. |
Exception | if object not found. |
void OSB_LIB::FilterManager::delFilterExpr | ( | OSB_DB::Session & | session, | |
const FilterExpr::Oid & | oid | |||
) |
This will remove the filter expression.
session | Database session to use. | |
oid | Unique object id to identify the filter expression. |
Exception | if object not found. |
void OSB_LIB::FilterManager::delFilterVersion | ( | OSB_DB::Session & | session, | |
const FilterVersion::Oid & | oid | |||
) |
This will remove the filter version object.
session | Database session to use. | |
oid | Unique object id to identify the filter version. |
Exception | if object not found. |
const Filter* OSB_LIB::FilterManager::findFilter | ( | const Filter::Oid & | oid | ) |
Find the filter object for the given object id.
oid | Unique object id to identify the filter object. |
Exception | if object not found. |
const FilterCond* OSB_LIB::FilterManager::findFilterCond | ( | const FilterCond::Oid & | oid | ) |
Find the filter condition object for the given object id.
oid | Unique object id to identify the filter condition object. |
Exception | if object not found. |
const FilterExpr* OSB_LIB::FilterManager::findFilterExpr | ( | const FilterExpr::Oid & | oid | ) |
Find the filter expression object for the given object id.
oid | Unique object id to identify the filter expression object. |
Exception | if object not found. |
const FilterVersion* OSB_LIB::FilterManager::findFilterVersion | ( | const FilterVersion::Oid & | oid | ) |
Find the filter version object for the given object id.
oid | Unique object id to identify the filter version object. |
Exception | if object not found. |
size_t OSB_LIB::FilterManager::freezeFilterCond | ( | OSB_DB::Session & | session, | |
const FilterCond::Oid & | oid, | |||
std::vector< OsbError > & | errors | |||
) |
Change the object status from 'editable' to 'standby'.
session | Database session. | |
oid | Id of the filter condition to change. | |
errors | Container of error messanges. |
size_t OSB_LIB::FilterManager::freezeFilterExpr | ( | OSB_DB::Session & | session, | |
const FilterExpr::Oid & | oid, | |||
std::vector< OsbError > & | errors | |||
) |
Change the object status from 'editable' to 'standby'.
session | Database session. | |
oid | Id of the filter expression to change. | |
errors | Container of error messanges. |
size_t OSB_LIB::FilterManager::freezeFilterVersion | ( | OSB_DB::Session & | session, | |
const FilterVersion::Oid & | oid, | |||
std::vector< OsbError > & | errors | |||
) |
Change the object status from 'editable' to 'standby'.
session | Database session. | |
oid | Id of the filter version to change. | |
errors | Container of error messanges. |
const Filter& OSB_LIB::FilterManager::getFilter | ( | const Filter::Oid & | oid | ) |
Get the filter object using object id and return the reference to that object.
oid | Unique object id to identify the filter object. |
Exception | if object not found. |
const FilterCond& OSB_LIB::FilterManager::getFilterCond | ( | const FilterCond::Oid & | oid | ) |
Get the filter condition object using object id and return the reference to that object.
oid | Unique object id to identify the filter condition object. |
Exception | if object not found. |
const FilterExpr& OSB_LIB::FilterManager::getFilterExpr | ( | const FilterExpr::Oid & | oid | ) |
Get the filter expression object using object id and return the reference to that object.
oid | Unique object id to identify the filter expression object. |
Exception | if object not found. |
static FilterManager* OSB_LIB::FilterManager::getFilterManager | ( | ) | [static] |
Returns the same instance of filter manager to everyone.
const FilterVersion& OSB_LIB::FilterManager::getFilterVersion | ( | const FilterVersion::Oid & | oid | ) |
Get the filter version object using object id and return the reference to that object.
oid | Unique object id to identify the filter version object. |
Exception | if object not found. |
void OSB_LIB::FilterManager::print | ( | ) |
This is for debugging purpose.
void OSB_LIB::FilterManager::read | ( | const OSB_DB::Session & | session | ) |
Intially load FilterManager from database.
session | Database session to use. |
OsbException | when encounter problems during fetching database. |
void OSB_LIB::FilterManager::readFilter | ( | const OSB_DB::Session & | session | ) | [private] |
Intially load filters from database.
session | The database session. |
OsbException | when encounter problems during fetching database. |
void OSB_LIB::FilterManager::readFilterCond | ( | const OSB_DB::Session & | session | ) | [private] |
Intially load filter conditions from database.
session | The database session. |
OsbException | when encounter problems during fetching database. |
void OSB_LIB::FilterManager::readFilterExpr | ( | const OSB_DB::Session & | session | ) | [private] |
Intially load filter expressions from database.
session | The database session. |
OsbException | when encounter problems during fetching database. |
void OSB_LIB::FilterManager::readFilterVersion | ( | const OSB_DB::Session & | session | ) | [private] |
Intially load filter versions from database.
session | The database session. |
OsbException | when encounter problems during fetching database. |
size_t OSB_LIB::FilterManager::releaseFilterCond | ( | OSB_DB::Session & | session, | |
const FilterCond::Oid & | oid, | |||
std::vector< OsbError > & | errors | |||
) |
Change the object status from 'standby' to 'release'.
session | Database session. | |
oid | Id of the filter condition to change. | |
errors | Container of error messages. |
size_t OSB_LIB::FilterManager::releaseFilterExpr | ( | OSB_DB::Session & | session, | |
const FilterExpr::Oid & | oid, | |||
std::vector< OsbError > & | errors | |||
) |
Change the object status from 'standby' to 'release'.
session | Database session. | |
oid | Id of the filter expression to change. | |
errors | Container of error messanges. |
size_t OSB_LIB::FilterManager::releaseFilterVersion | ( | OSB_DB::Session & | session, | |
const FilterVersion::Oid & | oid, | |||
std::vector< OsbError > & | errors | |||
) |
Change the object status from 'standby' to 'release'.
session | Database session. | |
oid | Id of the filter version to change. | |
errors | Container of error messanges. |
size_t OSB_LIB::FilterManager::revokeFilterCond | ( | OSB_DB::Session & | session, | |
const FilterCond::Oid & | oid, | |||
std::vector< OsbError > & | errors | |||
) |
Change the object status from 'release' to 'standby'.
session | Database session. | |
oid | Id of the filter condition to change. | |
errors | Container of error messanges. |
size_t OSB_LIB::FilterManager::revokeFilterExpr | ( | OSB_DB::Session & | session, | |
const FilterExpr::Oid & | oid, | |||
std::vector< OsbError > & | errors | |||
) |
Change the object status from 'release' to 'standby'.
session | Database session. | |
oid | Id of the filter expression to change. | |
errors | Container of error messanges. |
size_t OSB_LIB::FilterManager::revokeFilterVersion | ( | OSB_DB::Session & | session, | |
const FilterVersion::Oid & | oid, | |||
std::vector< OsbError > & | errors | |||
) |
Change the object status from 'release' to 'standby'.
session | Database session. | |
oid | Id of the filter version to change. | |
errors | Container of error messanges. |
size_t OSB_LIB::FilterManager::unfreezeFilterCond | ( | OSB_DB::Session & | session, | |
const FilterCond::Oid & | oid, | |||
std::vector< OsbError > & | errors | |||
) |
Change the object status from 'standby' to 'editable'.
session | Database session. | |
oid | Id of the filter condition to change. | |
errors | Container of error messanges. |
size_t OSB_LIB::FilterManager::unfreezeFilterExpr | ( | OSB_DB::Session & | session, | |
const FilterExpr::Oid & | oid, | |||
std::vector< OsbError > & | errors | |||
) |
Change the object status from 'standby' to 'editable'.
session | Database session. | |
oid | Id of the filter expression to change. | |
errors | Container of error messanges. |
size_t OSB_LIB::FilterManager::unfreezeFilterVersion | ( | OSB_DB::Session & | session, | |
const FilterVersion::Oid & | oid, | |||
std::vector< OsbError > & | errors | |||
) |
Change the object status from 'standby' to 'editable'.
session | Database session. | |
oid | Id of the filter version to change. | |
errors | Container of error messanges. |
OsbError OSB_LIB::FilterManager::updFilter | ( | OSB_DB::Session & | session, | |
Filter & | filt | |||
) |
OsbError OSB_LIB::FilterManager::updFilterCond | ( | OSB_DB::Session & | session, | |
FilterCond & | fc | |||
) |
OsbError OSB_LIB::FilterManager::updFilterExpr | ( | OSB_DB::Session & | session, | |
FilterExpr & | fe | |||
) |
OsbError OSB_LIB::FilterManager::updFilterVersion | ( | OSB_DB::Session & | session, | |
FilterVersion & | fv | |||
) |
This will update the filter version with the available information.
session | Database session to use. | |
fv | FilterVersion object to use. |
Exception | if object not found. |
FilterManager* OSB_LIB::FilterManager::filtermgr_ [static, private] |
Filters OSB_LIB::FilterManager::filters_ [private] |