Java Doc for GridComponent.java in  » Swing-Library » abeille-forms-designer » com » jeta » forms » gui » form » Java Source Code / Java DocumentationJava Source Code and Java Documentation

Java Source Code / Java Documentation
1. 6.0 JDK Core
2. 6.0 JDK Modules
3. 6.0 JDK Modules com.sun
4. 6.0 JDK Modules com.sun.java
5. 6.0 JDK Modules sun
6. 6.0 JDK Platform
7. Ajax
8. Apache Harmony Java SE
9. Aspect oriented
10. Authentication Authorization
11. Blogger System
12. Build
13. Byte Code
14. Cache
15. Chart
16. Chat
17. Code Analyzer
18. Collaboration
19. Content Management System
20. Database Client
21. Database DBMS
22. Database JDBC Connection Pool
23. Database ORM
24. Development
25. EJB Server geronimo
26. EJB Server GlassFish
27. EJB Server JBoss 4.2.1
28. EJB Server resin 3.1.5
29. ERP CRM Financial
30. ESB
31. Forum
32. GIS
33. Graphic Library
34. Groupware
35. HTML Parser
36. IDE
37. IDE Eclipse
38. IDE Netbeans
39. Installer
40. Internationalization Localization
41. Inversion of Control
42. Issue Tracking
43. J2EE
44. JBoss
45. JMS
46. JMX
47. Library
48. Mail Clients
49. Net
50. Parser
51. PDF
52. Portal
53. Profiler
54. Project Management
55. Report
56. RSS RDF
57. Rule Engine
58. Science
59. Scripting
60. Search Engine
61. Security
62. Sevlet Container
63. Source Control
64. Swing Library
65. Template Engine
66. Test Coverage
67. Testing
68. UML
69. Web Crawler
70. Web Framework
71. Web Mail
72. Web Server
73. Web Services
74. Web Services apache cxf 2.0.1
75. Web Services AXIS2
76. Wiki Engine
77. Workflow Engines
78. XML
79. XML UI
Java
Java Tutorial
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
Photoshop Tutorials
Maya Tutorials
Flash Tutorials
3ds-Max Tutorials
Illustrator Tutorials
GIMP Tutorials
C# / C Sharp
C# / CSharp Tutorial
C# / CSharp Open Source
ASP.Net
ASP.NET Tutorial
JavaScript DHTML
JavaScript Tutorial
JavaScript Reference
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
Ruby
PHP
Python
Python Tutorial
Python Open Source
SQL Server / T-SQL
SQL Server / T-SQL Tutorial
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net
VB.Net Tutorial
Flash / Flex / ActionScript
VBA / Excel / Access / Word
XML
XML Tutorial
Microsoft Office PowerPoint 2007 Tutorial
Microsoft Office Excel 2007 Tutorial
Microsoft Office Word 2007 Tutorial
Java Source Code / Java Documentation » Swing Library » abeille forms designer » com.jeta.forms.gui.form 
Source Cross Reference  Class Diagram Java Document (Java Doc) 


javax.swing.JPanel
   com.jeta.forms.gui.form.GridComponent

All known Subclasses:   com.jeta.forms.gui.form.StandardComponent,  com.jeta.swingbuilder.gui.formmgr.FormSurrogate,  com.jeta.forms.gui.form.FormComponent,
GridComponent
abstract public class GridComponent extends JPanel (Code)
This class is used to contain a JETABean in a cell on a form. It maintains information about its cell such as row/column location as well as other cell constraints. A GridComponent also defines methods (using memento pattern) for serializing itself to and from a persistent store. We don't use the standard Java serialization because the Sun does not guarantee compatibility with future versions of Java, and we need more fine-grained control of the serialization process. A GridComponent maintains a reference to keyboard and mouse handlers needed during design mode. Different GridComonent types will have different types of handlers.
author:
   Jeff Tassin


Field Summary
final static  intEMPTY_CELL_HEIGHT
    
final static  intEMPTY_CELL_WIDTH
    

Constructor Summary
public  GridComponent()
     Creates an uninitialized GridComponent instance.
public  GridComponent(GridView parentView)
     Creates a GridComponent instance with the specified GridView parent.
public  GridComponent(JETABean jbean, GridView parent)
     Creates a GridComponent instance with the specified GridView parent and JETABean.
Parameters:
  jbean - the underyling JETABean.

Method Summary
public  voidaddListener(GridCellListener listener)
     Adds a listener that is interested in GridCellEvents from this component.
public  voidfireGridCellEvent(GridCellEvent evt)
     Notifies all GridCellListeners with the specified event.
