vortex_array/execution/mod.rs
1// SPDX-License-Identifier: Apache-2.0
2// SPDX-FileCopyrightText: Copyright the Vortex contributors
3
4mod batch;
5mod mask;
6mod validity;
7
8pub use batch::*;
9pub use mask::*;
10use vortex_session::VortexSession;
11
12/// Execution context for batch array compute.
13// NOTE(ngates): This context will eventually hold cached resources for execution, such as CSE
14// nodes, and may well eventually support a type-map interface for arrays to stash arbitrary
15// execution-related data.
16pub struct ExecutionCtx {
17 session: VortexSession,
18}
19
20impl ExecutionCtx {
21 /// Create a new execution context with the given session.
22 pub(crate) fn new(session: VortexSession) -> Self {
23 Self { session }
24 }
25
26 /// Get the session associated with this execution context.
27 pub fn session(&self) -> &VortexSession {
28 &self.session
29 }
30}