Java Doc for BasicComponentFactory.java in  » Swing-Library » jgoodies-data-binding » com » jgoodies » binding » adapter » 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 » jgoodies data binding » com.jgoodies.binding.adapter 
Source Cross Reference  Class Diagram Java Document (Java Doc) 


java.lang.Object
   com.jgoodies.binding.adapter.BasicComponentFactory

BasicComponentFactory
public class BasicComponentFactory (Code)
Consists only of static methods that create and vend frequently used Swing components that are then bound to a given ValueModel. This class is one of two helper classes that help you establish a binding: 1) the Bindings class binds components that have been created before; it wraps ValueModels with the adapters from package com.jgoodies.binding.adapter. 2) this BasicComponentFactory creates Swing components that are then tied to ValueModels using the the different #bind methods in the Bindings class.

If you have an existing factory that vends Swing components, you can use Bindings to bind them to ValueModels. If you don't have such a factory, you can use this BasicComponentFactory to create and bind Swing components.

This class is intended to be used or extended by custom ComponentFactory classes. Such a factory can create a broader variety of component types, may use different default configurations, and can use your favorite Formatters, FormatterFactories, etc.
author:
   Karsten Lentzsch
version:
   $Revision: 1.14 $
See Also:   com.jgoodies.binding.value.ValueModel
See Also:   com.jgoodies.binding.adapter.Bindings




Constructor Summary
protected  BasicComponentFactory()
    

Method Summary
public static  JCheckBoxcreateCheckBox(ValueModel valueModel, String text)
     Creates and returns a check box with the specified text label that is bound to the given ValueModel.
public static  JColorChoosercreateColorChooser(ValueModel valueModel)
     Creates and returns a JColorChooser that has the color selection bound to the given ValueModel.
public static  JColorChoosercreateColorChooser(ValueModel valueModel, Color defaultColor)
     Creates and returns a JColorChooser that has the color selection bound to the given ValueModel.
public static  JComboBoxcreateComboBox(SelectionInList<E> selectionInList)
     Creates and returns a non-editable JComboBox that is bound to the given SelectionInList.
public static  JComboBoxcreateComboBox(SelectionInList<E> selectionInList, ListCellRenderer cellRenderer)
     Creates and returns a non-editable JComboBox that is bound to the given SelectionInList using the given cell renderer.
public static  JFormattedTextFieldcreateDateField(ValueModel valueModel)
     Creates and returns a formatted text field that is bound to the Date value of the given ValueModel. The JFormattedTextField is configured with an AbstractFormatter that uses two different DateFormats to edit and display the Date. A SHORT DateFormat with strict checking is used to edit (parse) a date; the DateFormatter's default DateFormat is used to display (format) a date.
public static  JFormattedTextFieldcreateFormattedTextField(ValueModel valueModel, Format format)
     Creates and returns a formatted text field that binds its value to the given model and converts Strings to values using the given Format.
public static  JFormattedTextFieldcreateFormattedTextField(ValueModel valueModel, JFormattedTextField.AbstractFormatter formatter)
     Creates and returns a formatted text field that binds its value to the given model and converts Strings to values using the given Formatter.
public static  JFormattedTextFieldcreateFormattedTextField(ValueModel valueModel, JFormattedTextField.AbstractFormatterFactory formatterFactory)
     Creates and returns a formatted text field that binds its value to the given model and converts Strings to values using Formatters provided by the given AbstractFormatterFactory.
public static  JFormattedTextFieldcreateFormattedTextField(ValueModel valueModel, String mask)
     Creates and returns a formatted text field that binds its value to the given model and converts Strings to values using a MaskFormatter that is based on the given mask.
public static  JFormattedTextFieldcreateIntegerField(ValueModel valueModel)
     Creates and returns a formatted text field that is bound to the Integer value of the given ValueModel.
public static  JFormattedTextFieldcreateIntegerField(ValueModel valueModel, int emptyNumber)
     Creates and returns a formatted text field that is bound to the Integer value of the given ValueModel.
public static  JFormattedTextFieldcreateIntegerField(ValueModel valueModel, NumberFormat numberFormat)
     Creates and returns a formatted text field that is bound to the Integer value of the given ValueModel.
public static  JFormattedTextFieldcreateIntegerField(ValueModel valueModel, NumberFormat numberFormat, int emptyNumber)
     Creates and returns a formatted text field that is bound to the Integer value of the given ValueModel.
