Package com.adobe.aem.dermis.api.bridge
Class Query
- java.lang.Object
-
- com.adobe.aem.dermis.api.bridge.Query
-
public class Query extends java.lang.Object
This represents a query object that is used to execute a operation in dermis.
-
-
Constructor Summary
Constructors Constructor Description Query(java.lang.String formDataModelPath, DataContext dataContext)
Create Query using form data model path and data contextQuery(java.lang.String formDataModelPath, DataContext dataContext, OperationOptions options)
Create Query using form data model path, data context and operation arguments
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description void
addEntityAndOperation(java.lang.String entityId, java.lang.String operationId)
org.apache.sling.commons.json.JSONObject
getArguments()
Deprecated.UsegetArgumentsValueMap()
insteadIValueMap
getArgumentsValueMap()
Get arguments representing the input of the operation as IValueMapDataContext
getDataContext()
GetsDataContext
represents a pluggable mechanism for resolving a operation arguments at evaluation time.java.lang.String
getEntityId()
java.util.Map<java.lang.String,java.lang.String>
getEntityOperationMapping()
java.lang.String
getFormDataModelPath()
Get FormDataModel unique identifierjava.lang.String
getOperationId()
OperationOptions
getOptions()
GetOperationOptions
which provide additional option of queryboolean
getOutputTypeArray()
Tells whether return type of this operation is an array or notjava.lang.String
getSelectionPoints()
boolean
isEvaluateComputedAttrs()
void
replaceOperationRefByName(java.lang.String operationRef, java.lang.String operationName)
void
setArguments(org.apache.sling.commons.json.JSONObject arguments)
Deprecated.UsesetArgumentsValueMap(IValueMap)
insteadvoid
setArgumentsValueMap(IValueMap arguments)
Set operation arguments, accepts an IValueMap for arguments Input arguments can be given either as a JSONObject or as IValueMap - these two formats are mutually exclusive.void
setDataContext(DataContext dataContext)
Sets the dataContext which will be used for resolving a operation arguments at evaluation time.void
setEvaluateComputedAttrs(boolean evaluateComputedAttrs)
void
setFormDataModelPath(java.lang.String formDataModelPath)
Sets the formDataModel unique identifier.void
setOptions(OperationOptions options)
SetOperationOptions
in queryvoid
setOutputTypeArray(boolean isOutputTypeArray)
Sets whether return type of this operation is an array or not
-
-
-
Constructor Detail
-
Query
public Query(java.lang.String formDataModelPath, DataContext dataContext)
Create Query using form data model path and data context- Parameters:
formDataModelPath
-dataContext
-
-
Query
public Query(java.lang.String formDataModelPath, DataContext dataContext, OperationOptions options)
Create Query using form data model path, data context and operation arguments- Parameters:
formDataModelPath
-dataContext
-options
-
-
-
Method Detail
-
getDataContext
public DataContext getDataContext()
GetsDataContext
represents a pluggable mechanism for resolving a operation arguments at evaluation time.- Returns:
- -
DataContext
-
setDataContext
public void setDataContext(DataContext dataContext)
Sets the dataContext which will be used for resolving a operation arguments at evaluation time.- Parameters:
dataContext
-DataContext
-
getFormDataModelPath
public java.lang.String getFormDataModelPath()
Get FormDataModel unique identifier- Returns:
- identifier of FormDataModel
-
setFormDataModelPath
public void setFormDataModelPath(java.lang.String formDataModelPath)
Sets the formDataModel unique identifier.- Parameters:
formDataModelPath
- - unique identifier of FormDataModel
-
getEntityId
public java.lang.String getEntityId()
- Returns:
- - identifier of entity
-
getOperationId
public java.lang.String getOperationId()
- Returns:
- - identifier of entity
-
addEntityAndOperation
public void addEntityAndOperation(java.lang.String entityId, java.lang.String operationId)
- Parameters:
entityId
-operationId
-
-
getOptions
public OperationOptions getOptions()
GetOperationOptions
which provide additional option of query- Returns:
OperationOptions
-
setOptions
public void setOptions(OperationOptions options)
SetOperationOptions
in query- Parameters:
options
-OperationOptions
-
setArguments
@Deprecated public void setArguments(org.apache.sling.commons.json.JSONObject arguments)
Deprecated.UsesetArgumentsValueMap(IValueMap)
insteadSet operation arguments, accepts a JSONObject for arguments Input arguments can be given either as a JSONObject or as IValueMap - these two formats are mutually exclusive. If input arguments have been provided in one format, it should not be provided in another format, unless the already provided inputs are cleared- Parameters:
arguments
-
-
setArgumentsValueMap
public void setArgumentsValueMap(IValueMap arguments)
Set operation arguments, accepts an IValueMap for arguments Input arguments can be given either as a JSONObject or as IValueMap - these two formats are mutually exclusive. If input arguments have been provided in one format, it should not be provided in another format, unless the already provided inputs are cleared- Parameters:
arguments
-
-
getArguments
@Deprecated public org.apache.sling.commons.json.JSONObject getArguments()
Deprecated.UsegetArgumentsValueMap()
insteadGet arguments representing the input of the operation as JSONObject- Returns:
- input in
JSONObject
format
-
getArgumentsValueMap
public IValueMap getArgumentsValueMap()
Get arguments representing the input of the operation as IValueMap- Returns:
- input in
IValueMap
format
-
getEntityOperationMapping
public java.util.Map<java.lang.String,java.lang.String> getEntityOperationMapping()
- Returns:
- Map of entity related operation details..
-
replaceOperationRefByName
public void replaceOperationRefByName(java.lang.String operationRef, java.lang.String operationName)
- Parameters:
operationRef
-operationName
-
-
getSelectionPoints
public java.lang.String getSelectionPoints()
- Returns:
- selectionPoints
-
getOutputTypeArray
public boolean getOutputTypeArray()
Tells whether return type of this operation is an array or not- Returns:
-
setOutputTypeArray
public void setOutputTypeArray(boolean isOutputTypeArray)
Sets whether return type of this operation is an array or not
-
isEvaluateComputedAttrs
public boolean isEvaluateComputedAttrs()
-
setEvaluateComputedAttrs
public void setEvaluateComputedAttrs(boolean evaluateComputedAttrs)
-
-