Autogenerated update for cbb7084898...d8f3fd54a6
This commit is contained in:
@@ -151,8 +151,8 @@ pub struct ScriptCreate {
|
||||
pub name: ::prost::alloc::string::String,
|
||||
#[prost(string, tag="2")]
|
||||
pub source: ::prost::alloc::string::String,
|
||||
#[prost(uint32, tag="3")]
|
||||
pub resource_type: u32,
|
||||
#[prost(enumeration="ResourceType", tag="3")]
|
||||
pub resource_type: i32,
|
||||
#[prost(uint64, optional, tag="4")]
|
||||
pub resource_id: ::core::option::Option<u64>,
|
||||
}
|
||||
@@ -163,8 +163,8 @@ pub struct ScriptFilter {
|
||||
pub name: ::core::option::Option<::prost::alloc::string::String>,
|
||||
#[prost(string, optional, tag="2")]
|
||||
pub source: ::core::option::Option<::prost::alloc::string::String>,
|
||||
#[prost(uint32, optional, tag="3")]
|
||||
pub resource_type: ::core::option::Option<u32>,
|
||||
#[prost(enumeration="ResourceType", optional, tag="3")]
|
||||
pub resource_type: ::core::option::Option<i32>,
|
||||
#[prost(uint64, optional, tag="4")]
|
||||
pub resource_id: ::core::option::Option<u64>,
|
||||
#[prost(uint64, optional, tag="5")]
|
||||
@@ -197,8 +197,8 @@ pub struct Script {
|
||||
pub name: ::prost::alloc::string::String,
|
||||
#[prost(string, tag="4")]
|
||||
pub source: ::prost::alloc::string::String,
|
||||
#[prost(uint32, tag="5")]
|
||||
pub resource_type: u32,
|
||||
#[prost(enumeration="ResourceType", tag="5")]
|
||||
pub resource_type: i32,
|
||||
#[prost(uint64, optional, tag="6")]
|
||||
pub resource_id: ::core::option::Option<u64>,
|
||||
}
|
||||
@@ -264,6 +264,35 @@ pub struct ScriptPolicyListResponse {
|
||||
}
|
||||
#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
|
||||
#[repr(i32)]
|
||||
pub enum ResourceType {
|
||||
None = 0,
|
||||
Mapfix = 1,
|
||||
Submission = 2,
|
||||
}
|
||||
impl ResourceType {
|
||||
/// 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::None => "ResourceTypeNone",
|
||||
Self::Mapfix => "ResourceTypeMapfix",
|
||||
Self::Submission => "ResourceTypeSubmission",
|
||||
}
|
||||
}
|
||||
/// Creates an enum from field names used in the ProtoBuf definition.
|
||||
pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
|
||||
match value {
|
||||
"ResourceTypeNone" => Some(Self::None),
|
||||
"ResourceTypeMapfix" => Some(Self::Mapfix),
|
||||
"ResourceTypeSubmission" => Some(Self::Submission),
|
||||
_ => None,
|
||||
}
|
||||
}
|
||||
}
|
||||
#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
|
||||
#[repr(i32)]
|
||||
pub enum Policy {
|
||||
None = 0,
|
||||
Allowed = 1,
|
||||
@@ -278,21 +307,21 @@ impl Policy {
|
||||
/// (if the ProtoBuf definition does not change) and safe for programmatic use.
|
||||
pub fn as_str_name(&self) -> &'static str {
|
||||
match self {
|
||||
Self::None => "None",
|
||||
Self::Allowed => "Allowed",
|
||||
Self::Blocked => "Blocked",
|
||||
Self::Delete => "Delete",
|
||||
Self::Replace => "Replace",
|
||||
Self::None => "PolicyNone",
|
||||
Self::Allowed => "PolicyAllowed",
|
||||
Self::Blocked => "PolicyBlocked",
|
||||
Self::Delete => "PolicyDelete",
|
||||
Self::Replace => "PolicyReplace",
|
||||
}
|
||||
}
|
||||
/// Creates an enum from field names used in the ProtoBuf definition.
|
||||
pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
|
||||
match value {
|
||||
"None" => Some(Self::None),
|
||||
"Allowed" => Some(Self::Allowed),
|
||||
"Blocked" => Some(Self::Blocked),
|
||||
"Delete" => Some(Self::Delete),
|
||||
"Replace" => Some(Self::Replace),
|
||||
"PolicyNone" => Some(Self::None),
|
||||
"PolicyAllowed" => Some(Self::Allowed),
|
||||
"PolicyBlocked" => Some(Self::Blocked),
|
||||
"PolicyDelete" => Some(Self::Delete),
|
||||
"PolicyReplace" => Some(Self::Replace),
|
||||
_ => None,
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user