Doctrine\OXM\Mapping\ClassMetadataInfo::getName PHP Метод

getName() публичный Метод

The name of this XmlEntity class.
public getName ( ) : string
Результат string $name The XmlEntity class name.
    public function getName()
    {
        return $this->name;
    }

Usage Example

Пример #1
0
 /**
  * @test
  */
 public function itShouldMapProperly()
 {
     $class = new ClassMetadataInfo('Doctrine\\Tests\\OXM\\Mapping\\Entity');
     $this->assertEquals('Doctrine\\Tests\\OXM\\Mapping\\Entity', $class->getName());
     $class->mapField(array('fieldName' => 'squibble', 'type' => 'string', 'required' => true, 'direct' => true, 'id' => true, 'collection' => false, 'nullable' => false, 'getMethod' => 'getSquibble', 'setMethod' => 'setSquibble'));
     $this->assertTrue($class->hasField('squibble'));
     $this->assertEquals('string', $class->getTypeOfField('squibble'));
     $this->assertTrue($class->isRequired('squibble'));
     $this->assertTrue($class->isDirect('squibble'));
     $this->assertFalse($class->isCollection('squibble'));
     $this->assertFalse($class->isNullable('squibble'));
 }