站内搜索: 请输入搜索关键词
当前页面: 在线文档首页 > JBOSS Portal 2.4 API 英文版文档

RequestParameter - JBOSS Portal 2.4 API 英文版文档


org.jboss.portal.server.request
Class RequestParameter

java.lang.Object
  extended byjava.util.AbstractCollection
      extended byjava.util.AbstractList
          extended byorg.jboss.portal.server.request.RequestParameter
All Implemented Interfaces:
java.util.Collection, java.util.List

public class RequestParameter
extends java.util.AbstractList
implements java.util.List

A request parameter. It implements the list interface to give access to the values of the parameter.


Field Summary
 
Fields inherited from class java.util.AbstractList
modCount
 
Method Summary
static RequestParameter create(java.lang.String name, java.lang.String[] values, int threshold)
           
static RequestParameter create(java.lang.String name, java.lang.String[] queryValues, java.lang.String[] bodyValues)
           
static RequestParameter createBody(java.lang.String name, java.lang.String value)
           
static RequestParameter createBody(java.lang.String name, java.lang.String[] values)
           
static RequestParameter createQuery(java.lang.String name, java.lang.String value)
           
static RequestParameter createQuery(java.lang.String name, java.lang.String[] values)
           
 java.lang.Object get(int index)
           
 java.lang.String getName()
          Return the parameter name.
 int getThreshold()
           
 java.lang.String getValue()
          Return the first value of this parameter.
 java.lang.String getValue(int index)
          Return a value of this parameter
 java.lang.String[] getValues()
          Return the values of the parameter.
 boolean isFromBody()
           
 boolean isFromBody(int index)
           
 boolean isFromQuery()
           
 boolean isFromQuery(int index)
           
 int size()
           
 
Methods inherited from class java.util.AbstractList
add, add, addAll, clear, equals, hashCode, indexOf, iterator, lastIndexOf, listIterator, listIterator, remove, removeRange, set, subList
 
Methods inherited from class java.util.AbstractCollection
addAll, contains, containsAll, isEmpty, remove, removeAll, retainAll, toArray, toArray, toString
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface java.util.List
add, add, addAll, addAll, clear, contains, containsAll, equals, hashCode, indexOf, isEmpty, iterator, lastIndexOf, listIterator, listIterator, remove, remove, removeAll, retainAll, set, subList, toArray, toArray
 

Method Detail

getName

public java.lang.String getName()
Return the parameter name.

Returns:
the parameter name

getValue

public java.lang.String getValue()
Return the first value of this parameter.

Returns:
the first value

getValue

public java.lang.String getValue(int index)
                          throws java.lang.IllegalArgumentException
Return a value of this parameter

Parameters:
index - the value index
Returns:
the value at the specified index
Throws:
java.lang.IllegalArgumentException - if the index is not valid

isFromQuery

public boolean isFromQuery()

isFromBody

public boolean isFromBody()

isFromQuery

public boolean isFromQuery(int index)
                    throws java.lang.IllegalArgumentException
Throws:
java.lang.IllegalArgumentException

isFromBody

public boolean isFromBody(int index)
                   throws java.lang.IllegalArgumentException
Throws:
java.lang.IllegalArgumentException

getValues

public java.lang.String[] getValues()
Return the values of the parameter. The returned array is a clone of the original one so it can be modified.

Returns:
the values

getThreshold

public int getThreshold()

get

public java.lang.Object get(int index)
Specified by:
get in interface java.util.List

size

public int size()
Specified by:
size in interface java.util.List

createQuery

public static RequestParameter createQuery(java.lang.String name,
                                           java.lang.String value)
                                    throws java.lang.IllegalArgumentException
Throws:
java.lang.IllegalArgumentException

createQuery

public static RequestParameter createQuery(java.lang.String name,
                                           java.lang.String[] values)
                                    throws java.lang.IllegalArgumentException
Throws:
java.lang.IllegalArgumentException

createBody

public static RequestParameter createBody(java.lang.String name,
                                          java.lang.String value)
                                   throws java.lang.IllegalArgumentException
Throws:
java.lang.IllegalArgumentException

createBody

public static RequestParameter createBody(java.lang.String name,
                                          java.lang.String[] values)
                                   throws java.lang.IllegalArgumentException
Throws:
java.lang.IllegalArgumentException

create

public static RequestParameter create(java.lang.String name,
                                      java.lang.String[] queryValues,
                                      java.lang.String[] bodyValues)
                               throws java.lang.IllegalArgumentException
Throws:
java.lang.IllegalArgumentException

create

public static RequestParameter create(java.lang.String name,
                                      java.lang.String[] values,
                                      int threshold)
                               throws java.lang.IllegalArgumentException
Throws:
java.lang.IllegalArgumentException