Java Doc for OrderableList.java in  » IDE-Netbeans » visualweb.api.designer » com » sun » rave » web » ui » component » 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 » IDE Netbeans » visualweb.api.designer » com.sun.rave.web.ui.component 
Source Cross Reference  Class Diagram Java Document (Java Doc) 


com.sun.rave.web.ui.component.OrderableListBase
   com.sun.rave.web.ui.component.OrderableList

OrderableList
public class OrderableList extends OrderableListBase implements ListManager(Code)

About this tag.

This tag renders an OrderableList component. Use this component when web application users need to create and modify a list of strings. The application user can add new strings by typing them into the textfield and clicking the "moveUp" button, and remove them by selecting one or more items from the list and clicking the "Remove" button.

Configuring the listbox tag

Use the list attribute to bind the component to a model. The value must be an EL expression that corresponds to a managed bean or a property of a managed bean, and it must evaluate to an array of java.lang.String.

To set the label of the textfield, use the fieldLabel attribute. To set the label of the textfield, use the listLabel attribute. To validate new items, use the fieldValidator attribute; to validate the contents of the list once the user has finished adding and removing items, specify a labelValidator.

Facets

  • fieldLabel: use this facet to specify a custom component for the textfield label.
  • listLabel: use this facet to specify a custom component for the textfield label.
  • field: use this facet to specify a custom component for the textfield.
  • moveUpButton: use this facet to specify a custom component for the moveUp button.
  • removeButton: use this facet to specify a custom component for the remove button.
  • search: use this facet to specify a custom component for the search button.
  • readOnly: use this facet to specify a custom component for display a readonly version of the component.
  • header: use this facet to specify a header, rendered in a table row above the component.
  • footer: use this facet to specify a header, rendered in a table row below the component.

Client-side JavaScript functions

  • NONE yet

author:
   avk


Field Summary
final public static  StringFOOTER_FACET
     The name for the footer facet.
final public static  StringJAVASCRIPT_PREFIX
     Represents the "javascript:" printed at the start of javascript event handler code.
final public static  StringJSOBJECT
     The name of the component attribute that stores the name of the JavaScript object that organizes the JavsSCript functions for the component.
final public static  StringLABEL_FACET
     The facet name for the label.
final public static  StringLABEL_ID
     The component ID for the label.
final public static  StringMOVEBOTTOM_BUTTON_FACET
     The facet name for the moveBottom button.
final public static  StringMOVEBOTTOM_BUTTON_ID
     The component id for the moveBottom button.
final public static  StringMOVEBOTTOM_FUNCTION
     Name of the JavaScript function which moves elements to the bottom.
final public static  StringMOVEDOWN_BUTTON_FACET
     The facet name for the moveDown button.
final public static  StringMOVEDOWN_BUTTON_ID
     The component id for the moveDown button.
final public static  StringMOVEDOWN_FUNCTION
     Name of the JavaScript function which moves elements down.
final public static  StringMOVETOP_BUTTON_FACET
     The facet name for the moveTop button.
final public static  StringMOVETOP_BUTTON_ID
     The component id for the moveTop button.
final public static  StringMOVETOP_FUNCTION
     Name of the JavaScript function which moves elements to the top.
final public static  StringMOVEUP_BUTTON_FACET
     The facet name for the moveUp button.
final public static  StringMOVEUP_BUTTON_ID
     The component id for the moveUp button.
final public static  StringMOVEUP_FUNCTION
     Name of the JavaScript function which moves elements up.
final public static  StringONCHANGE_FUNCTION
     Name of the JavaScript function that handles changes on the available list.
final public static  StringREAD_ONLY_FACET
     The facet name for the readOnly text field.
final public static  StringREAD_ONLY_ID
     The component ID for the read only text field.
final public static  StringREMOVE_BUTTON_FACET
     The facet name for the remove button.
final public static  StringREMOVE_BUTTON_ID
     The component ID for the remove button.
final public static  StringRETURN
     String representing "return false" printed at the end of the javascript event handlers.
final public static  StringUPDATEBUTTONS_FUNCTION
     Name of the JavaScript function that updates the buttons.

Constructor Summary
public  OrderableList()
    

Method Summary
protected  booleancompareValues(Object previous, Object value)
    

Return true if the new value is different from the previous value.

This only implements a compareValues for value if it is an Array.
protected  ListItemcreateListItem(UIComponent comp, Object value)
     Enforce non null values.
public  ObjectgetConvertedValue(FacesContext context, Object submittedValue)
     Retrieve the value of this component (the "selected" property) as an object.
public  UIComponentgetHeaderComponent()
     Gets or creates a component for the list label.
public  IteratorgetListItems(FacesContext context, boolean ruler)
     Retrieve an Iterator of ListSelector.ListItem, to be used by the renderer.
public  UIComponentgetMoveBottomButtonComponent(FacesContext context)
     Get or create the MOVEBOTTOM button.
