java.lang.Object
java.util.AbstractCollection
java.util.AbstractList
java.util.Vector
org.cybergarage.upnp.ArgumentList
- All Implemented Interfaces:
Serializable,Cloneable,Iterable,Collection,List,RandomAccess,SequencedCollection
A list of
Argument objects.
This class extends Vector to provide type-safe access to UPnP action arguments. It
includes methods for retrieving arguments by name or index, and for setting input/output argument
values.
- See Also:
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final StringThe XML element name for argument list nodes in SCPD documents.Fields inherited from class java.util.Vector
capacityIncrement, elementCount, elementDataFields inherited from class java.util.AbstractList
modCount -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiongetArgument(int n) Returns the argument at the specified index.getArgument(String name) Returns the argument with the specified name.voidset(ArgumentList inArgList) Deprecated.voidsetReqArgs(ArgumentList inArgList) Sets values for all input arguments from the provided list.voidsetResArgs(ArgumentList outArgList) Sets values for all output arguments from the provided list.Methods inherited from class java.util.Vector
add, add, addAll, addAll, addElement, capacity, clear, clone, contains, containsAll, copyInto, elementAt, elements, ensureCapacity, equals, firstElement, forEach, get, hashCode, indexOf, indexOf, insertElementAt, isEmpty, iterator, lastElement, lastIndexOf, lastIndexOf, listIterator, listIterator, remove, remove, removeAll, removeAllElements, removeElement, removeElementAt, removeIf, removeRange, replaceAll, retainAll, set, setElementAt, setSize, size, sort, spliterator, subList, toArray, toArray, toString, trimToSizeMethods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface java.util.Collection
parallelStream, stream, toArrayMethods inherited from interface java.util.List
addFirst, addLast, getFirst, getLast, removeFirst, removeLast, reversed
-
Field Details
-
ELEM_NAME
The XML element name for argument list nodes in SCPD documents.- See Also:
-
-
Constructor Details
-
ArgumentList
public ArgumentList()Constructs an empty argument list.
-
-
Method Details
-
getArgument
Returns the argument at the specified index.- Parameters:
n- the index of the argument to retrieve- Returns:
- the argument at the specified index
- Throws:
ArrayIndexOutOfBoundsException- if the index is out of range
-
getArgument
Returns the argument with the specified name.- Parameters:
name- the name of the argument to retrieve- Returns:
- the argument with the specified name, or
nullif not found
-
set
Deprecated.UsesetReqArgs(ArgumentList)orsetResArgs(ArgumentList)insteadSets argument values from the provided list.- Parameters:
inArgList- the argument list containing values to set
-
setReqArgs
Sets values for all input arguments from the provided list.Updates only arguments with direction "in" by matching names from the provided argument list.
- Parameters:
inArgList- the argument list containing input values- Throws:
IllegalArgumentException- if a required input argument is missing from the provided list
-
setResArgs
Sets values for all output arguments from the provided list.Updates only arguments with direction "out" by matching names from the provided argument list.
- Parameters:
outArgList- the argument list containing output values- Throws:
IllegalArgumentException- if a required output argument is missing from the provided list
-
setReqArgs(ArgumentList)orsetResArgs(ArgumentList)instead