Exemplo n.º 1
0
 /**
  * Return list of error reasons
  *
  * @return \Zuora\Object\Reason[]
  */
 public function getReasons()
 {
     $object = new \Zuora\Object\Object($this->getData());
     return $object->map('reasons', '\\Zuora\\Object\\Reason');
 }
Exemplo n.º 2
0
 /**
  * Map current result set to specific class
  *
  * @param string $entity
  *   Name of entity in result array.
  *
  * @param string $classname
  *   Name of class
  *
  * @return array
  *   Mapped to objects optionally by key.
  */
 public function map($entity, $classname)
 {
     $data = $this->response->getData();
     $object = new \Zuora\Object\Object($data);
     return $object->map($entity, $classname);
 }