NextApp Echo
App Container 1.1.4

nextapp.echoservlet
Interface InitialParameters


public interface InitialParameters

An interface provided to an EchoInstance such that it may access the parameters that were initially passed to the application container. An instance of an implementation of this interface is set as an attribute with ATTRIBUTE_NAME


Field Summary
static java.lang.String ATTRIBUTE_NAME
           
 
Method Summary
 java.lang.String[] getAllParameterNames()
          Returns an array of all the initial request parameters names.
 java.lang.String getParameter(java.lang.String name)
          Returns the value of an initial request parameter as a String, or null if the parameter does not exist.
 java.util.Map getParameterMap()
          Returns a java.util.Map of the parameters of the initial request.
 java.util.Iterator getParameterNames()
          Returns an Iterator of String objects containing the names of the parameters contained in the initial request.
 java.lang.String[] getParameterValues(java.lang.String name)
          Returns an array of String objects containing all of the values the given initial request parameter has, or null if the parameter does not exist.
 

Field Detail

ATTRIBUTE_NAME

public static final java.lang.String ATTRIBUTE_NAME
See Also:
Constant Field Values
Method Detail

getParameter

public java.lang.String getParameter(java.lang.String name)
Returns the value of an initial request parameter as a String, or null if the parameter does not exist.

You should only use this method when you are sure the parameter has only one value. If the parameter might have more than one value, use getParameterValues(java.lang.String).

If you use this method with a multivalued parameter, the value returned is equal to the first value in the array returned by getParameterValues.

Parameters:
name - - a String specifying the name of the parameter
Returns:
a String representing the single value of the parameter

getParameterMap

public java.util.Map getParameterMap()
Returns a java.util.Map of the parameters of the initial request.

Returns:
an immutable java.util.Map containing parameter names as keys and parameter values as map values. The keys in the parameter map are of type String. The values in the parameter map are of type String[].

getParameterNames

public java.util.Iterator getParameterNames()
Returns an Iterator of String objects containing the names of the parameters contained in the initial request. If the initial request has no parameters, the method returns an empty Enumeration.

Returns:
an Iterator of String objects, each String containing the name of an initial request parameter; or an empty Enumeration if the request has no parameters

getAllParameterNames

public java.lang.String[] getAllParameterNames()
Returns an array of all the initial request parameters names. If the initial request has no parameters, the method returns an zero length String array.

Returns:
an array of String objects, each String containing the name of a request parameter; or a zero length array if the request has no parameters

getParameterValues

public java.lang.String[] getParameterValues(java.lang.String name)
Returns an array of String objects containing all of the values the given initial request parameter has, or null if the parameter does not exist.

If the parameter has a single value, the array has a length of 1.

Parameters:
name - - a String containing the name of the parameter whose value is requested
Returns:
an array of String objects containing the parameter's values

NextApp Echo
App Container 1.1.4