Class/Object

cogdebugger.ui

Desktop

Related Docs: object Desktop | package ui

Permalink

class Desktop extends ProbeDesktop with RestorableState

A desktop that hosts windows/frames that in turn host visualizations for fields.

The Desktop reacts to cogdebugger.ui.structure.InteractiveGraphEvents (produced by one of the classes in cogdebugger.ui.structure) that indicate that a user is interested in some field. Please remember to actually subscribe this class to an event source! In response to an event, a window is launched on the Desktop that contains some manner of visualization of the data within the field. Windows can be resized, repositioned, and closed by users.

If requested, the Desktop can encode the state of any open visualizations (size, position, installed Viewer implementation) into an XML tag. If peristed to disk, this tag can then later be used to restore the state of the Desktop in a subsequent debugger session.

Linear Supertypes
RestorableState, ProbeDesktop, BorderPanel, LayoutContainer, Panel, Wrapper, Container, Component, UIElement, LazyPublisher, Publisher, Reactor, Proxy, AnyRef, Any
Ordering
  1. Alphabetic
  2. By inheritance
Inherited
  1. Desktop
  2. RestorableState
  3. ProbeDesktop
  4. BorderPanel
  5. LayoutContainer
  6. Panel
  7. Wrapper
  8. Container
  9. Component
  10. UIElement
  11. LazyPublisher
  12. Publisher
  13. Reactor
  14. Proxy
  15. AnyRef
  16. Any
  1. Hide All
  2. Show all
Visibility
  1. Public
  2. All

Instance Constructors

  1. new Desktop(moduleHierarchy: ModuleHierarchyTree, probeManager: ProbeManager)

    Permalink

    moduleHierarchy

    A tree describing the module hierarchy of the model being debugged.

    probeManager

    The ProbeManager responsible for tracking and reading probes attached to the model being debugged.

Type Members

  1. type Constraints = scala.swing.BorderPanel.Position.Value

    Permalink
    Definition Classes
    BorderPanel → LayoutContainer
  2. class Content extends BufferWrapper[Component]

    Permalink
    Attributes
    protected
    Definition Classes
    Wrapper
  3. trait SuperMixin extends JComponent

    Permalink
    Attributes
    protected
    Definition Classes
    Component

