Interface IContentPart<V extends Node>

Type Parameters:
V - The visual node used by this IContentPart.
All Superinterfaces:
IActivatable, IAdaptable, IAdaptable.Bound<IViewer>, IDisposable, IVisualPart<V>
All Known Subinterfaces:
IBendableContentPart<V>, IResizableContentPart<V>, ITransformableContentPart<V>
All Known Implementing Classes:
AbstractContentPart

public interface IContentPart<V extends Node> extends IVisualPart<V>
An IVisualPart that visualizes an underlying content element.
Noimplement:
This interface is not intended to be implemented by clients. Instead, AbstractContentPart should be sub-classed.
  • Property Details

  • Field Details

  • Method Details

    • addContentChild

      void addContentChild(Object contentChild, int index)
      Inserts the given contentChild as a child to this part's content, so that it will be returned by subsequent calls to getContentChildrenUnmodifiable().
      Parameters:
      contentChild - An Object which should be added as a child to this part's content.
      index - The index at which the contentChild should be added.
    • attachToContentAnchorage

      void attachToContentAnchorage(Object contentAnchorage, String role)
      Attaches this part's content to the given contentAnchorage under the specified role, so that it will be returned by subsequent calls to getContentAnchoragesUnmodifiable().
      Parameters:
      contentAnchorage - An Object to which this part's content should be attached to.
      role - The role under which the attachment is to be established.
    • contentAnchoragesUnmodifiableProperty

      ReadOnlySetMultimapProperty<Object,String> contentAnchoragesUnmodifiableProperty()
      Returns an unmodifiable read-only set-multimap property containing the content anchorages.
      See Also:
    • contentChildrenUnmodifiableProperty

      ReadOnlyListProperty<Object> contentChildrenUnmodifiableProperty()
      Returns an unmodfiable read-only property containing the content children.
      See Also:
    • contentProperty

      ObjectProperty<Object> contentProperty()
      A writable property representing the IContentPart's content.
      See Also:
    • detachFromContentAnchorage

      void detachFromContentAnchorage(Object contentAnchorage, String role)
      Detaches this part's content from the given contentAnchorage under the specified role, so that it will no longer be returned by subsequent calls to getContentAnchoragesUnmodifiable().
      Parameters:
      contentAnchorage - An Object from which this part's content should be detached from.
      role - The role under which the attachment is established.
    • getContent

      Object getContent()
      Returns this part's content.
      Returns:
      This part's content.
    • getContentAnchoragesUnmodifiable

      ObservableSetMultimap<Object,String> getContentAnchoragesUnmodifiable()
      Returns an unmodifiable ObservableSetMultimap that contains the content objects that are to be regarded as anchorages of this IContentPart's content (getContent()) with an (optional) role qualifier for each anchorage-anchored link that has to be established.

      In case of a connection, one anchorage could have the "START" role, and another the "END" role. Using the role mechanism, the same anchorage may also have both roles, which can, for instance, be used for self connections.

      Returns:
      An unmodifiable ObservableSetMultimap of the content anchorages with a role to qualify each anchorage-anchored link. If there is only a single anchorage-anchored link to a respective anchorage, its role may be left undefined (i.e. the map will contain an entry of the form (anchorage, null)).
    • getContentChildrenUnmodifiable

      ObservableList<Object> getContentChildrenUnmodifiable()
      Returns an unmodifiable ObservableList that contains the content children.
      Returns:
      A List of all of this part's content children.
    • isFocusable

      boolean isFocusable()
      Returns true if policies and other parts of the application are allowed to assign focus to this part by changing the FocusModel. Otherwise returns false.
      Returns:
      true if policies and other parts of the application are allowed to assign focus to this part by changing the FocusModel, otherwise false.
    • isSelectable

      boolean isSelectable()
      Returns true if policies and other parts of the application are allowed to add this part to the selection maintained by the SelectionModel. Otherwise returns false.
      Returns:
      true if policies and other parts of the application are allowed to add this part to the selection maintained by the SelectionModel, otherwise false.
    • refreshContentAnchorages

      void refreshContentAnchorages()
      Triggers a re-computation of the content anchorages of this IContentPart.
    • refreshContentChildren

      void refreshContentChildren()
      Triggers a re-computation of the content children of this IContentPart.
    • removeContentChild

      void removeContentChild(Object contentChild)
      Removes the given contentChild from this part's content children, so that it will no longer be returned by subsequent calls to getContentChildrenUnmodifiable().
      Parameters:
      contentChild - An Object which should be removed from this part's content children.
    • reorderContentChild

      void reorderContentChild(Object contentChild, int newIndex)
      Rearranges the given contentChild to the new index position. Fires property change events using CONTENT_CHILDREN_PROPERTY as property name.
      Parameters:
      contentChild - The Object which is to be reordered.
      newIndex - The index to which the content child is to be reordered.
    • setContent

      void setContent(Object content)
      Sets this part's content to the given value. Fires property change events using CONTENT_PROPERTY as property name.
      Parameters:
      content - The new content for this part.