net.windward.bean
Class BeanProviderImpl

java.lang.Object
  |
  +--net.windward.bean.BeanProviderImpl
All Implemented Interfaces:
BeanProvider
Direct Known Subclasses:
StatefulBeanProviderImpl, StatelessBeanProviderImpl

public abstract class BeanProviderImpl
extends java.lang.Object
implements BeanProvider

This implements a do nothing implementation of BeanProvider. It is equivilent to not having a bean. To implement a bean you can override this class and then implement all methods that need to perform non-default actions. Note: you do not need to inherit from this class to create a bean. You only need to implement the BeanProvider interface. This class exists as a convenience for developers who wish to use it.

Version:
1.0 Jun 18, 2004

Constructor Summary
BeanProviderImpl()
           
 
Method Summary
 boolean forEachTag(ForEachTag tag)
          Process a <wr:forEach ...
 BeanResult functionTag(FunctionTag tag, java.lang.String[] nodeValues, java.lang.String value, java.util.Locale locale)
          Process a <wr:function ...
 boolean ifTag(IfTag tag, boolean value)
          Process a <wr:if ...
 BeanResult outTag(OutTag tag, java.lang.String value, java.util.Locale locale)
          Process a <wr:out ...
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

BeanProviderImpl

public BeanProviderImpl()
Method Detail

functionTag

public BeanResult functionTag(FunctionTag tag,
                              java.lang.String[] nodeValues,
                              java.lang.String value,
                              java.util.Locale locale)
                       throws BeanProviderException
Process a <wr:function ... /> tag. Return the string and formatting to display. The tag can have a select=''.
Specified by:
functionTag in interface BeanProvider
Parameters:
tag - The tag that is being printed.
nodeValues - The initial values of each node used by the function tag.
value - The final string value for the tag.
locale - The locale in effect for the document.
Returns:
The string and formatting to write at this point in the report.
Throws:
BeanProviderException - Something is wrong with the bean. This is defined by the bean implementor.

outTag

public BeanResult outTag(OutTag tag,
                         java.lang.String value,
                         java.util.Locale locale)
                  throws BeanProviderException
Process a <wr:out ... /> tag. Return the string and formatting to display. The tag can have a select=''.
Specified by:
outTag in interface BeanProvider
Parameters:
tag - The tag that is being printed.
value - The final string value for the tag.
locale - The locale in effect for the document.
Returns:
The string and formatting to write at this point in the report.
Throws:
BeanProviderException - Something is wrong with the bean. This is defined by the bean implementor.

forEachTag

public boolean forEachTag(ForEachTag tag)
Process a <wr:forEach ... /> tag. This is called before each iteration of a forEach loop. This provides the ability to end a loop early. Return true to continue in the loop and false to end the loop. The tag can not have a select=''.
Specified by:
forEachTag in interface BeanProvider
Parameters:
tag - The tag that is being iterated.
Returns:
true to continue in the loop and false to end the loop.

ifTag

public boolean ifTag(IfTag tag,
                     boolean value)
Process a <wr:if ... /> tag. This provides the ability to set the value of the if. Return true to include the text inside the if and false to skip the if (or process the else if there is one). The tag can not have a select=''.
Specified by:
ifTag in interface BeanProvider
Parameters:
tag - The tag that is being evaluted.
value - The evaluated value of the tag.
Returns:
true true to include the text inside the if and false to skip the if (or process the else if there is one).


Copyright © 2002 - 2008 Windward Reports - All Rights Reserved. java reporting software