Class StringListCommandParameter
java.lang.Object
org.tweetyproject.plugin.parameter.CommandParameter
org.tweetyproject.plugin.parameter.StringListCommandParameter
- All Implemented Interfaces:
Cloneable
- Direct Known Subclasses:
CustomStringListCommandParameter
This class models a string list command parameter for
Work-in-Progress, do not use!
- Author:
- bwolf
-
Constructor Summary
ConstructorDescriptionStringListCommandParameter
(String id, String des) constructor with identifier and description -
Method Summary
Modifier and TypeMethodDescriptionclone()
method to clone this object for instantiationString[]
getValue()
Retrieves the value of this object.instantiates unary argument if validinstantiate
(String[] s) instantiates a list of arguments if validboolean
checks each input string for validityvoid
Sets the value of this object.Methods inherited from class org.tweetyproject.plugin.parameter.CommandParameter
getDescription, getIdentifier
-
Constructor Details
-
StringListCommandParameter
-
-
Method Details
-
getValue
Retrieves the value of this object.- Returns:
- a `String[]` representing the current value of this object, or `null` if no value has been set.
-
setValue
Sets the value of this object.- Parameters:
value
- a `String[]` representing the new value to be stored in this object.
-
isValid
checks each input string for validity- Specified by:
isValid
in classCommandParameter
- Parameters:
s
- the given input string- Returns:
- true if valid, false if not
-
instantiate
instantiates unary argument if valid- Specified by:
instantiate
in classCommandParameter
- Parameters:
s
- the given argument string- Returns:
- The CommandParameter instance or null if the given string is not valid.
-
instantiate
instantiates a list of arguments if valid- Parameters:
s
- an array of strings- Returns:
- the command parameter
-
clone
method to clone this object for instantiation
-