예제 #1
0
 public function testClassName()
 {
     $meta = new ResourceMetadata('Resource\\Test');
     $this->assertEquals('Resource\\Test', $meta->getClassName());
     $meta->setClassName('Resource\\TestTwo');
     $this->assertEquals('Resource\\TestTwo', $meta->getClassName());
 }
예제 #2
0
 /**
  * Constructor.
  *
  * @param \BedRest\Resource\Mapping\ResourceMetadata $resourceMetadata
  * @param \BedRest\Model\Doctrine\Mapper             $dataMapper
  */
 public function __construct(ResourceMetadata $resourceMetadata, Mapper $dataMapper)
 {
     $this->resourceMetadata = $resourceMetadata;
     $this->resourceClassName = $resourceMetadata->getClassName();
     $this->dataMapper = $dataMapper;
 }