pub struct Definition {
pub extension_id: u64,
pub description: String,
pub actual_uri: String,
pub dependencies: HashMap<String, Reference>,
pub type_classes: NamespaceReference,
pub type_variations: NamespaceReference,
pub function_impls: NamespaceReference,
}Expand description
A parsed simple extension module/file.
Fields§
§extension_id: u64Unique number within the tree that can be used to refer to this extension when exporting in protobuf form.
description: StringDescription of the module.
actual_uri: StringThe URI that was actually used to resolve the module.
dependencies: HashMap<String, Reference>Map with references to dependencies.
type_classes: NamespaceReferenceReference to the namespace in which this module’s type classes were defined. Unlike the type variation and function implementation namespaces, these should never be ambiguous, but we use the same mechanism anyway.
type_variations: NamespaceReferenceReference to the namespace in which this module’s type variations were defined. Note that variations are technically namespaced to the type class they were defined for; however, this would make type variation anchors very poorly defined. Instead, we pretend that they’re all in the same namespace, but allow multiple definitions with the same name within our namespace system. Only when a type variation anchor/reference pair is referred to in the plan and the type class is known do we attempt to solve this ambiguity.
function_impls: NamespaceReferenceReference to the namespace in which this module’s function implementations were defined. Each implementation is mapped twice: once for its simple function name, and once for its compound name. The former will be ambiguous if multiple implementations exist for a function, which we do indeed try to solve for using the type patterns, even though Substrait explicitly disallows referring to a function by its simple name if the function has multiple definitions. Likewise, we also solve this if a compound name is ambigous, again despite Substrait disallowing extensions from creating this situation.
Trait Implementations§
Source§impl Clone for Definition
impl Clone for Definition
Source§fn clone(&self) -> Definition
fn clone(&self) -> Definition
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for Definition
impl Debug for Definition
Source§impl Default for Definition
impl Default for Definition
Source§fn default() -> Definition
fn default() -> Definition
Source§impl Scope for Definition
impl Scope for Definition
Source§fn resolve_type_class<T>(&self, name: T) -> ResolutionResultwhere
T: Into<UnresolvedReference>,
fn resolve_type_class<T>(&self, name: T) -> ResolutionResultwhere
T: Into<UnresolvedReference>,
Resolves a to-be-resolved reference to a type class.
Source§fn resolve_type_variation<T>(&self, name: T) -> ResolutionResultwhere
T: Into<UnresolvedReference>,
fn resolve_type_variation<T>(&self, name: T) -> ResolutionResultwhere
T: Into<UnresolvedReference>,
Resolves a to-be-resolved reference to a type variation.
Source§fn resolve_function<T>(&self, name: T) -> ResolutionResultwhere
T: Into<UnresolvedReference>,
fn resolve_function<T>(&self, name: T) -> ResolutionResultwhere
T: Into<UnresolvedReference>,
Resolves a to-be-resolved reference to a function.
Auto Trait Implementations§
impl Freeze for Definition
impl RefUnwindSafe for Definition
impl Send for Definition
impl Sync for Definition
impl Unpin for Definition
impl UnwindSafe for Definition
Blanket Implementations§
Source§impl<T> AnyExt for T
impl<T> AnyExt for T
Source§fn downcast_ref<T>(this: &Self) -> Option<&T>where
T: Any,
fn downcast_ref<T>(this: &Self) -> Option<&T>where
T: Any,
T behind referenceSource§fn downcast_mut<T>(this: &mut Self) -> Option<&mut T>where
T: Any,
fn downcast_mut<T>(this: &mut Self) -> Option<&mut T>where
T: Any,
T behind mutable referenceSource§fn downcast_rc<T>(this: Rc<Self>) -> Result<Rc<T>, Rc<Self>>where
T: Any,
fn downcast_rc<T>(this: Rc<Self>) -> Result<Rc<T>, Rc<Self>>where
T: Any,
T behind Rc pointerSource§fn downcast_arc<T>(this: Arc<Self>) -> Result<Arc<T>, Arc<Self>>where
T: Any,
fn downcast_arc<T>(this: Arc<Self>) -> Result<Arc<T>, Arc<Self>>where
T: Any,
T behind Arc pointerSource§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T, X> CoerceTo<T> for Xwhere
T: CoerceFrom<X> + ?Sized,
impl<T, X> CoerceTo<T> for Xwhere
T: CoerceFrom<X> + ?Sized,
fn coerce_rc_to(self: Rc<X>) -> Rc<T>
fn coerce_box_to(self: Box<X>) -> Box<T>
fn coerce_ref_to(&self) -> &T
fn coerce_mut_to(&mut self) -> &mut T
Source§impl<T> DynScope for Twhere
T: Scope,
impl<T> DynScope for Twhere
T: Scope,
Source§fn resolve_type_class_from_ref(
&self,
name: Data<Definition>,
) -> ResolutionResult<Definition>
fn resolve_type_class_from_ref( &self, name: Data<Definition>, ) -> ResolutionResult<Definition>
Source§fn resolve_type_variation_from_ref(
&self,
name: Data<Definition>,
) -> ResolutionResult<Definition>
fn resolve_type_variation_from_ref( &self, name: Data<Definition>, ) -> ResolutionResult<Definition>
Source§fn resolve_function_from_ref(
&self,
name: Data<Definition>,
) -> ResolutionResult<Definition>
fn resolve_function_from_ref( &self, name: Data<Definition>, ) -> ResolutionResult<Definition>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more