public class Item
extends java.lang.Object
implements java.lang.Comparable
It represents an item throughout the execution of the algorithm
Constructor and Description |
---|
Item()
Default constructor
|
Item(int idAttr,
int idLabel)
It creates a new item by setting up its parameters
|
Modifier and Type | Method and Description |
---|---|
Item |
clone()
It allows to clone correctly an item
|
int |
compareTo(java.lang.Object item)
It compares an item with another one in order to accomplish ordering later.
|
boolean |
equals(java.lang.Object obj)
It indicates whether some other item is "equal to" this one
|
int |
getIDAttribute()
It returns the ID of the attribute involved in the item
|
int |
getIDLabel()
It returns the ID of the label involved in the item
|
void |
setIDAttribute(int idAttr)
Set the ID of the attribute involved in the item
|
java.lang.String |
toString()
It returns a raw string representation of an item
|
public Item()
Default constructor
public Item(int idAttr, int idLabel)
It creates a new item by setting up its parameters
idAttr
- The ID of the attribute which the item representsidLabel
- The ID of the label representing the involved fuzzy regionpublic int getIDAttribute()
It returns the ID of the attribute involved in the item
public void setIDAttribute(int idAttr)
Set the ID of the attribute involved in the item
idAttr
- Attribute id given.public int getIDLabel()
It returns the ID of the label involved in the item
public Item clone()
It allows to clone correctly an item
clone
in class java.lang.Object
public boolean equals(java.lang.Object obj)
It indicates whether some other item is "equal to" this one
equals
in class java.lang.Object
obj
- The reference object with which to comparepublic int compareTo(java.lang.Object item)
It compares an item with another one in order to accomplish ordering later.
compareTo
in interface java.lang.Comparable
item
- The object to be comparedpublic java.lang.String toString()
It returns a raw string representation of an item
toString
in class java.lang.Object