PHP Класс Braintree\Customer

== More information == For more detailed information on Customers, see {@link http://www.braintreepayments.com/gateway/customer-api http://www.braintreepaymentsolutions.com/gateway/customer-api}
Наследование: extends braintree\Base
Показать файл Открыть проект Примеры использования класса

Защищенные свойства (Protected)

Свойство Тип Описание
$_attributes registry of customer data

Открытые методы

Метод Описание
__toString ( ) : string returns a string representation of the customer
_defaultPaymentMethodFilter ( $paymentMethod )
all ( ) : Customer[]
create ( array $attribs = [] ) : Braintree\Result\Successful | Error
createCustomerUrl ( ) : string
createFromTransparentRedirect ( string $queryString ) : Braintree\Result\Successful
createNoValidate ( array $attribs = [] ) : Customer
credit ( integer $customerId, array $transactionAttribs ) : Braintree\Result\Successful | Error
creditNoValidate ( type $customerId, type $transactionAttribs ) : Transaction
defaultPaymentMethod ( ) : CreditCard | braintree\PayPalAccount returns the customer's default payment method
delete ( integer $customerId ) : Braintree\Result\Successful
factory ( array $attributes ) : Customer factory method: returns an instance of Customer to the requesting method, with populated properties
fetch ( string $query, int[] $ids ) : Customer | Customer[]
find ( string $id ) : Customer
isEqual ( object $otherCust ) : boolean returns false if comparing object is not a Customer, or is a Customer with a different id
paymentMethods ( ) : array returns an array containt all of the customer's payment methods
sale ( integer $customerId, array $transactionAttribs ) : Transaction
saleNoValidate ( integer $customerId, array $transactionAttribs ) : Transaction
search ( string $query ) : ResourceCollection
update ( integer $customerId, array $attributes ) : Braintree\Result\Successful | Error
updateCustomerUrl ( ) : string
updateFromTransparentRedirect ( string $queryString ) : Braintree\Result\Successful | Error
updateNoValidate ( integer $customerId, array $attributes ) : CustomerGateway

Защищенные методы

Метод Описание
_initialize ( array $customerAttribs ) sets instance properties from an array of values

Описание методов

__toString() публичный Метод

returns a string representation of the customer
public __toString ( ) : string
Результат string

_defaultPaymentMethodFilter() публичный статический Метод

public static _defaultPaymentMethodFilter ( $paymentMethod )

_initialize() защищенный Метод

sets instance properties from an array of values
protected _initialize ( array $customerAttribs )
$customerAttribs array array of customer data

all() публичный статический Метод

public static all ( ) : Customer[]
Результат Customer[]

create() публичный статический Метод

public static create ( array $attribs = [] ) : Braintree\Result\Successful | Error
$attribs array
Результат Braintree\Result\Successful | Braintree\Result\Error

createCustomerUrl() публичный статический Метод

Устаревший: since version 2.3.0
public static createCustomerUrl ( ) : string
Результат string

createFromTransparentRedirect() публичный статический Метод

Устаревший: since version 2.3.0
public static createFromTransparentRedirect ( string $queryString ) : Braintree\Result\Successful
$queryString string
Результат Braintree\Result\Successful

createNoValidate() публичный статический Метод

public static createNoValidate ( array $attribs = [] ) : Customer
$attribs array
Результат Customer

credit() публичный статический Метод

public static credit ( integer $customerId, array $transactionAttribs ) : Braintree\Result\Successful | Error
$customerId integer
$transactionAttribs array
Результат Braintree\Result\Successful | Braintree\Result\Error

creditNoValidate() публичный статический Метод

public static creditNoValidate ( type $customerId, type $transactionAttribs ) : Transaction
$customerId type
$transactionAttribs type
Результат Transaction

defaultPaymentMethod() публичный Метод

returns the customer's default payment method
public defaultPaymentMethod ( ) : CreditCard | braintree\PayPalAccount
Результат CreditCard | braintree\PayPalAccount

delete() публичный статический Метод

public static delete ( integer $customerId ) : Braintree\Result\Successful
$customerId integer
Результат Braintree\Result\Successful

factory() публичный статический Метод

factory method: returns an instance of Customer to the requesting method, with populated properties
public static factory ( array $attributes ) : Customer
$attributes array
Результат Customer

fetch() публичный статический Метод

public static fetch ( string $query, int[] $ids ) : Customer | Customer[]
$query string
$ids int[]
Результат Customer | Customer[]

find() публичный статический Метод

public static find ( string $id ) : Customer
$id string customer id
Результат Customer

isEqual() публичный Метод

returns false if comparing object is not a Customer, or is a Customer with a different id
public isEqual ( object $otherCust ) : boolean
$otherCust object customer to compare against
Результат boolean

paymentMethods() публичный Метод

returns an array containt all of the customer's payment methods
Устаревший: since version 3.1.0 - use the paymentMethods property directly
public paymentMethods ( ) : array
Результат array

sale() публичный статический Метод

public static sale ( integer $customerId, array $transactionAttribs ) : Transaction
$customerId integer
$transactionAttribs array
Результат Transaction

saleNoValidate() публичный статический Метод

public static saleNoValidate ( integer $customerId, array $transactionAttribs ) : Transaction
$customerId integer
$transactionAttribs array
Результат Transaction

update() публичный статический Метод

public static update ( integer $customerId, array $attributes ) : Braintree\Result\Successful | Error
$customerId integer
$attributes array
Результат Braintree\Result\Successful | Braintree\Result\Error

updateCustomerUrl() публичный статический Метод

Устаревший: since version 2.3.0
public static updateCustomerUrl ( ) : string
Результат string

updateFromTransparentRedirect() публичный статический Метод

Устаревший: since version 2.3.0
public static updateFromTransparentRedirect ( string $queryString ) : Braintree\Result\Successful | Error
$queryString string
Результат Braintree\Result\Successful | Braintree\Result\Error

updateNoValidate() публичный статический Метод

public static updateNoValidate ( integer $customerId, array $attributes ) : CustomerGateway
$customerId integer
$attributes array
Результат CustomerGateway

Описание свойств

$_attributes защищенное свойство

registry of customer data
protected $_attributes