public static function fromArray($data)
 {
     if (!is_null($data)) {
         $capture = new CaptureResponse();
         foreach ($data as $key => $value) {
             if ($key == "billingReferences") {
                 $capture->{$key} = BillingReferences::fromArray($value);
             } elseif ($key == "customerReference") {
                 $capture->{$key} = CustomerReference::fromArray($value);
             } else {
                 $capture->{$key} = $value;
             }
         }
         return $capture;
     }
 }
 public static function fromArray($data)
 {
     if (!is_null($data)) {
         $recurringBill = new RecurringBillResponse();
         foreach ($data as $key => $value) {
             if (property_exists(get_class($recurringBill), $key)) {
                 if ($key == "billingReferences") {
                     $recurringBill->{$key} = BillingReferences::fromArray($value);
                 } elseif ($key == "customerReference") {
                     $recurringBill->{$key} = CustomerReference::fromArray($value);
                 } else {
                     $recurringBill->{$key} = $value;
                 }
             }
         }
         return $recurringBill;
     }
 }
 public static function fromArray($data)
 {
     if (!is_null($data)) {
         $customer = new Customer();
         foreach ($data as $key => $value) {
             if (property_exists(get_class($customer), $key)) {
                 if ($key == "customerReference") {
                     $customer->{$key} = CustomerReference::fromArray($value);
                 } else {
                     $customer->{$key} = $value;
                 }
             }
         }
         return $customer;
     }
 }