public  JETABeangetBean()
     Returns the underlying JETABean.
 ComponentgetBeanChildComponent()
     Returns the component that is directly contained by the JETABean. Normally, this would be the Java bean.
public  ComponentgetBeanDelegate()
     Returns the actual Java Bean that is on the form.
public  StringgetBeanName()
     Returns the name property of the underlying Java bean.
public  intgetCellHeight()
    
public  intgetCellWidth()
    
public  intgetCellX()
     Returns the left origin (in parent coordinates) of the fist cell occupied by this component.
public  intgetCellY()
     Returns the top origin (in parent coordinates) of the fist cell occupied by this component.
public  intgetColumn()
     Returns the column that contains this component.
public  intgetColumnSpan()
     Returns the number of columns occupied by this component.
public  ComponentConstraintsgetConstraints()
     Returns the component constraints for this component.
public  StringgetId()
     Returns the id of this component.
public  CellKeyboardHandlergetKeyboardHandler()
     Returns the keyboard handler associated with this component.
public  DimensiongetMinimumSize()
     the minimum size for this component.
public  CellMouseHandlergetMouseHandler()
     Returns the mouse handler for this component.
public  GridViewgetParentView()
     Returns the GridView that contains this component.
public  DimensiongetPreferredSize()
     Returns the preferred size for this component.
public  intgetRow()
     Returns the row that contains this component.
public  intgetRowSpan()
     Returns the number of rows occupied by this component.
abstract public  ComponentMementogetState(StateRequest si)
     Returns the internal state of this component as a memento.
public  booleanhasBean()
     Returns true if this component contains a java bean.
public  booleanisSelected()
     Returns true if this component is currently selected.
public  booleanisShowing()
     Returns true if this component has a nonzero width and height.
public  voidpostInitialize(FormPanel panel)
     PostInitialize is called once after all components in a form have been re-instantiated and the state has been set at runtime (not design time).
abstract public  voidprint()
    
public  voidremoveListener(GridCellListener listener)
     Removes the previously registered grid cell listener.
protected  voidsetBean(JETABean jbean)
     Sets the JETABean associated with this component.
public  voidsetKeyboardHandler(CellKeyboardHandler handler)
     Sets the keyboard handler associated with this component.
public  voidsetMouseHandler(CellMouseHandler handler)
    
public  voidsetName(String name)
     This should never be called.
public  voidsetParentView(GridView view)
     Sets the GridView that contains this component.
public  voidsetSelected(boolean sel)
     Sets the selected flag for this component.
abstract public  voidsetState(ComponentMemento memento)
    

Field Detail
EMPTY_CELL_HEIGHT
final static int EMPTY_CELL_HEIGHT(Code)



EMPTY_CELL_WIDTH
final static int EMPTY_CELL_WIDTH(Code)
Empty cell dimension




Constructor Detail
GridComponent
public GridComponent()(Code)
Creates an uninitialized GridComponent instance.



GridComponent
public GridComponent(GridView parentView)(Code)
Creates a GridComponent instance with the specified GridView parent.
Parameters:
  parentView - the GridView that contains this component.



GridComponent
public GridComponent(JETABean jbean, GridView parent)(Code)
Creates a GridComponent instance with the specified GridView parent and JETABean.
Parameters:
  jbean - the underyling JETABean. This object contains the Java Bean.
Parameters:
  parent - the GridView that contains this component.




Method Detail
addListener
public void addListener(GridCellListener listener)(Code)
Adds a listener that is interested in GridCellEvents from this component. This is only needed in design mode.
Parameters:
  listener - the listener to add



fireGridCellEvent
public void fireGridCellEvent(GridCellEvent evt)(Code)
Notifies all GridCellListeners with the specified event. This is only used in design mode.
Parameters:
  evt - the event to send to all registered listeners



getBean
public JETABean getBean()(Code)
Returns the underlying JETABean. The JETABean is a container for the actual Java Bean. the JETABean component.



getBeanChildComponent
Component getBeanChildComponent()(Code)
Returns the component that is directly contained by the JETABean. Normally, this would be the Java bean. However, in a few cases, the JETABean does not directly contain the Java Bean. Scrollpanes are an example of this. the JETABean child component.



getBeanDelegate
public Component getBeanDelegate()(Code)
Returns the actual Java Bean that is on the form. the Java Bean that is contained by the JETABean.



getBeanName
public String getBeanName()(Code)
Returns the name property of the underlying Java bean. the name of the bean component



