Interface Tree<T extends Tree<T>>

All Superinterfaces:
Comparable<T>, Component<T>, Copyable<T>, Serializable
All Known Subinterfaces:
TreeExternal<E>, TreeView<V>
All Known Implementing Classes:
DefaultTreeExternal, DefaultTreeView

public interface Tree<T extends Tree<T>> extends Component<T>
Represents the metadata for a tree component. This is primarily used for managing highly hierarchical data sets such as categories.
Author:
Nick Crum (ncrum)
  • Method Details

    • ancestorsListKey

      default T ancestorsListKey(String ancestorsListKey)
    • itemDisplayNameKey

      default T itemDisplayNameKey(String itemDisplayNameKey)
    • itemIdKey

      default T itemIdKey(String itemIdKey)
    • itemParentIdKey

      default T itemParentIdKey(String itemParentIdKey)
    • itemTypeLabel

      default T itemTypeLabel(String itemTypeLabelKey)
    • itemTypeLabel

      default T itemTypeLabel(InternationalizedMessage itemTypeLabel)
    • readRootItemsEndpoint

      default T readRootItemsEndpoint(Endpoint<?> endpoint)
    • getReadRootItemsEndpoint

      default Endpoint<?> getReadRootItemsEndpoint()
    • readRootItemsEndpoint

      default T readRootItemsEndpoint(UnaryOperator<Endpoint<?>> fn)
    • readRootItemsUrl

      default T readRootItemsUrl(String url)
    • readRootItemsScope

      default T readRootItemsScope(String scope)
    • readRootItemsUrl

      default T readRootItemsUrl(String url, String scope)
    • readChildrenItemsEndpoint

      default T readChildrenItemsEndpoint(Endpoint<?> endpoint)
    • getReadChildrenItemsEndpoint

      default Endpoint<?> getReadChildrenItemsEndpoint()
    • readChildrenItemsEndpoint

      default T readChildrenItemsEndpoint(UnaryOperator<Endpoint<?>> fn)
    • readChildrenItemsUrl

      default T readChildrenItemsUrl(String url)
    • readChildrenItemsScope

      default T readChildrenItemsScope(String scope)
    • readChildrenItemsUrl

      default T readChildrenItemsUrl(String url, String scope)
    • readItemEndpoint

      default T readItemEndpoint(Endpoint<?> endpoint)
    • getReadItemEndpoint

      default Endpoint<?> getReadItemEndpoint()
    • readItemEndpoint

      default T readItemEndpoint(UnaryOperator<Endpoint<?>> fn)
    • readItemUrl

      default T readItemUrl(String url)
    • readItemScope

      default T readItemScope(String scope)
    • readItemUrl

      default T readItemUrl(String url, String scope)
    • readGridItemsEndpoint

      default T readGridItemsEndpoint(PageableEndpoint<?> endpoint)
    • getReadGridItemsEndpoint

      default PageableEndpoint<?> getReadGridItemsEndpoint()
    • findReadGridItemsEndpoint

      default Optional<PageableEndpoint<?>> findReadGridItemsEndpoint()
    • readGridItemsEndpoint

      default T readGridItemsEndpoint(UnaryOperator<PageableEndpoint<?>> fn)
    • readGridItemsUrl

      default T readGridItemsUrl(String url)
    • readGridItemsScope

      default T readGridItemsScope(String scope)
    • readGridItemsUrl

      default T readGridItemsUrl(String url, String scope)
    • readAncestorsEndpoint

      default T readAncestorsEndpoint(Endpoint<?> endpoint)
    • getReadAncestorsEndpoint

      default Endpoint<?> getReadAncestorsEndpoint()
    • readAncestorsEndpoint

      default T readAncestorsEndpoint(UnaryOperator<Endpoint<?>> fn)
    • readAncestorsUrl

      default T readAncestorsUrl(String url)
    • readAncestorsScope

      default T readAncestorsScope(String scope)
    • readAncestorsUrl

      default T readAncestorsUrl(String url, String scope)
    • createItemEndpoint

      default T createItemEndpoint(Endpoint<?> endpoint)
    • getCreateItemEndpoint

      default Endpoint<?> getCreateItemEndpoint()
    • createItemEndpoint

      default T createItemEndpoint(UnaryOperator<Endpoint<?>> fn)
    • createItemUrl

      default T createItemUrl(String url)
    • createItemScope

      default T createItemScope(String scope)
    • createItemUrl

      default T createItemUrl(String url, String scope)
    • updateItemEndpoint

      default T updateItemEndpoint(Endpoint<?> endpoint)
    • getUpdateItemEndpoint

      default Endpoint<?> getUpdateItemEndpoint()
    • updateItemEndpoint

      default T updateItemEndpoint(UnaryOperator<Endpoint<?>> fn)
    • updateItemUrl

      default T updateItemUrl(String url)
    • updateItemScope

      default T updateItemScope(String scope)
    • updateItemUrl

      default T updateItemUrl(String url, String scope)
    • deleteItemEndpoint

      default T deleteItemEndpoint(Endpoint<?> endpoint)
    • getDeleteItemEndpoint

      default Endpoint<?> getDeleteItemEndpoint()
    • deleteItemEndpoint

      default T deleteItemEndpoint(UnaryOperator<Endpoint<?>> fn)
    • deleteItemUrl

      default T deleteItemUrl(String url)
    • deleteItemScope

      default T deleteItemScope(String scope)
    • deleteItemUrl

      default T deleteItemUrl(String url, String scope)
    • updateTranslationsEndpoint

      default T updateTranslationsEndpoint(Endpoint<?> endpoint)
    • getUpdateTranslationsEndpoint

      default Endpoint<?> getUpdateTranslationsEndpoint()
    • updateTranslationsEndpoint

      default T updateTranslationsEndpoint(UnaryOperator<Endpoint<?>> fn)
    • updateTranslationsUrl

      default T updateTranslationsUrl(String url)
    • updateTranslationsScope

      default T updateTranslationsScope(String scope)
    • updateTranslationsUrl

      default T updateTranslationsUrl(String url, String scope)
    • addCreateForm

      default T addCreateForm(FormView<?> form)
    • createForm

      default T createForm(UnaryOperator<FormView<?>> fn)
    • getCreateForm

      default FormView<?> getCreateForm()
    • findCreateForm

      default Optional<FormView<?>> findCreateForm()
    • addUpdateForm

      default T addUpdateForm(String id, FormView<?> form)
    • updateForm

      default T updateForm(String id, UnaryOperator<FormView<?>> fn)
    • getUpdateForm

      default FormView<?> getUpdateForm(String id)
    • findUpdateForm

      default Optional<FormView<?>> findUpdateForm(String id)
    • getForm

      default FormView<?> getForm(String id)
    • findForm

      default Optional<FormView<?>> findForm(String id)
    • addGrid

      default T addGrid(TreeGridView<?> grid)
    • grid

      default T grid(UnaryOperator<TreeGridView<?>> fn)
    • getGrid

      default TreeGridView<?> getGrid()
    • findGrid

      default Optional<TreeGridView<?>> findGrid()
    • addSecondaryAction

      default T addSecondaryAction(Action<?> action)
      Adds a configured Action to display in a secondary position on the TreeView. Secondary actions will appear in the dropdowns of tree view navigator items and the editor breadcrumbs. The Action.getType() must be set.
      Parameters:
      action - The configured Action
      Returns:
      this
    • secondaryAction

      default T secondaryAction(Action<?> action)
      Parameters:
      action - The configured Action
      Returns:
      this
    • addSecondaryAction

      default T addSecondaryAction(String type, Action<?> action)
      Adds a configured Action to display in a secondary position on the TreeView. Secondary actions will appear in the dropdowns of tree view navigator items and the editor breadcrumbs.
      Parameters:
      type - The type of the action. See Tree.ActionTypes
      action - The configured Action
      Returns:
      this
    • secondaryAction

      default T secondaryAction(String type, Action<?> action)
      Parameters:
      type - The type of the action. See Tree.ActionTypes
      action - The configured Action
      Returns:
      this
    • getSecondaryAction

      default Action<?> getSecondaryAction(String type)
      Finds the secondary action matching the given type. Expects the action to be present.
      Parameters:
      type - The type of the action. See Tree.ActionTypes
      Returns:
      the requested action
      Throws:
      IllegalArgumentException - if the action is not found
    • findSecondaryAction

      default Optional<Action<?>> findSecondaryAction(String type)
      Same as getSecondaryAction(String) except that his returns the action wrapped in an Optional so that the action need not be present.
      Parameters:
      type - The type of the action. See Tree.ActionTypes
      Returns:
      the requested action or Optional.empty() if not present
    • addGlobalAction

      default T addGlobalAction(Action<?> action)
      Adds a configured Action to display in a global position on the TreeView. Global actions are usually visible via a dropdown in the TreeView Navigator title bar near the "add" and "search" actions. The Action.getType() must be set.
      Parameters:
      action - The configured Action
      Returns:
      this
    • globalAction

      default T globalAction(Action<?> action)
      Parameters:
      action - The configured Action
      Returns:
      this
    • addGlobalAction

      default T addGlobalAction(String type, Action<?> action)
      Adds a configured Action to display in a global position on the TreeView. Global actions are usually visible via a dropdown in the TreeView Navigator title bar near the "add" and "search" actions. The Action.getType() must be set.
      Parameters:
      type - The type of the action. See Tree.ActionTypes
      action - The configured Action
      Returns:
      this
    • globalAction

      default T globalAction(String type, Action<?> action)
      Parameters:
      type - The type of the action. See Tree.ActionTypes
      action - The configured Action
      Returns:
      this
    • getGlobalAction

      default Action<?> getGlobalAction(String type)
      Finds the global action matching the given type. Expects the action to be present.
      Parameters:
      type - The type of the action. See Tree.ActionTypes
      Returns:
      the requested action
      Throws:
      IllegalArgumentException - if the action is not found
    • findGlobalAction

      default Optional<Action<?>> findGlobalAction(String type)
    • pageSize

      default T pageSize(int pageSize)