Flipkart Search

Sunday 25 November 2012

Static list in ADF the other way

The manage bean property of ADF can also provide the static list without a actual managed Bean{Interesting ??}. Let's do with an Example.
Inside your adfc-config.xml or your page-flow.xml register this list as below

  <managed-bean id="__3">
        <managed-bean-name>StaticBean</managed-bean-name>
        <managed-bean-class>java.util.HashMap</managed-bean-class>
        <managed-bean-scope>application</managed-bean-scope>
        <map-entries>
            <map-entry>
                <key>rahulkaitian</key>
                <value>http://rahulkaitian.blogspot.in</value>
            </map-entry>
            <map-entry>
                <key>rahulkumar07</key>
                <value>http://rahulkumar07.blogspot.in</value>
            </map-entry>
        </map-entries>
    </managed-bean>







and access the pair  in EL as #{StaticBean['rahulkaitian']}

No comments:

Post a Comment