Java Doc for OrderableListBase.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

All known Subclasses:   com.sun.rave.web.ui.component.OrderableList,
OrderableListBase
abstract public class OrderableListBase extends javax.faces.component.UIInput (Code)

Use the ui:orderableList tag to create a list with buttons that allow the items on the list to be reordered.

HTML Elements and Layout

The textField component renders an XHTML fragment consisting of a selectelement representing a list, an input type="hidden" element which represents the current order of the list items, two or four input type="submit" elements for the buttons, and a label element for the label. The buttons are organized using a table, and the whole component is laid out using divs.

Configuring the ui:orderableList Tag

Use the list attribute to associate the component with a set of orderable items. The value of the list attribute must be a JavaServer Faces EL expression that evaluates to an array of Objects or to a java.util.List.

To allow users to select more than one item to move at a time, set multiple to true. To display buttons which moves the selected items to the top and bottom of the list, set moveTopBottom to true.

To specify a label for the component, use the label attribute, or specify a label facet. To place the label above the component, set labelOnTop to true.

Facets

  • label: use this facet to specify a custom component for the label.
  • readOnly: use this facet to specify a custom component for displaying the value of this component when it is marked as readonly. The default is a ui:staticText.
  • moveUpButton: use this facet to specify a custom component for the button that moves items up one step.
  • moveDownButton: use this facet to specify a custom component for the button that moves items down one step.
  • moveTopButton: use this facet to specify a custom component for the button that moves items to the top.
  • moveBottomButton: use this facet to specify a custom component for the button that moves items to the bottom.

Client-side JavaScript functions

