#[non_exhaustive]pub struct ServiceProjectAttachment {
pub name: String,
pub service_project: String,
pub create_time: Option<Timestamp>,
pub uid: String,
pub state: State,
/* private fields */
}Expand description
ServiceProjectAttachment represents an attachment from a service project to a host project. Service projects contain the underlying cloud infrastructure resources, and expose these resources to the host project through a ServiceProjectAttachment. With the attachments, the host project can provide an aggregated view of resources across all service projects.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.name: StringIdentifier. The resource name of a ServiceProjectAttachment. Format:
"projects/{host-project-id}/locations/global/serviceProjectAttachments/{service-project-id}."
service_project: StringRequired. Immutable. Service project name in the format: "projects/abc"
or "projects/123". As input, project name with either project id or
number are accepted. As output, this field will contain project number.
create_time: Option<Timestamp>Output only. Create time.
uid: StringOutput only. A globally unique identifier (in UUID4 format) for the
ServiceProjectAttachment.
state: StateOutput only. ServiceProjectAttachment state.
Implementations§
Source§impl ServiceProjectAttachment
impl ServiceProjectAttachment
Sourcepub fn set_service_project<T: Into<String>>(self, v: T) -> Self
pub fn set_service_project<T: Into<String>>(self, v: T) -> Self
Sets the value of service_project.
§Example
let x = ServiceProjectAttachment::new().set_service_project("example");Sourcepub fn set_create_time<T>(self, v: T) -> Self
pub fn set_create_time<T>(self, v: T) -> Self
Sets the value of create_time.
§Example
use wkt::Timestamp;
let x = ServiceProjectAttachment::new().set_create_time(Timestamp::default()/* use setters */);Sourcepub fn set_or_clear_create_time<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_create_time<T>(self, v: Option<T>) -> Self
Sets or clears the value of create_time.
§Example
use wkt::Timestamp;
let x = ServiceProjectAttachment::new().set_or_clear_create_time(Some(Timestamp::default()/* use setters */));
let x = ServiceProjectAttachment::new().set_or_clear_create_time(None::<Timestamp>);Sourcepub fn set_state<T: Into<State>>(self, v: T) -> Self
pub fn set_state<T: Into<State>>(self, v: T) -> Self
Sets the value of state.
§Example
use google_cloud_apphub_v1::model::service_project_attachment::State;
let x0 = ServiceProjectAttachment::new().set_state(State::Creating);
let x1 = ServiceProjectAttachment::new().set_state(State::Active);
let x2 = ServiceProjectAttachment::new().set_state(State::Deleting);Trait Implementations§
Source§impl Clone for ServiceProjectAttachment
impl Clone for ServiceProjectAttachment
Source§fn clone(&self) -> ServiceProjectAttachment
fn clone(&self) -> ServiceProjectAttachment
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for ServiceProjectAttachment
impl Debug for ServiceProjectAttachment
Source§impl Default for ServiceProjectAttachment
impl Default for ServiceProjectAttachment
Source§fn default() -> ServiceProjectAttachment
fn default() -> ServiceProjectAttachment
Source§impl Message for ServiceProjectAttachment
impl Message for ServiceProjectAttachment
Source§impl PartialEq for ServiceProjectAttachment
impl PartialEq for ServiceProjectAttachment
impl StructuralPartialEq for ServiceProjectAttachment
Auto Trait Implementations§
impl Freeze for ServiceProjectAttachment
impl RefUnwindSafe for ServiceProjectAttachment
impl Send for ServiceProjectAttachment
impl Sync for ServiceProjectAttachment
impl Unpin for ServiceProjectAttachment
impl UnsafeUnpin for ServiceProjectAttachment
impl UnwindSafe for ServiceProjectAttachment
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
Source§impl<T> FutureExt for T
impl<T> FutureExt for T
Source§fn with_context(self, otel_cx: Context) -> WithContext<Self>
fn with_context(self, otel_cx: Context) -> WithContext<Self>
Source§fn with_current_context(self) -> WithContext<Self>
fn with_current_context(self) -> WithContext<Self>
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
Source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
T in a tonic::Request