public static  JFormattedTextFieldcreateIntegerField(ValueModel valueModel, NumberFormat numberFormat, Integer emptyNumber)
     Creates and returns a formatted text field that is bound to the Integer value of the given ValueModel.
public static  JLabelcreateLabel(ValueModel valueModel)
     Creates and returns a text label that is bound to the given ValueModel.
public static  JLabelcreateLabel(ValueModel valueModel, Format format)
     Creates and returns a text label that is bound to the given ValueModel that is wrapped by a StringConverter.
public static  JListcreateList(SelectionInList<E> selectionInList)
     Creates and returns a JList for the given SelectionInList.

If the selectionInList's selection holder is a ComponentValueModel it is synchronized with the visible and enabled state of the returned list.

public static  JListcreateList(SelectionInList<E> selectionInList, ListCellRenderer cellRenderer)
     Creates and returns a JList for the given SelectionInList using the specified optional ListCellRenderer to render cells.

If the selectionInList's selection holder is a ComponentValueModel it is synchronized with the visible and enabled state of the returned list.

public static  JFormattedTextFieldcreateLongField(ValueModel valueModel)
     Creates and returns a formatted text field that is bound to the Long value of the given ValueModel.
public static  JFormattedTextFieldcreateLongField(ValueModel valueModel, long emptyNumber)
     Creates and returns a formatted text field that is bound to the Long value of the given ValueModel.
public static  JFormattedTextFieldcreateLongField(ValueModel valueModel, NumberFormat numberFormat)
     Creates and returns a formatted text field that is bound to the Long value of the given ValueModel.
public static  JFormattedTextFieldcreateLongField(ValueModel valueModel, NumberFormat numberFormat, long emptyNumber)
     Creates and returns a formatted text field that is bound to the Long value of the given ValueModel.
public static  JFormattedTextFieldcreateLongField(ValueModel valueModel, NumberFormat numberFormat, Long emptyNumber)
     Creates and returns a formatted text field that is bound to the Long value of the given ValueModel.
public static  JPasswordFieldcreatePasswordField(ValueModel valueModel)
     Creates and returns a JPasswordField with the content bound to the given ValueModel.
public static  JPasswordFieldcreatePasswordField(ValueModel valueModel, boolean commitOnFocusLost)
     Creates and returns a JPasswordField with the content bound to the given ValueModel.
public static  JRadioButtoncreateRadioButton(ValueModel model, Object choice, String text)
     Creates and returns a radio button with the specified text label that is bound to the given ValueModel.
public static  JTextAreacreateTextArea(ValueModel valueModel)
     Creates and returns a text area with the content bound to the given ValueModel.
public static  JTextAreacreateTextArea(ValueModel valueModel, boolean commitOnFocusLost)
     Creates and returns a text area with the content bound to the given ValueModel.
public static  JTextFieldcreateTextField(ValueModel valueModel)
     Creates and returns a text field with the content bound to the given ValueModel.
public static  JTextFieldcreateTextField(ValueModel valueModel, boolean commitOnFocusLost)
     Creates and returns a text field with the content bound to the given ValueModel.


Constructor Detail
BasicComponentFactory
protected BasicComponentFactory()(Code)




Method Detail
createCheckBox
public static JCheckBox createCheckBox(ValueModel valueModel, String text)(Code)
Creates and returns a check box with the specified text label that is bound to the given ValueModel. The check box is selected if and only if the model's value equals Boolean.TRUE.

The model is converted to the required ToggleButtonModel using a ToggleButtonAdapter.
Parameters:
  valueModel - the model that provides a Boolean value
Parameters:
  text - the check boxes' text label a check box with the specified text bound to the given model,selected if the model's value equals Boolean.TRUE
throws:
  NullPointerException - if the valueModel is null




createColorChooser
public static JColorChooser createColorChooser(ValueModel valueModel)(Code)
Creates and returns a JColorChooser that has the color selection bound to the given ValueModel. The ValueModel must be of type Color and must allow read-access to its value, and the initial value must not be null.

It is strongly recommended (though not required) that the underlying ValueModel provides only non-null values. This is so because the ColorSelectionModel behavior is undefined for null values and it may have unpredictable results. To avoid these problems, you may create the ColorChooser with a default color using BasicComponentFactory.createColorChooser(ValueModel,Color) .
Parameters:
  valueModel - a Color-typed ValueModel a color chooser with the selected color bound to the given model