The functions below must be invoked on the JavaScript object that corresponds to the orderableList. The name of this object is OrderableList_id where id is the DOM ID of the OrderableList component (the id of the outermost div with the colons replaced by underscores, e.g. OrderableList_form_taskOrder.

object.updateValue() Use this method to update the hidden field which represents the component value in any JavaScript function that changes the order of the items on the list.
object.moveUp() Moves the selected items up one step and updates the component value.
object.moveDown() Moves the selected items down one step and updates the component value.
object.moveTop() Moves the selected items to the top of the list and updates the component value.
object.moveBottom() Moves the selected items to the bottom of the list and updates the component value.
object.updateButtons() Use this method to update which buttons are selected in any JavaScript method that programmatically selects elements on the list.

Example

Example 1: OrderableList with Move to Top and Move to Bottom Buttons

This example uses a backing bean called AutomatedTasks with a property taskList which represents a list of tasks. Users are allowed to select more than one task to move. Buttons to move the items to the top and to the bottom are shown in addition to the default move up and move down buttons.

 <ui:orderableList id="taskOrder"
 list="#{AutomatedTasks.taskList}"
 label="Task execution order: "
 multiple="true"
 moveTopBottom="true"/>
 

Example 1: OrderableList with Move to Top and Move to Bottom Buttons

This example uses a backing bean called Volunteers and a property rotationOrder which is an ordered list of objects representing individual persons. A converter is used to derive a string representation of the person. Only the default move up and move down buttons are shown.

 <ui:orderableList id="callUpOrder"
 list="#{Volunteers.rotationOrder}"
 label="Call Up Order:" >
 <f:converter converterId="org.example.Person"/>
 <ui:orderableList>
 

Auto-generated component class. Do NOT modify; all changes will be lost!




Constructor Summary
public  OrderableListBase()
    

Method Summary
public  StringgetFamily()
    

Return the identifier of the component family to which this component belongs.

public  StringgetLabel()
    
public  intgetLabelLevel()
    

Sets the style level for the generated labels.

public  ObjectgetList()
    

The object that represents the list.

public  intgetRows()
    

The number of items to display.

public  StringgetStyle()
    
public  StringgetStyleClass()
    
public  intgetTabIndex()
    

Position of this element in the tabbing order for the current document.

public  StringgetToolTip()
    
public  ValueBindinggetValueBinding(String name)
    
public  booleanisDisabled()
    
public  booleanisLabelOnTop()
    

If this attribute is true, the label is rendered above the component.

public  booleanisMoveTopBottom()
    

If this attribute is true, the Move to Top and Move to Bottom buttons are shown.

public  booleanisMultiple()
    
public  booleanisReadOnly()
    
public  booleanisVisible()
    

Use the visible attribute to indicate whether the component should be viewable by the user in the rendered HTML page.

public  voidrestoreState(FacesContext _context, Object _state)
    
public  ObjectsaveState(FacesContext _context)
    
public  voidsetDisabled(boolean disabled)
    
public  voidsetLabel(String label)
    
public  voidsetLabelLevel(int labelLevel)
    

Sets the style level for the generated labels.

public  voidsetLabelOnTop(boolean labelOnTop)
    

If this attribute is true, the label is rendered above the component.

public  voidsetList(Object list)
    

The object that represents the list.

public  voidsetMoveTopBottom(boolean moveTopBottom)
    

If this attribute is true, the Move to Top and Move to Bottom buttons are shown.

public  voidsetMultiple(boolean multiple)
    
public  voidsetReadOnly(boolean readOnly)
    
public  voidsetRows(int rows)
    

The number of items to display.

public  voidsetStyle(String style)
    
public  voidsetStyleClass(String styleClass)
    
public  voidsetTabIndex(int tabIndex)
    

Position of this element in the tabbing order for the current document.

public  voidsetToolTip(String toolTip)
    
public  voidsetValueBinding(String name, ValueBinding binding)
    
public  voidsetVisible(boolean visible)
    

Use the visible attribute to indicate whether the component should be viewable by the user in the rendered HTML page.



Constructor Detail
OrderableListBase
public OrderableListBase()(Code)

Construct a new OrderableListBase.





Method Detail
getFamily
public String getFamily()(Code)

Return the identifier of the component family to which this component belongs. This identifier, in conjunction with the value of the rendererType property, may be used to select the appropriate Renderer for this component instance.




getLabel
public String getLabel()(Code)

If set, a label is rendered adjacent to the component with the value of this attribute as the label text.




getLabelLevel
public int getLabelLevel()(Code)

Sets the style level for the generated labels. Valid values are 1 (largest), 2 and 3 (smallest). The default value is 2.




getList
public Object getList()(Code)

The object that represents the list. It must be a JavaServer Faces EL expression that evaluates to an array of Objects or to a java.util.List.




getRows
public int getRows()(Code)

The number of items to display. The default value is 6.




getStyle
public String getStyle()(Code)

CSS style(s) to be applied when this component is rendered.




getStyleClass
public String getStyleClass()(Code)

CSS style class(es) to be applied when this component is rendered.




getTabIndex
public int getTabIndex()(Code)

Position of this element in the tabbing order for the current document. The tabbing order determines the sequence in which elements receive focus when the tab key is pressed. The tabIndex value must be an integer between 0 and 32767.




getToolTip
public String getToolTip()(Code)

Display the text as a tooltip for this component




getValueBinding
public ValueBinding getValueBinding(String name)(Code)

Return the ValueBinding stored for the specified name (if any), respecting any property aliases.


Parameters:
  name - Name of value binding to retrieve



isDisabled
public boolean isDisabled()(Code)

Flag indicating that activation of this component by the user is not currently permitted.




isLabelOnTop
public boolean isLabelOnTop()(Code)

If this attribute is true, the label is rendered above the component. If it is false, the label is rendered next to the component. The default is false.




isMoveTopBottom
public boolean isMoveTopBottom()(Code)

If this attribute is true, the Move to Top and Move to Bottom buttons are shown. The default is false.




isMultiple
public boolean isMultiple()(Code)

Flag indicating that the application user may make select more than one option from the listbox .




isReadOnly
public boolean isReadOnly()(Code)

If this attribute is set to true, the value of the component is rendered as text, preceded by the label if one was defined.




isVisible
public boolean isVisible()(Code)

Use the visible attribute to indicate whether the component should be viewable by the user in the rendered HTML page. If set to false, the HTML code for the component is present in the page, but the component is hidden with style attributes. By default, visible is set to true, so HTML for the component HTML is included and visible to the user. If the component is not visible, it can still be processed on subsequent form submissions because the HTML is present.




restoreState
public void restoreState(FacesContext _context, Object _state)(Code)

Restore the state of this component.




saveState
public Object saveState(FacesContext _context)(Code)

Save the state of this component.




setDisabled
public void setDisabled(boolean disabled)(Code)

Flag indicating that activation of this component by the user is not currently permitted.


See Also:   OrderableListBase.isDisabled()



setLabel
public void setLabel(String label)(Code)

If set, a label is rendered adjacent to the component with the value of this attribute as the label text.


See Also:   OrderableListBase.getLabel()



setLabelLevel
public void setLabelLevel(int labelLevel)(Code)

Sets the style level for the generated labels. Valid values are 1 (largest), 2 and 3 (smallest). The default value is 2.


See Also:   OrderableListBase.getLabelLevel()



setLabelOnTop
public void setLabelOnTop(boolean labelOnTop)(Code)

If this attribute is true, the label is rendered above the component. If it is false, the label is rendered next to the component. The default is false.


See Also:   OrderableListBase.isLabelOnTop()



setList
public void setList(Object list)(Code)

The object that represents the list. It must be a JavaServer Faces EL expression that evaluates to an array of Objects or to a java.util.List.


See Also:   OrderableListBase.getList()



setMoveTopBottom
public void setMoveTopBottom(boolean moveTopBottom)(Code)

If this attribute is true, the Move to Top and Move to Bottom buttons are shown. The default is false.


See Also:   OrderableListBase.isMoveTopBottom()



setMultiple
public void setMultiple(boolean multiple)(Code)

Flag indicating that the application user may make select more than one option from the listbox .


See Also:   OrderableListBase.isMultiple()



setReadOnly
public void setReadOnly(boolean readOnly)(Code)

If this attribute is set to true, the value of the component is rendered as text, preceded by the label if one was defined.


See Also:   OrderableListBase.isReadOnly()



setRows
public void setRows(int rows)(Code)

The number of items to display. The default value is 6.


See Also:   OrderableListBase.getRows()



setStyle
public void setStyle(String style)(Code)

CSS style(s) to be applied when this component is rendered.


See Also:   OrderableListBase.getStyle()



setStyleClass
public void setStyleClass(String styleClass)(Code)

CSS style class(es) to be applied when this component is rendered.


See Also:   OrderableListBase.getStyleClass()



setTabIndex
public void setTabIndex(int tabIndex)(Code)

Position of this element in the tabbing order for the current document. The tabbing order determines the sequence in which elements receive focus when the tab key is pressed. The tabIndex value must be an integer between 0 and 32767.


See Also:   OrderableListBase.getTabIndex()



setToolTip
public void setToolTip(String toolTip)(Code)

Display the text as a tooltip for this component


See Also:   OrderableListBase.getToolTip()



setValueBinding
public void setValueBinding(String name, ValueBinding binding)(Code)

Set the ValueBinding stored for the specified name (if any), respecting any property aliases.


Parameters:
  name - Name of value binding to set
Parameters:
  binding - ValueBinding to set, or null to remove



setVisible
public void setVisible(boolean visible)(Code)

Use the visible attribute to indicate whether the component should be viewable by the user in the rendered HTML page. If set to false, the HTML code for the component is present in the page, but the component is hidden with style attributes. By default, visible is set to true, so HTML for the component HTML is included and visible to the user. If the component is not visible, it can still be processed on subsequent form submissions because the HTML is present.


See Also:   OrderableListBase.isVisible()



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