vortex-proto 0.69.0

Protocol buffer definitions for Vortex types
Documentation
// This file is @generated by prost-build.
/// Captures a generic representation of expressions in Vortex.
/// Expression deserializers can be registered with a Vortex session to handle parsing this into
/// an in-memory expression for execution.
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct Expr {
    #[prost(string, tag = "1")]
    pub id: ::prost::alloc::string::String,
    #[prost(message, repeated, tag = "2")]
    pub children: ::prost::alloc::vec::Vec<Expr>,
    #[prost(bytes = "vec", optional, tag = "3")]
    pub metadata: ::core::option::Option<::prost::alloc::vec::Vec<u8>>,
}
/// Captures a serialized aggregate function with its ID and options metadata.
#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
pub struct AggregateFn {
    #[prost(string, tag = "1")]
    pub id: ::prost::alloc::string::String,
    #[prost(bytes = "vec", optional, tag = "2")]
    pub metadata: ::core::option::Option<::prost::alloc::vec::Vec<u8>>,
}
/// Options for `vortex.literal`
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct LiteralOpts {
    #[prost(message, optional, tag = "1")]
    pub value: ::core::option::Option<super::scalar::Scalar>,
}
/// Options for `vortex.pack`
#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
pub struct PackOpts {
    #[prost(string, repeated, tag = "1")]
    pub paths: ::prost::alloc::vec::Vec<::prost::alloc::string::String>,
    #[prost(bool, tag = "2")]
    pub nullable: bool,
}
/// Options for `vortex.getitem`
#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
pub struct GetItemOpts {
    #[prost(string, tag = "1")]
    pub path: ::prost::alloc::string::String,
}
/// Options for `vortex.binary`
#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
pub struct BinaryOpts {
    #[prost(enumeration = "binary_opts::BinaryOp", tag = "1")]
    pub op: i32,
}
/// Nested message and enum types in `BinaryOpts`.
pub mod binary_opts {
    #[derive(
        Clone,
        Copy,
        Debug,
        PartialEq,
        Eq,
        Hash,
        PartialOrd,
        Ord,
        ::prost::Enumeration
    )]
    #[repr(i32)]
    pub enum BinaryOp {
        Eq = 0,
        NotEq = 1,
        Gt = 2,
        Gte = 3,
        Lt = 4,
        Lte = 5,
        And = 6,
        Or = 7,
        Add = 8,
        Sub = 9,
        Mul = 10,
        Div = 11,
    }
    impl BinaryOp {
        /// String value of the enum field names used in the ProtoBuf definition.
        ///
        /// The values are not transformed in any way and thus are considered stable
        /// (if the ProtoBuf definition does not change) and safe for programmatic use.
        pub fn as_str_name(&self) -> &'static str {
            match self {
                Self::Eq => "Eq",
                Self::NotEq => "NotEq",
                Self::Gt => "Gt",
                Self::Gte => "Gte",
                Self::Lt => "Lt",
                Self::Lte => "Lte",
                Self::And => "And",
                Self::Or => "Or",
                Self::Add => "Add",
                Self::Sub => "Sub",
                Self::Mul => "Mul",
                Self::Div => "Div",
            }
        }
        /// Creates an enum from field names used in the ProtoBuf definition.
        pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
            match value {
                "Eq" => Some(Self::Eq),
                "NotEq" => Some(Self::NotEq),
                "Gt" => Some(Self::Gt),
                "Gte" => Some(Self::Gte),
                "Lt" => Some(Self::Lt),
                "Lte" => Some(Self::Lte),
                "And" => Some(Self::And),
                "Or" => Some(Self::Or),
                "Add" => Some(Self::Add),
                "Sub" => Some(Self::Sub),
                "Mul" => Some(Self::Mul),
                "Div" => Some(Self::Div),
                _ => None,
            }
        }
    }
}
#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
pub struct BetweenOpts {
    #[prost(bool, tag = "1")]
    pub lower_strict: bool,
    #[prost(bool, tag = "2")]
    pub upper_strict: bool,
}
#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
pub struct LikeOpts {
    #[prost(bool, tag = "1")]
    pub negated: bool,
    #[prost(bool, tag = "2")]
    pub case_insensitive: bool,
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct CastOpts {
    #[prost(message, optional, tag = "1")]
    pub target: ::core::option::Option<super::dtype::DType>,
}
#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
pub struct FieldNames {
    #[prost(string, repeated, tag = "1")]
    pub names: ::prost::alloc::vec::Vec<::prost::alloc::string::String>,
}
#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
pub struct SelectOpts {
    #[prost(oneof = "select_opts::Opts", tags = "1, 2")]
    pub opts: ::core::option::Option<select_opts::Opts>,
}
/// Nested message and enum types in `SelectOpts`.
pub mod select_opts {
    #[derive(Clone, PartialEq, Eq, Hash, ::prost::Oneof)]
    pub enum Opts {
        #[prost(message, tag = "1")]
        Include(super::FieldNames),
        #[prost(message, tag = "2")]
        Exclude(super::FieldNames),
    }
}
/// Options for `vortex.case_when`
/// Encodes num_when_then_pairs and has_else into a single u32 (num_children).
/// num_children = num_when_then_pairs * 2 + (has_else ? 1 : 0)
/// has_else = num_children % 2 == 1
/// num_when_then_pairs = num_children / 2
#[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
pub struct CaseWhenOpts {
    #[prost(uint32, tag = "1")]
    pub num_children: u32,
}