Class LXSnapshot.RackPatternView

java.lang.Object
heronarts.lx.snapshot.LXSnapshot.View
heronarts.lx.snapshot.LXSnapshot.RackPatternView
All Implemented Interfaces:
LXSerializable
Enclosing class:
LXSnapshot

public final class LXSnapshot.RackPatternView extends LXSnapshot.View
View for which pattern is active on a rack. Painfully redundant with ActivePatternView but easier to keep stored data format clear for backwards compatibility with a dedicated type here.
  • Field Details

  • Method Details

    • getPattern

      public LXPattern getPattern()
    • update

      public void update(int patternIndex)
    • getLabel

      public String getLabel()
      Description copied from class: LXSnapshot.View
      Gets a descriptive label for the parameter or field represented by the view
      Specified by:
      getLabel in class LXSnapshot.View
      Returns:
      Descriptive label for the parameter or field represented by the view
    • getDescription

      public String getDescription()
      Description copied from class: LXSnapshot.View
      Gets a description of the behavior of the parameter or field represented by the view
      Specified by:
      getDescription in class LXSnapshot.View
      Returns:
      Description of the behavior of the parameter or field represented by the view
    • getViewComponent

      public LXComponent getViewComponent()
      Description copied from class: LXSnapshot.View
      Gets the component that owns the parameter/field referenced by the view
      Specified by:
      getViewComponent in class LXSnapshot.View
      Returns:
      Component that owns the parameter/field referenced by the view
    • getViewPath

      public String getViewPath()
      Description copied from class: LXSnapshot.View
      Gets a unique path identifier for this view in the context of its snapshot
      Specified by:
      getViewPath in class LXSnapshot.View
      Returns:
      Unique path identifier for this view in the context of its snapshot
    • getCommand

      public LXCommand getCommand()
      Description copied from class: LXSnapshot.View
      Gets a command version of this view's operation, needed to make this action undoable.
      Specified by:
      getCommand in class LXSnapshot.View
      Returns:
      Command implementation of this view
    • isDependentOf

      protected boolean isDependentOf(LXComponent component)
      Description copied from class: LXSnapshot.View
      Subclasses must implement, determines whether the given view is dependent upon the specified component, and whether this view should be removed if the component is disposed
      Specified by:
      isDependentOf in class LXSnapshot.View
      Parameters:
      component - Component to test
      Returns:
      true if this view depends upon that component's existence, false otherwise
    • recall

      protected void recall()
      Description copied from class: LXSnapshot.View
      Subclasses must implement, should reapply the state of the view immediately
      Specified by:
      recall in class LXSnapshot.View
    • save

      public void save(LX lx, JsonObject obj)
      Description copied from interface: LXSerializable
      Serializes this instance into the JSON object
      Specified by:
      save in interface LXSerializable
      Overrides:
      save in class LXSnapshot.View
      Parameters:
      lx - LX instance
      obj - Object to serialize into