MCPcopy Create free account
hub / github.com/apache/datafusion / downcast_ref

Method downcast_ref

datafusion/catalog/src/table.rs:398–400  ·  view source on GitHub ↗

Attempts to downcast this table provider to a concrete type `T`, returning `None` if the provider is not of that type. Works correctly when called on `Arc ` via auto-deref, unlike `(&arc as &dyn Any).downcast_ref:: ()` which would attempt to downcast the `Arc` itself.

(&self)

Source from the content-addressed store, hash-verified

396 /// unlike `(&arc as &dyn Any).downcast_ref::<T>()` which would attempt to
397 /// downcast the `Arc` itself.
398 pub fn downcast_ref<T: TableProvider>(&self) -> Option<&T> {
399 (self as &dyn Any).downcast_ref()
400 }
401}
402
403/// Arguments for scanning a table with [`TableProvider::scan_with_args`].

Callers 4

getMethod · 0.45
downcast_array_helperMethod · 0.45

Calls

no outgoing calls

Tested by

no test coverage detected