|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.sun.labs.minion.classification.WeightedFeatureCluster
public class WeightedFeatureCluster
| Field Summary |
|---|
| Fields inherited from interface com.sun.labs.minion.classification.FeatureCluster |
|---|
weightComparator |
| Constructor Summary | |
|---|---|
WeightedFeatureCluster()
|
|
| Method Summary | |
|---|---|
void |
add(Feature f)
Adds a feature to this feature cluster |
int |
compareTo(FeatureCluster o)
|
FeatureCluster |
copy()
Return a copy of this feature cluster |
Feature |
get(int id)
Gets the feature with the given id out of this cluster. |
Feature |
get(java.lang.String name)
Gets the feature with the given name out of this cluster. |
java.util.SortedSet |
getContents()
Returns a set of features that are the contents of this cluster |
java.lang.String |
getHumanReadableName()
Gets a human-readable (for example, non-stemmed) name for this cluster. |
java.lang.String |
getName()
Gets the name of this feature cluster. |
float |
getWeight()
Gets the weight associated with this feature cluster |
java.util.Iterator<Feature> |
iterator()
Gets an iterator for the contents of this cluster. |
void |
merge(FeatureCluster other)
Merge another feature cluster into this one, preventing duplicates. |
void |
setName(java.lang.String name)
Sets the name of this feature cluster. |
void |
setWeight(float weight)
Sets the weight associated with this feature cluster |
int |
size()
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public WeightedFeatureCluster()
| Method Detail |
|---|
public java.lang.String getName()
FeatureCluster
getName in interface FeatureClusterpublic java.lang.String getHumanReadableName()
FeatureCluster
getHumanReadableName in interface FeatureClusterpublic void setName(java.lang.String name)
FeatureCluster
setName in interface FeatureClustername - the namepublic java.util.SortedSet getContents()
FeatureCluster
getContents in interface FeatureClusterpublic float getWeight()
FeatureCluster
getWeight in interface FeatureClusterpublic void setWeight(float weight)
FeatureCluster
setWeight in interface FeatureClusterweight - the new weightpublic Feature get(java.lang.String name)
FeatureCluster
get in interface FeatureClustername - the feature name
public Feature get(int id)
FeatureCluster
get in interface FeatureClusterid - the feature id
public java.util.Iterator<Feature> iterator()
FeatureCluster
iterator in interface FeatureClusteriterator in interface java.lang.Iterable<Feature>public void add(Feature f)
FeatureCluster
add in interface FeatureClusterf - the feature to addpublic FeatureCluster copy()
FeatureCluster
copy in interface FeatureClusterpublic void merge(FeatureCluster other)
FeatureCluster
merge in interface FeatureClusterother - the other clusterpublic int size()
size in interface FeatureClusterpublic int compareTo(FeatureCluster o)
compareTo in interface java.lang.Comparable<FeatureCluster>
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||