Gets the mapping of a (regular) field that holds some data but not a
reference to another object.
public getFieldMapping ( string $fieldName ) : array | ||
$fieldName | string | The field name. |
return | array | The field mapping. |
public function itShouldInferGettersProperly() { $class = new ClassMetadataInfo('Doctrine\\Tests\\OXM\\Mapping\\Entity'); $class->mapField(array('fieldName' => 'squibble', 'type' => 'string')); $mapping = $class->getFieldMapping('squibble'); // todo - don't like relying on internal implementation $this->assertEquals('getSquibble', $mapping['getMethod']); $this->assertEquals('setSquibble', $mapping['setMethod']); }