com.novell.zos.jdl
Class Constraint

java.lang.Object
  extended by com.novell.zos.jdl.Constraint
Direct Known Subclasses:
BinaryConstraint, ContainerConstraint, DefinedConstraint, UndefinedConstraint

public class Constraint
extends java.lang.Object

Constraint is the base class for all constraint classes.


Method Summary
 java.lang.String getFact()
          Retrieve the fact id of the left side of the operation.
 java.lang.String getFactValue()
          Retrieve the fact name whose value is used right side of the operation if set with setFactValue() otherwise this will return None.
 java.lang.String getReason()
          Retrieve reason string that contains human readable explanation that can be displayed as an error when a constraint evaluates to false.
 org.python.core.PyObject getValue()
          Retrieve the value of the right side of the operation if set as a value or else it returns null.
 void setFact(java.lang.String fact)
          Sets the fact id for the left side of the operation.
 void setFactValue(java.lang.String factvalue)
          Sets the fact name whose value is used in the right side of the operation and in doing so negates any previous setValue() call.
 void setReason(java.lang.String reason)
          Sets the reason string that contains human readable explanation that can be displayed as an error when a constraint evaluates to false.
 void setValue(org.python.core.PyObject value)
          Sets the value of the right side of the operation and in doing so negates any previous setFactValue() call.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

getFact

public java.lang.String getFact()
Retrieve the fact id of the left side of the operation.

Returns:
the fact id

setFact

public void setFact(java.lang.String fact)
Sets the fact id for the left side of the operation.

Parameters:
fact - the fact id

setFactValue

public void setFactValue(java.lang.String factvalue)
Sets the fact name whose value is used in the right side of the operation and in doing so negates any previous setValue() call.

Parameters:
factvalue - the fact name whose value to retrieve

getFactValue

public java.lang.String getFactValue()
Retrieve the fact name whose value is used right side of the operation if set with setFactValue() otherwise this will return None.

Returns:
the name of the fact whose value to retrieve

setValue

public void setValue(org.python.core.PyObject value)
Sets the value of the right side of the operation and in doing so negates any previous setFactValue() call.

Parameters:
value - the right side value of the operation

getValue

public org.python.core.PyObject getValue()
Retrieve the value of the right side of the operation if set as a value or else it returns null.

Returns:
the right side value of the operation

setReason

public void setReason(java.lang.String reason)
Sets the reason string that contains human readable explanation that can be displayed as an error when a constraint evaluates to false.

Parameters:
reason - containing reason to display

getReason

public java.lang.String getReason()
Retrieve reason string that contains human readable explanation that can be displayed as an error when a constraint evaluates to false.

Returns:
string containing reason to display


Copyright (c) 2009 Novell, Inc. All rights reserved.