cx_api/generated/
com.coralogixapis.logs2metrics.v2.rs

1// This file is @generated by prost-build.
2#[derive(serde::Serialize, serde::Deserialize)]
3#[serde(rename_all = "snake_case")]
4#[derive(Clone, PartialEq, ::prost::Message)]
5pub struct LogsQuery {
6    /// lucene query
7    #[prost(message, optional, tag = "1")]
8    pub lucene: ::core::option::Option<::prost::alloc::string::String>,
9    /// alias
10    #[prost(message, optional, tag = "2")]
11    pub alias: ::core::option::Option<::prost::alloc::string::String>,
12    /// application name filters
13    #[prost(message, repeated, tag = "3")]
14    pub applicationname_filters: ::prost::alloc::vec::Vec<
15        ::prost::alloc::string::String,
16    >,
17    /// subsystem names filters
18    #[prost(message, repeated, tag = "4")]
19    pub subsystemname_filters: ::prost::alloc::vec::Vec<::prost::alloc::string::String>,
20    /// severity type filters
21    #[prost(enumeration = "Severity", repeated, tag = "5")]
22    pub severity_filters: ::prost::alloc::vec::Vec<i32>,
23}
24/// enum that represents severity types
25#[derive(serde::Serialize, serde::Deserialize)]
26#[serde(rename_all = "snake_case")]
27#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
28#[repr(i32)]
29pub enum Severity {
30    Unspecified = 0,
31    Debug = 1,
32    Verbose = 2,
33    Info = 3,
34    Warning = 4,
35    Error = 5,
36    Critical = 6,
37}
38impl Severity {
39    /// String value of the enum field names used in the ProtoBuf definition.
40    ///
41    /// The values are not transformed in any way and thus are considered stable
42    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
43    pub fn as_str_name(&self) -> &'static str {
44        match self {
45            Self::Unspecified => "SEVERITY_UNSPECIFIED",
46            Self::Debug => "SEVERITY_DEBUG",
47            Self::Verbose => "SEVERITY_VERBOSE",
48            Self::Info => "SEVERITY_INFO",
49            Self::Warning => "SEVERITY_WARNING",
50            Self::Error => "SEVERITY_ERROR",
51            Self::Critical => "SEVERITY_CRITICAL",
52        }
53    }
54    /// Creates an enum from field names used in the ProtoBuf definition.
55    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
56        match value {
57            "SEVERITY_UNSPECIFIED" => Some(Self::Unspecified),
58            "SEVERITY_DEBUG" => Some(Self::Debug),
59            "SEVERITY_VERBOSE" => Some(Self::Verbose),
60            "SEVERITY_INFO" => Some(Self::Info),
61            "SEVERITY_WARNING" => Some(Self::Warning),
62            "SEVERITY_ERROR" => Some(Self::Error),
63            "SEVERITY_CRITICAL" => Some(Self::Critical),
64            _ => None,
65        }
66    }
67}