Package de.learnlib.oracle
Interface SingleQueryOracle<I,D>
-
- Type Parameters:
I- input symbol typeD- output domain type
- All Superinterfaces:
BatchProcessor<Query<I,D>>,MembershipOracle<I,D>,QueryAnswerer<I,D>
- All Known Subinterfaces:
SingleQueryOracle.SingleQueryOracleDFA<I>,SingleQueryOracle.SingleQueryOracleMealy<I,O>,SingleQueryOracle.SingleQueryOracleMoore<I,O>
public interface SingleQueryOracle<I,D> extends MembershipOracle<I,D>
Base interface for oracles whose semantic is defined in terms of directly answering single queries (like aQueryAnswerer), and that cannot profit from batch processing of queries.Implementing this class instead of directly implementing
MembershipOraclemeans that theanswerQuery(Word, Word)instead of theprocessQueries(Collection)method needs to be implemented.
-
-
Nested Class Summary
Nested Classes Modifier and Type Interface Description static interfaceSingleQueryOracle.SingleQueryOracleDFA<I>static interfaceSingleQueryOracle.SingleQueryOracleMealy<I,O>static interfaceSingleQueryOracle.SingleQueryOracleMoore<I,O>-
Nested classes/interfaces inherited from interface de.learnlib.oracle.MembershipOracle
MembershipOracle.DFAMembershipOracle<I>, MembershipOracle.MealyMembershipOracle<I,O>, MembershipOracle.MooreMembershipOracle<I,O>
-
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description DanswerQuery(Word<I> prefix, Word<I> suffix)default voidprocessQueries(Collection<? extends Query<I,D>> queries)Processes the specified collection of queries.default voidprocessQuery(Query<I,D> query)Processes a single query.-
Methods inherited from interface de.learnlib.oracle.MembershipOracle
answerQuery, asOracle, processBatch
-
-
-
-
Method Detail
-
processQuery
default void processQuery(Query<I,D> query)
Description copied from interface:MembershipOracleProcesses a single query. When this method returns, theQuery.answer(Object)method of the supplied object will have been called with an argument reflecting the SUL response to the respective query.The default implementation of this method will simply wrap the provided
Queryin a singletonCollectionusingCollections.singleton(Object). Implementations in subclasses should override this method to circumvent the Collection object creation, if possible.- Specified by:
processQueryin interfaceMembershipOracle<I,D>- Parameters:
query- the query to process
-
processQueries
default void processQueries(Collection<? extends Query<I,D>> queries)
Description copied from interface:MembershipOracleProcesses the specified collection of queries. When this method returns, each of the contained queriesQuery.answer(Object)method should have been called with an argument reflecting the SUL response to the respective query.- Specified by:
processQueriesin interfaceMembershipOracle<I,D>- Parameters:
queries- the queries to process- See Also:
Query.answer(Object)
-
answerQuery
D answerQuery(Word<I> prefix, Word<I> suffix)
- Specified by:
answerQueryin interfaceMembershipOracle<I,D>- Specified by:
answerQueryin interfaceQueryAnswerer<I,D>
-
-