Class ElementBindingHarness
java.lang.Object
com.inductiveautomation.perspective.gateway.model.AbstractBindingHarness
com.inductiveautomation.perspective.gateway.model.ElementBindingHarness
- All Implemented Interfaces:
AuditingContext, BindingContext, LoggingContext
-
Field Summary
Fields inherited from class AbstractBindingHarness
binding, shutdown, targetComponent, targetProperty, transforms, typeCode -
Constructor Summary
ConstructorsConstructorDescriptionElementBindingHarness(PerspectiveElement targetComponent, PropertyKey target, BindingConfig config) -
Method Summary
Modifier and TypeMethodDescriptionnewFactory(PerspectiveElement element) protected @Nullable RunnablesubscribeToTarget(Consumer<PropertyTreeChangeEvent> callback) Attempt to subscribe to the target property.toString()protected voidwriteToTarget(QualifiedValue value) Write the given value to the target property.Methods inherited from class AbstractBindingHarness
getAuditSnapshot, getInitialValueFuture, getLastValue, getLogger, getMdcParent, getTargetElement, getTargetProperty, mdcSetup, mdcTeardown, onBindingProducedValue, onTransformProducedValue, processPublishedValue, publish, refresh, resolveReferences, shutdown, startupMethods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface AuditingContext
auditMethods inherited from interface BindingContext
getAuditProfile, getDiagnosticPath, getExecutorService, getMutabilityMode, getScheduler, getSession, publishMethods inherited from interface LoggingContext
mdc, mdcSetupTree, mdcTeardownTree, mdcWrap
-
Constructor Details
-
ElementBindingHarness
public ElementBindingHarness(PerspectiveElement targetComponent, PropertyKey target, BindingConfig config)
-
-
Method Details
-
newFactory
-
toString
-
subscribeToTarget
Description copied from class:AbstractBindingHarnessAttempt to subscribe to the target property.- Specified by:
subscribeToTargetin classAbstractBindingHarness- Parameters:
callback- When the target property changes, call this consumer and give it a way to fetch the new value- Returns:
- A runnable which when called will tear down the subscription. May be null if the subscription wasn't able to be established.
-
writeToTarget
Description copied from class:AbstractBindingHarnessWrite the given value to the target property.- Specified by:
writeToTargetin classAbstractBindingHarness
-