« lib/WebService/Braintree/_/PayPalAccount.pm
↑ Summary
lib/WebService/Braintree/_/PaymentMethodNonceDetails.pm »
| 1 | # vim: sw=4 ts=4 ft=perl | ||
| 2 | |||
| 3 | package WebService::Braintree::_::PaymentMethodNonce; | ||
| 4 | 22 | $WebService::Braintree::_::PaymentMethodNonce::VERSION = '1.7'; | |
| 5 | 22 | ▶ | use 5.010_001; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 6 | 22 | ▶ | use strictures 1; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 7 | |||
| 8 | =head1 NAME | ||
| 9 | |||
| 10 | WebService::Braintree::_::PaymentMethodNonce | ||
| 11 | |||
| 12 | =head1 PURPOSE | ||
| 13 | |||
| 14 | This class represents a payment method nonce. | ||
| 15 | |||
| 16 | This class will only be created as part of a L<response|WebService::Braintree::Result> or L<error response|WebService::Braintree::ErrorResult>. | ||
| 17 | |||
| 18 | =cut | ||
| 19 | |||
| 20 | 22 | ▶ | use Moo; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 21 | 22 | ▶ | use MooX::Aliases; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 22 | |||
| 23 | 22 | extends 'WebService::Braintree::_'; | |
| 24 | |||
| 25 | 22 | ▶ | use Types::Standard qw(Undef); |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 26 | 22 | ▶ | use WebService::Braintree::Types qw( |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 27 | BinData | ||
| 28 | PaymentMethodNonceDetails | ||
| 29 | ThreeDSecureInfo | ||
| 30 | 22 | ); | |
| 31 | |||
| 32 | =head1 ATTRIBUTES | ||
| 33 | |||
| 34 | =cut | ||
| 35 | |||
| 36 | =head2 bin_data() | ||
| 37 | |||
| 38 | This returns the nonce's bin data. This will be an object of type | ||
| 39 | L<bin data|WebService::Braintree::_::BinData/>. | ||
| 40 | |||
| 41 | =cut | ||
| 42 | |||
| 43 | 22 | has bin_data => ( | |
| 44 | is => 'ro', | ||
| 45 | isa => BinData, | ||
| 46 | coerce => 1, | ||
| 47 | ); | ||
| 48 | |||
| 49 | =head2 consumed() | ||
| 50 | |||
| 51 | This returns if this nonce has been consumed. | ||
| 52 | |||
| 53 | C<< is_consumed() >> is an alias for this attribute. | ||
| 54 | |||
| 55 | =cut | ||
| 56 | |||
| 57 | 22 | has consumed => ( | |
| 58 | is => 'ro', | ||
| 59 | alias => 'is_consumed', | ||
| 60 | ); | ||
| 61 | |||
| 62 | =head2 default() | ||
| 63 | |||
| 64 | This returns if this nonce is default. | ||
| 65 | |||
| 66 | C<< is_default() >> is an alias for this attribute. | ||
| 67 | |||
| 68 | =cut | ||
| 69 | |||
| 70 | 22 | has default => ( | |
| 71 | is => 'ro', | ||
| 72 | alias => 'is_default', | ||
| 73 | ); | ||
| 74 | |||
| 75 | =head2 description() | ||
| 76 | |||
| 77 | This returns the nonce's description. | ||
| 78 | |||
| 79 | =cut | ||
| 80 | |||
| 81 | 22 | has description => ( | |
| 82 | is => 'ro', | ||
| 83 | ); | ||
| 84 | |||
| 85 | =head2 details() | ||
| 86 | |||
| 87 | This returns the nonce's details. This will be an object of type | ||
| 88 | L<defaults|WebService::Braintree::_::PaymentMethodNonceDetails/>. | ||
| 89 | |||
| 90 | =cut | ||
| 91 | |||
| 92 | 22 | has details => ( | |
| 93 | is => 'ro', | ||
| 94 | isa => PaymentMethodNonceDetails, | ||
| 95 | coerce => 1, | ||
| 96 | ); | ||
| 97 | |||
| 98 | =head2 is_locked() | ||
| 99 | |||
| 100 | This returns true if this nonce is locked. | ||
| 101 | |||
| 102 | =cut | ||
| 103 | |||
| 104 | 22 | has is_locked => ( | |
| 105 | is => 'ro', | ||
| 106 | ); | ||
| 107 | |||
| 108 | =head2 nonce() | ||
| 109 | |||
| 110 | This returns the nonce's nonce. | ||
| 111 | |||
| 112 | =cut | ||
| 113 | |||
| 114 | 22 | has nonce => ( | |
| 115 | is => 'ro', | ||
| 116 | ); | ||
| 117 | |||
| 118 | =head2 security_questions() | ||
| 119 | |||
| 120 | This returns the nonce's security questions. | ||
| 121 | |||
| 122 | =cut | ||
| 123 | |||
| 124 | 22 | has security_questions => ( | |
| 125 | is => 'ro', | ||
| 126 | ); | ||
| 127 | |||
| 128 | =head2 three_d_secure_info() | ||
| 129 | |||
| 130 | This returns the nonce's ThreeD secure info. This will be an object of type | ||
| 131 | L<ThreeD secure info|WebService::Braintree::_::ThreeDSecureInfo/>. | ||
| 132 | |||
| 133 | =cut | ||
| 134 | |||
| 135 | 22 | has three_d_secure_info => ( | |
| 136 | is => 'ro', | ||
| 137 | isa => ThreeDSecureInfo|Undef, | ||
| 138 | coerce => 1, | ||
| 139 | ); | ||
| 140 | |||
| 141 | =head2 type() | ||
| 142 | |||
| 143 | This returns the nonce's type. | ||
| 144 | |||
| 145 | =cut | ||
| 146 | |||
| 147 | 22 | has type => ( | |
| 148 | is => 'ro', | ||
| 149 | ); | ||
| 150 | |||
| 151 | 22 | __PACKAGE__->meta->make_immutable; | |
| 152 | |||
| 153 | 22 | 1; | |
| 154 | __END__ | ||