public  UIComponentgetMoveDownButtonComponent(FacesContext context)
     Get or create the MOVEDOWN button.
public  UIComponentgetMoveTopButtonComponent(FacesContext context)
     Get or create the MOVETOP button.
public  UIComponentgetMoveUpButtonComponent(FacesContext context)
     Get or create the MOVE UP button.
public  StringgetOnChange()
    
public  StringgetPrimaryElementID(FacesContext context)
    
public  UIComponentgetReadOnlyValueComponent()
     Creates a component for the OrderableList in case the component is read-only.
public  intgetRows()
    
protected  StringgetValueAsReadOnly(FacesContext context)
     Return a string suitable for displaying the value in read only mode.
public  String[]getValueAsStringArray(FacesContext context)
    
public  booleanmainListSubmits()
    

Field Detail
FOOTER_FACET
final public static String FOOTER_FACET(Code)
The name for the footer facet.



JAVASCRIPT_PREFIX
final public static String JAVASCRIPT_PREFIX(Code)
Represents the "javascript:" printed at the start of javascript event handler code.



JSOBJECT
final public static String JSOBJECT(Code)
The name of the component attribute that stores the name of the JavaScript object that organizes the JavsSCript functions for the component.



LABEL_FACET
final public static String LABEL_FACET(Code)
The facet name for the label.



LABEL_ID
final public static String LABEL_ID(Code)
The component ID for the label.



MOVEBOTTOM_BUTTON_FACET
final public static String MOVEBOTTOM_BUTTON_FACET(Code)
The facet name for the moveBottom button.



MOVEBOTTOM_BUTTON_ID
final public static String MOVEBOTTOM_BUTTON_ID(Code)
The component id for the moveBottom button.



MOVEBOTTOM_FUNCTION
final public static String MOVEBOTTOM_FUNCTION(Code)
Name of the JavaScript function which moves elements to the bottom.



MOVEDOWN_BUTTON_FACET
final public static String MOVEDOWN_BUTTON_FACET(Code)
The facet name for the moveDown button.



MOVEDOWN_BUTTON_ID
final public static String MOVEDOWN_BUTTON_ID(Code)
The component id for the moveDown button.



MOVEDOWN_FUNCTION
final public static String MOVEDOWN_FUNCTION(Code)
Name of the JavaScript function which moves elements down.



MOVETOP_BUTTON_FACET
final public static String MOVETOP_BUTTON_FACET(Code)
The facet name for the moveTop button.



MOVETOP_BUTTON_ID
final public static String MOVETOP_BUTTON_ID(Code)
The component id for the moveTop button.



MOVETOP_FUNCTION
final public static String MOVETOP_FUNCTION(Code)
Name of the JavaScript function which moves elements to the top.



MOVEUP_BUTTON_FACET
final public static String MOVEUP_BUTTON_FACET(Code)
The facet name for the moveUp button.



MOVEUP_BUTTON_ID
final public static String MOVEUP_BUTTON_ID(Code)
The component id for the moveUp button.



MOVEUP_FUNCTION
final public static String MOVEUP_FUNCTION(Code)
Name of the JavaScript function which moves elements up.



ONCHANGE_FUNCTION
final public static String ONCHANGE_FUNCTION(Code)
Name of the JavaScript function that handles changes on the available list.



READ_ONLY_FACET
final public static String READ_ONLY_FACET(Code)
The facet name for the readOnly text field.



READ_ONLY_ID
final public static String READ_ONLY_ID(Code)
The component ID for the read only text field.



REMOVE_BUTTON_FACET
final public static String REMOVE_BUTTON_FACET(Code)
The facet name for the remove button.



REMOVE_BUTTON_ID
final public static String REMOVE_BUTTON_ID(Code)
The component ID for the remove button.



RETURN
final public static String RETURN(Code)
String representing "return false" printed at the end of the javascript event handlers.



UPDATEBUTTONS_FUNCTION
final public static String UPDATEBUTTONS_FUNCTION(Code)
Name of the JavaScript function that updates the buttons.




Constructor Detail
OrderableList
public OrderableList()(Code)




Method Detail
compareValues
protected boolean compareValues(Object previous, Object value)(Code)

Return true if the new value is different from the previous value.

This only implements a compareValues for value if it is an Array. If value is not an Array, defer to super.compareValues. The assumption is that the ordering of the elements between the previous value and the new value is determined in the same manner. Another assumption is that the two object arguments are of the same type, both arrays of both not arrays.
Parameters:
  previous - old value of this component (if any)
Parameters:
  value - new value of this component (if any)



createListItem
protected ListItem createListItem(UIComponent comp, Object value)(Code)
Enforce non null values. This is ok, since Converter returns null on null input. And secondly this is equivalent to SelectItem and therefore Option which do not allow null values. However we have to be wary of values that are "". But if the null case is out of the way the this should work ok.



