Interface ClientItemsPlugin

All Superinterfaces:
org.timepedia.exporter.client.Exportable

public interface ClientItemsPlugin extends org.timepedia.exporter.client.Exportable
The provider for actions in a specific context.
Example for the implementation of a ClientItemsPlugin:
     function clientItemsPluginImpl(context, receiver) {
         // context: ClientItemContext
         // receiver: function(result: Array<ClientItem>)
         var items = [];
         var fsid = context.getProperty("fsid");
         if (fsid) {
            items.push(context.createItem("iconUrl", "title", function clientItemPerformable() {
                // Perform action
                console.log("Performing action for element with id '" + fsid.getId() + "'...");
                // Refresh related view on modification
                context.refresh();
            }));
         }
         // Send the ClientItem to the caller, so it will be shown in the appropriate context.
         receiver(items);
     });
 
Since:
5.2.181105
See Also:
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    getItems(@NotNull ClientItemContext context, @NotNull com.google.gwt.core.client.JavaScriptObject callback)
    Requests action in the specified context.