org.opengts.war.report
Class ReportConditional

java.lang.Object
  extended by org.opengts.war.report.ReportConditional

public class ReportConditional
extends java.lang.Object


Constructor Summary
ReportConditional()
          Constructor
ReportConditional(java.lang.String trueProp, java.lang.String falseProp)
          Constructor
 
Method Summary
 void addFalsePropertyKey(java.lang.String prop)
          Adds the specified property key to the list of keys to check for "false" Undefined property keys will be skipped.
 void addFalsePropertyKeys(java.lang.String[] props)
          Adds the specified list of property keys to the list of keys to check for "false"
Undefined property keys will be skipped.
 void addTruePropertyKey(java.lang.String prop)
          Adds the specified property key to the list of keys to check for "true" Undefined property keys will be skipped.
 void addTruePropertyKeys(java.lang.String[] props)
          Adds the specified list of property keys to the list of keys to check for "true" Undefined property keys will be skipped.
static ReportConditional createReportConditional(java.lang.String trueProp, java.lang.String falseProp)
          Creates a new ReportConditional if either "trueProp" or "falseProp" is specified (non-blank) Returns null if both "trueProp" and "falseProp" are null/blank.
 boolean isTrue(BasicPrivateLabel bpl)
          Returns the conditional value for the PrivateLabel context
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ReportConditional

public ReportConditional()
Constructor


ReportConditional

public ReportConditional(java.lang.String trueProp,
                         java.lang.String falseProp)
Constructor

Method Detail

createReportConditional

public static ReportConditional createReportConditional(java.lang.String trueProp,
                                                        java.lang.String falseProp)
Creates a new ReportConditional if either "trueProp" or "falseProp" is specified (non-blank) Returns null if both "trueProp" and "falseProp" are null/blank.

Parameters:
trueProp - The properties to check for "true"
falseProp - The properties to check for "false"
Returns:
The new ReportCondition instance, or null if both "trueProp" and "falseProp" are null/blank.

addTruePropertyKey

public void addTruePropertyKey(java.lang.String prop)
Adds the specified property key to the list of keys to check for "true" Undefined property keys will be skipped. The propery key test will stop at the first defined property key found.

Parameters:
prop - The property key to add

addTruePropertyKeys

public void addTruePropertyKeys(java.lang.String[] props)
Adds the specified list of property keys to the list of keys to check for "true" Undefined property keys will be skipped. The propery key test will stop at the first defined property key found.

Parameters:
props - The property key list to add

addFalsePropertyKey

public void addFalsePropertyKey(java.lang.String prop)
Adds the specified property key to the list of keys to check for "false" Undefined property keys will be skipped. The propery key test will stop at the first defined property key found.

Parameters:
prop - The property key to add

addFalsePropertyKeys

public void addFalsePropertyKeys(java.lang.String[] props)
Adds the specified list of property keys to the list of keys to check for "false"
Undefined property keys will be skipped. The propery key test will stop at the first defined property key found.

Parameters:
props - The property key list to add

isTrue

public boolean isTrue(BasicPrivateLabel bpl)
Returns the conditional value for the PrivateLabel context

Returns:
The value of the property conditions