throws:
  NullPointerException - if the valueModel is null,or if its initial value is null
See Also:   BasicComponentFactory.createColorChooser(ValueModel,Color)
since:
   1.0.3




createColorChooser
public static JColorChooser createColorChooser(ValueModel valueModel, Color defaultColor)(Code)
Creates and returns a JColorChooser that has the color selection bound to the given ValueModel. The ValueModel must be of type Color and must allow read-access to its value. If the valueModel returns null, the given default color is used instead. This avoids problems with the ColorSelectionModel that may have unpredictable result for null values.
Parameters:
  valueModel - a Color-typed ValueModel
Parameters:
  defaultColor - the color used if the valueModel returns null a color chooser with the selected color bound to the given model
throws:
  NullPointerException - if the valueModel or the default coloris null,
since:
   1.1



createComboBox
public static JComboBox createComboBox(SelectionInList<E> selectionInList)(Code)
Creates and returns a non-editable JComboBox that is bound to the given SelectionInList. The SelectionInList's ListModel is the list data provider and the selection index holder is used for the combo box model's selected item.

If the selectionInList's selection holder is a ComponentValueModel it is synchronized with the visible and enabled state of the returned combo box.

There are a couple of other possibilities to bind a JComboBox. See the constructors and the class comment of the ComboBoxAdapter .
Parameters:
  selectionInList - provides the list and selection<
Parameters:
  E - > the type of the combo box items and the selection a non-editable JComboBox that is bound to the SelectionInList
throws:
  NullPointerException - if the selectionInListis null
See Also:   ComboBoxAdapter
since:
   1.0.1




createComboBox
public static JComboBox createComboBox(SelectionInList<E> selectionInList, ListCellRenderer cellRenderer)(Code)
Creates and returns a non-editable JComboBox that is bound to the given SelectionInList using the given cell renderer. The SelectionInList provides the list data and the selection index holder is used for the combo box model's selected item.

If the selectionInList's selection holder is a ComponentValueModel it is synchronized with the visible and enabled state of the returned combo box.

There are a couple of other possibilities to bind a JComboBox. See the constructors and the class comment of the ComboBoxAdapter .
Parameters:
  selectionInList - provides the list and selection
Parameters:
  cellRenderer - an optional ListCellRenderer,can be null<
Parameters:
  E - > the type of the combo box items and the selection a non-editable JComboBox that is bound to the SelectionInListand uses the given renderer - if non-null
throws:
  NullPointerException - if the selectionInListis null
See Also:   ComboBoxAdapter
since:
   1.0.1




createDateField
public static JFormattedTextField createDateField(ValueModel valueModel)(Code)
Creates and returns a formatted text field that is bound to the Date value of the given ValueModel. The JFormattedTextField is configured with an AbstractFormatter that uses two different DateFormats to edit and display the Date. A SHORT DateFormat with strict checking is used to edit (parse) a date; the DateFormatter's default DateFormat is used to display (format) a date. In both cases null Dates are mapped to the empty String.
Parameters:
  valueModel - the model that holds the value to be edited a formatted text field for Date instances that is boundto the given value model
throws:
  NullPointerException - if the valueModel is null



createFormattedTextField
public static JFormattedTextField createFormattedTextField(ValueModel valueModel, Format format)(Code)
Creates and returns a formatted text field that binds its value to the given model and converts Strings to values using the given Format.
Parameters:
  valueModel - the model that provides the value
Parameters:
  format - the Format used to convert valuesinto a text representation and vice versa via #formatand #parse a formatted text field that is bound to the given value model
throws:
  NullPointerException - if the valueModel is null



createFormattedTextField
public static JFormattedTextField createFormattedTextField(ValueModel valueModel, JFormattedTextField.AbstractFormatter formatter)(Code)
Creates and returns a formatted text field that binds its value to the given model and converts Strings to values using the given Formatter.
Parameters:
  valueModel - the model that provides the value
Parameters:
  formatter - the Formatter used to convert values toa text representation and vice versa via #valueToStringand #stringToValue a formatted text field that is bound to the given value model
throws:
  NullPointerException - if the valueModel is null



