addInheritedAssociationMapping() 공개 메소드

This is mainly used to add inherited association mappings to derived classes.
public addInheritedAssociationMapping ( array $mapping ) : void
$mapping array
리턴 void
 public function testAddInheritedAssociationMapping()
 {
     $cm = new ClassMetadataInfo('stdClass');
     $mapping = array('fieldName' => 'assoc', 'reference' => true, 'type' => 'one', 'simple' => true);
     $cm->addInheritedAssociationMapping($mapping);
     $expected = array('assoc' => $mapping);
     $this->assertEquals($expected, $cm->associationMappings);
 }