Zend Framework
LICENSE
This source file is subject to the new BSD license that is bundled with this package in the file LICENSE.txt. It is also available through the world-wide-web at this URL: http://framework.zend.com/license/new-bsd If you did not receive a copy of the license and are unable to obtain it through the world-wide-web, please send an email to license@zend.com so we can send you a copy immediately.
string ALL = 'All'
Detected CCI list
AMERICAN_EXPRESS = 'American_Express'
UNIONPAY = 'Unionpay'
DINERS_CLUB = 'Diners_Club'
DINERS_CLUB_US = 'Diners_Club_US'
DISCOVER = 'Discover'
JCB = 'JCB'
LASER = 'Laser'
MAESTRO = 'Maestro'
MASTERCARD = 'Mastercard'
SOLO = 'Solo'
VISA = 'Visa'
CHECKSUM = 'creditcardChecksum'
CONTENT = 'creditcardContent'
INVALID = 'creditcardInvalid'
LENGTH = 'creditcardLength'
PREFIX = 'creditcardPrefix'
SERVICE = 'creditcardService'
SERVICEFAILURE = 'creditcardServiceFailure'
array $_cardLength = 'array'
List of allowed CCV lengths
array $_cardType = 'array'
List of accepted CCV provider tags
array $_messageTemplates = 'array'
Validation failure message template definitions
callback $_service = ''
Service callback for additional validation
array $_type = 'array'
CCIs which are accepted by validation
__construct(
$options
=
array
)
:
Constructor
addType(
string|array $type
)
:
Zend_Validate_CreditCard
Adds a CCI to be accepted by validation
getService(
)
:
callback
Returns the actual set service
getType(
)
:
array
Returns a list of accepted CCIs
isValid(
string $value
)
:
boolean
Defined by Zend_Validate_Interface
Returns true if and only if $value follows the Luhn algorithm (mod-10 checksum)
setService(
unknown_type $service
)
:
Sets a new callback for service validation
setType(
string|array $type
)
:
Zend_Validate_CreditCard
Sets CCIs which are accepted by validation