org.jasig.cas.util
Class DefaultRandomStringGenerator
java.lang.Object
org.jasig.cas.util.DefaultRandomStringGenerator
- All Implemented Interfaces:
- RandomStringGenerator
public final class DefaultRandomStringGenerator
- extends java.lang.Object
- implements RandomStringGenerator
Implementation of the RandomStringGenerator that allows you to define the
length of the random part.
- Since:
- 3.0
- Version:
- $Revision: 42053 $ $Date: 2007-06-10 09:17:55 -0400 (Sun, 10 Jun 2007) $
- Author:
- Scott Battaglia
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
DefaultRandomStringGenerator
public DefaultRandomStringGenerator()
DefaultRandomStringGenerator
public DefaultRandomStringGenerator(int maxRandomLength)
getMinLength
public int getMinLength()
- Specified by:
getMinLength in interface RandomStringGenerator
- Returns:
- the minimum length as an int guaranteed by this generator.
getMaxLength
public int getMaxLength()
- Specified by:
getMaxLength in interface RandomStringGenerator
- Returns:
- the maximum length as an int guaranteed by this generator.
getNewString
public java.lang.String getNewString()
- Specified by:
getNewString in interface RandomStringGenerator
- Returns:
- the new random string
getNewStringAsBytes
public byte[] getNewStringAsBytes()
- Specified by:
getNewStringAsBytes in interface RandomStringGenerator
Copyright © 2004-2010 Java Architectures Special Interest Group. All Rights Reserved.