Inheritance diagram for sosc::MasterCard:

Public Methods | |
| MasterCard (final String mastercard) | |
| boolean | equals (final Object o) |
Static Public Methods | |
| boolean | validate (String num) |
Protected Methods | |
| boolean | checkSize () |
| boolean | checkPrefix () |
Definition at line 9 of file MasterCard.java.
|
|
The constructor for MasterCard calls the cunstructor from Validatable in order to set the number and type field values.
Definition at line 18 of file MasterCard.java. Referenced by sosc::MasterCard::validate(). |
|
|
checkPrefix() tests the prefix of the number being validated to see if it is correct for the related type.
Reimplemented from sosc::Validatable. Definition at line 58 of file MasterCard.java. References sosc::Validatable::number. |
|
|
checkSize() is used to check that the number being validated has the correct number digits for its type.
Implements sosc::Validatable. Definition at line 46 of file MasterCard.java. References sosc::Validatable::number. |
|
|
The equals method checks to see if the object passed in is an instance of this class. If it is an instance, the equals method from the Validatable class is called.
Definition at line 31 of file MasterCard.java. |
|
|
The static validate method creates a new object and calls the instance validate() method.
Definition at line 72 of file MasterCard.java. References sosc::MasterCard::MasterCard(). |
1.2.15