#![allow(rustdoc::redundant_explicit_links)]
#![allow(rustdoc::broken_intra_doc_links)]
#![no_implicit_prelude]
extern crate bytes;
extern crate google_cloud_apps_script_type;
extern crate serde;
extern crate serde_json;
extern crate serde_with;
extern crate std;
extern crate wkt;
mod debug;
mod deserialize;
mod serialize;
#[derive(Clone, Default, PartialEq)]
#[non_exhaustive]
pub struct SheetsAddOnManifest {
pub homepage_trigger:
std::option::Option<google_cloud_apps_script_type::model::HomepageExtensionPoint>,
pub on_file_scope_granted_trigger: std::option::Option<crate::model::SheetsExtensionPoint>,
pub(crate) _unknown_fields: serde_json::Map<std::string::String, serde_json::Value>,
}
impl SheetsAddOnManifest {
pub fn new() -> Self {
std::default::Default::default()
}
pub fn set_homepage_trigger<T>(mut self, v: T) -> Self
where
T: std::convert::Into<google_cloud_apps_script_type::model::HomepageExtensionPoint>,
{
self.homepage_trigger = std::option::Option::Some(v.into());
self
}
pub fn set_or_clear_homepage_trigger<T>(mut self, v: std::option::Option<T>) -> Self
where
T: std::convert::Into<google_cloud_apps_script_type::model::HomepageExtensionPoint>,
{
self.homepage_trigger = v.map(|x| x.into());
self
}
pub fn set_on_file_scope_granted_trigger<T>(mut self, v: T) -> Self
where
T: std::convert::Into<crate::model::SheetsExtensionPoint>,
{
self.on_file_scope_granted_trigger = std::option::Option::Some(v.into());
self
}
pub fn set_or_clear_on_file_scope_granted_trigger<T>(
mut self,
v: std::option::Option<T>,
) -> Self
where
T: std::convert::Into<crate::model::SheetsExtensionPoint>,
{
self.on_file_scope_granted_trigger = v.map(|x| x.into());
self
}
}
impl wkt::message::Message for SheetsAddOnManifest {
fn typename() -> &'static str {
"type.googleapis.com/google.apps.script.type.sheets.SheetsAddOnManifest"
}
}
#[derive(Clone, Default, PartialEq)]
#[non_exhaustive]
pub struct SheetsExtensionPoint {
pub run_function: std::string::String,
pub(crate) _unknown_fields: serde_json::Map<std::string::String, serde_json::Value>,
}
impl SheetsExtensionPoint {
pub fn new() -> Self {
std::default::Default::default()
}
pub fn set_run_function<T: std::convert::Into<std::string::String>>(mut self, v: T) -> Self {
self.run_function = v.into();
self
}
}
impl wkt::message::Message for SheetsExtensionPoint {
fn typename() -> &'static str {
"type.googleapis.com/google.apps.script.type.sheets.SheetsExtensionPoint"
}
}