Interface ClientActionSink
- All Superinterfaces:
Serializable
- Functional Interface:
- This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.
Receives the client-side function an
Action renders to when it is
bound through a SinkTrigger, and is responsible for getting it
invoked in the browser.
Implemented by whatever accepts client actions — typically a renderer that
passes the function into its own client-side template so a @click
binding can call it. The function takes (event, context): the client
event that fired it, if any, and {args}, the arguments the template
called the action with. Clipboard.writeText(), for example, copies
args[0].
For internal use only. May be renamed or removed in a future release.
-
Method Summary
Modifier and TypeMethodDescriptioninstall(JsFunction action) Takes the rendered action function and arranges for it to be called on the client.
-
Method Details
-
install
Takes the rendered action function and arranges for it to be called on the client.- Parameters:
action- the action function, to be invoked asaction(event, context), notnull- Returns:
- a registration that undoes the installation, never
null
-