Class CConnectionEditor

    • Constructor Detail

      • CConnectionEditor

        public CConnectionEditor()
        Connection Editor creating new Connection
    • Method Detail

      • setReadWrite

        public void setReadWrite​(boolean rw)
        Enable Editor
        Specified by:
        setReadWrite in interface CEditor
        Parameters:
        rw - true, if you can enter/select data
      • isReadWrite

        public boolean isReadWrite()
        Is it possible to edit
        Specified by:
        isReadWrite in interface CEditor
        Returns:
        true, if editable
      • setMandatory

        public void setMandatory​(boolean mandatory)
        Set Editor Mandatory
        Specified by:
        setMandatory in interface CEditor
        Parameters:
        mandatory - true, if you have to enter data
      • isMandatory

        public boolean isMandatory()
        Is Field mandatory
        Specified by:
        isMandatory in interface CEditor
        Returns:
        true, if mandatory
      • setBackground

        public void setBackground​(boolean error)
        Set Background based on editable / mandatory / error
        Specified by:
        setBackground in interface CEditor
        Parameters:
        error - if true, set background to error color, otherwise mandatory/editable
      • setBackground

        public void setBackground​(Color color)
        Set Background color
        Overrides:
        setBackground in class JComponent
        Parameters:
        color -
      • setVisible

        public void setVisible​(boolean visible)
        Set Visible
        Specified by:
        setVisible in interface CEditor
        Overrides:
        setVisible in class JComponent
        Parameters:
        visible - true if field is to be shown
      • setValue

        public void setValue​(Object value)
        Set Editor to value
        Specified by:
        setValue in interface CEditor
        Parameters:
        value - value of the editor
      • getValue

        public Object getValue()
        Return Editor value
        Specified by:
        getValue in interface CEditor
        Returns:
        current value
      • getDisplay

        public String getDisplay()
        Return Display Value
        Specified by:
        getDisplay in interface CEditor
        Returns:
        displayed String value
      • setDisplay

        public void setDisplay()
        Update Display with Connection info
      • removeActionListener

        public void removeActionListener​(ActionListener l)
        Remove Action Listener
        Parameters:
        l -
      • addActionListener

        public void addActionListener​(ActionListener l)
        Add Action Listener
        Parameters:
        l -
      • main

        public static void main​(String[] args)
        Test Method
        Parameters:
        args -