getCellHeight
public int getCellHeight()(Code)
Returns the total height in pixels of the cells occupied by this component



getCellWidth
public int getCellWidth()(Code)
Returns the total width in pixels of the cells occupied by this component



getCellX
public int getCellX()(Code)
Returns the left origin (in parent coordinates) of the fist cell occupied by this component. the left location of this cell in the parent coordinates.



getCellY
public int getCellY()(Code)
Returns the top origin (in parent coordinates) of the fist cell occupied by this component. the top location of this cell in the parent coordinates.



getColumn
public int getColumn()(Code)
Returns the column that contains this component.



getColumnSpan
public int getColumnSpan()(Code)
Returns the number of columns occupied by this component. This is normally 1 unless the column span was changed in the designer.



getConstraints
public ComponentConstraints getConstraints()(Code)
Returns the component constraints for this component. Component constraints include the column, row, column span, and row span assignments. They also include any alignment and inset values for this component. the component constraints associated with this component.



getId
public String getId()(Code)
Returns the id of this component. This is only valid for form components. the id of this component.



getKeyboardHandler
public CellKeyboardHandler getKeyboardHandler()(Code)
Returns the keyboard handler associated with this component. Handlers are set only during design mode.



getMinimumSize
public Dimension getMinimumSize()(Code)
the minimum size for this component. When in design mode, we setthe min size to something like 4x4 to prevent the grid cells inthe GridView from being too small.



getMouseHandler
public CellMouseHandler getMouseHandler()(Code)
Returns the mouse handler for this component. This is only set and used by the designer.



getParentView
public GridView getParentView()(Code)
Returns the GridView that contains this component. This is not the same as this component's immediate parent. the view that contains this component



getPreferredSize
public Dimension getPreferredSize()(Code)
Returns the preferred size for this component. When in design mode, we set the preferred size to some non-zero value to prevent the grid cells in the GridView from being too small. the preferred size for this component.



getRow
public int getRow()(Code)
Returns the row that contains this component.



getRowSpan
public int getRowSpan()(Code)
Returns the number of rows occupied by this component. This is normally 1 unless the row span was changed in the designer.



getState
abstract public ComponentMemento getState(StateRequest si) throws FormException(Code)
Returns the internal state of this component as a memento. This includes the cell constraints as well as the properties for the underlying Java bean.
Parameters:
  si - a request object that controls how much information should bestored in the memento.



hasBean
public boolean hasBean()(Code)
Returns true if this component contains a java bean. In design mode empty cells on the form will not contain a bean but will contain a valid GridComponent true if this component contains java bean



isSelected
public boolean isSelected()(Code)
Returns true if this component is currently selected. This is used only in design mode.



isShowing
public boolean isShowing()(Code)
Returns true if this component has a nonzero width and height. This can occur in some cases in the designer. If we have non visible component, we show an icon so the user has some indication that it exists. true if this component is large enough to be visible



postInitialize
public void postInitialize(FormPanel panel)(Code)
PostInitialize is called once after all components in a form have been re-instantiated and the state has been set at runtime (not design time). This gives each property and component a chance to do some last minute initializations that might depend on the top level parent.



print
abstract public void print()(Code)
Print for debugging



removeListener
public void removeListener(GridCellListener listener)(Code)
Removes the previously registered grid cell listener.



setBean
protected void setBean(JETABean jbean)(Code)
Sets the JETABean associated with this component.



setKeyboardHandler
public void setKeyboardHandler(CellKeyboardHandler handler)(Code)
Sets the keyboard handler associated with this component. Handlers are set only during design mode.



setMouseHandler
public void setMouseHandler(CellMouseHandler handler)(Code)
Sets the mouse handler for this component



setName
public void setName(String name)(Code)
This should never be called. Overridden here so we can assert when debugging.



setParentView
public void setParentView(GridView view)(Code)
Sets the GridView that contains this component. This is not the same as the immediate parent of this component. the view that contains this component



setSelected
public void setSelected(boolean sel)(Code)
Sets the selected flag for this component.



setState
abstract public void setState(ComponentMemento memento) throws FormException(Code)
Sets the state of this component from a previously stored state
Parameters:
  memento - the state information to set.



Methods inherited from javax.swing.JPanel
public AccessibleContext getAccessibleContext()(Code)(Java Doc)
public PanelUI getUI()(Code)(Java Doc)
public String getUIClassID()(Code)(Java Doc)
protected String paramString()(Code)(Java Doc)
public void setUI(PanelUI ui)(Code)(Java Doc)
public void updateUI()(Code)(Java Doc)

www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.