|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.ObjectfleXplorer.Terms.CompoundTerm
public class CompoundTerm
Constructor Summary | |
---|---|
CompoundTerm(int id,
FT ft)
Constructs a compound term with a specific id and defines the faceted taxonomy which belong the terms of the compound term. |
Method Summary | |
---|---|
boolean |
addTerm(java.lang.String facet,
int termId)
Adds a term to the compound term. |
boolean |
containsFacet(java.lang.String facet)
Checks if the compound term contains a term of a specific facet. |
boolean |
containsTerm(java.lang.String facet,
int termId)
Checks if compound term contains a specific term of a facet. |
java.util.HashMap<java.lang.String,java.util.ArrayList<java.lang.Integer>> |
getAllTerms()
Returns all terms. |
java.util.ArrayList<java.lang.String> |
getFacets()
Returns the names of facets that compound term contains terms. |
FT |
getFT()
Returns the faceted taxonomy that compound term belongs. |
int |
getId()
Returns the id of the compound term. |
int |
getSize()
Returns the number of the terms. |
java.util.ArrayList<java.lang.Integer> |
getTerms(java.lang.String facet)
Returns the ids of the terms of a specific facet. |
boolean |
isNarrowerThan(CompoundTerm s)
Checks if compound term is narrower than an other (subsumption checking). |
boolean |
isSingleton()
Returns true if compound term is singleton; false otherwise. |
void |
removeFacet(java.lang.String facet)
Removes from the compound term all the terms that belong to a specific facet. |
boolean |
removeTerm(java.lang.String facet,
int termId)
Removes a specific term of a facet from the compound term. |
void |
setFT(FT ft)
Sets the faceted taxonomy that compound term will belong. |
void |
setId(int id)
Sets the id of the compound term. |
java.lang.String |
toString()
Returns the String representation of the compound term. |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public CompoundTerm(int id, FT ft)
id
- the id of the compound term.ft
- the faceted taxonomy which belong the terms.Method Detail |
---|
public boolean addTerm(java.lang.String facet, int termId)
facet
- the name of the facet that term bolongs.termId
- the id of the term.
public boolean isSingleton()
public boolean isNarrowerThan(CompoundTerm s)
s
- the compound term
public boolean containsFacet(java.lang.String facet)
facet
- the name of the facet
public boolean containsTerm(java.lang.String facet, int termId)
facet
- the name of the facet.termId
- the id of the term.
public boolean removeTerm(java.lang.String facet, int termId)
facet
- the name of the facet.termId
- the id of the facet.
public void removeFacet(java.lang.String facet)
facet
- the name of the facet.public int getSize()
public java.util.ArrayList<java.lang.Integer> getTerms(java.lang.String facet)
facet
- the name of the facet.
public java.util.HashMap<java.lang.String,java.util.ArrayList<java.lang.Integer>> getAllTerms()
public java.util.ArrayList<java.lang.String> getFacets()
public int getId()
public void setId(int id)
id
- the id of the compound term.public FT getFT()
public void setFT(FT ft)
ft
- the faceted taxonomypublic java.lang.String toString()
toString
in class java.lang.Object
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |