Struct datafusion::execution::context::TaskContext
source · pub struct TaskContext { /* private fields */ }
Expand description
Task Execution Context
Implementations§
source§impl TaskContext
impl TaskContext
sourcepub fn try_new(
task_id: String,
session_id: String,
task_props: HashMap<String, String>,
scalar_functions: HashMap<String, Arc<ScalarUDF>>,
aggregate_functions: HashMap<String, Arc<AggregateUDF>>,
runtime: Arc<RuntimeEnv>,
extensions: Extensions
) -> Result<Self>
pub fn try_new( task_id: String, session_id: String, task_props: HashMap<String, String>, scalar_functions: HashMap<String, Arc<ScalarUDF>>, aggregate_functions: HashMap<String, Arc<AggregateUDF>>, runtime: Arc<RuntimeEnv>, extensions: Extensions ) -> Result<Self>
Create a new task context instance
sourcepub fn session_config(&self) -> &SessionConfig
pub fn session_config(&self) -> &SessionConfig
Return the SessionConfig associated with the Task
sourcepub fn session_id(&self) -> String
pub fn session_id(&self) -> String
Return the session_id
of this TaskContext
sourcepub fn task_id(&self) -> Option<String>
pub fn task_id(&self) -> Option<String>
Return the task_id
of this TaskContext
sourcepub fn memory_pool(&self) -> &Arc<dyn MemoryPool>
pub fn memory_pool(&self) -> &Arc<dyn MemoryPool>
Return the MemoryPool
associated with this TaskContext
sourcepub fn runtime_env(&self) -> Arc<RuntimeEnv>
pub fn runtime_env(&self) -> Arc<RuntimeEnv>
Return the RuntimeEnv associated with this TaskContext
Trait Implementations§
source§impl From<&SessionContext> for TaskContext
impl From<&SessionContext> for TaskContext
Create a new task context instance from SessionContext
source§fn from(session: &SessionContext) -> Self
fn from(session: &SessionContext) -> Self
Converts to this type from the input type.
source§impl From<&SessionState> for TaskContext
impl From<&SessionState> for TaskContext
Create a new task context instance from SessionState
source§fn from(state: &SessionState) -> Self
fn from(state: &SessionState) -> Self
Converts to this type from the input type.