#[non_exhaustive]pub struct BucketContribution {
pub bucket: String,
pub throttled_requests: i64,
pub percentage_increase: f64,
pub details: Option<Details>,
/* private fields */
}Expand description
Represents the throttled requests details for a bucket.
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.bucket: StringOutput only. The name of the bucket.
throttled_requests: i64Output only. The count of throttled requests for the bucket.
percentage_increase: f64Output only. The percentage increase in throttled requests for the bucket.
details: Option<Details>The details of the bucket’s contribution towards the
IntelligenceFinding.
Implementations§
Source§impl BucketContribution
impl BucketContribution
Sourcepub fn set_bucket<T: Into<String>>(self, v: T) -> Self
pub fn set_bucket<T: Into<String>>(self, v: T) -> Self
Sourcepub fn set_throttled_requests<T: Into<i64>>(self, v: T) -> Self
pub fn set_throttled_requests<T: Into<i64>>(self, v: T) -> Self
Sets the value of throttled_requests.
§Example
let x = BucketContribution::new().set_throttled_requests(42);Sourcepub fn set_percentage_increase<T: Into<f64>>(self, v: T) -> Self
pub fn set_percentage_increase<T: Into<f64>>(self, v: T) -> Self
Sets the value of percentage_increase.
§Example
let x = BucketContribution::new().set_percentage_increase(42.0);Sourcepub fn set_details<T: Into<Option<Details>>>(self, v: T) -> Self
pub fn set_details<T: Into<Option<Details>>>(self, v: T) -> Self
Sets the value of details.
Note that all the setters affecting details are mutually
exclusive.
§Example
use google_cloud_storage::model::intelligence_finding::throttled_request_spike::bucket_contribution::Contribution;
let x = BucketContribution::new().set_details(Some(
google_cloud_storage::model::intelligence_finding::throttled_request_spike::bucket_contribution::Details::Contribution(Contribution::default().into())));Sourcepub fn contribution(&self) -> Option<&Box<Contribution>>
pub fn contribution(&self) -> Option<&Box<Contribution>>
The value of details
if it holds a Contribution, None if the field is not set or
holds a different branch.
Sourcepub fn set_contribution<T: Into<Box<Contribution>>>(self, v: T) -> Self
pub fn set_contribution<T: Into<Box<Contribution>>>(self, v: T) -> Self
Sets the value of details
to hold a Contribution.
Note that all the setters affecting details are
mutually exclusive.
§Example
use google_cloud_storage::model::intelligence_finding::throttled_request_spike::bucket_contribution::Contribution;
let x = BucketContribution::new().set_contribution(Contribution::default()/* use setters */);
assert!(x.contribution().is_some());
assert!(x.error().is_none());Sourcepub fn error(&self) -> Option<&Box<Status>>
pub fn error(&self) -> Option<&Box<Status>>
The value of details
if it holds a Error, None if the field is not set or
holds a different branch.
Sourcepub fn set_error<T: Into<Box<Status>>>(self, v: T) -> Self
pub fn set_error<T: Into<Box<Status>>>(self, v: T) -> Self
Sets the value of details
to hold a Error.
Note that all the setters affecting details are
mutually exclusive.
§Example
use google_cloud_rpc::model::Status;
let x = BucketContribution::new().set_error(Status::default()/* use setters */);
assert!(x.error().is_some());
assert!(x.contribution().is_none());Trait Implementations§
Source§impl Clone for BucketContribution
impl Clone for BucketContribution
Source§fn clone(&self) -> BucketContribution
fn clone(&self) -> BucketContribution
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 BucketContribution
impl Debug for BucketContribution
Source§impl Default for BucketContribution
impl Default for BucketContribution
Source§fn default() -> BucketContribution
fn default() -> BucketContribution
Source§impl Message for BucketContribution
impl Message for BucketContribution
Source§impl PartialEq for BucketContribution
impl PartialEq for BucketContribution
Source§fn eq(&self, other: &BucketContribution) -> bool
fn eq(&self, other: &BucketContribution) -> bool
self and other values to be equal, and is used by ==.impl StructuralPartialEq for BucketContribution
Auto Trait Implementations§
impl Freeze for BucketContribution
impl RefUnwindSafe for BucketContribution
impl Send for BucketContribution
impl Sync for BucketContribution
impl Unpin for BucketContribution
impl UnsafeUnpin for BucketContribution
impl UnwindSafe for BucketContribution
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