NetCharts Pro

netcharts.pro.charts.diagram
Class NFPolyExpr

java.lang.Object
  extended by netcharts.pro.common.NFBaseClass
      extended by netcharts.pro.charts.diagram.NFPolyExpr
All Implemented Interfaces:
java.lang.Cloneable

public class NFPolyExpr
extends NFBaseClass

This class is used to define an expression for coloring polygons in a diagram chart. An expression consists of the operator, the compare value(s), and the fillColor. When the expression is true, the diagram will color the polygon with the given fillColor.


Field Summary
static int BETWEEN
          BETWEEN expression identifier (between)
static java.lang.String BETWEEN_STRING
          EQUAL_TEXT expression String (=)
static int EQUAL
          EQUAL expression identifier (==)
static java.lang.String EQUAL_STRING
          EQUAL expression String (==)
static int EQUAL_TEXT
          EQUAL_TEXT expression identifier (=)
static java.lang.String EQUAL_TEXT_STRING
          NOT_EQUAL_TEXT expression String (<>)
static java.util.Hashtable expressionOpMap
          The set of allowed expressions.
static java.lang.String[] expressions
          The set of allowed expressions.
static int GREATER_THAN
          GREATER_THAN expression identifier (>)
static int GREATER_THAN_OR_EQUAL
          GREATER_THAN_OR_EQUAL expression identifier (>=)
static java.lang.String GREATER_THAN_STRING
          GREATER_THAN expression String (>)
static java.lang.String GREATER_THEN_OR_EQUAL_STRING
          GREATER_THAN_OR_EQUAL expression String (>=)
static int LESS_THAN
          LESS_THAN expression identifier (<)
static int LESS_THAN_OR_EQUAL
          LESS_THAN_OR_EQUAL expression identifier (<=)
static java.lang.String LESS_THAN_STRING
          LESS_THAN expression String (<)
static java.lang.String LESS_THEN_OR_EQUAL_STRING
          LESS_THAN_OR_EQUAL expression String (<=)
static int NOT_EQUAL
          NOT_EQUAL expression identifier (!=)
static java.lang.String NOT_EQUAL_STRING
          NOT_EQUAL expression String (!=)
static int NOT_EQUAL_TEXT
          NOT_EQUAL_TEXT expression identifier (<>)
static java.lang.String NOT_EQUAL_TEXT_STRING
          NOT_EQUAL_TEXT expression String (<>)
 
Constructor Summary
NFPolyExpr()
          Constructs a default poly expression
NFPolyExpr(int operator, java.lang.Object value1, java.lang.Object value2, java.awt.Color fillColor)
          Constructs a default poly expression
 
Method Summary
 java.lang.String getCDL()
          Generate CDL parameters representing this polygon expression.
 java.awt.Color getFillColor()
          Gets the fill color to be used if the expression is true
static int getIntOperator(java.lang.String operator)
          Returns the int associated with the string based expression operator
 int getOperator()
          Gets expression operator
static java.lang.String getStringOperator(int operator)
          Returns the expression operator string associated with the int based expression operator
 java.lang.Object getValue1()
          Gets the expression value
 java.lang.Object getValue2()
          Gets the second value.
 void setCDL(java.lang.String s)
          Configures this object from a CDL parameter representation.
 void setFillColor(java.awt.Color fillColor)
          Sets the fill color to be used if the expression is true
 void setOperator(int operator)
          Sets expression operator
 void setValue1(java.lang.Object value1)
          Sets the expression value
 void setValue2(java.lang.Object value2)
          Sets the second value.
 java.lang.String toString()
          Returns a new String object representing this poly expr.
 
Methods inherited from class netcharts.pro.common.NFBaseClass
clone, getModified, getUserObject, setModified, setUserObject
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

GREATER_THAN

public static final int GREATER_THAN
GREATER_THAN expression identifier (>)

See Also:
Constant Field Values

LESS_THAN

public static final int LESS_THAN
LESS_THAN expression identifier (<)

See Also:
Constant Field Values

EQUAL

public static final int EQUAL
EQUAL expression identifier (==)

See Also:
Constant Field Values

GREATER_THAN_OR_EQUAL

public static final int GREATER_THAN_OR_EQUAL
GREATER_THAN_OR_EQUAL expression identifier (>=)

See Also:
Constant Field Values

LESS_THAN_OR_EQUAL

public static final int LESS_THAN_OR_EQUAL
LESS_THAN_OR_EQUAL expression identifier (<=)

See Also:
Constant Field Values

NOT_EQUAL

public static final int NOT_EQUAL
NOT_EQUAL expression identifier (!=)

See Also:
Constant Field Values

BETWEEN

public static final int BETWEEN
BETWEEN expression identifier (between)

See Also:
Constant Field Values

EQUAL_TEXT

public static final int EQUAL_TEXT
EQUAL_TEXT expression identifier (=)

See Also:
Constant Field Values

NOT_EQUAL_TEXT

public static final int NOT_EQUAL_TEXT
NOT_EQUAL_TEXT expression identifier (<>)

