How to Use the Rating Component

The Rating JSF component that was created by Matthew Bohm allows users to rate items and have the model updated through an AJAX call.  The component uses a managed bean to configure the advanced properties as well as the resultant user rating selection.  The tag library for the Rating component can be accessed using the declaration:
    <%@taglib prefix="ui" uri="http://java.sun.com/blueprints/ui"%>
An example of the JSF Rating component's use is as follows:
   <ui:rating id="rating" maxGrade="5" includeNotInterested="true" includeClear="true" 
hoverTexts="#{RatingBean.ratingText}" notInterestedHoverText="Not Interested"
clearHoverText="Clear Rating" grade="#{RatingBean.grade}"/>

JSP Tag Attributes

The Rating component supports the following attributes.

Java BluePrints | Sun Microsystems © 2007 Sun Microsystems Inc. All rights reserved. Use is subject to license terms.