|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectreasoner.KnowledgeBase
public class KnowledgeBase
This class represents a knowledge base as a container of Concepts, ConcreteConcepts, Individuals, ULineEvents, Roles, Quantifiers and one Query
Field Summary | |
---|---|
private java.util.HashMap<java.lang.String,Concept> |
concepts
The Concept map |
private java.util.HashMap<java.lang.String,ConcreteConcept> |
concrConcepts
The ConcreteConcept map |
private java.util.HashMap<java.lang.String,Individual> |
individuals
The Individual map |
private double |
NOW
The constant NOW |
private java.util.HashMap<java.lang.String,Quantifier> |
quantifiers
The Quantifier map |
private Query |
query
The Query |
private java.util.HashMap<java.lang.String,Role> |
roles
The role map |
private double |
SELF
The constant SELF |
private java.util.HashMap<java.lang.String,ULineEvent> |
uLineEvents
The ULineEvent map |
Constructor Summary | |
---|---|
KnowledgeBase()
Constructor for a new empty Knowledge Base as a container of empty HashMaps of Concepts, ConcreteConcepts, Individuals, ULineEvents, Roles and Quantifiers and with a null Query |
|
KnowledgeBase(java.util.HashMap<java.lang.String,Concept> concepts,
java.util.HashMap<java.lang.String,ConcreteConcept> concrConcepts,
java.util.HashMap<java.lang.String,Individual> individuals,
java.util.HashMap<java.lang.String,ULineEvent> uLineEvents,
java.util.HashMap<java.lang.String,Role> roles,
java.util.HashMap<java.lang.String,Quantifier> quantifiers)
Constructor for a new Knowledge Base from given HashMaps of elements |
|
KnowledgeBase(java.util.HashMap<java.lang.String,Concept> concepts,
java.util.HashMap<java.lang.String,ConcreteConcept> concrConcepts,
java.util.HashMap<java.lang.String,Individual> individuals,
java.util.HashMap<java.lang.String,ULineEvent> uLineEvents,
java.util.HashMap<java.lang.String,Role> roles,
java.util.HashMap<java.lang.String,Quantifier> quantifiers,
Query query)
Constructor for a new Knowledge Base from given HashMaps of elements |
Method Summary | |
---|---|
void |
addConcept(Concept c)
Adds a Concept to this KB |
void |
addConcreteConcept(ConcreteConcept tc)
Adds a ConcreteConcept to this KB |
void |
addIndividual(Individual i)
Adds an Individual to this KB |
void |
addQuantifier(Quantifier q)
Adds a Quantifier to this KB |
void |
addRole(Role r)
Adds a Role to this KB |
void |
addULineEv(ULineEvent ul)
Adds an ULineEvent to this KB |
void |
clear()
Clears all the maps in this KB |
java.util.HashMap<java.lang.String,Concept> |
getConcepts()
|
java.util.HashMap<java.lang.String,ConcreteConcept> |
getConcrConcepts()
|
java.util.HashMap<java.lang.String,Individual> |
getIndividuals()
|
double |
getNOW()
|
java.util.HashMap<java.lang.String,Quantifier> |
getQuantifiers()
|
Query |
getQuery()
|
java.util.HashMap<java.lang.String,Role> |
getRoles()
|
double |
getSELF()
|
java.util.Set<java.lang.Double> |
getTimeSet()
Gives the total time set |
java.util.HashMap<java.lang.String,ULineEvent> |
getULineEvents()
|
void |
setConcepts(java.util.HashMap<java.lang.String,Concept> concepts)
|
void |
setConcrConcepts(java.util.HashMap<java.lang.String,ConcreteConcept> concrConcepts)
sets the HashMap of ConcreteConcepts |
void |
setIndividuals(java.util.HashMap<java.lang.String,Individual> individuals)
|
void |
setQuantifiers(java.util.HashMap<java.lang.String,Quantifier> quantifiers)
|
void |
setQuery(Query query)
|
void |
setRoles(java.util.HashMap<java.lang.String,Role> roles)
|
void |
setULineEvents(java.util.HashMap<java.lang.String,ULineEvent> uLineEvents)
|
java.lang.String |
toString()
Gives a String representation for this KB |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
private java.util.HashMap<java.lang.String,Concept> concepts
private java.util.HashMap<java.lang.String,ConcreteConcept> concrConcepts
private java.util.HashMap<java.lang.String,Individual> individuals
private java.util.HashMap<java.lang.String,ULineEvent> uLineEvents
private java.util.HashMap<java.lang.String,Role> roles
private java.util.HashMap<java.lang.String,Quantifier> quantifiers
private Query query
private final double NOW
private final double SELF
Constructor Detail |
---|
public KnowledgeBase()
public KnowledgeBase(java.util.HashMap<java.lang.String,Concept> concepts, java.util.HashMap<java.lang.String,ConcreteConcept> concrConcepts, java.util.HashMap<java.lang.String,Individual> individuals, java.util.HashMap<java.lang.String,ULineEvent> uLineEvents, java.util.HashMap<java.lang.String,Role> roles, java.util.HashMap<java.lang.String,Quantifier> quantifiers)
concepts
- the HashMap of Concept names and ConceptsconcrConcepts
- the HashMap of ConcreteConcept names and ConcreteConceptsindividuals
- the HashMap of Individual names and IndividualsuLineEvents
- the HashMap of ULineEvent names and ULineEventsroles
- the HashMap of Role names and Rolesquantifiers
- the HashMap of Quantifier names and Quantifierspublic KnowledgeBase(java.util.HashMap<java.lang.String,Concept> concepts, java.util.HashMap<java.lang.String,ConcreteConcept> concrConcepts, java.util.HashMap<java.lang.String,Individual> individuals, java.util.HashMap<java.lang.String,ULineEvent> uLineEvents, java.util.HashMap<java.lang.String,Role> roles, java.util.HashMap<java.lang.String,Quantifier> quantifiers, Query query)
concepts
- the HashMap of Concept names and ConceptsconcrConcepts
- the HashMap of ConcreteConcept names and ConcreteConceptsindividuals
- the HashMap of Individual names and IndividualsuLineEvents
- the HashMap of ULineEvent names and ULineEventsroles
- the HashMap of Role names and Rolesquantifiers
- the HashMap of Quantifier names and Quantifiersquery
- the given QueryMethod Detail |
---|
public java.util.Set<java.lang.Double> getTimeSet()
public void addRole(Role r)
r
- the Rolepublic void addQuantifier(Quantifier q)
q
- the Quantifierpublic void addConcept(Concept c)
c
- the concept to addpublic void addULineEv(ULineEvent ul)
ul
- the ULineEvent to addpublic void addIndividual(Individual i)
i
- the Individual to addpublic void addConcreteConcept(ConcreteConcept tc)
tc
- the ConcreteConceptpublic java.util.HashMap<java.lang.String,Quantifier> getQuantifiers()
public void setQuantifiers(java.util.HashMap<java.lang.String,Quantifier> quantifiers)
quantifiers
- the HashMap of Quantifiers to setpublic java.util.HashMap<java.lang.String,Concept> getConcepts()
public void setConcepts(java.util.HashMap<java.lang.String,Concept> concepts)
concepts
- the HashMap of Concepts to setpublic java.util.HashMap<java.lang.String,Role> getRoles()
public void setRoles(java.util.HashMap<java.lang.String,Role> roles)
roles
- the HashMap of Roles to setpublic java.util.HashMap<java.lang.String,ULineEvent> getULineEvents()
public void setULineEvents(java.util.HashMap<java.lang.String,ULineEvent> uLineEvents)
uLineEvents
- the HashMap of uLineEvents to set in this KBpublic java.util.HashMap<java.lang.String,ConcreteConcept> getConcrConcepts()
public void setConcrConcepts(java.util.HashMap<java.lang.String,ConcreteConcept> concrConcepts)
concrConcepts
- the HashMap of concrConceptspublic java.util.HashMap<java.lang.String,Individual> getIndividuals()
public void setIndividuals(java.util.HashMap<java.lang.String,Individual> individuals)
individuals
- the HashMap of Individuals to setpublic Query getQuery()
public void setQuery(Query query)
query
- the Query to setpublic double getNOW()
public double getSELF()
public void clear()
public 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 |