-
- All Superinterfaces:
BatchProcessor<Query<I,D>>
,QueryAnswerer<I,D>
- All Known Subinterfaces:
LearningCacheOracle<A,I,D>
,LearningCacheOracle.DFALearningCacheOracle<I>
,LearningCacheOracle.MealyLearningCacheOracle<I,O>
,LearningCacheOracle.MooreLearningCacheOracle<I,O>
,MembershipOracle.DFAMembershipOracle<I>
,MembershipOracle.MealyMembershipOracle<I,O>
,MembershipOracle.MooreMembershipOracle<I,O>
,ParallelOracle<I,D>
,SingleQueryOracle<I,D>
,SingleQueryOracle.SingleQueryOracleDFA<I>
,SingleQueryOracle.SingleQueryOracleMealy<I,O>
,SingleQueryOracle.SingleQueryOracleMoore<I,O>
,StatisticOracle<I,D>
- All Known Implementing Classes:
CounterOracle
,DFACacheOracle
,DFACounterOracle
,DFAHashCacheOracle
,DFAHistogramOracle
,DFASimulatorOracle
,DynamicParallelOracle
,HistogramOracle
,InterningMealyMembershipOracle
,InterningMembershipOracle
,InterningMooreMembershipOracle
,MappedOracle
,MealyCacheOracle
,MealyCounterOracle
,MealyHistogramOracle
,MealySimulatorOracle
,MooreCacheOracle
,MooreCounterOracle
,MooreHistogramOracle
,MooreSimulatorOracle
,NFASimulatorOracle
,ReuseOracle
,SBASimulatorOracle
,SEVPASimulatorOracle
,SimulatorOracle
,SPASimulatorOracle
,SPMMSimulatorOracle
,StateLocalInputSULOracle
,StaticParallelOracle
,SULOracle
,ThreadSafeDFACacheOracle
,ThreadSafeMealyCacheOracle
,ThreadSafeMooreCacheOracle
public interface MembershipOracle<I,D> extends QueryAnswerer<I,D>, BatchProcessor<Query<I,D>>
Membership oracle interface. A membership oracle provides an elementary abstraction to a System Under Learning (SUL), by allowing to posequeries
: A query is a sequence of input symbols (divided into a prefix and a suffix part, cf.Query.getPrefix()
andQuery.getSuffix()
) in reaction to which the SUL produces a specific observable behavior (outputting a word, acceptance/rejection etc.).- See Also:
DefaultQuery
-
-
Nested Class Summary
Nested Classes Modifier and Type Interface Description static interface
MembershipOracle.DFAMembershipOracle<I>
A specialization of theMembershipOracle
that binds the output domain toBoolean
s.static interface
MembershipOracle.MealyMembershipOracle<I,O>
A specialization of theMembershipOracle
that binds the output domain toWord
s of the specified output type.static interface
MembershipOracle.MooreMembershipOracle<I,O>
A specialization of theMembershipOracle
that binds the output domain toWord
s of the specified output type.
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description default D
answerQuery(net.automatalib.word.Word<I> input)
default D
answerQuery(net.automatalib.word.Word<I> prefix, net.automatalib.word.Word<I> suffix)
default MembershipOracle<I,D>
asOracle()
default void
processBatch(Collection<? extends Query<I,D>> batch)
Process the batch.void
processQueries(Collection<? extends Query<I,D>> queries)
Processes the specified collection of queries.default void
processQuery(Query<I,D> query)
Processes a single query.
-
-
-
Method Detail
-
answerQuery
default D answerQuery(net.automatalib.word.Word<I> input)
- Specified by:
answerQuery
in interfaceQueryAnswerer<I,D>
-
answerQuery
default D answerQuery(net.automatalib.word.Word<I> prefix, net.automatalib.word.Word<I> suffix)
- Specified by:
answerQuery
in interfaceQueryAnswerer<I,D>
-
processQuery
default void processQuery(Query<I,D> query)
Processes 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
Query
in a singletonCollection
usingCollections.singleton(Object)
. Implementations in subclasses should override this method to circumvent the Collection object creation, if possible.- Parameters:
query
- the query to process
-
processQueries
void processQueries(Collection<? extends Query<I,D>> queries)
Processes 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.- Parameters:
queries
- the queries to process- See Also:
Query.answer(Object)
-
asOracle
default MembershipOracle<I,D> asOracle()
- Specified by:
asOracle
in interfaceQueryAnswerer<I,D>
-
processBatch
default void processBatch(Collection<? extends Query<I,D>> batch)
Description copied from interface:BatchProcessor
Process the batch.- Specified by:
processBatch
in interfaceBatchProcessor<I>
- Parameters:
batch
- the batch to process
-
-