Skip to content

Commit

Permalink
[2.0][DDC-92] Fixed. Patch provided by Christian Heinrich. [DDC-274] …
Browse files Browse the repository at this point in the history
…Started some method renaming. [DDC-142] Fixed (join column names and discriminator column names dont support quoting) [DDC-258] Fixed.
  • Loading branch information
romanb committed Mar 5, 2010
1 parent 715da59 commit df6ca60
Show file tree
Hide file tree
Showing 77 changed files with 1,578 additions and 1,609 deletions.
6 changes: 3 additions & 3 deletions lib/Doctrine/Common/Annotations/AnnotationException.php
Expand Up @@ -32,14 +32,14 @@
* @author Jonathan Wage <jonwage@gmail.com>
* @author Roman Borschel <roman@code-factory.org>
*/
class AnnotationException extends \Doctrine\Common\DoctrineException
class AnnotationException extends \Doctrine\Common\CommonException
{
public static function syntaxError($message)
{
return new self('[Syntax Error] ' . $message);
}


public static function semanticalError($message)
{
return new self('[Semantical Error] ' . $message);
Expand Down
12 changes: 9 additions & 3 deletions lib/Doctrine/Common/Annotations/AnnotationReader.php
Expand Up @@ -105,7 +105,9 @@ public function setAnnotationNamespaceAlias($namespace, $alias)
public function getClassAnnotations(ReflectionClass $class)
{
$cacheKey = $class->getName() . self::$CACHE_SALT;


//FIXME: Just use ->fetch(), otherwise some drivers, i.e. APC will fetch twice because they
// implement contains() in terms of fetch(), *sigh*.
if ($this->_cache->contains($cacheKey)) {
return $this->_cache->fetch($cacheKey);
}
Expand Down Expand Up @@ -140,7 +142,9 @@ public function getClassAnnotation(ReflectionClass $class, $annotation)
public function getPropertyAnnotations(ReflectionProperty $property)
{
$cacheKey = $property->getDeclaringClass()->getName() . '$' . $property->getName() . self::$CACHE_SALT;


//FIXME: Just use ->fetch(), otherwise some drivers, i.e. APC will fetch twice because they
// implement contains() in terms of fetch(), *sigh*.
if ($this->_cache->contains($cacheKey)) {
return $this->_cache->fetch($cacheKey);
}
Expand Down Expand Up @@ -176,7 +180,9 @@ public function getPropertyAnnotation(ReflectionProperty $property, $annotation)
public function getMethodAnnotations(ReflectionMethod $method)
{
$cacheKey = $method->getDeclaringClass()->getName() . '#' . $method->getName() . self::$CACHE_SALT;


//FIXME: Just use ->fetch(), otherwise some drivers, i.e. APC will fetch twice because they
// implement contains() in terms of fetch(), *sigh*.
if ($this->_cache->contains($cacheKey)) {
return $this->_cache->fetch($cacheKey);
}
Expand Down

0 comments on commit df6ca60

Please sign in to comment.