Package gnu.mapping
Interface ArgList
- All Known Implementing Classes:
ArgListImpl
,ArgListPair
,ArgListVector
,CallContext
public interface ArgList
-
Method Summary
Modifier and TypeMethodDescriptionint
findKeyword
(String key) Find index for keyword.int
getArgAsObject
(int i) Index into arguments, not counting keywords.getKeyword
(int index) Get keyword (as an interned String) for given argument.int
Number of actual arguments.int
-
Method Details
-
numArguments
int numArguments()Number of actual arguments. Each (keyword,argument)-pair counts as one (not two). -
getArgAsObject
Index into arguments, not counting keywords. I.e. for [a b k1: c k2: d e] the index 0 returns a, 2 returns c, 3 returns d, 4 returns e. -
numKeywords
int numKeywords() -
firstKeyword
int firstKeyword() -
getKeyword
Get keyword (as an interned String) for given argument. Indexing is the same as getArgAsObject. Return null for non-keyword arguments. -
findKeyword
Find index for keyword.- Parameters:
key
- an interned string
-