createFormattedTextField
public static JFormattedTextField createFormattedTextField(ValueModel valueModel, JFormattedTextField.AbstractFormatterFactory formatterFactory)(Code)
Creates and returns a formatted text field that binds its value to the given model and converts Strings to values using Formatters provided by the given AbstractFormatterFactory.
Parameters:
  valueModel - the model that provides the value
Parameters:
  formatterFactory - provides formatters for different field statesthat in turn are used to convert values to a text representation andvice versa via #valueToStringand #stringToValue a formatted text field that is bound to the given value model
throws:
  NullPointerException - if the valueModel is null



createFormattedTextField
public static JFormattedTextField createFormattedTextField(ValueModel valueModel, String mask)(Code)
Creates and returns a formatted text field that binds its value to the given model and converts Strings to values using a MaskFormatter that is based on the given mask.
Parameters:
  valueModel - the model that provides the value
Parameters:
  mask - the mask pattern used to create an instance ofMaskFormatter that in turn converts values to Stringsand vice versa a bound formatted text field using a MaskFormatter
throws:
  NullPointerException - if the valueModel is null
throws:
  IllegalArgumentException - if the mask is invalid



createIntegerField
public static JFormattedTextField createIntegerField(ValueModel valueModel)(Code)
Creates and returns a formatted text field that is bound to the Integer value of the given ValueModel. Empty strings are converted to null and vice versa.

The Format used to convert numbers to strings and vice versa is NumberFormat.getIntegerInstance().
Parameters:
  valueModel - the model that holds the value to be edited a formatted text field for Integer instances that is boundto the specified valueModel
throws:
  NullPointerException - if the valueModel is null




createIntegerField
public static JFormattedTextField createIntegerField(ValueModel valueModel, int emptyNumber)(Code)
Creates and returns a formatted text field that is bound to the Integer value of the given ValueModel. Empty strings are converted to the specified empty number.

The Format used to convert numbers to strings and vice versa is NumberFormat.getIntegerInstance().
Parameters:
  valueModel - the model that holds the value to be edited
Parameters:
  emptyNumber - an Integer that represents the empty string a formatted text field for Integer instances that is boundto the specified valueModel
throws:
  NullPointerException - if the valueModel is null




createIntegerField
public static JFormattedTextField createIntegerField(ValueModel valueModel, NumberFormat numberFormat)(Code)
Creates and returns a formatted text field that is bound to the Integer value of the given ValueModel. Empty strings are converted to null and vice versa.
Parameters:
  valueModel - the model that holds the value to be edited
Parameters:
  numberFormat - used to convert numbers to strings and vice versa a formatted text field for Integer instances that is boundto the specified valueModel
throws:
  NullPointerException - if the valueModel is null



createIntegerField
public static JFormattedTextField createIntegerField(ValueModel valueModel, NumberFormat numberFormat, int emptyNumber)(Code)
Creates and returns a formatted text field that is bound to the Integer value of the given ValueModel. Empty strings are converted to the specified empty number.
Parameters:
  valueModel - the model that holds the value to be edited
Parameters:
  numberFormat - used to convert numbers to strings and vice versa
Parameters:
  emptyNumber - an Integer that represents the empty string a formatted text field for Integer instances that is boundto the specified valueModel
throws:
  NullPointerException - if the valueModel is null



createIntegerField
public static JFormattedTextField createIntegerField(ValueModel valueModel, NumberFormat numberFormat, Integer emptyNumber)(Code)
Creates and returns a formatted text field that is bound to the Integer value of the given ValueModel. Empty strings are converted to the specified empty number.
Parameters:
  valueModel - the model that holds the value to be edited
Parameters:
  numberFormat - used to convert numbers to strings and vice versa
Parameters:
  emptyNumber - an Integer that represents the empty string a formatted text field for Integer instances that is boundto the specified valueModel
throws:
  NullPointerException - if the valueModel is null



createLabel
public static JLabel createLabel(ValueModel valueModel)(Code)
Creates and returns a text label that is bound to the given ValueModel.
Parameters:
  valueModel - the model that provides the value a text label that is bound to the given value model
throws:
  NullPointerException - if the valueModel is null



createLabel
public static JLabel createLabel(ValueModel valueModel, Format format)(Code)
Creates and returns a text label that is bound to the given ValueModel that is wrapped by a StringConverter. The conversion to Strings uses the specified Format.
Parameters:
  valueModel - the model that provides the value
