#[non_exhaustive]pub struct SchemaBundle {
pub name: String,
pub etag: String,
pub type: Option<Type>,
/* private fields */
}Expand description
A named collection of related schemas.
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 unique name identifying this schema bundle.
Values are of the form
projects/{project}/instances/{instance}/tables/{table}/schemaBundles/{schema_bundle}
etag: StringOptional. The etag for this schema bundle. This may be sent on update and delete requests to ensure the client has an up-to-date value before proceeding. The server returns an ABORTED error on a mismatched etag.
type: Option<Type>The type of this schema bundle. The oneof case cannot change after creation.
Implementations§
Source§impl SchemaBundle
impl SchemaBundle
pub fn new() -> Self
Sourcepub fn set_type<T: Into<Option<Type>>>(self, v: T) -> Self
pub fn set_type<T: Into<Option<Type>>>(self, v: T) -> Self
Sets the value of r#type.
Note that all the setters affecting r#type are mutually
exclusive.
§Example
use google_cloud_bigtable_admin_v2::model::ProtoSchema;
let x = SchemaBundle::new().set_type(Some(
google_cloud_bigtable_admin_v2::model::schema_bundle::Type::ProtoSchema(ProtoSchema::default().into())));Sourcepub fn proto_schema(&self) -> Option<&Box<ProtoSchema>>
pub fn proto_schema(&self) -> Option<&Box<ProtoSchema>>
The value of [r#type][crate::model::SchemaBundle::r#type]
if it holds a ProtoSchema, None if the field is not set or
holds a different branch.
Sourcepub fn set_proto_schema<T: Into<Box<ProtoSchema>>>(self, v: T) -> Self
pub fn set_proto_schema<T: Into<Box<ProtoSchema>>>(self, v: T) -> Self
Sets the value of [r#type][crate::model::SchemaBundle::r#type]
to hold a ProtoSchema.
Note that all the setters affecting r#type are
mutually exclusive.
§Example
use google_cloud_bigtable_admin_v2::model::ProtoSchema;
let x = SchemaBundle::new().set_proto_schema(ProtoSchema::default()/* use setters */);
assert!(x.proto_schema().is_some());Trait Implementations§
Source§impl Clone for SchemaBundle
impl Clone for SchemaBundle
Source§fn clone(&self) -> SchemaBundle
fn clone(&self) -> SchemaBundle
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more