# CommonDaoWorker Class Reference
[Root classes for building DAO hierarchies]

Tunable (aka manual) caching DAO worker. More...

Inheritance diagram for CommonDaoWorker:
[legend]

List of all members.

## Public Member Functions

| getById ($id, $expires=Cache::EXPIRES_MEDIUM)
| single object getters
| getByLogic (LogicalObject $logic, $expires=Cache::DO_NOT_CACHE)
| getByQuery (SelectQuery $query, $expires=Cache::DO_NOT_CACHE)
| getCustom (SelectQuery $query, $expires=Cache::DO_NOT_CACHE)
| getListByIds (array $ids, $expires=Cache::EXPIRES_MEDIUM)
| object's list getters
| getListByQuery (SelectQuery $query, $expires=Cache::DO_NOT_CACHE)
| getListByLogic (LogicalObject $logic, $expires=Cache::DO_NOT_CACHE)
| getPlainList ($expires=Cache::EXPIRES_MEDIUM)
| getTotalCount ($expires=Cache::DO_NOT_CACHE)
| getCustomList (SelectQuery $query, $expires=Cache::DO_NOT_CACHE)
| custom list getters
| getCustomRowList (SelectQuery $query, $expires=Cache::DO_NOT_CACHE)
| getQueryResult (SelectQuery $query, $expires=Cache::DO_NOT_CACHE)
| query result getters
| dropById ($id)
| erasers
| uncacheById ($id)
| uncachers
| uncacheByIds ($ids)
| uncacheLists ()

## Protected Member Functions

| cacheById (Identifiable $object, $expires=Cache::EXPIRES_MEDIUM)
| cachers
| cacheByQuery (SelectQuery $query, $object, $expires=Cache::DO_NOT_CACHE)
| cacheListByQuery (SelectQuery $query, $array)

## Detailed Description

Tunable (aka manual) caching DAO worker.

See also:
  SmartDaoWorker for auto-caching one.

Definition at line 19 of file CommonDaoWorker.class.php.

## Member Function Documentation

CommonDaoWorker::cacheById | ( | Identifiable $ | object,
|  | $ | expires = `Cache::EXPIRES_MEDIUM` |
| ) |  |  | `[protected]`

cachers

Reimplemented in NullDaoWorker, and TransparentDaoWorker.

Definition at line 425 of file CommonDaoWorker.class.php.

References Cache::DO_NOT_CACHE, Identifiable::getId(), BaseDaoWorker::makeIdKey(), and Cache::me().

Here is the call graph for this function:

CommonDaoWorker::cacheByQuery | ( | SelectQuery $ | query,
|  | $ | object,
|  | $ | expires = `Cache::DO_NOT_CACHE` |
| ) |  |  | `[protected]`

Reimplemented in CacheDaoWorker, NullDaoWorker, SmartDaoWorker, and VoodooDaoWorker.

Definition at line 442 of file CommonDaoWorker.class.php.

References Cache::DO_NOT_CACHE, BaseDaoWorker::makeQueryKey(), and Cache::me().

Referenced by TransparentDaoWorker::getByQuery(), TransparentDaoWorker::getCustom(), getCustom(), TransparentDaoWorker::getCustomList(), getCustomList(), TransparentDaoWorker::getCustomRowList(), getCustomRowList(), getListByQuery(), and getQueryResult().

Here is the call graph for this function:

CommonDaoWorker::cacheListByQuery | ( | SelectQuery $ | query,
|  | $ | array |
| ) |  |  | `[protected]`

Reimplemented in CacheDaoWorker, SmartDaoWorker, and VoodooDaoWorker.

Definition at line 461 of file CommonDaoWorker.class.php.

Referenced by TransparentDaoWorker::getListByQuery().

CommonDaoWorker::dropById | ( | $ | id | ) |

erasers

Reimplemented from BaseDaoWorker.

Definition at line 472 of file CommonDaoWorker.class.php.

CommonDaoWorker::getById | ( | $ | id,
|  | $ | expires = `Cache::EXPIRES_MEDIUM` |
| ) |  |  |

single object getters

Definition at line 23 of file CommonDaoWorker.class.php.

References BaseDaoWorker::cachedFetchObject(), DBField::create(), Cache::DO_NOT_CACHE, Expression::eq(), BaseDaoWorker::fetchObject(), BaseDaoWorker::getCachedById(), DBPool::me(), and Cache::NOT_FOUND.

Here is the call graph for this function:

CommonDaoWorker::getByLogic | ( | LogicalObject $ | logic,
|  | $ | expires = `Cache::DO_NOT_CACHE` |
| ) |  |  |

Definition at line 73 of file CommonDaoWorker.class.php.

References getByQuery().

Here is the call graph for this function:

CommonDaoWorker::getByQuery | ( | SelectQuery $ | query,
|  | $ | expires = `Cache::DO_NOT_CACHE` |
| ) |  |  |

Definition at line 83 of file CommonDaoWorker.class.php.

References BaseDaoWorker::cachedFetchObject(), Cache::DO_NOT_CACHE, BaseDaoWorker::fetchObject(), BaseDaoWorker::getCachedByQuery(), DBPool::me(), and Cache::NOT_FOUND.

