#[non_exhaustive]pub struct NotebookSoftwareConfig {
pub env: Vec<EnvVar>,
pub post_startup_script_config: Option<PostStartupScriptConfig>,
pub runtime_image: Option<RuntimeImage>,
/* private fields */
}Available on crate feature
notebook-service only.Expand description
Notebook Software Config. This is passed to the backend when user makes software configurations in UI.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Non-exhaustive structs could have additional fields added in future. Therefore, non-exhaustive structs cannot be constructed in external crates using the traditional
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.env: Vec<EnvVar>Optional. Environment variables to be passed to the container. Maximum limit is 100.
post_startup_script_config: Option<PostStartupScriptConfig>Optional. Post startup script config.
runtime_image: Option<RuntimeImage>The image to be used by the notebook runtime.
Implementations§
Source§impl NotebookSoftwareConfig
impl NotebookSoftwareConfig
pub fn new() -> Self
Sourcepub fn set_post_startup_script_config<T>(self, v: T) -> Selfwhere
T: Into<PostStartupScriptConfig>,
pub fn set_post_startup_script_config<T>(self, v: T) -> Selfwhere
T: Into<PostStartupScriptConfig>,
Sets the value of post_startup_script_config.
§Example
ⓘ
use google_cloud_aiplatform_v1::model::PostStartupScriptConfig;
let x = NotebookSoftwareConfig::new().set_post_startup_script_config(PostStartupScriptConfig::default()/* use setters */);Sourcepub fn set_or_clear_post_startup_script_config<T>(self, v: Option<T>) -> Selfwhere
T: Into<PostStartupScriptConfig>,
pub fn set_or_clear_post_startup_script_config<T>(self, v: Option<T>) -> Selfwhere
T: Into<PostStartupScriptConfig>,
Sets or clears the value of post_startup_script_config.
§Example
ⓘ
use google_cloud_aiplatform_v1::model::PostStartupScriptConfig;
let x = NotebookSoftwareConfig::new().set_or_clear_post_startup_script_config(Some(PostStartupScriptConfig::default()/* use setters */));
let x = NotebookSoftwareConfig::new().set_or_clear_post_startup_script_config(None::<PostStartupScriptConfig>);Sourcepub fn set_runtime_image<T: Into<Option<RuntimeImage>>>(self, v: T) -> Self
pub fn set_runtime_image<T: Into<Option<RuntimeImage>>>(self, v: T) -> Self
Sets the value of runtime_image.
Note that all the setters affecting runtime_image are mutually
exclusive.
§Example
ⓘ
use google_cloud_aiplatform_v1::model::ColabImage;
let x = NotebookSoftwareConfig::new().set_runtime_image(Some(
google_cloud_aiplatform_v1::model::notebook_software_config::RuntimeImage::ColabImage(ColabImage::default().into())));Sourcepub fn colab_image(&self) -> Option<&Box<ColabImage>>
pub fn colab_image(&self) -> Option<&Box<ColabImage>>
The value of runtime_image
if it holds a ColabImage, None if the field is not set or
holds a different branch.
Sourcepub fn set_colab_image<T: Into<Box<ColabImage>>>(self, v: T) -> Self
pub fn set_colab_image<T: Into<Box<ColabImage>>>(self, v: T) -> Self
Sets the value of runtime_image
to hold a ColabImage.
Note that all the setters affecting runtime_image are
mutually exclusive.
§Example
ⓘ
use google_cloud_aiplatform_v1::model::ColabImage;
let x = NotebookSoftwareConfig::new().set_colab_image(ColabImage::default()/* use setters */);
assert!(x.colab_image().is_some());Trait Implementations§
Source§impl Clone for NotebookSoftwareConfig
impl Clone for NotebookSoftwareConfig
Source§fn clone(&self) -> NotebookSoftwareConfig
fn clone(&self) -> NotebookSoftwareConfig
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for NotebookSoftwareConfig
impl Debug for NotebookSoftwareConfig
Source§impl Default for NotebookSoftwareConfig
impl Default for NotebookSoftwareConfig
Source§fn default() -> NotebookSoftwareConfig
fn default() -> NotebookSoftwareConfig
Returns the “default value” for a type. Read more
Source§impl Message for NotebookSoftwareConfig
impl Message for NotebookSoftwareConfig
Source§impl PartialEq for NotebookSoftwareConfig
impl PartialEq for NotebookSoftwareConfig
impl StructuralPartialEq for NotebookSoftwareConfig
Auto Trait Implementations§
impl Freeze for NotebookSoftwareConfig
impl RefUnwindSafe for NotebookSoftwareConfig
impl Send for NotebookSoftwareConfig
impl Sync for NotebookSoftwareConfig
impl Unpin for NotebookSoftwareConfig
impl UnwindSafe for NotebookSoftwareConfig
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more