#[non_exhaustive]pub struct CreateServiceRequest {
pub parent: String,
pub service: Option<Service>,
pub service_id: String,
pub validate_only: bool,
/* private fields */
}Expand description
Request message for creating a Service.
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.parent: StringRequired. The location and project in which this service should be created. Format: projects/{project}/locations/{location}, where {project} can be project id or number. Only lowercase characters, digits, and hyphens.
service: Option<Service>Required. The Service instance to create.
service_id: StringRequired. The unique identifier for the Service. It must begin with letter, and cannot end with hyphen; must contain fewer than 50 characters. The name of the service becomes {parent}/services/{service_id}.
validate_only: boolIndicates that the request should be validated and default values populated, without persisting the request or creating any resources.
Implementations§
Source§impl CreateServiceRequest
impl CreateServiceRequest
pub fn new() -> Self
Sourcepub fn set_parent<T: Into<String>>(self, v: T) -> Self
pub fn set_parent<T: Into<String>>(self, v: T) -> Self
Sets the value of parent.
Sourcepub fn set_service<T>(self, v: T) -> Self
pub fn set_service<T>(self, v: T) -> Self
Sets the value of service.
Sourcepub fn set_or_clear_service<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_service<T>(self, v: Option<T>) -> Self
Sets or clears the value of service.
Sourcepub fn set_service_id<T: Into<String>>(self, v: T) -> Self
pub fn set_service_id<T: Into<String>>(self, v: T) -> Self
Sets the value of service_id.
Sourcepub fn set_validate_only<T: Into<bool>>(self, v: T) -> Self
pub fn set_validate_only<T: Into<bool>>(self, v: T) -> Self
Sets the value of validate_only.
Trait Implementations§
Source§impl Clone for CreateServiceRequest
impl Clone for CreateServiceRequest
Source§fn clone(&self) -> CreateServiceRequest
fn clone(&self) -> CreateServiceRequest
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more