Referenced by getByLogic().

Here is the call graph for this function:

CommonDaoWorker::getCustom | ( | SelectQuery $ | query,
|  | $ | expires = `Cache::DO_NOT_CACHE` |
| ) |  |  |

Definition at line 120 of file CommonDaoWorker.class.php.

References cacheByQuery(), Cache::DO_NOT_CACHE, DBPool::getByDao(), BaseDaoWorker::getCachedByQuery(), SelectQuery::getLimit(), DBPool::me(), Cache::NOT_FOUND, and SelectQuery::toDialectString().

Referenced by getTotalCount().

Here is the call graph for this function:

CommonDaoWorker::getCustomList | ( | SelectQuery $ | query,
|  | $ | expires = `Cache::DO_NOT_CACHE` |
| ) |  |  |

custom list getters

Definition at line 306 of file CommonDaoWorker.class.php.

References cacheByQuery(), Cache::DO_NOT_CACHE, DBPool::getByDao(), BaseDaoWorker::getCachedByQuery(), DBPool::me(), Cache::NOT_FOUND, and SelectQuery::toDialectString().

Here is the call graph for this function:

CommonDaoWorker::getCustomRowList | ( | SelectQuery $ | query,
|  | $ | expires = `Cache::DO_NOT_CACHE` |
| ) |  |  |

Definition at line 341 of file CommonDaoWorker.class.php.

References cacheByQuery(), Cache::DO_NOT_CACHE, DBPool::getByDao(), BaseDaoWorker::getCachedByQuery(), SelectQuery::getFieldsCount(), DBPool::me(), Cache::NOT_FOUND, and SelectQuery::toDialectString().

Here is the call graph for this function:

CommonDaoWorker::getListByIds | ( | array $ | ids,
|  | $ | expires = `Cache::EXPIRES_MEDIUM` |
| ) |  |  |

object's list getters

Definition at line 165 of file CommonDaoWorker.class.php.

References Cache::DO_NOT_CACHE, getListByLogic(), Expression::in(), BaseDaoWorker::makeIdKey(), Cache::me(), and Cache::NOT_FOUND.

Here is the call graph for this function:

CommonDaoWorker::getListByLogic | ( | LogicalObject $ | logic,
|  | $ | expires = `Cache::DO_NOT_CACHE` |
| ) |  |  |

Definition at line 277 of file CommonDaoWorker.class.php.

References getListByQuery().

Referenced by getListByIds().

Here is the call graph for this function:

CommonDaoWorker::getListByQuery | ( | SelectQuery $ | query,
|  | $ | expires = `Cache::DO_NOT_CACHE` |
| ) |  |  |

Definition at line 242 of file CommonDaoWorker.class.php.

References cacheByQuery(), Cache::DO_NOT_CACHE, BaseDaoWorker::fetchList(), BaseDaoWorker::getCachedByQuery(), DBPool::me(), Cache::NOT_FOUND, and SelectQuery::toDialectString().

Referenced by getListByLogic(), and getPlainList().

Here is the call graph for this function:

CommonDaoWorker::getPlainList | ( | $ | expires = `Cache::EXPIRES_MEDIUM` | ) |

Definition at line 287 of file CommonDaoWorker.class.php.

References getListByQuery().

Here is the call graph for this function:

CommonDaoWorker::getQueryResult | ( | SelectQuery $ | query,
|  | $ | expires = `Cache::DO_NOT_CACHE` |
| ) |  |  |

query result getters

Definition at line 384 of file CommonDaoWorker.class.php.

References cacheByQuery(), QueryResult::create(), SQLFunction::create(), Cache::DO_NOT_CACHE, BaseDaoWorker::fetchList(), DBPool::getByDao(), and BaseDaoWorker::getCachedByQuery().

Here is the call graph for this function:

CommonDaoWorker::getTotalCount | ( | $ | expires = `Cache::DO_NOT_CACHE` | ) |

Definition at line 294 of file CommonDaoWorker.class.php.

References getCustom().

Here is the call graph for this function:

CommonDaoWorker::uncacheById | ( | $ | id | ) |

uncachers

Reimplemented from BaseDaoWorker.

Reimplemented in DalayedDropDaoWorker, and NullDaoWorker.

Definition at line 484 of file CommonDaoWorker.class.php.

Referenced by uncacheByIds().

CommonDaoWorker::uncacheByIds | ( | $ | ids | ) |

Implements BaseDAO.

Reimplemented in NullDaoWorker.

Definition at line 491 of file CommonDaoWorker.class.php.

References uncacheById().

Here is the call graph for this function:

CommonDaoWorker::uncacheLists | ( |  | ) |

Implements BaseDAO.

Reimplemented in CacheDaoWorker, NullDaoWorker, SmartDaoWorker, and VoodooDaoWorker.

Definition at line 500 of file CommonDaoWorker.class.php.

References BaseDaoWorker::uncacheByQuery().

Here is the call graph for this function:

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

- main/DAOs/Workers/CommonDaoWorker.class.php