Class PublishingVariableTest.MyVariableTableSubscriber
java.lang.Object
com.singularsys.jep.misc.publishingvariable.VariableTableSubscriber
com.singularsys.jeptests.unit.misc.PublishingVariableTest.MyVariableTableSubscriber
- All Implemented Interfaces:
Flow.Subscriber<VariableTableAction>
- Enclosing class:
PublishingVariableTest
A more advances subscriber.
When the appropriate method is called, it adds a item to
actions.-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidCalled when the non-constant variables have been removed.protected voidconstantAdded(String name, Object value) Called when a constant is addedvoidMethod invoked when it is known that no additional Subscriber method invocations will occur for a Subscription that is not already terminated by error, after which no other Subscriber methods are invoked by the Subscription.voidMethod invoked upon an unrecoverable error encountered by a Publisher or Subscription, after which no other Subscriber methods are invoked by the Subscription.protected voidCalled when the variable table has been cleared.protected voidvariableAdded(String name, Object value) Called when a variable is added to the table.protected voidvariableChanged(String name, Object oldValue, Object newValue) Called when a variable value has changed.protected voidvariableRemoved(String name) Called when a variable is removed from the table.Methods inherited from class com.singularsys.jep.misc.publishingvariable.VariableTableSubscriber
cancel, onNext, onSubscribe
-
Constructor Details
-
MyVariableTableSubscriber
public MyVariableTableSubscriber()
-
-
Method Details
-
tableCleared
protected void tableCleared()Description copied from class:VariableTableSubscriberCalled when the variable table has been cleared. Intended to be overridden by subclasses. Default implementation does nothing.- Overrides:
tableClearedin classVariableTableSubscriber
-
variableChanged
Description copied from class:VariableTableSubscriberCalled when a variable value has changed. Intended to be overridden by subclasses. Default implementation does nothing.- Overrides:
variableChangedin classVariableTableSubscriber- Parameters:
name- name of the variableoldValue- previous value of the variablenewValue- value of the variable after the change
-
variableAdded
Description copied from class:VariableTableSubscriberCalled when a variable is added to the table. Intended to be overridden by subclasses. Default implementation does nothing.- Overrides:
variableAddedin classVariableTableSubscriber- Parameters:
name- the name of the variable which has been added.value- the value of the variable which has been added.
-
constantAdded
Description copied from class:VariableTableSubscriberCalled when a constant is added- Overrides:
constantAddedin classVariableTableSubscriber- Parameters:
name- name of variablevalue- value of variable
-
variableRemoved
Description copied from class:VariableTableSubscriberCalled when a variable is removed from the table. Intended to be overridden by subclasses. Default implementation does nothing.- Overrides:
variableRemovedin classVariableTableSubscriber- Parameters:
name- the name of the variable which has been removed.
-
clearNonConstants
public void clearNonConstants()Description copied from class:VariableTableSubscriberCalled when the non-constant variables have been removed. Intended to be overridden by subclasses. Default implementation does nothing.- Overrides:
clearNonConstantsin classVariableTableSubscriber
-
onComplete
public void onComplete()Description copied from class:VariableTableSubscriberMethod invoked when it is known that no additional Subscriber method invocations will occur for a Subscription that is not already terminated by error, after which no other Subscriber methods are invoked by the Subscription. The default implementation does nothing.- Specified by:
onCompletein interfaceFlow.Subscriber<VariableTableAction>- Overrides:
onCompletein classVariableTableSubscriber
-
onError
Description copied from class:VariableTableSubscriberMethod invoked upon an unrecoverable error encountered by a Publisher or Subscription, after which no other Subscriber methods are invoked by the Subscription. The default implementation does nothing.- Specified by:
onErrorin interfaceFlow.Subscriber<VariableTableAction>- Overrides:
onErrorin classVariableTableSubscriber- Parameters:
throwable- the exception
-