Web Services
  Home arrow Web Services arrow Page 8 - Dynamic Data Analysis on the Web-a Design Approach
Dev Shed Forums  
Administration  
AJAX  
Apache  
BrainDump  
DHTML  
Flash  
Java  
JavaScript  
Multimedia  
MySQL  
Oracle  
Perl  
PHP  
Practices  
Python  
Reviews  
Security  
Smartphone Development  
Style-Sheets  
Web Services  
XML  
Zend  
Zope  
Mobile Linux  
App Generation ROI  
IBM® developerWorks  
Forums Sitemap  
E-Commerce Hosting  
Linux Web Hosting  
Managed Hosting  
Small Business Hosting  
VPS Hosting  
Weekly Newsletter

 
Developer Updates  
Free Website Content 
 RSS  Articles
 RSS  Forums
 RSS  All Feeds
Write For Us Get Paid  
Request Media Kit
Contact Us  
Site Map  
Privacy Policy  
Support  
 USERNAME
 
 PASSWORD
 
 
  >>> SIGN UP!  
  Lost Password? 
WEB SERVICES

Dynamic Data Analysis on the Web-a Design Approach
By: developerWorks
  • Search For More Articles!
  • Disclaimer
  • Author Terms
  • Rating: starstarstarstarstar / 14
    2004-12-29


    Table of Contents:
  • Dynamic Data Analysis on the Web-a Design Approach
  • Data analysis concepts
  • Dimensions and measures
  • Filtering and ordering
  • Dimension, measure, and slice dimension tags
  • Presenting data
  • Value formatting tags
  • Use of JavaBeans to provide dynamic values
  • Reporting common errors
  • Tag containment
  • Custom tags: lightweight, cheap, replaceable
  • Benefits of this design approach
  • In conclusion

  • Rate this Article: Poor Best 
      ADD THIS ARTICLE TO:
      error-file:tidyout.log Del.ici.ous error-file:tidyout.log Digg
      error-file:tidyout.log Blink error-file:tidyout.log Simpy
      error-file:tidyout.log Google error-file:tidyout.log Spurl
      error-file:tidyout.log Y! MyWeb error-file:tidyout.log Furl
    Email Me Similar Content When Posted
    Add Developer Shed Article Feed To Your Site
    Email Article To Friend
    Print Version Of Article
    PDF Version Of Article

     
     
    ADVERTISEMENT


    Dynamic Data Analysis on the Web-a Design Approach - Use of JavaBeans to provide dynamic values
    ( Page 8 of 13 )

    A common way to transfer information within and between JSPs is by using JavaBeans. Bean attribute values might be set using HTML form submission, or a variety of other means. Once set, those attribute values can be used to control aspects of the data-related tags.

    Listing 4. Controlling filtering using a JavaBean


    <%@ taglib uri="/WEB-INF/tlds/dd.tld" prefix="dd" %>
    <jsp:useBean class="package.beanClass" id="salesChoices" scope="page"/%>

    <dd:data id="sales">
      ...
      <dd:filters>
        <dd:includeFilter>
          <dd:dimension>Sales Region</dd:dimension>
          <dd:value
            ><jsp:getProperty name="salesChoices" property="region"/>
          </dd:value>
        </dd:includeFilter>
      </dd:filters>
    </dd:data>

    In Listing 4, a JavaBean is given an id of salesChoices and given page scope. This bean might support a number of properties that have been set by various means, but in this case, we assume that the region attribute has been set by user input using an HTML form control. The includeFilter tag filters on the sales region dimension, and the value to be included is taken from the region attribute of our salesChoices bean.

    Populating form fields with dynamic values

    To make the example shown in Listing 4, the page author will need to construct a page where the user can select the region from a list of current regions. The page author might choose to hard code a set of known sales region values. This is an acceptable strategy if the set of valid sales regions is fixed. However, if the list of current regions is volatile, or the list of regions that will be returned in the data varies according to other selections, the page author will wish to present the user with region choices that reflect the current state.

    To meet this requirement, provide custom JSP tags can that produce HTML form controls populated with the appropriate values. You can obtain these values from the data source by leveraging the existing data definition.



     
     
    >>> More Web Services Articles          >>> More By developerWorks
     

       

    WEB SERVICES ARTICLES

    - Dynamic Data Analysis on the Web-a Design Ap...
    - Use collection types with SOAP and JAX-RPC
    - Blogging Away To Glory (A bBlog Primer)
    - Introduction to Service Oriented Architectur...
    - Connecting Smart Devices on the Internet
    - An Embeddable Standards Compliant Web Servic...


    Email Marketing Software
    iContact Email Marketing Software Simplifies Online Communication.
    Online Survey Software
    Vovici online survey software, sample surveys & survey templates.
    Internet Marketing Company
    Provider of internet marketing services to boost your site rankings.
    SEO Services
    Top seo services provider; great organic rankings & qualified traffic
    SEO Firm
    SEO firm with excellent organic results for clients in all verticals



    © 2003-2009 by Developer Shed. All rights reserved. DS Cluster 2 Hosted by Hostway
    Stay green...Green IT