Doctrine\OXM\Mapping\MappingException::mappingNotFound PHP 메소드

mappingNotFound() 공개 정적인 메소드

public static mappingNotFound ( $className, $fieldName )
    public static function mappingNotFound($className, $fieldName)
    {
        return new self("No mapping found for field '{$fieldName}' on class '{$className}'.");
    }

Usage Example

예제 #1
0
 /**
  * @param string $fieldName
  * @return boolean
  *
  */
 public function isNullable($fieldName)
 {
     if (!isset($this->fieldMappings[$fieldName])) {
         throw MappingException::mappingNotFound($this->name, $fieldName);
     }
     return $this->fieldMappings[$fieldName]['nullable'] ? true : false;
 }