org.apache.fulcrum.intake.xmlmodel
Class Rule

java.lang.Object
  extended by org.apache.fulcrum.intake.xmlmodel.Rule
All Implemented Interfaces:
Serializable, Constraint

public class Rule
extends Object
implements Constraint, Serializable

A Class for holding data about a constraint on a property.

Version:
$Id: Rule.java 670328 2008-06-22 09:34:11Z tv $
Author:
John McNally, Thomas Vandahl
See Also:
Serialized Form

Constructor Summary
Rule()
          Default Constructor
 
Method Summary
 XmlField getField()
          Get the parent Field of the rule
 String getMessage()
          Get the error message
 String getName()
          Get the name of the parameter
 String getValue()
          Get the value of the parameter
 void loadFromXML(Attributes attrib)
          Imports a column from an XML specification
 void setField(XmlField parent)
          Set the parent Field of the rule
 void setMessage(String newMessage)
          Set the error message
 void setName(String newName)
          Set the name of the parameter
 void setValue(String newValue)
          Set the value of the parameter
 String toString()
          String representation of the column.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

Rule

public Rule()
Default Constructor

Method Detail

loadFromXML

public void loadFromXML(Attributes attrib)
Imports a column from an XML specification


setName

public void setName(String newName)
Set the name of the parameter


getName

public String getName()
Get the name of the parameter

Specified by:
getName in interface Constraint

setValue

public void setValue(String newValue)
Set the value of the parameter


getValue

public String getValue()
Get the value of the parameter

Specified by:
getValue in interface Constraint

setMessage

public void setMessage(String newMessage)
Set the error message


getMessage

public String getMessage()
Get the error message

Specified by:
getMessage in interface Constraint

setField

public void setField(XmlField parent)
Set the parent Field of the rule


getField

public XmlField getField()
Get the parent Field of the rule


toString

public String toString()
String representation of the column. This is an xml representation.

Overrides:
toString in class Object


Copyright © 2005-2009 The Apache Software Foundation. All Rights Reserved.