|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectnet.sourceforge.fuzzyservices.beans.LinguisticVariable
public class LinguisticVariable
This class represents a linguistic variable according to JavaBeans conventions.
LinguisticVariable,
Serialized Form| Field Summary | |
|---|---|
static String |
LINGUISTIC_TERMS_PROPERTY
Bound property name for linguisticTerms. |
static String |
NAME_PROPERTY
Bound property name for name. |
| Constructor Summary | |
|---|---|
LinguisticVariable()
Default LinguisticVariable constructor. |
|
| Method Summary | |
|---|---|
void |
addPropertyChangeListener(PropertyChangeListener listener)
Adds a PropertyChangeListener to the listener list. |
void |
addVetoableChangeListener(VetoableChangeListener listener)
Adds a VetoableChangeListener to the listener list. |
Object |
clone()
|
boolean |
contains(LinguisticTerm linguisticTerm)
Tests whether or not the linguisticTerm is part of this
linguistic variable. |
boolean |
equals(Object obj)
|
int |
getId()
Returns the technical identifier (e.g. within a database). |
LinguisticTerm |
getLinguisticTerm(String aName)
Gets the linguistic term with the specified name of this
linguistic variable. |
LinguisticTerm[] |
getLinguisticTerms()
Returns all linguistic terms of this linguistic variable. |
LinguisticTerm |
getLinguisticTerms(int index)
Gets the linguistic term located at the specified index of
this linguistic variable. |
String |
getName()
Returns the name of this linguistic variable. |
int |
hashCode()
|
void |
removePropertyChangeListener(PropertyChangeListener listener)
Removes a PropertyChangeListener from the listener list. |
void |
removeVetoableChangeListener(VetoableChangeListener listener)
Removes a VetoableChangeListener from the listener list. |
void |
setLinguisticTerms(int index,
LinguisticTerm newLinguisticTerms)
Replaces a linguistic term of this linguistic variable. |
void |
setLinguisticTerms(LinguisticTerm[] newLinguisticTerms)
Defines new linguistic terms for this linguistic variable. |
void |
setName(String newName)
Sets the name of this linguistic variable. |
String |
toString()
|
String |
toString(boolean withTerms)
Returns a textual representation of the linguistic variable |
| 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 LINGUISTIC_TERMS_PROPERTY
linguisticTerms.
| Constructor Detail |
|---|
public LinguisticVariable()
LinguisticVariable constructor.
| Method Detail |
|---|
public int getId()
public String getName()
name propertysetName(java.lang.String)public LinguisticTerm[] getLinguisticTerms()
linguisticTerms propertysetLinguisticTerms(LinguisticTerm[])
public LinguisticTerm getLinguisticTerms(int index)
throws ArrayIndexOutOfBoundsException
index of
this linguistic variable.
index - the position of the linguistic term to be returned.
ArrayIndexOutOfBoundsException - if index is an
invalid positionsetLinguisticTerms(LinguisticTerm[])public LinguisticTerm getLinguisticTerm(String aName)
name of this
linguistic variable.
aName - the name of the linguistic term to be returned.
setLinguisticTerms(LinguisticTerm[])
public final void setLinguisticTerms(LinguisticTerm[] newLinguisticTerms)
throws IllegalArgumentException,
PropertyVetoException
newLinguisticTerms - An array with linguistic terms
IllegalArgumentException - if there are identical terms
PropertyVetoException - when the attempt to set the property is
vetoed by a listenergetLinguisticTerms()
public final void setLinguisticTerms(int index,
LinguisticTerm newLinguisticTerms)
throws ArrayIndexOutOfBoundsException,
IllegalArgumentException,
PropertyVetoException
index - The index value into the property array.newLinguisticTerms - A new linguistic term for this linguistic
variable
ArrayIndexOutOfBoundsException - if index is an
invalid position
IllegalArgumentException - if there are identical terms
PropertyVetoException - when the attempt to set the property is
vetoed by a listenergetLinguisticTerms()
public final void setName(String newName)
throws PropertyVetoException
newName - The new value for the property.
PropertyVetoException - when the attempt to set the property is
vetoed by a listenergetName()public final boolean contains(LinguisticTerm linguisticTerm)
linguisticTerm is part of this
linguistic variable.
linguisticTerm - The linguistic term to check
true if the linguisticTerm is part
of this linguistic variable, false otherwise.setLinguisticTerms(LinguisticTerm[])public final void addVetoableChangeListener(VetoableChangeListener listener)
VetoableChangeListener to the listener list. The
listener is registered for all properties.
listener - the VetoableChangeListener to be addedpublic final void removeVetoableChangeListener(VetoableChangeListener listener)
VetoableChangeListener from the listener list.
This removes a VetoableChangeListener that was registered
for all properties.
listener - the VetoableChangeListener to be removedpublic 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 withTerms)
withTerms - true if all linguistic term definitions are also returned,
false otherwise.
LinguisticTerm.toString()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||