Package org.rumbledb.types
Class XQueryArrayItemType
java.lang.Object
org.rumbledb.types.XQueryArrayItemType
- All Implemented Interfaces:
com.esotericsoftware.kryo.KryoSerializable,Serializable,ItemType
XQuery/XPath array item type: array(*) and array(T) per XDM 3.1 / XPath 3.1.
The primitive array(*) type is modeled as a subtype of function(*)
by using
BuiltinTypesCatalogue.anyFunctionItem as its base type.- See Also:
-
Method Summary
Modifier and TypeMethodDescriptionbooleanTests for itemType equality.getName()Returns the SparkSQL type of the item type for use in a query.intinthashCode()booleanhasName()Tests for QName.booleanisCompatibleWithDataFrames(RumbleRuntimeConfiguration configuration) Checks compatibility with DataFrames.booleanbooleanisSubtypeOf(ItemType superType) booleanvoidread(com.esotericsoftware.kryo.Kryo kryo, com.esotericsoftware.kryo.io.Input input) voidresolve(DynamicContext context, ExceptionMetadata metadata) voidresolve(StaticContext context, ExceptionMetadata metadata) toString()voidwrite(com.esotericsoftware.kryo.Kryo kryo, com.esotericsoftware.kryo.io.Output output) Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface org.rumbledb.types.ItemType
canBePromotedTo, findLeastCommonSuperTypeLax, getArrayContentFacet, getBoundedFacet, getCardinalityFacet, getCastingPrimitiveType, getClosedFacet, getConstraintsFacet, getEnumerationFacet, getExplicitTimezoneFacet, getFractionDigitsFacet, getLengthFacet, getLexicalSpacePatterns, getMapKeyItemType, getMapValueSequenceType, getMaxExclusiveFacet, getMaxInclusiveFacet, getMaxLengthFacet, getMinExclusiveFacet, getMinInclusiveFacet, getMinLengthFacet, getNumericFacet, getObjectContentFacet, getOrderedFacet, getPatternFacet, getPrimitiveType, getSignature, getTotalDigitsFacet, getTypes, getWhitespaceFacet, isArrayItemType, isAtomicItemType, isCastingPrimitive, isEqualTo, isFunctionItemType, isJsonItemType, isMapItemType, isNodeItemType, isNumeric, isObjectItemType, isPrimitive, isStaticallyCastableAs, isTopmostItemType, isUnionType, isUserDefined
-
Method Details
-
isXQueryArrayItemType
public boolean isXQueryArrayItemType()- Specified by:
isXQueryArrayItemTypein interfaceItemType- Returns:
- true it [this] is an XQuery array item type.
-
equals
Description copied from interface:ItemTypeTests for itemType equality. -
hashCode
public int hashCode() -
isSubtypeOf
- Specified by:
isSubtypeOfin interfaceItemType- Parameters:
superType- another item type- Returns:
- true if [this] is a subtype of [superType], any type is considered a subtype of itself. If [this] has a name, then this is determined strictly based on the hierarchy. If [this] does not have a name, then this is determined based on facets.
-
findLeastCommonSuperTypeWith
- Specified by:
findLeastCommonSuperTypeWithin interfaceItemType- Parameters:
other- another item type- Returns:
- the common supertype between [this] and [other], that would be the LCA in the item type tree of [this] and [other] (does not take into account union types as common ancestor, but only the type tree)
-
write
public void write(com.esotericsoftware.kryo.Kryo kryo, com.esotericsoftware.kryo.io.Output output) - Specified by:
writein interfacecom.esotericsoftware.kryo.KryoSerializable
-
read
public void read(com.esotericsoftware.kryo.Kryo kryo, com.esotericsoftware.kryo.io.Input input) - Specified by:
readin interfacecom.esotericsoftware.kryo.KryoSerializable
-
hasName
public boolean hasName()Description copied from interface:ItemTypeTests for QName. -
getName
-
getTypeTreeDepth
public int getTypeTreeDepth()- Specified by:
getTypeTreeDepthin interfaceItemType- Returns:
- an int representing the depth of the item type in the type tree ('item' is the root with depth 0)
-
getBaseType
- Specified by:
getBaseTypein interfaceItemType- Returns:
- the base type for a type, return null for the topmost item type
-
getMemberSequenceType
- Specified by:
getMemberSequenceTypein interfaceItemType- Returns:
- the sequence type for the members of the array item type
-
resolve
-
resolve
-
isResolved
public boolean isResolved()- Specified by:
isResolvedin interfaceItemType
-
getAllowedFacets
- Specified by:
getAllowedFacetsin interfaceItemType- Returns:
- a set containing the allowed facets for restricting the type
-
getIdentifierString
- Specified by:
getIdentifierStringin interfaceItemType- Returns:
- a String that uniquely identify an item type
-
toString
-
isCompatibleWithDataFrames
Description copied from interface:ItemTypeChecks compatibility with DataFrames.- Specified by:
isCompatibleWithDataFramesin interfaceItemType- Returns:
- true if compatible with DataFrames and false otherwise.
-
getSparkSQLType
Description copied from interface:ItemTypeReturns the SparkSQL type of the item type for use in a query.- Specified by:
getSparkSQLTypein interfaceItemType- Returns:
- String representing the SparkSQL type of the item type.
-