protected function tryToGetJoinColumnAnnotationOfMappedBy($annotation){
        $result = null;
        if($annotation->targetEntity && $annotation->mappedBy) {
            $result = $this->getAnnotation(
                $annotation->targetEntity,
                $annotation->mappedBy,
                'Doctrine\ORM\Mapping\JoinColumn'
            );
            if ($result === null) {
                $result = $this->getAnnotation(
                    $annotation->targetEntity,
                    $annotation->mappedBy,
                    'Doctrine\ORM\Mapping\JoinColumns'
                );
            }
        }
        return $result;
    }