Class UIPanelPartCnr

All Implemented Interfaces:
EventListener, IFocusComp, IMessageBox, IComponent, IClassReferenceOwner, ICustomDataProvider, IGProp<GProp<?>[]>, IPanelPartReferenceOwner, IPropCnr, IUIClassReferenceOwner, IUIComp, IUIContainer, IUIContextMenuOwner, IUIFocusComp, IVSComponentListener, IVSComponentState, IVSFieldListener, IVSGenericComponentListener, Cloneable
Direct Known Subclasses:
EUIPanelPartCnr

public class UIPanelPartCnr extends UIContainer implements IPanelPartReferenceOwner, IUIClassReferenceOwner
The UI panel part container.
Author:
Christopher Mindus
  • Constructor Details

    • UIPanelPartCnr

      public UIPanelPartCnr()
      Creates the container without name with a null value.
    • UIPanelPartCnr

      public UIPanelPartCnr(Atom propertyAtom)
      Creates the container with the specified name with a null value.
      Parameters:
      propertyAtom - the property atom.
  • Method Details

    • isContextMenuSupported

      public boolean isContextMenuSupported()
      Returns if the context menu is supported for this component or not.
      Specified by:
      isContextMenuSupported in interface IUIContextMenuOwner
      Returns:
      false as the Panel Part Container does not support context menus.
    • hasImplicitAlignFillX

      public boolean hasImplicitAlignFillX()
      Returns if the component has implicit component horizontal fill.
      Overrides:
      hasImplicitAlignFillX in class UIContainer
      Returns:
      Always true: true means component will always fill the space in X.
    • hasImplicitAlignFillY

      public boolean hasImplicitAlignFillY()
      Returns if the component has implicit component vertical fill.
      Overrides:
      hasImplicitAlignFillY in class UIContainer
      Returns:
      Always: true means component will always fill the space in Y.
    • getPropBaseReference

      public PropCnr getPropBaseReference()
      The panel is the base component base reference.
      Specified by:
      getPropBaseReference in interface IGProp<GProp<?>[]>
      Overrides:
      getPropBaseReference in class PropCnr
      Returns:
      This UIPanelBase instance.
    • onPropParentChanged

      protected void onPropParentChanged(PropCnr oldParent, PropCnr newParent)
      Called when the parent is changed for this class. The proxy is started if required.
      Overrides:
      onPropParentChanged in class GProp<GProp<?>[]>
      Parameters:
      oldParent - The old parent (or null if none).
      newParent - The new parent (or null if none).
    • onResolved

      public void onResolved(UIPanelPart panelPart)
      Called when the panel part reference has been resolved.
      Specified by:
      onResolved in interface IPanelPartReferenceOwner
      Parameters:
      panelPart - The target reference.
    • onPropDispose

      protected void onPropDispose()
      Called when a property is disposed of by delete/remove in a container, or by the dispose method.
      Overrides:
      onPropDispose in class UIComp
    • onBroken

      public void onBroken(UIPanelPart panelPart)
      Called when the panel part reference has been broken, i.e. unresolved.
      Specified by:
      onBroken in interface IPanelPartReferenceOwner
      Parameters:
      panelPart - The target reference.
    • clone

      public UIPanelPartCnr clone()
      Clones the panel part container.
      Overrides:
      clone in class UIContainer
    • virtualize

      protected final UIPanelPartCnr virtualize(IAppSessionGyro appGyro, IClientSessionGyro clientGyro, VirtualSpace virtualSpace) throws CloneNotSupportedException, PropException
      Call this method to "virtualize" a property tree. This method is used at runtime in the Server for the application session of virtual instances of VirtualSpace, but also virtual instances of panels, for the individual client session. The VirtualSpace is virtualized once for the application session and is shared for parallel client sessions.

      This method is similar to cloning, but enables references that are already resolved to remain if they point to a shared instance, e.g. the VirtualSpace pointing to its participants in the application property container shared instance, or a panel with references to text IDs, assets, etc.

      It is up to the property class to handle this by overriding this method.

      Overrides:
      virtualize in class PropCnr
      Parameters:
      appGyro - The application gyro instance performing the virtualization.
      clientGyro - The client gyro session, can be null if not initialized from the client gyro.
      virtualSpace - The virtualized VirtualSpace.
      Returns:
      The virtualized property.
      Throws:
      CloneNotSupportedException - If a subclass doesn't allow cloning, e.g. the client properties.
      PropException - For property errors during the virtualization.
    • getClassReference

      public final ClassReference getClassReference()
      Gets the ClassReference in the property container from the ClassReference instance.
      Specified by:
      getClassReference in interface IClassReferenceOwner
      Returns:
      The resolved class reference instance, null if not resolved or found.
    • getClassReference

      public final ClassReference getClassReference(String id, boolean doCreateIfNotPresent)
      Gets or creates the ClassReference in the property container.
      Specified by:
      getClassReference in interface IClassReferenceOwner
      Specified by:
      getClassReference in interface IUIClassReferenceOwner
      Parameters:
      id - ID for the class reference if several exist, null for default.
      doCreateIfNotPresent - Flag to create the property (this flag can only be true in Designer)!
      Returns:
      The resolved class reference instance, null if the ClassReference doesn't exist if the create flag is false. If flag is true, an orphan unresolved EditorClassReference instance (ONLY for the Designer).
    • isClassReferenceAnnotationBackReferenceRequired

      public final boolean isClassReferenceAnnotationBackReferenceRequired(String id)
      Checks if the ClassReference require an annotation back-reference.
      Specified by:
      isClassReferenceAnnotationBackReferenceRequired in interface IClassReferenceOwner
      Specified by:
      isClassReferenceAnnotationBackReferenceRequired in interface IUIClassReferenceOwner
      Parameters:
      id - ID for the class reference if several exist, null for default.
      Returns:
      true, always: the annotation is required to have a back-reference on the "ref" member value pair to the ClassReference owner.
    • getClassReferenceRequiredAnnotation

      public final String getClassReferenceRequiredAnnotation(String id)
      Returns the required annotation, or null for none.
      Specified by:
      getClassReferenceRequiredAnnotation in interface IClassReferenceOwner
      Specified by:
      getClassReferenceRequiredAnnotation in interface IUIClassReferenceOwner
      Parameters:
      id - ID for the class reference if several exist, null for default.
      Returns:
      The fully qualified name of the interface for the class, or null for none. For panel this is always AnnotationType.UI.fqn.