Parameters:
  format - the format used to create the StringConverter a text label that is bound to the given value model
throws:
  NullPointerException - if the valueModel is null
See Also:   ConverterFactory



createList
public static JList createList(SelectionInList<E> selectionInList)(Code)
Creates and returns a JList for the given SelectionInList.

If the selectionInList's selection holder is a ComponentValueModel it is synchronized with the visible and enabled state of the returned list.
Parameters:
  selectionInList - provides the list and selection<
Parameters:
  E - > the type of the list items and the selection a JList bound to the given SelectionInList
throws:
  NullPointerException - if selectionInList is null




createList
public static JList createList(SelectionInList<E> selectionInList, ListCellRenderer cellRenderer)(Code)
Creates and returns a JList for the given SelectionInList using the specified optional ListCellRenderer to render cells.

If the selectionInList's selection holder is a ComponentValueModel it is synchronized with the visible and enabled state of the returned list.
Parameters:
  selectionInList - provides the list and selection
Parameters:
  cellRenderer - an optional ListCellRenderer,can be null<
Parameters:
  E - > the type of the list items and the selection a JList bound to the given SelectionInList
throws:
  NullPointerException - if selectionInList is null




createLongField
public static JFormattedTextField createLongField(ValueModel valueModel)(Code)
Creates and returns a formatted text field that is bound to the Long value of the given ValueModel. Empty strings are converted to null and vice versa.

The Format used to convert numbers to strings and vice versa is NumberFormat.getIntegerInstance().
Parameters:
  valueModel - the model that holds the value to be edited a formatted text field for Long instances that is bound to thespecified valueModel
throws:
  NullPointerException - if the model is null




createLongField
public static JFormattedTextField createLongField(ValueModel valueModel, long emptyNumber)(Code)
Creates and returns a formatted text field that is bound to the Long value of the given ValueModel. Empty strings are converted to the specified empty number.

The Format used to convert numbers to strings and vice versa is NumberFormat.getIntegerInstance().
Parameters:
  valueModel - the model that holds the value to be edited
Parameters:
  emptyNumber - a Long that represents the empty string a formatted text field for Long instances that is bound to thespecified valueModel
throws:
  NullPointerException - if the model is null




createLongField
public static JFormattedTextField createLongField(ValueModel valueModel, NumberFormat numberFormat)(Code)
Creates and returns a formatted text field that is bound to the Long value of the given ValueModel. Empty strings are converted to null and vice versa.
Parameters:
  valueModel - the model that holds the value to be edited
Parameters:
  numberFormat - used to convert numbers to strings and vice versa a formatted text field for Long instances that is bound to thespecified valueModel
throws:
  NullPointerException - if the model is null



createLongField
public static JFormattedTextField createLongField(ValueModel valueModel, NumberFormat numberFormat, long emptyNumber)(Code)
Creates and returns a formatted text field that is bound to the Long value of the given ValueModel. Empty strings are converted to the specified empty number.
Parameters:
  valueModel - the model that holds the value to be edited
Parameters:
  numberFormat - used to convert numbers to strings and vice versa
Parameters:
  emptyNumber - a Long that represents the empty string a formatted text field for Long instances that is bound to thespecified valueModel
throws:
  NullPointerException - if the model is null



createLongField
public static JFormattedTextField createLongField(ValueModel valueModel, NumberFormat numberFormat, Long emptyNumber)(Code)
Creates and returns a formatted text field that is bound to the Long value of the given ValueModel. Empty strings are converted to the specified empty number.
Parameters:
  valueModel - the model that holds the value to be edited
Parameters:
  numberFormat - used to convert numbers to strings and vice versa
Parameters:
  emptyNumber - a Long that represents the empty string a formatted text field for Long instances that is bound to thespecified valueModel
throws:
  NullPointerException - if the model is null



createPasswordField
public static JPasswordField createPasswordField(ValueModel valueModel)(Code)
Creates and returns a JPasswordField with the content bound to the given ValueModel. Text changes are committed to the model on focus lost.

Security Note: The binding created by this method uses Strings as values of the given ValueModel. The String-typed passwords could potentially be observed in a security fraud. For stronger security it is recommended to request a character array from the JPasswordField and clear the array after use by setting each character to zero. Method JPasswordField.getPassword return's the field's password as a character array.
Parameters:
  valueModel - the model that provides the value a text field that is bound to the given value model