See Also:
Constant Field Values

GREATER_THAN_STRING

public static java.lang.String GREATER_THAN_STRING
GREATER_THAN expression String (>)


LESS_THAN_STRING

public static java.lang.String LESS_THAN_STRING
LESS_THAN expression String (<)


EQUAL_STRING

public static java.lang.String EQUAL_STRING
EQUAL expression String (==)


GREATER_THEN_OR_EQUAL_STRING

public static java.lang.String GREATER_THEN_OR_EQUAL_STRING
GREATER_THAN_OR_EQUAL expression String (>=)


LESS_THEN_OR_EQUAL_STRING

public static java.lang.String LESS_THEN_OR_EQUAL_STRING
LESS_THAN_OR_EQUAL expression String (<=)


NOT_EQUAL_STRING

public static java.lang.String NOT_EQUAL_STRING
NOT_EQUAL expression String (!=)


BETWEEN_STRING

public static java.lang.String BETWEEN_STRING
EQUAL_TEXT expression String (=)


EQUAL_TEXT_STRING

public static java.lang.String EQUAL_TEXT_STRING
NOT_EQUAL_TEXT expression String (<>)


NOT_EQUAL_TEXT_STRING

public static java.lang.String NOT_EQUAL_TEXT_STRING
NOT_EQUAL_TEXT expression String (<>)


expressions

public static java.lang.String[] expressions
The set of allowed expressions. Consists of GREATER_THAN_STRING, LESS_THAN_STRING, EQUAL_STRING, GREATER_THEN_OR_EQUAL_STRING, LESS_THEN_OR_EQUAL_STRING, NOT_EQUAL_STRING, BETWEEN_STRING, EQUAL_TEXT_STRING, NOT_EQUAL_TEXT_STRING


expressionOpMap

public static java.util.Hashtable expressionOpMap
The set of allowed expressions. Consists of GREATER_THAN_STRING, LESS_THAN_STRING, EQUAL_STRING, GREATER_THEN_OR_EQUAL_STRING, LESS_THEN_OR_EQUAL_STRING, NOT_EQUAL_STRING, BETWEEN_STRING, EQUAL_TEXT_STRING, NOT_EQUAL_TEXT_STRING

Constructor Detail

NFPolyExpr

public NFPolyExpr()
Constructs a default poly expression


NFPolyExpr

public NFPolyExpr(int operator,
                  java.lang.Object value1,
                  java.lang.Object value2,
                  java.awt.Color fillColor)
Constructs a default poly expression

Parameters:
operator - Expression operator
value1 - Object to compare with
value2 - Only used if expression is BETWEEN
Method Detail

setOperator

public void setOperator(int operator)
Sets expression operator

Parameters:
operator -

getOperator

public int getOperator()
Gets expression operator

Returns:
operator

setValue1

public void setValue1(java.lang.Object value1)
Sets the expression value

Parameters:
value1 - The expression value to compare with.

getValue1

public java.lang.Object getValue1()
Gets the expression value

Returns:
The expression value to compare with.

setValue2

public void setValue2(java.lang.Object value2)
Sets the second value. Only used if operator is BETWEEN

Parameters:
value2 - The second value in the between statement

getValue2

public java.lang.Object getValue2()
Gets the second value. Only valid if operator is BETWEEN

Returns:
value2 The second value in the between statement

setFillColor

public void setFillColor(java.awt.Color fillColor)
Sets the fill color to be used if the expression is true

Parameters:
fillColor - The color to fill the polygon with if the expression is true

getFillColor

public java.awt.Color getFillColor()
Gets the fill color to be used if the expression is true

Returns:
The color to fill the polygon with if the expression is true

toString

public java.lang.String toString()
Returns a new String object representing this poly expr.

Overrides:
toString in class java.lang.Object
Returns:
A new String object in the same form as that given by getCDL().

setCDL

public void setCDL(java.lang.String s)
Configures this object from a CDL parameter representation.

Parameters:
cdl - CDL in the form: ("operator",value1,value2,color)

getCDL

public java.lang.String getCDL()
Generate CDL parameters representing this polygon expression.

Returns:
CDL in the form: ("operator",value1,value2,color)

getIntOperator

public static int getIntOperator(java.lang.String operator)
Returns the int associated with the string based expression operator

Parameters:
operator - The expression operator
Returns:
The static expression operator int associated with the expression operator string.

getStringOperator

public static java.lang.String getStringOperator(int operator)
Returns the expression operator string associated with the int based expression operator

Parameters:
operator - The expression operator
Returns:
The static expression operator string associated with the expression operator int.

NetCharts Pro


Visual Mining, Inc.
2099 Gaither Rd.
Suite 220
Rockville, MD 20850
800.308.0731
301.947.8293 FAX

Copyright © Visual Mining, Inc. 1996 - 2011
All Rights Reserved.

NetCharts Pro TM is a registered trademark of Visual Mining, Inc. Other brands and their products are trademarks of their respective holders.

Last Modified: Jun 28, 2011