com.agentfactory.logic.reasoner
Interface Queryable

All Known Implementing Classes:
QueryEngine.TestQuerySource

public interface Queryable

This interface specifies all methods required by a Knowledge Source (i.e. a database that contains items that can be queried, such as beliefs, goals, desires, ...).


Method Summary
 boolean hasType(java.lang.String type)
          Check whether the KS supports the specified type of item
 java.util.List query(FOS query)
          Query the KS for items that match the specified query.
 

Method Detail

hasType

boolean hasType(java.lang.String type)
Check whether the KS supports the specified type of item

Parameters:
type - the type of KS being searched for
Returns:
true if the KS holds items of that type, false otherwise

query

java.util.List query(FOS query)
Query the KS for items that match the specified query. This method assumes that the has Type method has been invoked prior to its invocation.

Parameters:
query - the item being searched for
Returns:
a list of matching items.