throws:
  NullPointerException - if the valueModel is null
See Also:   BasicComponentFactory.createPasswordField(ValueModel,boolean)
See Also:   JPasswordField.getPassword




createPasswordField
public static JPasswordField createPasswordField(ValueModel valueModel, boolean commitOnFocusLost)(Code)
Creates and returns a JPasswordField with the content bound to the given ValueModel. Text changes can be committed to the model on focus lost or on every character typed.

Security Note: The binding created by this method uses Strings as values of the given ValueModel. The String-typed passwords could potentially be observed in a security fraud. For stronger security it is recommended to request a character array from the JPasswordField and clear the array after use by setting each character to zero. Method JPasswordField.getPassword return's the field's password as a character array.
Parameters:
  valueModel - the model that provides the value
Parameters:
  commitOnFocusLost - true to commit text changes on focus lost,false to commit text changes on every character typed a text field that is bound to the given value model
throws:
  NullPointerException - if the valueModel is null
See Also:   BasicComponentFactory.createPasswordField(ValueModel)
See Also:   JPasswordField.getPassword




createRadioButton
public static JRadioButton createRadioButton(ValueModel model, Object choice, String text)(Code)
Creates and returns a radio button with the specified text label that is bound to the given ValueModel. The radio button is selected if and only if the model's value equals the specified choice.

The model is converted to the required ToggleButton using a RadioButtonAdapter.
Parameters:
  model - the model that provides the current choice
Parameters:
  choice - this button's value
Parameters:
  text - the radio buttons' text label a radio button with the specified text bound to the given model,selected if the model's value equals the specified choice
throws:
  NullPointerException - if the valueModel is null




createTextArea
public static JTextArea createTextArea(ValueModel valueModel)(Code)
Creates and returns a text area with the content bound to the given ValueModel. Text changes are committed to the model on focus lost.
Parameters:
  valueModel - the model that provides the value a text area that is bound to the given value model
throws:
  NullPointerException - if the valueModel is null
See Also:   BasicComponentFactory.createTextArea(ValueModel,boolean)



createTextArea
public static JTextArea createTextArea(ValueModel valueModel, boolean commitOnFocusLost)(Code)
Creates and returns a text area with the content bound to the given ValueModel. Text changes can be committed to the model on focus lost or on every character typed.
Parameters:
  valueModel - the model that provides the text value
Parameters:
  commitOnFocusLost - true to commit text changes on focus lost,false to commit text changes on every character typed a text area that is bound to the given value model
throws:
  NullPointerException - if the valueModel is null
See Also:   BasicComponentFactory.createTextArea(ValueModel)



createTextField
public static JTextField createTextField(ValueModel valueModel)(Code)
Creates and returns a text field with the content bound to the given ValueModel. Text changes are committed to the model on focus lost.
Parameters:
  valueModel - the model that provides the value a text field that is bound to the given value model
throws:
  NullPointerException - if the valueModel is null
See Also:   BasicComponentFactory.createTextField(ValueModel,boolean)



createTextField
public static JTextField createTextField(ValueModel valueModel, boolean commitOnFocusLost)(Code)
Creates and returns a text field with the content bound to the given ValueModel. Text changes can be committed to the model on focus lost or on every character typed.
Parameters:
  valueModel - the model that provides the text value
Parameters:
  commitOnFocusLost - true to commit text changes on focus lost,false to commit text changes on every character typed a text field that is bound to the given value model
throws:
  NullPointerException - if the valueModel is null
See Also:   BasicComponentFactory.createTextField(ValueModel)



Methods inherited from java.lang.Object
native protected Object clone() throws CloneNotSupportedException(Code)(Java Doc)
public boolean equals(Object obj)(Code)(Java Doc)
protected void finalize() throws Throwable(Code)(Java Doc)
final native public Class getClass()(Code)(Java Doc)
native public int hashCode()(Code)(Java Doc)
final native public void notify()(Code)(Java Doc)
final native public void notifyAll()(Code)(Java Doc)
public String toString()(Code)(Java Doc)
final native public void wait(long timeout) throws InterruptedException(Code)(Java Doc)
final public void wait(long timeout, int nanos) throws InterruptedException(Code)(Java Doc)
final public void wait() throws InterruptedException(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.