easik.ui.datatype
Class DataTypePane

java.lang.Object
  extended by java.awt.Component
      extended by java.awt.Container
          extended by javax.swing.JComponent
              extended by javax.swing.JPanel
                  extended by easik.ui.datatype.DataTypePane
All Implemented Interfaces:
java.awt.image.ImageObserver, java.awt.MenuContainer, java.io.Serializable, javax.accessibility.Accessible

public class DataTypePane
extends javax.swing.JPanel

This class is used for the display of one single data type within the data type controller ui.

Since:
2006-06-21 Kevin Green
Version:
2006-06-28 Kevin Green
Author:
Kevin Green 2006
See Also:
Serialized Form

Nested Class Summary
 
Nested classes/interfaces inherited from class javax.swing.JPanel
javax.swing.JPanel.AccessibleJPanel
 
Nested classes/interfaces inherited from class javax.swing.JComponent
javax.swing.JComponent.AccessibleJComponent
 
Nested classes/interfaces inherited from class java.awt.Container
java.awt.Container.AccessibleAWTContainer
 
Nested classes/interfaces inherited from class java.awt.Component
java.awt.Component.AccessibleAWTComponent, java.awt.Component.BltBufferStrategy, java.awt.Component.FlipBufferStrategy
 
Field Summary
private  javax.swing.JPanel _buttonPane
          The button pane
private  DataTypeController _controller
          The data type controller
private  DataType _dataType
          The data type associated with the pane
private  javax.swing.JTextField _dataTypeDescBox
          The data type description text box
private  javax.swing.JTextField _dataTypeNameBox
          The data type name text box
private  DatatypesUI _dataTypesUI
          The data type user interface
private  PlatformTypePane _DB2Pane
          The DB2 platform pane
private  javax.swing.JButton _editButton
          The edit button
private  boolean _isEditable
          True if the data type is editable, false otherwise
private  PlatformTypePane _MySQLPane
          The MySQL platform pane
private  PlatformTypePane _OraclePane
          The Oracle platform pane
private  javax.swing.JButton _removeButton
          The remove button
private  javax.swing.JPanel _typeInfoPane
          The data type information pane
private  javax.swing.JPanel _typesPane
          The types pane
private  javax.swing.JTextField _userDefinedBox
          The User Defined platform text box
private  javax.swing.JPanel _UserDefinedPane
          The User Defined platform pane
private  PlatformTypePane _XMLPane
          The XML platform pane
 
Fields inherited from class javax.swing.JComponent
accessibleContext, listenerList, TOOL_TIP_TEXT_KEY, ui, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOW
 
Fields inherited from class java.awt.Component
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT
 
Fields inherited from interface java.awt.image.ImageObserver
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH
 
Constructor Summary
DataTypePane(DataType inType, DataTypeController inCont, DatatypesUI inUI)
          Default Constructor.
 
Method Summary
 boolean isEditable()
           
 void makeButtonPane()
          Makes the button pane
 void makePane()
          Makes the main pane
 void makeTypeInfoPane()
          Makes the data type information pane
 void makeUserDefinedPane()
          Makes the user defined data type pane
 void removeDataType()
          Removes the data type associated with this pane from the data type controller and this pane from the window.
 boolean saveErrorCheck()
          Error checks before the save operation.
private  void saveValues()
          Saves the values from the GUI back into the data type
 void setEditability(boolean inVal)
          Sets if the data type is editable or disabled from changes
 void setTypeVisibility()
          Sets only the types that active to visible.
 
Methods inherited from class javax.swing.JPanel
getAccessibleContext, getUI, getUIClassID, paramString, setUI, updateUI
 
Methods inherited from class javax.swing.JComponent
addAncestorListener, addNotify, addVetoableChangeListener, computeVisibleRect, contains, createToolTip, disable, enable, firePropertyChange, firePropertyChange, firePropertyChange, fireVetoableChange, getActionForKeyStroke, getActionMap, getAlignmentX, getAlignmentY, getAncestorListeners, getAutoscrolls, getBorder, getBounds, getClientProperty, getComponentGraphics, getComponentPopupMenu, getConditionForKeyStroke, getDebugGraphicsOptions, getDefaultLocale, getFontMetrics, getGraphics, getHeight, getInheritsPopupMenu, getInputMap, getInputMap, getInputVerifier, getInsets, getInsets, getListeners, getLocation, getMaximumSize, getMinimumSize, getNextFocusableComponent, getPopupLocation, getPreferredSize, getRegisteredKeyStrokes, getRootPane, getSize, getToolTipLocation, getToolTipText, getToolTipText, getTopLevelAncestor, getTransferHandler, getVerifyInputWhenFocusTarget, getVetoableChangeListeners, getVisibleRect, getWidth, getX, getY, grabFocus, isDoubleBuffered, isLightweightComponent, isManagingFocus, isOpaque, isOptimizedDrawingEnabled, isPaintingTile, isRequestFocusEnabled, isValidateRoot, paint, paintBorder, paintChildren, paintComponent, paintImmediately, paintImmediately, print, printAll, printBorder, printChildren, printComponent, processComponentKeyEvent, processKeyBinding, processKeyEvent, processMouseEvent, processMouseMotionEvent, putClientProperty, registerKeyboardAction, registerKeyboardAction, removeAncestorListener, removeNotify, removeVetoableChangeListener, repaint, repaint, requestDefaultFocus, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, resetKeyboardActions, reshape, revalidate, scrollRectToVisible, setActionMap, setAlignmentX, setAlignmentY, setAutoscrolls, setBackground, setBorder, setComponentPopupMenu, setDebugGraphicsOptions, setDefaultLocale, setDoubleBuffered, setEnabled, setFocusTraversalKeys, setFont, setForeground, setInheritsPopupMenu, setInputMap, setInputVerifier, setMaximumSize, setMinimumSize, setNextFocusableComponent, setOpaque, setPreferredSize, setRequestFocusEnabled, setToolTipText, setTransferHandler, setUI, setVerifyInputWhenFocusTarget, setVisible, unregisterKeyboardAction, update
 
