theoafactor / repeaterpolicies

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Working with RepeaterPolicies

This project is intended for educational purposes at Cyclobold School of Software Engineering

Please report questions to olu@cyclobold.com

Visit https://cyclobold.com for more information.


  • Add the code as a package to your project

  • Declare an import command at the top of your project:

       import com.cyclobold.repeaterplicies.Repeater;
  • Create a new instance of the class.

       Repeater repeater = new Repeater();
  • Now you can use the methods available

       repeater.validateUpperCase(4, "MySamplePASSWORD");

Methods Available

1. validateUpperCase(int maxNumber, String password):
This method enforces a policy that prevents repetition of uppercase beyond the maximum declared in the method (maxNumber). The second argument is the password to enforce the policy on.
2. validateNumber(int maxNumber, String password):
This method enforces a policy that prevents repetition of numbers beyond the maximum declared in the method (maxNumber). The second argument is the password to enforce the policy on.
3. validateSpecialChars(int maxNumber, String password):
This method enforces a policy that prevents repetition of special characters beyond the maximum declared in the method (maxNumber). The second argument is the password to enforce the policy on. Please feel free to directly edit the special characters to check. You will that editing the special characters is incredibly easy to do. Within the validateSpecialChars() method, you will find the variable **specialChars**

About


Languages

Language:Java 100.0%