Class SerializedObjectPanel

    • Field Detail

      • PREFIX_PREFERRED_VIEWER

        public static final String PREFIX_PREFERRED_VIEWER
        the prefix for the preferred viewer keys in the props file.
        See Also:
        Constant Field Values
      • m_Properties

        protected static Properties m_Properties
        the properties.
      • m_PanelView

        protected JPanel m_PanelView
        panel for the actual view.
      • m_PanelCombobox

        protected JPanel m_PanelCombobox
        the panel for the combobox with available viewers.
      • m_ComboBoxViewers

        protected BaseComboBox m_ComboBoxViewers
        the combobox with the viewers.
      • m_Current

        protected Object m_Current
        the currently displayed object.
    • Constructor Detail

      • SerializedObjectPanel

        public SerializedObjectPanel()
    • Method Detail

      • initialize

        protected void initialize()
        Initializes the members.
        Overrides:
        initialize in class BasePanel
      • initGUI

        protected void initGUI()
        Initializes the widgets.
        Overrides:
        initGUI in class BasePanel
      • setCurrent

        public void setCurrent​(Object value)
        Sets the object to display.
        Parameters:
        value - the object
      • getCurrent

        public Object getCurrent()
        Returns the currently displayed object.
        Returns:
        the current object, null if none set
      • update

        protected void update()
        Updates the view and available viewers.
      • updateView

        protected void updateView​(SerializedObjectViewer viewer)
        Updates the view.
        Parameters:
        viewer - the viewer to create the view
      • getViewers

        protected static SerializedObjectViewer[] getViewers()
        Returns all available viewers.
        Returns:
        the viewers
      • getPreferredViewer

        protected SerializedObjectViewer getPreferredViewer​(Class cls)
        Returns the preferred viewer.
        Parameters:
        cls - the class to get the preferred viewer for
        Returns:
        the preferred viewer
      • updatePreferredViewer

        protected void updatePreferredViewer​(Class cls,
                                             BaseComboBox combobox)
        Updates the preferred viewer.
        Parameters:
        cls - the class of the current object
        combobox - the current state of viewers
      • getProperties

        public static Properties getProperties()
        Returns the properties that define the editor.
        Returns:
        the properties