Value Members

  1. final def !=(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  2. final def ##(): Int

    Permalink
    Definition Classes
    AnyRef → Any
  3. final def ==(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  4. val _contents: Content

    Permalink
    Attributes
    protected
    Definition Classes
    Wrapper
  5. def add(c: Component, l: Constraints): Unit

    Permalink
    Attributes
    protected
    Definition Classes
    BorderPanel → LayoutContainer
  6. def addFrame(frame: InternalFrame): Unit

    Permalink

    Subscribe the tiler to frame and add the frame to the desktop.

    Subscribe the tiler to frame and add the frame to the desktop.

    Definition Classes
    ProbeDesktop
  7. def addViewer(title: String, viewer: Viewer, viewerTarget: ProbedField): DesktopFrame

    Permalink

    Builds a cogdebugger.ui.DesktopFrame with the given title to host the given viewer and adds it to the desktop.

    Builds a cogdebugger.ui.DesktopFrame with the given title to host the given viewer and adds it to the desktop. If the viewer is an EventDrivenViewer, this method will create a cogdebugger.Probe to drive it and subscribe the viewer to the probe before making the frame visible.

    All frames created by this method are listened to by the cogdebugger.coggui3ports.Tiler. As soon as they pack themselves, the Tiler will attempt to position them such they don't overlap any existing panels (note that this position is immediately overriden by restoreFrame if the viewer was added as part of the Desktop's restore process).

    title

    Title for the desktop frame that will be shown

    viewer

    The viewer to be installed in a frame and shown on the desktop

    viewerTarget

    The ProbedField the viewer is visualizing

    Attributes
    protected
  8. def areValid(c: Constraints): (Boolean, String)

    Permalink
    Attributes
    protected
    Definition Classes
    BorderPanel → LayoutContainer
  9. final def asInstanceOf[T0]: T0

    Permalink
    Definition Classes
    Any
  10. def background: Color

    Permalink
    Definition Classes
    UIElement
  11. def background_=(c: Color): Unit

    Permalink
    Definition Classes
    UIElement
  12. def border: Border

    Permalink
    Definition Classes
    Component
  13. def border_=(b: Border): Unit

    Permalink
    Definition Classes
    Component
  14. def bounds: Rectangle

    Permalink
    Definition Classes
    UIElement
  15. def buildViewerFor(target: AnyRef): Unit

    Permalink

    Constructs a Viewer for the target field, installs it in a frame, and adds that frame to the desktop.

  16. def clone(): AnyRef

    Permalink
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  17. def constraintsFor(comp: Component): scala.swing.BorderPanel.Position.Value

    Permalink
    Attributes
    protected
    Definition Classes
    BorderPanel → LayoutContainer
  18. def contents: Seq[Component]

    Permalink
    Definition Classes
    Wrapper → Container
  19. def cursor: Cursor

    Permalink
    Definition Classes
    UIElement
  20. def cursor_=(c: Cursor): Unit

    Permalink
    Definition Classes
    UIElement
  21. def deafTo(ps: Publisher*): Unit

    Permalink
    Definition Classes
    Reactor
  22. lazy val desktop: WrappedInternalDesktopPane

    Permalink
    Attributes
    protected
    Definition Classes
    DesktopProbeDesktop
  23. def desktopHeight: Int

    Permalink
    Definition Classes
    ProbeDesktop
  24. def desktopWidth: Int

    Permalink
    Definition Classes
    ProbeDesktop
  25. def displayable: Boolean

    Permalink
    Definition Classes
    UIElement
  26. def enabled: Boolean

    Permalink
    Definition Classes
    Component
  27. def enabled_=(b: Boolean): Unit

    Permalink
    Definition Classes
    Component
  28. final def eq(arg0: AnyRef): Boolean

    Permalink
    Definition Classes
    AnyRef
  29. def equals(that: Any): Boolean

    Permalink
    Definition Classes
    Proxy → Any
  30. def finalize(): Unit

    Permalink
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] )
  31. def focusable: Boolean

    Permalink
    Definition Classes
    Component
  32. def focusable_=(b: Boolean): Unit

    Permalink
    Definition Classes
    Component
  33. def font: Font

    Permalink
    Definition Classes
    UIElement
  34. def font_=(f: Font): Unit

    Permalink
    Definition Classes
    UIElement
  35. def foreground: Color

    Permalink
    Definition Classes
    UIElement
  36. def foreground_=(c: Color): Unit

    Permalink
    Definition Classes
    UIElement
  37. def frames: Seq[InternalFrame]

    Permalink

    All the InternalFrames currently on the desktp.

    All the InternalFrames currently on the desktp.

    Definition Classes
    ProbeDesktop
  38. final def getClass(): Class[_]

    Permalink
    Definition Classes
    AnyRef → Any
  39. def hasFocus: Boolean

    Permalink
    Definition Classes
    Component
  40. def hashCode(): Int

    Permalink
    Definition Classes
    Proxy → Any
  41. def ignoreRepaint: Boolean

    Permalink
    Definition Classes
    UIElement
  42. def ignoreRepaint_=(b: Boolean): Unit

    Permalink
    Definition Classes
    UIElement
  43. var initP: JComponent

    Permalink
    Definition Classes
    Component
  44. def inputVerifier: (Component) ⇒ Boolean

    Permalink
    Definition Classes
    Component
  45. def inputVerifier_=(v: (Component) ⇒ Boolean): Unit

    Permalink
    Definition Classes
    Component
  46. final def isInstanceOf[T0]: Boolean

    Permalink
    Definition Classes
    Any
  47. def layout: Map[Component, Constraints]

    Permalink
    Definition Classes
    LayoutContainer
  48. def layoutManager: BorderLayout

    Permalink
    Definition Classes
    BorderPanel
  49. def listenTo(ps: Publisher*): Unit

    Permalink
    Definition Classes
    Reactor
  50. val listeners: RefSet[Reaction] { val underlying: scala.collection.mutable.HashSet[scala.ref.Reference[scala.swing.Reactions.Reaction]] }

    Permalink
    Attributes
    protected
    Definition Classes
    Publisher
  51. def locale: Locale

    Permalink
    Definition Classes
    UIElement
  52. def location: Point

    Permalink
    Definition Classes
    UIElement
  53. def locationOnScreen: Point

    Permalink
    Definition Classes
    UIElement
  54. def maximumSize: Dimension

    Permalink
    Definition Classes
    UIElement
  55. def maximumSize_=(x: Dimension): Unit

    Permalink
    Definition Classes
    UIElement
  56. def minimumSize: Dimension

    Permalink
    Definition Classes
    UIElement
  57. def minimumSize_=(x: Dimension): Unit

    Permalink
    Definition Classes
    UIElement
  58. object mouse

    Permalink
    Definition Classes
    Component
  59. def name: String

    Permalink
    Definition Classes
    Component
  60. def name_=(s: String): Unit

    Permalink
    Definition Classes
    Component
  61. final def ne(arg0: AnyRef): Boolean

    Permalink
    Definition Classes
    AnyRef
  62. final def notify(): Unit

    Permalink
    Definition Classes
    AnyRef
  63. final def notifyAll(): Unit

    Permalink
    Definition Classes
    AnyRef
  64. def onFirstSubscribe(): Unit

    Permalink
    Attributes
    protected
    Definition Classes
    Component → UIElement → LazyPublisher
  65. def onLastUnsubscribe(): Unit

    Permalink
    Attributes
    protected
    Definition Classes
    UIElement → LazyPublisher
  66. def opaque: Boolean

    Permalink
    Definition Classes
    Component
  67. def opaque_=(b: Boolean): Unit

    Permalink
    Definition Classes
    Component
  68. def paint(g: Graphics2D): Unit

    Permalink
    Definition Classes
    Component
  69. def paintBorder(g: Graphics2D): Unit

    Permalink
    Attributes
    protected
    Definition Classes
    Component
  70. def paintChildren(g: Graphics2D): Unit

    Permalink
    Attributes
    protected
    Definition Classes
    Component
  71. def paintComponent(g: Graphics2D): Unit

    Permalink
    Attributes
    protected
    Definition Classes
    Component
  72. lazy val peer: JPanel with SuperMixin

    Permalink
    Definition Classes
    BorderPanel → Panel → Wrapper → Component → UIElement
  73. def preferredSize: Dimension

    Permalink
    Definition Classes
    UIElement
  74. def preferredSize_=(x: Dimension): Unit

    Permalink
    Definition Classes
    UIElement
  75. def publish(e: Event): Unit

    Permalink
    Definition Classes
    Publisher
  76. val reactions: Reactions

    Permalink
    Definition Classes
    Reactor
  77. def repaint(rect: Rectangle): Unit

    Permalink
    Definition Classes
    UIElement
  78. def repaint(): Unit

    Permalink
    Definition Classes
    UIElement
  79. def requestFocus(): Unit

    Permalink
    Definition Classes
    Component
  80. def requestFocusInWindow(): Boolean

    Permalink
    Definition Classes
    Component
  81. def restore(savedState: Node): Unit

    Permalink

    Restores the state of the desktop to that described in the given xml node savedState.

    Restores the state of the desktop to that described in the given xml node savedState. It's expected that savedState describes the sizes, positions, and viewers installed in any frames left open on the desktop the last time the debugger was shut down. This method will recreate those windows with the same sizes, positions, and installed viewers.

    Note that any exception encountered while attempting to restore the desktop will immediately abort the remainder of the operation. Any visualizations that were successfully restored prior to the exception will remain, but everything else is simply dropped.

    See cogdebugger.ui.Desktop#save for the expected format of the xml.

    Definition Classes
    DesktopRestorableState
  82. def restoreFrame(frameTag: Node): Unit

    Permalink

    Attempts to restore an individual frame as described in an XML node.

    Attempts to restore an individual frame as described in an XML node.

    The XML node contains the long name of the field that was being visualized. If the field still exists in the current compute graph (it may have been removed or renamed in between debugger sessions), a Viewer implementation is instantiated based on the class name saved in the XML tag. If the Viewer implements cogdebugger.RestorableState, it's handed the visualization subtree/tag of the XML and can attempt to restore its own saved state (see java.awt.Desktop#save for an example of the XML). Lastly, the frame is sized and positioned according to the details saved in the XML.

  83. def revalidate(): Unit

    Permalink
    Definition Classes
    Component
  84. def save: Elem

    Permalink

    Produces an XML element describing the state of the Desktop, with the intent that this tag will be saved to disk and later used during the startup of a subsequent debugger session to arrange any open visualizations just as the user had left them.

    Produces an XML element describing the state of the Desktop, with the intent that this tag will be saved to disk and later used during the startup of a subsequent debugger session to arrange any open visualizations just as the user had left them.

    The desktop itself cannot save much information aside from which fields are being visualized and the sizes and postitions of thier visualizations on the desktop, as the inner details of any given viewer are unknown to the desktop. Thus, individual Viewer implementations must also be able to save to (and restore from) XML details about their internal state if the user's debugger environment is to actually remain consistent across runs. Each Viewer that implements cogdebugger.RestorableState will have its own save function called and its tag nested within Desktop's. The viewer's tag will be used as an argument to its restore method the next time the debugger is launched (for the same app).

    The tag produced by this function appears thusly:

    <Desktop>
      <frame>
        <layout>
          <size width=... height=.../>
          <position x=... y=.../>
        </layout>
        <probes>
          <probe>#Name of field being probed#</probe>
          ...
        </probes>
        <visualization>
          <viewerclass class=.../>
          #Installed viewer's XML tag goes here#
        </visualization>
      </frame>
      ...
    </Desktop>
    Definition Classes
    DesktopRestorableState
  85. def self: Component

    Permalink
    Definition Classes
    UIElement → Proxy
  86. def showing: Boolean

    Permalink
    Definition Classes
    UIElement
  87. def size: Dimension

    Permalink
    Definition Classes
    UIElement
  88. def subscribe(listener: Reaction): Unit

    Permalink
    Definition Classes
    LazyPublisher → Publisher
  89. final def synchronized[T0](arg0: ⇒ T0): T0

    Permalink
    Definition Classes
    AnyRef
  90. lazy val tiler: Tiler

    Permalink
    Definition Classes
    ProbeDesktop
  91. def toString(): String

    Permalink
    Definition Classes
    Component → Proxy → AnyRef → Any
  92. val toolbar: ZoomingToolbar { ... /* 2 definitions in type refinement */ }

    Permalink
    Attributes
    protected
    Definition Classes
    ProbeDesktop
  93. def toolkit: Toolkit

    Permalink
    Definition Classes
    UIElement
  94. def tooltip: String

    Permalink
    Definition Classes
    Component
  95. def tooltip_=(t: String): Unit

    Permalink
    Definition Classes
    Component
  96. def unsubscribe(listener: Reaction): Unit

    Permalink
    Definition Classes
    LazyPublisher → Publisher
  97. def visible: Boolean

    Permalink
    Definition Classes
    UIElement
  98. def visible_=(b: Boolean): Unit

    Permalink
    Definition Classes
    UIElement
  99. final def wait(): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  100. final def wait(arg0: Long, arg1: Int): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  101. final def wait(arg0: Long): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  102. def xLayoutAlignment: Double

    Permalink
    Definition Classes
    Component
  103. def xLayoutAlignment_=(x: Double): Unit

    Permalink
    Definition Classes
    Component
  104. def yLayoutAlignment: Double

    Permalink
    Definition Classes
    Component
  105. def yLayoutAlignment_=(y: Double): Unit

    Permalink
    Definition Classes
    Component

Inherited from RestorableState

Inherited from ProbeDesktop

Inherited from BorderPanel

Inherited from LayoutContainer

Inherited from Panel

Inherited from Wrapper

Inherited from Container

Inherited from Component

Inherited from UIElement

Inherited from LazyPublisher

Inherited from Publisher

Inherited from Reactor

Inherited from Proxy

Inherited from AnyRef

Inherited from Any

Ungrouped