예제 #1
0
파일: PhpGenerator.php 프로젝트: gdbots/pbj
 /**
  * {@inheritdoc}
  */
 protected function getSchemaTarget(SchemaDescriptor $schema, $filename, $directory = null, $isLatest = false)
 {
     $filename = str_replace(['{className}'], [StringUtils::toCamelFromSlug($schema->getId()->getMessage())], $filename);
     $directory = str_replace('\\', '/', $schema->getLanguage('php')->get('namespace'));
     return parent::getSchemaTarget($schema, $filename, $directory, $isLatest);
 }
예제 #2
0
 /**
  * @param SchemaDescriptor $a
  * @param SchemaDescriptor $b
  *
  * @return bool
  */
 public function isSameNamespace(SchemaDescriptor $a, SchemaDescriptor $b)
 {
     return $a->getLanguage('php')->get('namespace') == $b->getLanguage('php')->get('namespace');
 }