Value List Handler
Tag retrieve
Retrieve a ValueList from adapter in a JSP. In MVC style programming you should't do that! Instead of this use ValueListHandlerHelper
in a controller.
Example
<vlh:retrieve name="players1" focusProperty ="id" focusValue ="30204" />
It retrievies data from the named adapter "players1" and focus on page, where is player with id 30204.
The name of adapter depends on configuration bean, where is a map of adapters like this:
<bean id="valueListHandler" singleton="true" class="net.mlw.vlh.DefaultValueListHandlerImpl"> <property name="config.adapters"> <map> <entry key="players1"> <bean class="net.mlw.vlh.adapter.hibernate.Hibernate20Adapter"> <property name="sessionFactory"><ref bean="mySessionFactory"/></property> <property name="defaultNumberPerPage"><value>20</value></property> <property name="defaultSortColumn"><value>lastName</value></property> <property name="defaultSortDirection"><value>asc</value></property> <property name="hql"> <value> FROM net.mlw.data.Player AS vo /~name: WHERE vo.lastName LIKE {name} ~/ /~sortColumn: ORDER BY vo.[sortColumn] [sortDirection]~/
</value>
</property>
<property name="defaultFocusPropertyObjectAlias"><value>vo</value></property>
<property name="maxRowsForFocus"><value>160000</value></property>
<property name="removeEmptyStrings"><value>true</value></property>
</bean>
</entry>
... </map>
</property>
</bean>
Tag Information |
Tag Class | net.mlw.vlh.web.tag.ValueListRetriever |
TagExtraInfo Class | None |
Body Content | JSP |
Display Name | None |
Attributes |
Name | Required | Request-time | Type | Description |
name | true | true | java.lang.String | The name of adpater to retrieve ValueList data. |
focusProperty | false | true | java.lang.String | The adapter property of the list column to determine focusValue in generated hql. Use this options rather via MVC and ValueListInfo.setFocusProperty(). |
focusValue | false | true | java.lang.String | Adapter will scroll to focused value and try to highlight it. If there is too many items, or value is not found or found, it set focus status (ValueListInfo.FOCUS_NOT_FOUND, ValueListInfo.FOCUS_TOO_MANY_ITEMS, ValueListInfo.FOCUS_FOUND ) |
Variables |
No Variables Defined. |
Output Generated by
Tag Library Documentation Generator.
Java, JSP, and JavaServer Pages are trademarks or
registered trademarks of Sun Microsystems, Inc. in the US and other
countries. Copyright 2002-4 Sun Microsystems, Inc.
4150 Network Circle
Santa Clara, CA 95054, U.S.A.
All Rights Reserved.