public class ParameterizedN1qlQuery extends AbstractN1qlQuery
Represent a N1QL with an optionally parameterized statement (in which case the values must be passed according to the type and number of placeholders).
Positional placeholders (in the form of either “$1” “$2” or just simple “?”) are filled by the values taken from a JsonArray
.
Named placeholders (in the form of “$param1”, “$myOtherParam”, etc…) are filled by the values taken from a JsonObject
. If in this JsonObject attributes don’t have the $ prefix, it is added upon building the query.
Modifier and Type | Method and Description |
---|---|
boolean |
isPositional() |
JsonValue |
statementParameters()
The parameters to inject in the query, null or empty to ignore.
|
protected String |
statementType()
The type of the statement, used as JSON name in the final JSON form of the query
|
protected Object |
statementValue()
The JSON representation for the underlying
Statement in the final JSON form of the query |
n1ql, params, populateParameters, statement
parameterized, parameterized, parameterized, parameterized, parameterized, parameterized, parameterized, parameterized, simple, simple, simple, simple
protected String statementType()
AbstractN1qlQuery
The type of the statement, used as JSON name in the final JSON form of the query
statementType
in class AbstractN1qlQuery
protected Object statementValue()
AbstractN1qlQuery
The JSON representation for the underlying Statement
in the final JSON form of the query
statementValue
in class AbstractN1qlQuery
public JsonValue statementParameters()
AbstractN1qlQuery
The parameters to inject in the query, null or empty to ignore.
statementParameters
in class AbstractN1qlQuery
public boolean isPositional()
Copyright © 2015 Couchbase, Inc.