#[non_exhaustive]pub struct Reference {
pub kind: Option<String>,
pub reference_type: Option<String>,
pub referrer: Option<String>,
pub target: Option<String>,
/* private fields */
}Available on crate feature
instances only.Expand description
Represents a reference to a resource.
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.kind: Option<String>Output only. [Output Only] Type of the resource. Always compute#reference for references.
reference_type: Option<String>A description of the reference type with no implied semantics. Possible values include:
1. MEMBER_OFreferrer: Option<String>URL of the resource which refers to the target.
target: Option<String>URL of the resource to which this reference points.
Implementations§
Source§impl Reference
impl Reference
pub fn new() -> Self
Sourcepub fn set_or_clear_kind<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_kind<T>(self, v: Option<T>) -> Self
Sourcepub fn set_reference_type<T>(self, v: T) -> Self
pub fn set_reference_type<T>(self, v: T) -> Self
Sourcepub fn set_or_clear_reference_type<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_reference_type<T>(self, v: Option<T>) -> Self
Sets or clears the value of reference_type.
§Example
ⓘ
let x = Reference::new().set_or_clear_reference_type(Some("example"));
let x = Reference::new().set_or_clear_reference_type(None::<String>);Sourcepub fn set_referrer<T>(self, v: T) -> Self
pub fn set_referrer<T>(self, v: T) -> Self
Sourcepub fn set_or_clear_referrer<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_referrer<T>(self, v: Option<T>) -> Self
Sourcepub fn set_target<T>(self, v: T) -> Self
pub fn set_target<T>(self, v: T) -> Self
Trait Implementations§
impl StructuralPartialEq for Reference
Auto Trait Implementations§
impl Freeze for Reference
impl RefUnwindSafe for Reference
impl Send for Reference
impl Sync for Reference
impl Unpin for Reference
impl UnwindSafe for Reference
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