SPT RWT Application API

com.sptci.rwt.webui
Class SaveQueryComponent

java.lang.Object
  extended by nextapp.echo2.app.Component
      extended by nextapp.echo2.app.Grid
          extended by com.sptci.rwt.webui.SaveQueryComponent
All Implemented Interfaces:
com.sptci.echo2.View, Serializable, RenderIdSupport

public class SaveQueryComponent
extends Grid
implements com.sptci.echo2.View

A component that is used to display the components necessary to prompt the user for entering information to save a SQL statement.

© Copyright 2007 Sans Pareil Technologies, Inc.

Version:
$Id: SaveQueryComponent.java 4123 2008-05-25 21:49:01Z rakesh $
Author:
Rakesh Vidyadharan 2007-10-10
See Also:
Serialized Form

Field Summary
private  ComboBox category
          The component used to display available categories.
private  MainController controller
          The controller to use to interact with the rest of the application.
private  TextField name
          The component used to enter the name for the query.
 
Fields inherited from class nextapp.echo2.app.Grid
DEFAULT_SIZE, ORIENTATION_HORIZONTAL, ORIENTATION_VERTICAL, PROPERTY_BORDER, PROPERTY_COLUMN_WIDTH, PROPERTY_HEIGHT, PROPERTY_INSETS, PROPERTY_ORIENTATION, PROPERTY_ROW_HEIGHT, PROPERTY_SIZE, PROPERTY_WIDTH
 
Fields inherited from class nextapp.echo2.app.Component
CHILDREN_CHANGED_PROPERTY, ENABLED_CHANGED_PROPERTY, FOCUS_TRAVERSAL_INDEX_CHANGED_PROPERTY, FOCUS_TRAVERSAL_PARTICIPANT_CHANGED_PROPERTY, LAYOUT_DIRECTION_CHANGED_PROPERTY, LOCALE_CHANGED_PROPERTY, PROPERTY_BACKGROUND, PROPERTY_FONT, PROPERTY_FOREGROUND, PROPERTY_LAYOUT_DATA, STYLE_CHANGED_PROPERTY, STYLE_NAME_CHANGED_PROPERTY, VISIBLE_CHANGED_PROPERTY
 
Constructor Summary
SaveQueryComponent(MainController controller)
          Create a new instance with the specified controller.
 
Method Summary
protected  void createCategory()
          Initialise the category component with data from the Queries data object.
protected  void createName()
          Initialise the name component and its associated Label.
 String getCategory()
          Return the value entered/selected in category field.
 String getName()
          Return the value entered in name field.
 void init()
          Life-cycle method used to initialise the component.
 
Methods inherited from class nextapp.echo2.app.Grid
getBorder, getColumnWidth, getHeight, getInsets, getOrientation, getRowHeight, getSize, getWidth, setBorder, setColumnWidth, setHeight, setInsets, setOrientation, setRowHeight, setSize, setWidth
 
Methods inherited from class nextapp.echo2.app.Component
add, add, addPropertyChangeListener, addPropertyChangeListener, dispose, firePropertyChange, getApplicationInstance, getBackground, getComponent, getComponent, getComponentCount, getComponents, getEventListenerList, getFocusTraversalIndex, getFont, getForeground, getId, getIndexedProperty, getLayoutData, getLayoutDirection, getLocale, getParent, getProperty, getRenderId, getRenderIndexedProperty, getRenderIndexedProperty, getRenderLayoutDirection, getRenderLocale, getRenderProperty, getRenderProperty, getStyle, getStyleName, getVisibleComponent, getVisibleComponentCount, getVisibleComponents, hasEventListenerList, indexOf, isAncestorOf, isEnabled, isFocusTraversalParticipant, isRegistered, isRenderEnabled, isRenderVisible, isValidChild, isValidParent, isVisible, processInput, remove, remove, removeAll, removePropertyChangeListener, removePropertyChangeListener, setBackground, setEnabled, setFocusTraversalIndex, setFocusTraversalParticipant, setFont, setForeground, setId, setIndexedProperty, setLayoutData, setLayoutDirection, setLocale, setProperty, setRenderId, setStyle, setStyleName, setVisible, validate, verifyInput, visibleIndexOf
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

category

private ComboBox category
The component used to display available categories.


name

private TextField name
The component used to enter the name for the query.


controller

private final MainController controller
The controller to use to interact with the rest of the application.

Constructor Detail

SaveQueryComponent

public SaveQueryComponent(MainController controller)
Create a new instance with the specified controller.

Parameters:
controller - The controller to use to interact with the application.
Method Detail

init

public void init()
Life-cycle method used to initialise the component.

Overrides:
init in class Component
See Also:
createCategory(), createName()

createCategory

protected void createCategory()
Initialise the category component with data from the Queries data object.


createName

protected void createName()
Initialise the name component and its associated Label.


getCategory

public String getCategory()
Return the value entered/selected in category field.

Returns:
The value entered/selected or an empty string if no value was selected or entered.

getName

public String getName()
Return the value entered in name field.

Returns:
The value entered or an empty string if no value was entered.

SPT RWT Application API