Jarves\Storage\AbstractStorage::configure PHP Method

configure() public method

Important call directly after the creation of this class.
public configure ( string $objectKey, Object $definition )
$objectKey string
$definition Object
    public function configure($objectKey, $definition)
    {
        $this->objectKey = \Jarves\Objects::normalizeObjectKey($objectKey);
        $this->definition = $definition;
        foreach ($this->definition->getFields() as $field) {
            if ($field->isPrimaryKey()) {
                $this->primaryKeys[] = $field->getId();
            }
        }
    }

Usage Example

Example #1
0
 public function configure($objectKey, $definition)
 {
     parent::configure($objectKey, $definition);
     if ($this->propelPrimaryKeys) {
         return;
     }
     $this->query = $this->getQueryClass();
     $this->tableMap = $this->query->getTableMap();
     $this->propelPrimaryKeys = $this->tableMap->getPrimaryKeys();
 }