# UnifiedContainer Class Reference
[IdentifiableObject collections handlers]

IdentifiableObject childs collection handling. More...

Inheritance diagram for UnifiedContainer:
[legend]

List of all members.

## Public Member Functions

| getParentIdField ()
| getChildIdField ()
| __construct (Identifiable $parent, GenericDAO $dao, $lazy=true)
| __sleep ()
| __wakeup ()
| getParentObject ()
| getDao ()
| isLazy ()
| isFetched ()
| setCriteria (Criteria $criteria)
| getCriteria ()
| setObjectComparator (Comparator $comparator)
| setList ($list)
| mergeList (array $list)
| getList ()
| getCount ()
| fetch ()
| save ()
| clean ()
| dropList ()

## Static Public Member Functions

static | destroy (UnifiedContainer $container)

## Protected Member Functions

| fetchList ()

## Protected Attributes

| $worker = null
| $parent = null
| $dao = null
| $lazy = true
| $fetched = false
| $list = array()
| $clones = array()
| $workerClass = null
| $daoClass = null
| $comparator = null

## Private Member Functions

| importList (array $list)
| syncClones ()

## Detailed Description

IdentifiableObject childs collection handling.

See also:
  StorableContainer for alternative

Definition at line 60 of file UnifiedContainer.class.php.

## Constructor & Destructor Documentation

UnifiedContainer::__construct | ( | Identifiable $ | parent,
|  | GenericDAO $ | dao,
|  | $ | lazy = `true` |
| ) |  |  |

Reimplemented in ManyToManyLinked, and OneToManyLinked.

Definition at line 82 of file UnifiedContainer.class.php.

References $lazy, GenericDAO::getObjectName(), Assert::isBoolean(), Assert::isInstance(), and SerializedObjectComparator::me().

Here is the call graph for this function:

## Member Function Documentation

UnifiedContainer::__sleep | ( |  | ) |

Definition at line 97 of file UnifiedContainer.class.php.

UnifiedContainer::__wakeup | ( |  | ) |

Definition at line 104 of file UnifiedContainer.class.php.

References Singleton::getInstance().

Here is the call graph for this function:

UnifiedContainer::clean | ( |  | ) |

Returns:
  UnifiedContainer

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

Referenced by dropList().

static UnifiedContainer::destroy | ( | UnifiedContainer $ | container | ) | `[static]`

Definition at line 362 of file UnifiedContainer.class.php.

UnifiedContainer::dropList | ( |  | ) |

Returns:
  UnifiedContainer

Definition at line 353 of file UnifiedContainer.class.php.

References clean().

Here is the call graph for this function:

UnifiedContainer::fetch | ( |  | ) |

Exceptions:

  | WrongStateException |

Returns:
  UnifiedContainer

Definition at line 223 of file UnifiedContainer.class.php.

References fetchList().

Referenced by getList().

Here is the call graph for this function:

UnifiedContainer::fetchList | ( |  | ) | `[protected]`

Definition at line 367 of file UnifiedContainer.class.php.

References $list, getChildIdField(), and importList().

Referenced by fetch().

Here is the call graph for this function:

UnifiedContainer::getChildIdField | ( |  | ) | `[abstract]`

Reimplemented in OneToManyLinked.

Referenced by fetchList().

UnifiedContainer::getCount | ( |  | ) |

Definition at line 208 of file UnifiedContainer.class.php.

References isFetched().

Here is the call graph for this function:

UnifiedContainer::getCriteria | ( |  | ) |

Returns:
  Criteria

Definition at line 158 of file UnifiedContainer.class.php.

UnifiedContainer::getDao | ( |  | ) |

Returns:
  GenericDAO

Definition at line 118 of file UnifiedContainer.class.php.

Referenced by save().

UnifiedContainer::getList | ( |  | ) |

Definition at line 200 of file UnifiedContainer.class.php.

References fetch(), and isFetched().

Here is the call graph for this function:

UnifiedContainer::getParentIdField | ( |  | ) | `[abstract]`

UnifiedContainer::getParentObject | ( |  | ) |

Definition at line 110 of file UnifiedContainer.class.php.

UnifiedContainer::importList | ( | array $ | list | ) | `[private]`

Returns:
  UnifiedContainer

Definition at line 397 of file UnifiedContainer.class.php.

References mergeList(), and syncClones().

Referenced by fetchList().

Here is the call graph for this function:

UnifiedContainer::isFetched | ( |  | ) |

Definition at line 128 of file UnifiedContainer.class.php.

Referenced by getCount(), and getList().

UnifiedContainer::isLazy | ( |  | ) |

Definition at line 123 of file UnifiedContainer.class.php.

UnifiedContainer::mergeList | ( | array $ | list | ) |

Returns:
  UnifiedContainer

Definition at line 186 of file UnifiedContainer.class.php.

Referenced by importList().

UnifiedContainer::save | ( |  | ) |

Exceptions:

  | WrongArgumentException |

Returns:
  UnifiedContainer

Definition at line 245 of file UnifiedContainer.class.php.

References $clones, $list, DBPool::getByDao(), getDao(), Assert::isArray(), and syncClones().

Here is the call graph for this function:

UnifiedContainer::setCriteria | ( | Criteria $ | criteria | ) |

Exceptions:

  | WrongArgumentException |

Returns:
  UnifiedContainer

Definition at line 137 of file UnifiedContainer.class.php.

References Criteria::getDao(), Assert::isTrue(), and Criteria::setDao().

Here is the call graph for this function:

UnifiedContainer::setList | ( | $ | list | ) |

Exceptions:

  | WrongArgumentException |

Returns:
  UnifiedContainer

Definition at line 174 of file UnifiedContainer.class.php.

References $list, and Assert::isArray().

Here is the call graph for this function:

UnifiedContainer::setObjectComparator | ( | Comparator $ | comparator | ) |

Definition at line 163 of file UnifiedContainer.class.php.

UnifiedContainer::syncClones | ( |  | ) | `[private]`

Returns:
  UnifiedContainer

Definition at line 409 of file UnifiedContainer.class.php.

Referenced by importList(), and save().

## Member Data Documentation

UnifiedContainer::$clones = array()`[protected]`

Definition at line 71 of file UnifiedContainer.class.php.

Referenced by save().

UnifiedContainer::$comparator = null`[protected]`

Definition at line 77 of file UnifiedContainer.class.php.

UnifiedContainer::$dao = null`[protected]`

Definition at line 65 of file UnifiedContainer.class.php.

UnifiedContainer::$daoClass = null`[protected]`

Definition at line 75 of file UnifiedContainer.class.php.

UnifiedContainer::$fetched = false`[protected]`

Definition at line 68 of file UnifiedContainer.class.php.

UnifiedContainer::$lazy = true`[protected]`

Definition at line 67 of file UnifiedContainer.class.php.

Referenced by __construct(), OneToManyLinked::__construct(), and ManyToManyLinked::__construct().

UnifiedContainer::$list = array()`[protected]`

Definition at line 70 of file UnifiedContainer.class.php.

Referenced by fetchList(), save(), and setList().

UnifiedContainer::$parent = null`[protected]`

Definition at line 63 of file UnifiedContainer.class.php.

UnifiedContainer::$worker = null`[protected]`

Definition at line 62 of file UnifiedContainer.class.php.

Referenced by OneToManyLinked::__construct(), and ManyToManyLinked::__construct().

UnifiedContainer::$workerClass = null`[protected]`

Definition at line 74 of file UnifiedContainer.class.php.

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

- main/UnifiedContainer/UnifiedContainer.class.php