Class QueryBinding
java.lang.Object
com.inductiveautomation.perspective.gateway.binding.AbstractPollingBinding<QueryBindingParams>
com.inductiveautomation.perspective.gateway.binding.query.QueryBinding
- All Implemented Interfaces:
- QueryBindingConstants,- Binding
public class QueryBinding
extends AbstractPollingBinding<QueryBindingParams>
implements QueryBindingConstants
Implementation of a perspective query binding. These bindings will execute a named query, optionally on a rate.
 
The polling rate, as well as the parameter values, are all expressions that can produce new values at any time. Care is taken to ensure that any blocking work takes place on the perspective working thread-pool.
- 
Nested Class SummaryNested classes/interfaces inherited from class com.inductiveautomation.perspective.gateway.binding.AbstractPollingBindingAbstractPollingBinding.State
- 
Field SummaryFields inherited from class com.inductiveautomation.perspective.gateway.binding.AbstractPollingBindingcontext, stateFields inherited from interface com.inductiveautomation.perspective.gateway.api.BindingBAD_CONFIG, BAD_REF, BIDIRECTIONAL_KEY, INITIAL_VALUE, MDC_BINDING_TARGET, NOT_FOUNDFields inherited from interface com.inductiveautomation.perspective.common.config.constants.QueryBindingConstantsQUERY_PATH, TYPE_ID
- 
Method SummaryModifier and TypeMethodDescriptionprotected QueryBindingParamsThis method will be called when it is time to fetch a new value.static QualifiedValueexecute(QueryBindingParams params) protected booleanisDirty()If any dependencies of the implementation have changed, this method should return true, which will kick off another execution if dependencies have changed while the execution was running.protected booleanisReady()Indicates whether or not the instance of the underlying implementation is ready for execution.voidshutdown()Shut down the binding.voidstartup()Start up the binding.Methods inherited from class com.inductiveautomation.perspective.gateway.binding.AbstractPollingBindingonUserRefresh, scheduleNowMethods inherited from class java.lang.Objectclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface com.inductiveautomation.perspective.gateway.api.BindingisBidirectional, onTargetUpdated
- 
Method Details- 
resolveReferences- Specified by:
- resolveReferencesin interface- Binding
- Overrides:
- resolveReferencesin class- AbstractPollingBinding<QueryBindingParams>
 
- 
startuppublic void startup()Description copied from interface:BindingStart up the binding. Will be called on-queue- Specified by:
- startupin interface- Binding
- Overrides:
- startupin class- AbstractPollingBinding<QueryBindingParams>
 
- 
shutdownpublic void shutdown()Description copied from interface:BindingShut down the binding. Will be called on-queue- Specified by:
- shutdownin interface- Binding
- Overrides:
- shutdownin class- AbstractPollingBinding<QueryBindingParams>
 
- 
isReadyprotected boolean isReady()Description copied from class:AbstractPollingBindingIndicates whether or not the instance of the underlying implementation is ready for execution.- Specified by:
- isReadyin class- AbstractPollingBinding<QueryBindingParams>
 
- 
isDirtyprotected boolean isDirty()Description copied from class:AbstractPollingBindingIf any dependencies of the implementation have changed, this method should return true, which will kick off another execution if dependencies have changed while the execution was running.- Specified by:
- isDirtyin class- AbstractPollingBinding<QueryBindingParams>
 
- 
buildFetchParametersDescription copied from class:AbstractPollingBindingThis method will be called when it is time to fetch a new value. The parameter object must implement hashcode and equals, and must contain everything needed to run this parameter's fetch function. The parameter object will be given to theValueCache, which will then execute the fetch function if a new value is needed. This method will be called within a synchronized block holding this lock.- Specified by:
- buildFetchParametersin class- AbstractPollingBinding<QueryBindingParams>
 
- 
execute
 
-