Package com.aspectran.utils.apon
Interface Parameter
- All Known Implementing Classes:
ParameterValue
public interface Parameter
-
Method Summary
Modifier and TypeMethodDescriptionvoid
Change parameter type to array type.int
Returns the size of the array if the value is an array.Returns theParameters
that contains theParameter
.getName()
Returns the parameter name.Returns the fully qualified parameter name.getValue()
Returns a value as anObject
.Returns a value as aBoolean
.Boolean[]
Returns a value as aBoolean
array.Returns a value as aList<Boolean>
.Returns a value as aDouble
.Double[]
Returns a value as aDouble
array.Returns a value as aList<Double>
.Returns a value as aFloat
.Float[]
Returns a value as aFloat
array.Returns a value as aList<Float>
.Returns a value as anInteger
.Integer[]
Returns a value as anInteger
array.Returns a value as aList<Integer>
.Returns a value as aLong
.Long[]
Returns a value as aLong
array.Returns a value as aList<Long>
.Returns a value as aParameters
.Returns a value as aParameters
array.Returns a value as aList<Parameters>
.Returns a value as aString
.String[]
Returns a value as aString
array.Returns a value as aList<String>
.List<?>
Returns a value as aList
.Object[]
Returns a value as anObject
array.Returns the parameter value type.boolean
hasValue()
Returns whether a non-null value has been assigned.boolean
isArray()
Returns whether the parameter value is an array.boolean
Returns whether a parameter has been assigned a value.boolean
Returns whether the value of the array is represented using square brackets.boolean
Returns whether this is a predefined parameter.boolean
Returns whether the value type is hinted.<T extends Parameters>
TnewParameters
(Parameter identifier) Creates a new instance ofParameters
with the specified identifierParameter
.void
Puts the parameter value.void
Removes the parameter value.void
setValueType
(ValueType valueType) Sets the parameter value type.void
setValueTypeHinted
(boolean valueTypeHinted) Sets whether the value type is hinted.
-
Method Details
-
getContainer
Parameters getContainer()Returns theParameters
that contains theParameter
.- Returns:
- the
Parameters
-
getName
String getName()Returns the parameter name.- Returns:
- the parameter name
-
getQualifiedName
String getQualifiedName()Returns the fully qualified parameter name.- Returns:
- the qualified name
-
getValueType
ValueType getValueType()Returns the parameter value type.- Returns:
- the parameter value type
-
setValueType
Sets the parameter value type.- Parameters:
valueType
- the parameter value type
-
isValueTypeFixed
boolean isValueTypeFixed()Returns whether this is a predefined parameter.- Returns:
true
if this is a predefined parameter, otherwisefalse
-
isValueTypeHinted
boolean isValueTypeHinted()Returns whether the value type is hinted.- Returns:
- true if the value type is hinted; false otherwise
-
setValueTypeHinted
void setValueTypeHinted(boolean valueTypeHinted) Sets whether the value type is hinted.- Parameters:
valueTypeHinted
- true if the value type is hinted; false otherwise
-
isArray
boolean isArray()Returns whether the parameter value is an array.- Returns:
true
if the parameter value is an array, otherwisefalse
-
isBracketed
boolean isBracketed()Returns whether the value of the array is represented using square brackets.- Returns:
true
if the value of the array is represented using square brackets, otherwisefalse
-
isAssigned
boolean isAssigned()Returns whether a parameter has been assigned a value. Even if a null is assigned, it is valid.- Returns:
true
if a parameter has been assigned a value, otherwisefalse
-
hasValue
boolean hasValue()Returns whether a non-null value has been assigned.- Returns:
true
if a non-null value is assigned, otherwisefalse
-
getArraySize
int getArraySize()Returns the size of the array if the value is an array.- Returns:
- the size of the array
-
getValue
Object getValue()Returns a value as anObject
.- Returns:
- an
Object
-
arraylize
void arraylize()Change parameter type to array type. -
putValue
Puts the parameter value.- Parameters:
value
- the parameter value
-
removeValue
void removeValue()Removes the parameter value. -
getValues
Object[] getValues()Returns a value as anObject
array.- Returns:
- an array of
Object
-
getValueList
List<?> getValueList()Returns a value as aList
.- Returns:
- a
List
-
getValueAsString
String getValueAsString()Returns a value as aString
.- Returns:
- a
String
-
getValueAsStringArray
String[] getValueAsStringArray()Returns a value as aString
array.- Returns:
- a
String
array
-
getValueAsStringList
Returns a value as aList<String>
.- Returns:
- a
List<String>
-
getValueAsInt
Integer getValueAsInt()Returns a value as anInteger
.- Returns:
- an
Integer
-
getValueAsIntArray
Integer[] getValueAsIntArray()Returns a value as anInteger
array.- Returns:
- an
Integer
array
-
getValueAsIntList
Returns a value as aList<Integer>
.- Returns:
- a
List<Integer>
-
getValueAsLong
Long getValueAsLong()Returns a value as aLong
.- Returns:
- a
Long
-
getValueAsLongArray
Long[] getValueAsLongArray()Returns a value as aLong
array.- Returns:
- a
Long
array
-
getValueAsLongList
Returns a value as aList<Long>
.- Returns:
- a
List<Long>
-
getValueAsFloat
Float getValueAsFloat()Returns a value as aFloat
.- Returns:
- a
Float
-
getValueAsFloatArray
Float[] getValueAsFloatArray()Returns a value as aFloat
array.- Returns:
- a
Float
array
-
getValueAsFloatList
Returns a value as aList<Float>
.- Returns:
- a
List<Float>
-
getValueAsDouble
Double getValueAsDouble()Returns a value as aDouble
.- Returns:
- a
Double
-
getValueAsDoubleArray
Double[] getValueAsDoubleArray()Returns a value as aDouble
array.- Returns:
- a
Double
array
-
getValueAsDoubleList
Returns a value as aList<Double>
.- Returns:
- a
List<Double>
-
getValueAsBoolean
Boolean getValueAsBoolean()Returns a value as aBoolean
.- Returns:
- a
Boolean
-
getValueAsBooleanArray
Boolean[] getValueAsBooleanArray()Returns a value as aBoolean
array.- Returns:
- a
Boolean
array
-
getValueAsBooleanList
Returns a value as aList<Boolean>
.- Returns:
- a
List<Boolean>
-
getValueAsParameters
Parameters getValueAsParameters()Returns a value as aParameters
.- Returns:
- a
Parameters
-
getValueAsParametersArray
Parameters[] getValueAsParametersArray()Returns a value as aParameters
array.- Returns:
- a
Parameters
array
-
getValueAsParametersList
List<Parameters> getValueAsParametersList()Returns a value as aList<Parameters>
.- Returns:
- a
List<Parameters>
-
newParameters
Creates a new instance ofParameters
with the specified identifierParameter
.- Type Parameters:
T
- the type of the new Parameters object- Parameters:
identifier
- the specified identifierParameter
- Returns:
- a
Parameters
-