commons-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From rlel...@apache.org
Subject cvs commit: jakarta-commons/validator/src/share/org/apache/commons/validator CreditCardValidator.java GenericValidator.java
Date Wed, 30 Apr 2003 22:11:07 GMT
rleland     2003/04/30 15:11:06

  Modified:    validator/src/share/org/apache/commons/validator
                        CreditCardValidator.java GenericValidator.java
  Log:
  Rollback changing functions to static, so
  polymorphism/overriding can take place.
  
  Revision  Changes    Path
  1.3       +6 -6      jakarta-commons/validator/src/share/org/apache/commons/validator/CreditCardValidator.java
  
  Index: CreditCardValidator.java
  ===================================================================
  RCS file: /home/cvs/jakarta-commons/validator/src/share/org/apache/commons/validator/CreditCardValidator.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- CreditCardValidator.java	30 Apr 2003 21:24:41 -0000	1.2
  +++ CreditCardValidator.java	30 Apr 2003 22:11:06 -0000	1.3
  @@ -118,7 +118,7 @@
   	 *
   	 * @param cardNumber Credit Card Number.
   	 */
  -	protected static boolean validateCreditCardLuhnCheck(String cardNumber) {
  +	protected boolean validateCreditCardLuhnCheck(String cardNumber) {
   		// number must be validated as 0..9 numeric first!!
   		int digits = cardNumber.length();
   		int oddoeven = digits & 1;
  @@ -155,7 +155,7 @@
   	 *
   	 * @param cardNumber Credit Card Number.
   	 */
  -	protected static boolean validateCreditCardPrefixCheck(String cardNumber) {
  +	protected boolean validateCreditCardPrefixCheck(String cardNumber) {
   
   		int length = cardNumber.length();
   		if (length < 13) {
  
  
  
  1.20      +6 -6      jakarta-commons/validator/src/share/org/apache/commons/validator/GenericValidator.java
  
  Index: GenericValidator.java
  ===================================================================
  RCS file: /home/cvs/jakarta-commons/validator/src/share/org/apache/commons/validator/GenericValidator.java,v
  retrieving revision 1.19
  retrieving revision 1.20
  diff -u -r1.19 -r1.20
  --- GenericValidator.java	30 Apr 2003 21:28:40 -0000	1.19
  +++ GenericValidator.java	30 Apr 2003 22:11:06 -0000	1.20
  @@ -310,7 +310,7 @@
       * @deprecated Use CreditCardValidator.validateCreditCardLuhnCheck() instead.
       */
      protected static boolean validateCreditCardLuhnCheck(String cardNumber) {
  -      return CreditCardValidator.validateCreditCardLuhnCheck(
  +      return CreditCardValidator.getInstance().validateCreditCardLuhnCheck(
               cardNumber);
      }
   
  @@ -321,7 +321,7 @@
       * @deprecated Use CreditCardValidator.validateCreditCardPrefixCheck() instead.
       */
      protected boolean validateCreditCardPrefixCheck(String cardNumber) {
  -      return CreditCardValidator.validateCreditCardPrefixCheck(
  +      return CreditCardValidator.getInstance().validateCreditCardPrefixCheck(
               cardNumber);
      }
   
  
  
  

---------------------------------------------------------------------
To unsubscribe, e-mail: commons-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: commons-dev-help@jakarta.apache.org


Mime
View raw message