public class ArgListImpl extends java.lang.Object implements ArgList, ArgListBuilder
Modifier and Type | Field and Description |
---|---|
protected int |
count
Number of arguments.
|
Constructor and Description |
---|
ArgListImpl() |
ArgListImpl(ArgListImpl args) |
Modifier and Type | Method and Description |
---|---|
void |
add(java.lang.Object arg) |
void |
add(java.lang.Object arg0,
java.lang.Object arg1,
java.lang.Object arg2,
java.lang.Object arg3) |
void |
addAll(ArgList args) |
void |
addAll(java.util.List<?> args) |
void |
addArgList(java.lang.Object args) |
void |
addKey(java.lang.String keyword,
java.lang.Object arg) |
void |
addSequence(java.lang.Object args) |
ArgList |
asArgList() |
ArgList |
asFreshArgList() |
void |
clear() |
static int |
findKeyword(ArgList args,
java.lang.String key) |
int |
findKeyword(java.lang.String key)
Find index for keyword.
|
int |
firstKeyword() |
java.lang.Object |
getArgAsObject(int i)
Index into arguments, not counting keywords.
|
java.lang.String |
getKeyword(int index)
Get keyword (as an interned String) for given argument.
|
int |
numArguments()
Number of actual arguments.
|
int |
numKeywords() |
java.lang.Object |
popLast() |
void |
printArgs() |
void |
setArgs() |
void |
setArgs(java.lang.Object arg0) |
void |
setArgs(java.lang.Object arg0,
java.lang.Object arg1) |
void |
setArgs(java.lang.Object arg0,
java.lang.Object arg1,
java.lang.Object arg2) |
void |
setArgs(java.lang.Object arg0,
java.lang.Object arg1,
java.lang.Object arg2,
java.lang.Object arg3) |
void |
setArgsAll(java.lang.Object[] args) |
void |
setArgsAll(java.lang.Object[] args,
int fromIndex,
int toIndex) |
void |
setKeys(int numKeywords,
java.lang.String[] keys,
short[] sorted)
Note the the previous numKeywords arguments were keywords arguments.
|
void |
shiftArgs(int toDrop) |
protected int count
public ArgListImpl()
public ArgListImpl(ArgListImpl args)
public void printArgs()
public int numArguments()
ArgList
numArguments
in interface ArgList
public java.lang.Object popLast()
public void shiftArgs(int toDrop)
public void clear()
clear
in interface ArgListBuilder
public void setArgs()
setArgs
in interface ArgListBuilder
public void setArgs(java.lang.Object arg0)
setArgs
in interface ArgListBuilder
public void setArgs(java.lang.Object arg0, java.lang.Object arg1)
setArgs
in interface ArgListBuilder
public void setArgs(java.lang.Object arg0, java.lang.Object arg1, java.lang.Object arg2)
setArgs
in interface ArgListBuilder
public void setArgs(java.lang.Object arg0, java.lang.Object arg1, java.lang.Object arg2, java.lang.Object arg3)
setArgs
in interface ArgListBuilder
public void setArgsAll(java.lang.Object[] args)
public void setArgsAll(java.lang.Object[] args, int fromIndex, int toIndex)
public void add(java.lang.Object arg)
add
in interface ArgListBuilder
public void add(java.lang.Object arg0, java.lang.Object arg1, java.lang.Object arg2, java.lang.Object arg3)
public void addAll(ArgList args)
addAll
in interface ArgListBuilder
public void addSequence(java.lang.Object args)
public void addArgList(java.lang.Object args)
public void addAll(java.util.List<?> args)
addAll
in interface ArgListBuilder
public void addKey(java.lang.String keyword, java.lang.Object arg)
addKey
in interface ArgListBuilder
keyword
- must be an interned Stringarg
- the corresponding valuepublic java.lang.Object getArgAsObject(int i)
ArgList
getArgAsObject
in interface ArgList
public int firstKeyword()
firstKeyword
in interface ArgList
public int numKeywords()
numKeywords
in interface ArgList
public java.lang.String getKeyword(int index)
ArgList
getKeyword
in interface ArgList
public static int findKeyword(ArgList args, java.lang.String key)
public int findKeyword(java.lang.String key)
ArgList
findKeyword
in interface ArgList
key
- an interned stringpublic void setKeys(int numKeywords, java.lang.String[] keys, short[] sorted)
ArgListBuilder
setKeys
in interface ArgListBuilder
public ArgList asArgList()
asArgList
in interface ArgListBuilder
public ArgList asFreshArgList()
asFreshArgList
in interface ArgListBuilder