Class VSMappings

java.lang.Object
com.iizix.prop.ui.VSMappings

public class VSMappings extends Object
Class containing mappings of a panel and its components to the VirtualSpace and the VSComponents.
Author:
Christopher Mindus
  • Method Details

    • add

      public boolean add(String uiRef, UIComp uiComp, VSComponent vsComp)
      Adds a new mapping. Calling this method several times for the same UIComp/VSComponent pair will not add an additional entry. If the VS component is ignoring UI focus, this method does nothing...

      This method is equivalent to calling add(uiRef, uiComp, vsComp, false);.

      Parameters:
      uiRef - The uiComp.getReferencePropName() value.
      uiComp - The panel component.
      vsComp - The VirtualSpace component.
      Returns:
      true if added, false otherwise (might be a duplicate).
    • add

      public boolean add(String uiRef, UIComp uiComp, VSComponent vsComp, boolean force)
      Adds a new mapping. Calling this method several times for the same UIComp/VSComponent pair will not add an additional entry. If the VS component is ignoring UI focus, this method does nothing...
      Parameters:
      uiRef - The uiComp.getReferencePropName() value.
      uiComp - The panel component.
      vsComp - The VirtualSpace component.
      force - Flag to forcibly add the reference, regardless if the component is set to ignore focus.
      Returns:
      true if added, false otherwise (might be a duplicate).
    • get

      public List<UIComp> get(VSComponent vsComp)
      Gets the mappings of a VSComponent to the panel components.
      Parameters:
      vsComp - The VirtualSpace component.
      Returns:
      An unmodifiable collection of UIComp's, or null for none. The list is sorted with the deepest UI component first.
    • get

      public List<VSComponent> get(UIComp uiComp)
      Gets the mappings of a panel UIComp to the VirtualSpace VSComponent's.
      Parameters:
      uiComp - The UI component.
      Returns:
      An unmodifiable list of VSComponent's, or null for none. The list is sorted with the deepest VS component first.
    • list

      public String list(UIComp uiComp, String indent)
      Lists the mappings from UI to VS.
      Parameters:
      uiComp - UI component to look-up, null for all.
      indent - Indent string to prepend all new lines with.
      Returns:
      The list string.
    • list

      public String list(VSComponent vsComp, String indent)
      Lists the mappings from VS to UI.
      Parameters:
      vsComp - VS component to look-up, null for all.
      indent - Indent string to prepend all new lines with.
      Returns:
      The list string.