示例#1
0
 /**
  * Constructor
  * @param array $methodDetail
  */
 public function __construct(array $methodDetail)
 {
     $this->name = ApiGeenerator::stringToCamel($methodDetail['id']);
     $this->setDescription($methodDetail);
     $this->reference = isset($methodDetail['doc']['apigee:url']) ? html_entity_decode($methodDetail['doc']['apigee:url']) : '';
     $parameters = isset($methodDetail['params']) && is_array($methodDetail['params']) ? $methodDetail['params'] : array();
     $this->setParameters($parameters);
 }
示例#2
0
 /**
  * Constructor
  *
  * @param array $parameter
  * @param array $options
  */
 public function __construct(array $parameter, array $options = array())
 {
     $this->name = ApiGeenerator::stringToCamel($parameter['name'], false);
     $this->type = $parameter['type'];
     $this->description = isset($parameter['doc']['content']) ? $parameter['doc']['content'] : ucfirst($this->name);
 }