Class Parameters
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescription<T> T
Gets a parameter's value.final Object
Gets a parameter's value.final Parameters
Set the Array value to the query parameter referenced by the given name.final Parameters
Set the Blob value to the query parameter referenced by the given name.final Parameters
setBoolean
(String name, boolean value) Set a boolean value to the query parameter referenced by the given name.final Parameters
Set a date value to the query parameter referenced by the given name.final Parameters
setDictionary
(String name, Dictionary value) Set the Dictionary value to the query parameter referenced by the given name.final Parameters
Set a double value to the query parameter referenced by the given name.final Parameters
Set a float value to the query parameter referenced by the given name.final Parameters
Set an int value to the query parameter referenced by the given name.final Parameters
Set an long value to the query parameter referenced by the given name.final Parameters
Set an Number value to the query parameter referenced by the given name.final Parameters
Set an String value to the query parameter referenced by the given name.Set a value to the query parameter referenced by the given name.Methods inherited from class com.couchbase.lite.internal.BaseJFleeceCollection
asArray, asBlob, asBoolean, asDictionary, asNumber, asString, asValue, toBoolean, toDouble, toDouble, toFloat, toFloat, toInteger, toInteger, toJFleece, toJFleeceCollection, toLong, toLong
-
Constructor Details
-
Parameters
public Parameters() -
Parameters
-
-
Method Details
-
getValue
Gets a parameter's value.- Parameters:
name
- The parameter name.- Returns:
- The parameter value.
-
getValue
Gets a parameter's value.- Parameters:
name
- the key.- Returns:
- The value in the dictionary at the key (or null).
- Throws:
ClassCastException
- if the value is not of the passed class.
-
setString
Set an String value to the query parameter referenced by the given name. A query parameter is defined by using the Expression's parameter(String name) function.- Parameters:
name
- The parameter name.value
- The String value.- Returns:
- The self object.
-
setNumber
Set an Number value to the query parameter referenced by the given name. A query parameter is defined by using the Expression's parameter(String name) function.- Parameters:
name
- The parameter name.value
- The Number value.- Returns:
- The self object.
-
setInt
Set an int value to the query parameter referenced by the given name. A query parameter is defined by using the Expression's parameter(String name) function.- Parameters:
name
- The parameter name.value
- The int value.- Returns:
- The self object.
-
setLong
Set an long value to the query parameter referenced by the given name. A query parameter is defined by using the Expression's parameter(String name) function.- Parameters:
name
- The parameter name.value
- The long value.- Returns:
- The self object.
-
setFloat
Set a float value to the query parameter referenced by the given name. A query parameter is defined by using the Expression's parameter(String name) function.- Parameters:
name
- The parameter name.value
- The float value.- Returns:
- The self object.
-
setDouble
Set a double value to the query parameter referenced by the given name. A query parameter is defined by using the Expression's parameter(String name) function.- Parameters:
name
- The parameter name.value
- The double value.- Returns:
- The self object.
-
setBoolean
Set a boolean value to the query parameter referenced by the given name. A query parameter is defined by using the Expression's parameter(String name) function.- Parameters:
name
- The parameter name.value
- The boolean value.- Returns:
- The self object.
-
setDate
Set a date value to the query parameter referenced by the given name. A query parameter is defined by using the Expression's parameter(String name) function.Note: The date value is stored as a string in the ISO 8601 format. params.setDate("foo", new Date()).getValue("foo") returns a string in ISO 8601 format, not a Date.
- Parameters:
name
- The parameter name.value
- The date value.- Returns:
- The self object.
-
setBlob
Set the Blob value to the query parameter referenced by the given name. A query parameter is defined by using the Expression's parameter(String name) function.- Parameters:
name
- The parameter name.value
- The Blob value.- Returns:
- The self object.
-
setArray
Set the Array value to the query parameter referenced by the given name. A query parameter is defined by using the Expression's parameter(String name) function.Note: The Array is not copied before insertion into the Parameters object: changes to the Array after it is set in the Array but before the Parameters are attached to a Query, will be reflected in the Query. Changes to the Dictionary after the Parameters are attached to a Query will not be reflected in the Query and will leave the Parameters in an inconsistent state.
- Parameters:
name
- The parameter name.value
- The Array value.- Returns:
- The self object.
-
setDictionary
Set the Dictionary value to the query parameter referenced by the given name. A query parameter is defined by using the Expression's parameter(String name) function.Note: The Dictionary is not copied before insertion into the Parameters object: changes to the Dictionary after it is set in the Array but before the Parameters are attached to a Query, will be reflected in the Query. Changes to the Dictionary after the Parameters are attached to a Query will not be reflected in the Query and will leave the Parameters in an inconsistent state.
- Parameters:
name
- The parameter name.value
- The Dictionary value.- Returns:
- The self object.
-
setValue
Set a value to the query parameter referenced by the given name. A query parameter is defined by using the Expression's parameter(String name) function.- Parameters:
name
- The parameter name.value
- The value.- Returns:
- The self object.
-