public abstract class AbstractVPDAlphabet<I> extends AbstractAlphabet<I> implements VPDAlphabet<I>
VPDAlphabet.SymbolTypemodCount| Constructor and Description |
|---|
AbstractVPDAlphabet(Alphabet<I> internalAlphabet,
Alphabet<I> callAlphabet,
Alphabet<I> returnAlphabet) |
| Modifier and Type | Method and Description |
|---|---|
boolean |
containsSymbol(I symbol)
Checks whether the given symbol is part of the alphabet.
|
Alphabet<I> |
getCallAlphabet() |
I |
getCallSymbol(int index)
The
Alphabet.getSymbol(int) variant for the call alphabet. |
int |
getCallSymbolIndex(I symbol)
The
Alphabet.getSymbolIndex(Object) variant for the call alphabet. |
Alphabet<I> |
getInternalAlphabet() |
I |
getInternalSymbol(int index)
The
Alphabet.getSymbol(int) variant for the internal alphabet. |
int |
getInternalSymbolIndex(I symbol)
The
Alphabet.getSymbolIndex(Object) variant for the internal alphabet. |
int |
getNumCalls() |
int |
getNumInternals() |
int |
getNumReturns() |
Alphabet<I> |
getReturnAlphabet() |
I |
getReturnSymbol(int index)
The
Alphabet.getSymbol(int) variant for the return alphabet. |
int |
getReturnSymbolIndex(I symbol)
The
Alphabet.getSymbolIndex(Object) variant for the return alphabet. |
I |
getSymbol(int index)
Returns the symbol with the given index in this alphabet.
|
int |
getSymbolIndex(I symbol)
Returns the index of the given symbol in the alphabet.
|
VPDAlphabet.SymbolType |
getSymbolType(I symbol)
Returns the
symbol type of the given alphabet symbol. |
int |
size()
The size of this container.
|
getadd, add, addAll, clear, equals, hashCode, indexOf, iterator, lastIndexOf, listIterator, listIterator, remove, removeRange, set, subListaddAll, contains, containsAll, isEmpty, remove, removeAll, retainAll, toArray, toArray, toStringclone, equals, finalize, getClass, notify, notifyAll, wait, wait, waitcallReturnBalance, isCallMatched, isCallSymbol, isInternalSymbol, isReturnMatched, isReturnSymbol, isWellMatched, longestWellMatchedPrefix, longestWellMatchedSuffixapply, applyAsInt, compare, translateFrom, writeToArrayadd, addAll, clear, contains, containsAll, equals, hashCode, isEmpty, iterator, parallelStream, remove, removeAll, removeIf, retainAll, spliterator, stream, toArray, toArraycomparing, comparing, comparingDouble, comparingInt, comparingLong, equals, naturalOrder, nullsFirst, nullsLast, reversed, reverseOrder, thenComparing, thenComparing, thenComparing, thenComparingDouble, thenComparingInt, thenComparingLongaddAll, contains, containsAll, isEmpty, remove, removeAll, replaceAll, retainAll, sort, spliterator, toArray, toArraypublic Alphabet<I> getCallAlphabet()
getCallAlphabet in interface VPDAlphabet<I>public I getCallSymbol(int index)
VPDAlphabetAlphabet.getSymbol(int) variant for the call alphabet.getCallSymbol in interface VPDAlphabet<I>index - the index of the symbolpublic int getCallSymbolIndex(I symbol)
VPDAlphabetAlphabet.getSymbolIndex(Object) variant for the call alphabet.getCallSymbolIndex in interface VPDAlphabet<I>symbol - the symbol whose index should be determinedpublic int getNumCalls()
getNumCalls in interface VPDAlphabet<I>public Alphabet<I> getInternalAlphabet()
getInternalAlphabet in interface VPDAlphabet<I>public I getInternalSymbol(int index)
VPDAlphabetAlphabet.getSymbol(int) variant for the internal alphabet.getInternalSymbol in interface VPDAlphabet<I>index - the index of the symbolpublic int getInternalSymbolIndex(I symbol)
VPDAlphabetAlphabet.getSymbolIndex(Object) variant for the internal alphabet.getInternalSymbolIndex in interface VPDAlphabet<I>symbol - the symbol whose index should be determinedpublic int getNumInternals()
getNumInternals in interface VPDAlphabet<I>public Alphabet<I> getReturnAlphabet()
getReturnAlphabet in interface VPDAlphabet<I>public I getReturnSymbol(int index)
VPDAlphabetAlphabet.getSymbol(int) variant for the return alphabet.getReturnSymbol in interface VPDAlphabet<I>index - the index of the symbolpublic int getReturnSymbolIndex(I symbol)
VPDAlphabetAlphabet.getSymbolIndex(Object) variant for the return alphabet.getReturnSymbolIndex in interface VPDAlphabet<I>symbol - the symbol whose index should be determinedpublic int getNumReturns()
getNumReturns in interface VPDAlphabet<I>public VPDAlphabet.SymbolType getSymbolType(I symbol)
VPDAlphabetsymbol type of the given alphabet symbol.getSymbolType in interface VPDAlphabet<I>symbol - the symbol whose type should be returnedsymbol type of the given alphabet symbol.public int size()
ArrayWritablesize in interface Collection<I>size in interface List<I>size in interface ArrayWritable<I>size in class AbstractCollection<I>public I getSymbol(int index)
Alphabetpublic int getSymbolIndex(I symbol)
AlphabetgetSymbolIndex in interface Alphabet<I>symbol - the symbol whose index should be determinedpublic boolean containsSymbol(I symbol)
AlphabetCaution: the default implementation is rather inefficient and should be overridden, if possible.
containsSymbol in interface Alphabet<I>symbol - the symbol to checktrue iff the symbol is part of the alphabetCopyright © 2020. All rights reserved.