#[non_exhaustive]pub struct GuestAttributes {
pub query_path: String,
pub query_value: Option<GuestAttributesValue>,
/* private fields */
}Expand description
A guest attributes.
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.query_path: StringThe path to be queried. This can be the default namespace (‘/’) or a nested namespace (‘/<namespace>/’) or a specified key (‘/<namespace>/<key>’)
query_value: Option<GuestAttributesValue>The value of the requested queried path.
Implementations§
Source§impl GuestAttributes
impl GuestAttributes
pub fn new() -> Self
Sourcepub fn set_query_path<T: Into<String>>(self, v: T) -> Self
pub fn set_query_path<T: Into<String>>(self, v: T) -> Self
Sourcepub fn set_query_value<T>(self, v: T) -> Selfwhere
T: Into<GuestAttributesValue>,
pub fn set_query_value<T>(self, v: T) -> Selfwhere
T: Into<GuestAttributesValue>,
Sets the value of query_value.
§Example
ⓘ
use google_cloud_tpu_v2::model::GuestAttributesValue;
let x = GuestAttributes::new().set_query_value(GuestAttributesValue::default()/* use setters */);Sourcepub fn set_or_clear_query_value<T>(self, v: Option<T>) -> Selfwhere
T: Into<GuestAttributesValue>,
pub fn set_or_clear_query_value<T>(self, v: Option<T>) -> Selfwhere
T: Into<GuestAttributesValue>,
Sets or clears the value of query_value.
§Example
ⓘ
use google_cloud_tpu_v2::model::GuestAttributesValue;
let x = GuestAttributes::new().set_or_clear_query_value(Some(GuestAttributesValue::default()/* use setters */));
let x = GuestAttributes::new().set_or_clear_query_value(None::<GuestAttributesValue>);Trait Implementations§
Source§impl Clone for GuestAttributes
impl Clone for GuestAttributes
Source§fn clone(&self) -> GuestAttributes
fn clone(&self) -> GuestAttributes
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 GuestAttributes
impl Debug for GuestAttributes
Source§impl Default for GuestAttributes
impl Default for GuestAttributes
Source§fn default() -> GuestAttributes
fn default() -> GuestAttributes
Returns the “default value” for a type. Read more
Source§impl Message for GuestAttributes
impl Message for GuestAttributes
Source§impl PartialEq for GuestAttributes
impl PartialEq for GuestAttributes
impl StructuralPartialEq for GuestAttributes
Auto Trait Implementations§
impl Freeze for GuestAttributes
impl RefUnwindSafe for GuestAttributes
impl Send for GuestAttributes
impl Sync for GuestAttributes
impl Unpin for GuestAttributes
impl UnsafeUnpin for GuestAttributes
impl UnwindSafe for GuestAttributes
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