|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectnet.sourceforge.fuzzyservices.beans.RuleBase
public class RuleBase
This class represents a rule base according to JavaBeans conventions.
RuleBase,
Serialized Form| Field Summary | |
|---|---|
static String |
ACCUMULATION_OPERATOR_PROPERTY
Bound property name for accumulationOperator. |
static String |
NAME_PROPERTY
Bound property name for name. |
static String |
RULES_PROPERTY
Bound property name for rules. |
| Constructor Summary | |
|---|---|
RuleBase()
Default RuleBase constructor. |
|
RuleBase(String newName)
Constructs a new rule base with given name. |
|
| Method Summary | |
|---|---|
void |
addPropertyChangeListener(PropertyChangeListener listener)
Adds a PropertyChangeListener to the listener list. |
Object |
clone()
|
boolean |
equals(Object obj)
|
Operator |
getAccumulationOperator()
Returns the accumulation operator of this rule base. |
int |
getId()
Returns the technical identifier (e.g. within a database). |
String |
getName()
Returns the name of this rule base. |
Rule[] |
getRules()
Returns all rules of this rule base. |
Rule |
getRules(int index)
Gets the rule located at the specified index of this rule
base. |
int |
hashCode()
|
void |
removePropertyChangeListener(PropertyChangeListener listener)
Removes a PropertyChangeListener from the listener list. |
void |
setAccumulationOperator(Operator newAccumulationOperator)
Sets the accumulation operator of this rule base. |
void |
setName(String newName)
Sets the name of this rule base. |
void |
setRules(int index,
Rule newRule)
Replaces the rule at the position index of the rule base. |
void |
setRules(Rule[] newRules)
Fills the rule base with rules. |
String |
toString()
|
String |
toString(boolean withRules)
Returns a textual representation of the rule base |
void |
vetoableChange(PropertyChangeEvent evt)
|
| Methods inherited from class java.lang.Object |
|---|
finalize, getClass, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
public static final String NAME_PROPERTY
name.
public static final String RULES_PROPERTY
rules.
public static final String ACCUMULATION_OPERATOR_PROPERTY
accumulationOperator.
| Constructor Detail |
|---|
public RuleBase()
RuleBase constructor. This constructor sets a
default accumulation operator specified in
RuleBase, and registers itself as a vetoable
change listener.
RuleBase.getDefaultAccumulationOperator()public RuleBase(String newName)
newName - The new value for the property.| Method Detail |
|---|
public int getId()
public final String getName()
name propertysetName(java.lang.String)public final Rule[] getRules()
rules propertysetRules(net.sourceforge.fuzzyservices.beans.Rule[])public final Rule getRules(int index)
index of this rule
base.
index - the position of the rule to be returned.
setRules(net.sourceforge.fuzzyservices.beans.Rule[])public final Operator getAccumulationOperator()
accumulationOperator propertysetAccumulationOperator(net.sourceforge.fuzzyservices.beans.Operator)public final void setAccumulationOperator(Operator newAccumulationOperator)
newAccumulationOperator - The new value for the property.getAccumulationOperator()public final void setName(String newName)
newName - The new value for the property.getName()public final void setRules(Rule[] newRules)
newRules - an array with rules.getRules()
public final void setRules(int index,
Rule newRule)
index of the rule base.
index - The index value into the property array.newRule - the new rule for the rule base.getRules(int)
public final void vetoableChange(PropertyChangeEvent evt)
throws PropertyVetoException
vetoableChange in interface VetoableChangeListenerPropertyVetoExceptionpublic final void addPropertyChangeListener(PropertyChangeListener listener)
PropertyChangeListener to the listener list. The
listener is registered for all properties.
A PropertyChangeEvent will get fired in response to setting
a bound property.
listener - the PropertyChangeListener to be addedpublic final void removePropertyChangeListener(PropertyChangeListener listener)
PropertyChangeListener from the listener list.
This removes a PropertyChangeListener that was registered
for all properties.
listener - the PropertyChangeListener to be removedpublic Object clone()
clone in class Objectpublic final boolean equals(Object obj)
equals in class Objectpublic int hashCode()
hashCode in class Objectpublic String toString()
toString in class Objectpublic String toString(boolean withRules)
withRules - true if all rule definitions are also returned,
false otherwise.
Rule.toString()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||