Class BaseKeyExpression
- java.lang.Object
-
- com.apple.foundationdb.record.metadata.expressions.BaseKeyExpression
-
- All Implemented Interfaces:
KeyExpression
,PlanHashable
- Direct Known Subclasses:
ElementKeyExpression
,EmptyKeyExpression
,FieldKeyExpression
,FunctionKeyExpression
,GroupingKeyExpression
,KeyWithValueExpression
,ListKeyExpression
,LiteralKeyExpression
,NestingKeyExpression
,RecordTypeKeyExpression
,SplitKeyExpression
,ThenKeyExpression
,VersionKeyExpression
@API(MAINTAINED) public abstract class BaseKeyExpression extends Object implements KeyExpression
Base class to provide some common logic shared between most expression implementations.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
BaseKeyExpression.IllegalSubKeyException
An exception that is thrown whengetSubKey(int, int)
is used incorrectly.static class
BaseKeyExpression.UnsplittableKeyExpressionException
An exception indicating that the key expression is not splittable.-
Nested classes/interfaces inherited from interface com.apple.foundationdb.record.metadata.expressions.KeyExpression
KeyExpression.DeserializationException, KeyExpression.FanType, KeyExpression.InvalidExpressionException, KeyExpression.InvalidResultException, KeyExpression.NoSuchArgumentException, KeyExpression.SerializationException
-
-
Constructor Summary
Constructors Constructor Description BaseKeyExpression()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description KeyExpression
getSubKey(int start, int end)
Returns a sub-set of the key expression.protected KeyExpression
getSubKeyImpl(int start, int end)
boolean
isPrefixKey(KeyExpression key)
Check whether a key is a prefix of another key.-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface com.apple.foundationdb.record.metadata.expressions.KeyExpression
createsDuplicates, evaluate, evaluateMessage, evaluateSingleton, flattenForPlanner, getColumnSize, hasProperInterfaces, hasRecordTypeKey, normalizeForPlanner, normalizeKeyForPositions, toKeyExpression, toProto, validate, versionColumns
-
Methods inherited from interface com.apple.foundationdb.record.PlanHashable
planHash
-
-
-
-
Method Detail
-
getSubKey
@Nonnull public final KeyExpression getSubKey(int start, int end)
Description copied from interface:KeyExpression
Returns a sub-set of the key expression.- Specified by:
getSubKey
in interfaceKeyExpression
- Parameters:
start
- starting positionend
- ending position- Returns:
- a key expression for the subkey between
start
andend
-
getSubKeyImpl
@Nonnull protected KeyExpression getSubKeyImpl(int start, int end)
-
isPrefixKey
public boolean isPrefixKey(@Nonnull KeyExpression key)
Description copied from interface:KeyExpression
Check whether a key is a prefix of another key.- Specified by:
isPrefixKey
in interfaceKeyExpression
- Parameters:
key
- the whole key to check- Returns:
true
ifprefix
is a left subset ofkey
-
-