org.apache.taglibs.random
Class RandomStrgTag

java.lang.Object
  extended byjavax.servlet.jsp.tagext.TagSupport
      extended byorg.apache.taglibs.random.RandomStrgTag
All Implemented Interfaces:
javax.servlet.jsp.tagext.IterationTag, java.io.Serializable, javax.servlet.jsp.tagext.Tag

public class RandomStrgTag
extends javax.servlet.jsp.tagext.TagSupport

RandomStrg tag will create a random string generator accessiable by the jsp:getProperty tag.. <tag> <name>random</name> <tagclass>org.apache.taglibs.random.RandomTag</tagclass> <bodycontent>empty</bodycontent> <info>Creates an variable length random string generator</info> <attribute> <name>id</name> <required>true</required> <rtexprvalue>false</rtexprvalue> </attribute> <attribute> <name>length</name> <required>false</required> <rtexprvalue>false</rtexprvalue> </attribute> <attribute> <name>map</name> <required>false</required> <rtexprvalue>false</rtexprvalue> </attribute> <attribute> <name>charset</name> <required>false</required> <rtexprvalue>false</rtexprvalue> </attribute> <attribute> <name>algorithm</name> <required>false</required> <rtexprvalue>false</rtexprvalue> </attribute> <attribute> <name>provider</name> <required>false</required> <rtexprvalue>false</rtexprvalue> </attribute> </tag>

Version:
1.0
Author:
Rich Catlett
See Also:
Serialized Form

Field Summary
 
Fields inherited from class javax.servlet.jsp.tagext.TagSupport
id, pageContext
 
Fields inherited from interface javax.servlet.jsp.tagext.IterationTag
EVAL_BODY_AGAIN
 
Fields inherited from interface javax.servlet.jsp.tagext.Tag
EVAL_BODY_INCLUDE, EVAL_PAGE, SKIP_BODY, SKIP_PAGE
 
Constructor Summary
RandomStrgTag()
           
 
Method Summary
 int doStartTag()
          implementation of method from the Tag interface that tells the JSP what to do upon encountering the start tag for this tag set
 void setAlgorithm(java.lang.String value)
          set the algorithm name
 void setCharset(java.lang.String value)
          set the range of characters to use
 void setLength(java.lang.String value)
          set the length of the password
 void setMap(java.lang.String value)
          set the name of the map
 void setProvider(java.lang.String value)
          set the provider name
 
Methods inherited from class javax.servlet.jsp.tagext.TagSupport
doAfterBody, doEndTag, findAncestorWithClass, getId, getParent, getValue, getValues, release, removeValue, setId, setPageContext, setParent, setValue
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

RandomStrgTag

public RandomStrgTag()
Method Detail

doStartTag

public final int doStartTag()
                     throws javax.servlet.jsp.JspException
implementation of method from the Tag interface that tells the JSP what to do upon encountering the start tag for this tag set

Returns:
SKIP_BODY - integer value telling the JSP engine to not evaluate the body of this tag
Throws:
javax.servlet.jsp.JspException - thrown when error occurs in processing the body of this method

setMap

public final void setMap(java.lang.String value)
set the name of the map

Parameters:
value - name of the hashmap to search for on the server that contains the keys to compare the random strings to

setLength

public final void setLength(java.lang.String value)
set the length of the password

Parameters:
value - length of the random string to be generated

setAlgorithm

public final void setAlgorithm(java.lang.String value)
set the algorithm name

Parameters:
value - name of the algorithm to use for a SecureRandom object

setProvider

public final void setProvider(java.lang.String value)
set the provider name

Parameters:
value - name of the package to check for the algorithm

setCharset

public final void setCharset(java.lang.String value)
set the range of characters to use

Parameters:
value - the range of characters to use could be any char from a-z, A-Z 0-9 or ! @ # $ % ^ & * ( ) _ \- + = [ ] { } \ | ; : ' " , . / < > ?


Copyright ? 2000-2004 The Apache Software Foundation. All Rights Reserved.