Пример #1
0
 public function __construct(array $data, IEntityPreloadContainer $root = NULL)
 {
     $this->data = $data;
     $this->setDataIndex(NULL);
     $this->identification = $root ? $root->getIdentification() : uniqid();
 }
 protected function calculateCacheKey(QueryBuilder $builder, IEntityPreloadContainer $preloadIterator = NULL, $parent)
 {
     return md5($builder->getQuerySQL() . json_encode($builder->getQueryParameters()) . ($preloadIterator ? $preloadIterator->getIdentification() : json_encode($parent->getRawValue($this->metadata->name))));
 }
 protected function calculateCacheKey(QueryBuilder $builder, IEntityPreloadContainer $preloadIterator = NULL, IEntity $parent)
 {
     return md5($builder->getQuerySql() . json_encode($builder->getQueryParameters()) . ($preloadIterator ? $preloadIterator->getIdentification() : json_encode($parent->getValue('id'))));
 }