Inherits from NSObject
Declared in OICardInfo.h
OICardInfo.m

Overview

Class contain informations about user credit card.

Tasks

Properties

address

The billing address (OIAddress).

@property (nonatomic, readwrite, retain) OIAddress *address

Discussion

The billing address (OIAddress).

Declared In

OICardInfo.h

cvc

The 3 or 4 digit security code.

@property (nonatomic, readwrite, retain) NSNumber *cvc

Discussion

The 3 or 4 digit security code.

Declared In

OICardInfo.h

expirationMonth

The 2 digit expiry month (i.e. 01 = January, 12 = December).

@property (nonatomic, readwrite, copy) NSString *expirationMonth

Discussion

The 2 digit expiry month (i.e. 01 = January, 12 = December).

Declared In

OICardInfo.h

expirationYear

The 4 digit expiry year.

@property (nonatomic, readwrite, copy) NSString *expirationYear

Discussion

The 4 digit expiry year.

Declared In

OICardInfo.h

lastFiveDigits

The last 5 digits of the card.

@property (nonatomic, readwrite, retain) NSNumber *lastFiveDigits

Discussion

The last 5 digits of the card.

Declared In

OICardInfo.h

name

The name on the card.

@property (nonatomic, readwrite, copy) NSString *name

Discussion

The name on the card.

Declared In

OICardInfo.h

nickname

The nickname of the card.

@property (nonatomic, readwrite, copy) NSString *nickname

Discussion

The nickname of the card.

Declared In

OICardInfo.h

number

The 15 or 16 digit credit card number, no spaces or punctuation.

@property (nonatomic, readwrite, copy) NSString *number

Discussion

The 15 or 16 digit credit card number, no spaces or punctuation.

Declared In

OICardInfo.h

type

The type of card (i.e. American Express).

@property (nonatomic, readwrite, copy) NSString *type

Discussion

The type of card (i.e. American Express).

Declared In

OICardInfo.h

Class Methods

addCreditCard:usingBlock:

Add credit card (OICardInfo) to the server and to the credit cards of the user (OIUser).

+ (void)addCreditCard:(OICardInfo *)creditCard usingBlock:(void ( ^ ) ( NSError *error ))block

Parameters

block

Block return nil if request finished successfully.

address

New credit card (OICardInfo) which will be added to the user credit cards (server, application).

Discussion

Add credit card (OICardInfo) to the server and to the credit cards of the user (OIUser).

Declared In

OICardInfo.h

deleteCreditCardByNickname:usingBlock:

Delete user credit card by its nickname.

+ (void)deleteCreditCardByNickname:(NSString *)nickname usingBlock:(void ( ^ ) ( NSError *error ))block

Parameters

nickname

The nick name of the credit card, which will be deleted.

block

Block return nil if request finished successfully.

Discussion

Delete user credit card by its nickname.

Declared In

OICardInfo.h

loadCreditCardByNickname:usingBlock:

Load user credit card (OICardInfo) by its nickname.

+ (void)loadCreditCardByNickname:(NSString *)nickname usingBlock:(void ( ^ ) ( OICardInfo *cardInfo ))block

Parameters

nickname

The nickname of the searching credit card.

block

Block return credit card (OICardInfo) with required nickname.

Discussion

Load user credit card (OICardInfo) by its nickname.

Declared In

OICardInfo.h

loadCreditCardsUsingBlock:

Load all user credit cards.

+ (void)loadCreditCardsUsingBlock:(void ( ^ ) ( NSMutableArray *creditCards ))block

Parameters

block

Block return all user credit cards.

Discussion

Load all user credit cards.

Declared In

OICardInfo.h

Instance Methods

updateCreditCardWithCard:usingBlock:

Update credit card info.

- (void)updateCreditCardWithCard:(OICardInfo *)creditCard usingBlock:(void ( ^ ) ( NSError *error ))block

Parameters

creditCard

Changed credit card (OICardInfo), which will replace previous credit card.

block

Block return nil if request finished successfully.

Discussion

Update credit card info.

Declared In

OICardInfo.h