Package de.learnlib.filter.cache.sul
Class ThreadSafeSULCaches
- java.lang.Object
-
- de.learnlib.filter.cache.sul.ThreadSafeSULCaches
-
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static <I,O>
ThreadSafeSULCache<I,O>createCache(Alphabet<I> alphabet, SUL<I,O> sul)
static <I,O>
ThreadSafeSULCache<I,O>createDAGCache(Alphabet<I> alphabet, SUL<I,O> sul)
static <I,O>
ThreadSafeStateLocalInputSULCache<I,O>createStateLocalInputCache(Alphabet<I> alphabet, StateLocalInputSUL<I,O> sul)
Wraps a givenStateLocalInputSUL
in a thread-safe variant of aStateLocalInputSULCache
that supportsforking
iff the givenSUL
supports it.static <I,O>
ThreadSafeStateLocalInputSULCache<I,O>createStateLocalInputTreeCache(Alphabet<I> alphabet, StateLocalInputSUL<I,O> sul)
Wraps a givenStateLocalInputSUL
in a thread-safe variant of aStateLocalInputSULCache
that supportsforking
iff the givenSUL
supports it and uses a tree for internal cache organization.static <I,O>
ThreadSafeSULCache<I,O>createTreeCache(Alphabet<I> alphabet, SUL<I,O> sul)
-
-
-
Method Detail
-
createCache
public static <I,O> ThreadSafeSULCache<I,O> createCache(Alphabet<I> alphabet, SUL<I,O> sul)
Wraps a givenSUL
in a thread-safe variant of aSULCache
that supportsforking
iff the givenSUL
supports it.Note that this method does not specify the implementation to use for the cache. Currently, a DAG (
createDAGCache(Alphabet, SUL)
) is used; however, this may change in the future.- Type Parameters:
I
- input symbol typeO
- output symbol type- Parameters:
alphabet
- the alphabet containing the symbols of possible queriessul
- the supplier that is used as a delegate, in case of a cache-miss.- Returns:
- a
ThreadSafeSULCache
.
-
createDAGCache
public static <I,O> ThreadSafeSULCache<I,O> createDAGCache(Alphabet<I> alphabet, SUL<I,O> sul)
Wraps a givenSUL
in a thread-safe variant of aSULCache
that supportsforking
iff the givenSUL
supports it and uses a DAG for internal cache organization.- Type Parameters:
I
- input symbol typeO
- output symbol type- Parameters:
alphabet
- the alphabet containing the symbols of possible queriessul
- the supplier that is used as a delegate, in case of a cache-miss.- Returns:
- a
ThreadSafeSULCache
. - See Also:
IncrementalMealyDAGBuilder
-
createTreeCache
public static <I,O> ThreadSafeSULCache<I,O> createTreeCache(Alphabet<I> alphabet, SUL<I,O> sul)
Wraps a givenSUL
in a thread-safe variant of aSULCache
that supportsforking
iff the givenSUL
supports it and uses a tree for internal cache organization.- Type Parameters:
I
- input symbol typeO
- output symbol type- Parameters:
alphabet
- the alphabet containing the symbols of possible queriessul
- the supplier that is used as a delegate, in case of a cache-miss.- Returns:
- a
ThreadSafeSULCache
. - See Also:
IncrementalMealyTreeBuilder
-
createStateLocalInputCache
public static <I,O> ThreadSafeStateLocalInputSULCache<I,O> createStateLocalInputCache(Alphabet<I> alphabet, StateLocalInputSUL<I,O> sul)
Wraps a givenStateLocalInputSUL
in a thread-safe variant of aStateLocalInputSULCache
that supportsforking
iff the givenSUL
supports it.Note that this method does not specify the implementation to use for the cache. Currently, a tree (
createStateLocalInputTreeCache(Alphabet, StateLocalInputSUL)
) is used; however, this may change in the future.- Type Parameters:
I
- input symbol typeO
- output symbol type- Parameters:
alphabet
- the alphabet containing the symbols of possible queriessul
- the supplier that is used as a delegate, in case of a cache-miss.- Returns:
- a
ThreadSafeSULCache
.
-
createStateLocalInputTreeCache
public static <I,O> ThreadSafeStateLocalInputSULCache<I,O> createStateLocalInputTreeCache(Alphabet<I> alphabet, StateLocalInputSUL<I,O> sul)
Wraps a givenStateLocalInputSUL
in a thread-safe variant of aStateLocalInputSULCache
that supportsforking
iff the givenSUL
supports it and uses a tree for internal cache organization.- Type Parameters:
I
- input symbol typeO
- output symbol type- Parameters:
alphabet
- the alphabet containing the symbols of possible queriessul
- the supplier that is used as a delegate, in case of a cache-miss.- Returns:
- a
ThreadSafeStateLocalInputSULCache
. - See Also:
IncrementalMealyTreeBuilder
-
-