Package com.vaadin.flow.dom.impl
Class ElementJsInitializerRegistration
java.lang.Object
com.vaadin.flow.dom.impl.ElementJsInitializerRegistration
- All Implemented Interfaces:
Registration,Serializable
Server-side bookkeeping for a JavaScript initializer registered through
Element.addJsInitializer(String, Object...).
Re-emits the init invocation each time the client acquires a fresh DOM for
this element, and emits a matching dispose when the registration is removed.
The user expression is sent as a JsFunction parameter; the wrapper
expression itself contains only framework code that delegates registry
bookkeeping to this.registerInitializer /
this.disposeInitializer, which the client provides as part of the
executeJs execution context.
For internal use only.
- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionElementJsInitializerRegistration(StateNode node, String expression, Object[] parameters) Creates a new registration and schedules the first init invocation if the node is currently attached. -
Method Summary
Modifier and TypeMethodDescriptionvoidremove()Removes the associated listener from the event source.
-
Constructor Details
-
ElementJsInitializerRegistration
Creates a new registration and schedules the first init invocation if the node is currently attached.- Parameters:
node- the owning state node, notnullexpression- the user-supplied expression, notnullparameters- the user-supplied parameters, captured by the JsFunction
-
-
Method Details
-
remove
public void remove()Description copied from interface:RegistrationRemoves the associated listener from the event source.The
removemethod called after removal does nothing.- Specified by:
removein interfaceRegistration- See Also:
-