getConvertedValue
public Object getConvertedValue(FacesContext context, Object submittedValue) throws ConverterException(Code)
Retrieve the value of this component (the "selected" property) as an object. This method is invoked by the JSF engine during the validation phase. The JSF default behaviour is for components to defer the conversion and validation to the renderer, but for the Selector based components, the renderers do not share as much functionality as the components do, so it is more efficient to do it here.
Parameters:
  context - The FacesContext of the request
Parameters:
  submittedValue - The submitted value of the component



getHeaderComponent
public UIComponent getHeaderComponent()(Code)
Gets or creates a component for the list label. Retrieves the listLabel facet if one was specified, or creates a new label component. A UIComponent for the list label



getListItems
public Iterator getListItems(FacesContext context, boolean ruler) throws FacesException(Code)
Retrieve an Iterator of ListSelector.ListItem, to be used by the renderer. an Iterator over ListItem.
throws:
  javax.faces.FacesException -



getMoveBottomButtonComponent
public UIComponent getMoveBottomButtonComponent(FacesContext context)(Code)
Get or create the MOVEBOTTOM button. Retrieves the component specified by the moveBottomButton facet (if there is one) or creates a new Button component. A UI Component for the Move Bottom button



getMoveDownButtonComponent
public UIComponent getMoveDownButtonComponent(FacesContext context)(Code)
Get or create the MOVEDOWN button. Retrieves the component specified by the moveDownButton facet (if there is one) or creates a new Button component. A UI Component for the MOVEDOWN button



getMoveTopButtonComponent
public UIComponent getMoveTopButtonComponent(FacesContext context)(Code)
Get or create the MOVETOP button. Retrieves the component specified by the moveTopButton facet (if there is one) or creates a new Button component. A UI Component for the Add button



getMoveUpButtonComponent
public UIComponent getMoveUpButtonComponent(FacesContext context)(Code)
Get or create the MOVE UP button. Retrieves the component specified by the moveUpButton facet (if there is one) or creates a new Button component. A UI Component for the moveUp button



getOnChange
public String getOnChange()(Code)



getPrimaryElementID
public String getPrimaryElementID(FacesContext context)(Code)



getReadOnlyValueComponent
public UIComponent getReadOnlyValueComponent()(Code)
Creates a component for the OrderableList in case the component is read-only. A UIComponent that displays the read-only value



getRows
public int getRows()(Code)



getValueAsReadOnly
protected String getValueAsReadOnly(FacesContext context) throws FacesException(Code)
Return a string suitable for displaying the value in read only mode. The default is to separate the list values with a comma.
Parameters:
  context - The FacesContext
throws:
  javax.faces.FacesException - If the list items cannot be processed



getValueAsStringArray
public String[] getValueAsStringArray(FacesContext context)(Code)



mainListSubmits
public boolean mainListSubmits()(Code)



Methods inherited from com.sun.rave.web.ui.component.OrderableListBase
public String getFamily()(Code)(Java Doc)
public String getLabel()(Code)(Java Doc)
public int getLabelLevel()(Code)(Java Doc)
public Object getList()(Code)(Java Doc)
public int getRows()(Code)(Java Doc)
public String getStyle()(Code)(Java Doc)
public String getStyleClass()(Code)(Java Doc)
public int getTabIndex()(Code)(Java Doc)
public String getToolTip()(Code)(Java Doc)
public ValueBinding getValueBinding(String name)(Code)(Java Doc)
public boolean isDisabled()(Code)(Java Doc)
public boolean isLabelOnTop()(Code)(Java Doc)
public boolean isMoveTopBottom()(Code)(Java Doc)
public boolean isMultiple()(Code)(Java Doc)
public boolean isReadOnly()(Code)(Java Doc)
public boolean isVisible()(Code)(Java Doc)
public void restoreState(FacesContext _context, Object _state)(Code)(Java Doc)
public Object saveState(FacesContext _context)(Code)(Java Doc)
public void setDisabled(boolean disabled)(Code)(Java Doc)
public void setLabel(String label)(Code)(Java Doc)
public void setLabelLevel(int labelLevel)(Code)(Java Doc)
public void setLabelOnTop(boolean labelOnTop)(Code)(Java Doc)
public void setList(Object list)(Code)(Java Doc)
public void setMoveTopBottom(boolean moveTopBottom)(Code)(Java Doc)
public void setMultiple(boolean multiple)(Code)(Java Doc)
public void setReadOnly(boolean readOnly)(Code)(Java Doc)
public void setRows(int rows)(Code)(Java Doc)
public void setStyle(String style)(Code)(Java Doc)
public void setStyleClass(String styleClass)(Code)(Java Doc)
public void setTabIndex(int tabIndex)(Code)(Java Doc)
public void setToolTip(String toolTip)(Code)(Java Doc)
public void setValueBinding(String name, ValueBinding binding)(Code)(Java Doc)
public void setVisible(boolean visible)(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.