Methods inherited from class java.awt.Container
add, add, add, add, add, addContainerListener, addImpl, addPropertyChangeListener, addPropertyChangeListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getComponentZOrder, getContainerListeners, getFocusTraversalKeys, getFocusTraversalPolicy, getLayout, getMousePosition, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusCycleRoot, isFocusTraversalPolicyProvider, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, preferredSize, printComponents, processContainerEvent, processEvent, remove, remove, removeAll, removeContainerListener, setComponentZOrder, setFocusCycleRoot, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, setLayout, transferFocusBackward, transferFocusDownCycle, validate, validateTree
 
Methods inherited from class java.awt.Component
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, coalesceEvents, contains, createImage, createImage, createVolatileImage, createVolatileImage, disableEvents, dispatchEvent, enable, enableEvents, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getBackground, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusCycleRootAncestor, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getForeground, getGraphicsConfiguration, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputContext, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocale, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMousePosition, getMouseWheelListeners, getName, getParent, getPeer, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getToolkit, getTreeLock, gotFocus, handleEvent, hasFocus, hide, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isMaximumSizeSet, isMinimumSizeSet, isPreferredSizeSet, isShowing, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, postEvent, prepareImage, prepareImage, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processMouseWheelEvent, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, resize, resize, setBounds, setBounds, setComponentOrientation, setCursor, setDropTarget, setFocusable, setFocusTraversalKeysEnabled, setIgnoreRepaint, setLocale, setLocation, setLocation, setName, setSize, setSize, show, show, size, toString, transferFocus, transferFocusUpCycle
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

_dataType

private DataType _dataType
The data type associated with the pane


_controller

private DataTypeController _controller
The data type controller


_dataTypesUI

private DatatypesUI _dataTypesUI
The data type user interface


_removeButton

private javax.swing.JButton _removeButton
The remove button


_editButton

private javax.swing.JButton _editButton
The edit button


_buttonPane

private javax.swing.JPanel _buttonPane
The button pane


_typesPane

private javax.swing.JPanel _typesPane
The types pane


_typeInfoPane

private javax.swing.JPanel _typeInfoPane
The data type information pane


_UserDefinedPane

private javax.swing.JPanel _UserDefinedPane
The User Defined platform pane


_MySQLPane

private PlatformTypePane _MySQLPane
The MySQL platform pane


_OraclePane

private PlatformTypePane _OraclePane
The Oracle platform pane


_DB2Pane

private PlatformTypePane _DB2Pane
The DB2 platform pane


_XMLPane

private PlatformTypePane _XMLPane
The XML platform pane


_dataTypeNameBox

private javax.swing.JTextField _dataTypeNameBox
The data type name text box


_dataTypeDescBox

private javax.swing.JTextField _dataTypeDescBox
The data type description text box


_userDefinedBox

private javax.swing.JTextField _userDefinedBox
The User Defined platform text box


_isEditable

private boolean _isEditable
True if the data type is editable, false otherwise

Constructor Detail

DataTypePane

public DataTypePane(DataType inType,
                    DataTypeController inCont,
                    DatatypesUI inUI)
Default Constructor. Makes the GUI components and sets it to be uneditiable by default.

Parameters:
inType - The data type associated with the pane
inCont - The data type controller for the sketch
inUI - The parent GUI that this pane is displayed in
Method Detail

makePane

public void makePane()
Makes the main pane


makeButtonPane

public void makeButtonPane()
Makes the button pane


makeTypeInfoPane

public void makeTypeInfoPane()
Makes the data type information pane


makeUserDefinedPane

public void makeUserDefinedPane()
Makes the user defined data type pane


setTypeVisibility

public void setTypeVisibility()
Sets only the types that active to visible.


removeDataType

public void removeDataType()
Removes the data type associated with this pane from the data type controller and this pane from the window.


setEditability

public void setEditability(boolean inVal)
Sets if the data type is editable or disabled from changes

Parameters:
inVal - True is editable, false if disabled from changes.

saveErrorCheck

public boolean saveErrorCheck()
Error checks before the save operation.

Returns:
True if there are no errors, false if there are errors.

saveValues

private void saveValues()
Saves the values from the GUI back into the data type


isEditable

public boolean isEditable()
Returns:
Returns the _isEditable.