Skip to main content

AggregatedListRequest

Struct AggregatedListRequest 

Source
#[non_exhaustive]
pub struct AggregatedListRequest { pub filter: Option<String>, pub include_all_scopes: Option<bool>, pub max_results: Option<u32>, pub order_by: Option<String>, pub page_token: Option<String>, pub project: String, pub return_partial_success: Option<bool>, pub service_project_number: Option<i64>, /* private fields */ }
Available on crate feature target-https-proxies only.
Expand description

Synthetic request message for the aggregatedList() method.

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.
§filter: Option<String>

A filter expression that filters resources listed in the response. Most Compute resources support two types of filter expressions: expressions that support regular expressions and expressions that follow API improvement proposal AIP-160. These two types of filter expressions cannot be mixed in one request.

If you want to use AIP-160, your expression must specify the field name, an operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The operator must be either =, !=, >, <, <=, >= or :.

For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance.

The :* comparison can be used to test whether a key has been defined. For example, to find all objects with owner label use:

labels.owner:*

You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based onresource labels.

To filter on multiple expressions, provide each separate expression within parentheses. For example:

(scheduling.automaticRestart = true)
(cpuPlatform = "Intel Skylake")

By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example:

(cpuPlatform = "Intel Skylake") OR
(cpuPlatform = "Intel Broadwell") AND
(scheduling.automaticRestart = true)

If you want to use a regular expression, use the eq (equal) or ne (not equal) operator against a single un-parenthesized expression with or without quotes or against multiple parenthesized expressions. Examples:

fieldname eq unquoted literal fieldname eq 'single quoted literal' fieldname eq "double quoted literal" (fieldname1 eq literal) (fieldname2 ne "literal")

The literal value is interpreted as a regular expression using GoogleRE2 library syntax. The literal value must match the entire field.

For example, to filter for instances that do not end with name “instance”, you would use name ne .*instance.

You cannot combine constraints on multiple fields using regular expressions.

§include_all_scopes: Option<bool>

Indicates whether every visible scope for each scope type (zone, region, global) should be included in the response. For new resource types added after this field, the flag has no effect as new resource types will always include every visible scope for each scope type in response. For resource types which predate this field, if this flag is omitted or false, only scopes of the scope types where the resource type is expected to be found will be included.

§max_results: Option<u32>

The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests. Acceptable values are 0 to 500, inclusive. (Default: 500)

§order_by: Option<String>

Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name.

You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first.

Currently, only sorting by name or creationTimestamp desc is supported.

§page_token: Option<String>

Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results.

§project: String

Name of the project scoping this request.

§return_partial_success: Option<bool>

Opt-in for partial success behavior which provides partial results in case of failure. The default value is false.

For example, when partial success behavior is enabled, aggregatedList for a single zone scope either returns all resources in the zone or no resources, with an error code.

§service_project_number: Option<i64>

The Shared VPC service project id or service project number for which aggregated list request is invoked for subnetworks list-usable api.

Implementations§

Source§

impl AggregatedListRequest

Source

pub fn new() -> Self

Source

pub fn set_filter<T>(self, v: T) -> Self
where T: Into<String>,

Sets the value of filter.

§Example
let x = AggregatedListRequest::new().set_filter("example");
Source

pub fn set_or_clear_filter<T>(self, v: Option<T>) -> Self
where T: Into<String>,

Sets or clears the value of filter.

§Example
let x = AggregatedListRequest::new().set_or_clear_filter(Some("example"));
let x = AggregatedListRequest::new().set_or_clear_filter(None::<String>);
Source

pub fn set_include_all_scopes<T>(self, v: T) -> Self
where T: Into<bool>,

Sets the value of include_all_scopes.

§Example
let x = AggregatedListRequest::new().set_include_all_scopes(true);
Source

pub fn set_or_clear_include_all_scopes<T>(self, v: Option<T>) -> Self
where T: Into<bool>,

Sets or clears the value of include_all_scopes.

§Example
let x = AggregatedListRequest::new().set_or_clear_include_all_scopes(Some(false));
let x = AggregatedListRequest::new().set_or_clear_include_all_scopes(None::<bool>);
Source

pub fn set_max_results<T>(self, v: T) -> Self
where T: Into<u32>,

Sets the value of max_results.

§Example
let x = AggregatedListRequest::new().set_max_results(42_u32);
Source

pub fn set_or_clear_max_results<T>(self, v: Option<T>) -> Self
where T: Into<u32>,

Sets or clears the value of max_results.

§Example
let x = AggregatedListRequest::new().set_or_clear_max_results(Some(42_u32));
let x = AggregatedListRequest::new().set_or_clear_max_results(None::<u32>);
Source

pub fn set_order_by<T>(self, v: T) -> Self
where T: Into<String>,

Sets the value of order_by.

§Example
let x = AggregatedListRequest::new().set_order_by("example");
Source

pub fn set_or_clear_order_by<T>(self, v: Option<T>) -> Self
where T: Into<String>,

Sets or clears the value of order_by.

§Example
let x = AggregatedListRequest::new().set_or_clear_order_by(Some("example"));
let x = AggregatedListRequest::new().set_or_clear_order_by(None::<String>);
Source

pub fn set_page_token<T>(self, v: T) -> Self
where T: Into<String>,

Sets the value of page_token.

§Example
let x = AggregatedListRequest::new().set_page_token("example");
Source

pub fn set_or_clear_page_token<T>(self, v: Option<T>) -> Self
where T: Into<String>,

Sets or clears the value of page_token.

§Example
let x = AggregatedListRequest::new().set_or_clear_page_token(Some("example"));
let x = AggregatedListRequest::new().set_or_clear_page_token(None::<String>);
Source

pub fn set_project<T: Into<String>>(self, v: T) -> Self

Sets the value of project.

§Example
let x = AggregatedListRequest::new().set_project("example");
Source

pub fn set_return_partial_success<T>(self, v: T) -> Self
where T: Into<bool>,

Sets the value of return_partial_success.

§Example
let x = AggregatedListRequest::new().set_return_partial_success(true);
Source

pub fn set_or_clear_return_partial_success<T>(self, v: Option<T>) -> Self
where T: Into<bool>,

Sets or clears the value of return_partial_success.

§Example
let x = AggregatedListRequest::new().set_or_clear_return_partial_success(Some(false));
let x = AggregatedListRequest::new().set_or_clear_return_partial_success(None::<bool>);
Source

pub fn set_service_project_number<T>(self, v: T) -> Self
where T: Into<i64>,

Sets the value of service_project_number.

§Example
let x = AggregatedListRequest::new().set_service_project_number(42);
Source

pub fn set_or_clear_service_project_number<T>(self, v: Option<T>) -> Self
where T: Into<i64>,

Sets or clears the value of service_project_number.

§Example
let x = AggregatedListRequest::new().set_or_clear_service_project_number(Some(42));
let x = AggregatedListRequest::new().set_or_clear_service_project_number(None::<i32>);

Trait Implementations§

Source§

impl Clone for AggregatedListRequest

Source§

fn clone(&self) -> AggregatedListRequest

Returns a duplicate of the value. Read more
1.0.0 · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for AggregatedListRequest

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl Default for AggregatedListRequest

Source§

fn default() -> AggregatedListRequest

Returns the “default value” for a type. Read more
Source§

impl PartialEq for AggregatedListRequest

Source§

fn eq(&self, other: &AggregatedListRequest) -> bool

Tests for self and other values to be equal, and is used by ==.
1.0.0 · Source§

fn ne(&self, other: &Rhs) -> bool

Tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
Source§

impl StructuralPartialEq for AggregatedListRequest

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T> Instrument for T

Source§

fn instrument(self, span: Span) -> Instrumented<Self>

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more
Source§

fn in_current_span(self) -> Instrumented<Self>

Instruments this type with the current Span, returning an Instrumented wrapper. Read more
Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> PolicyExt for T
where T: ?Sized,

Source§

fn and<P, B, E>(self, other: P) -> And<T, P>
where T: Policy<B, E>, P: Policy<B, E>,

Create a new Policy that returns Action::Follow only if self and other return Action::Follow. Read more
Source§

fn or<P, B, E>(self, other: P) -> Or<T, P>
where T: Policy<B, E>, P: Policy<B, E>,

Create a new Policy that returns Action::Follow if either self or other returns Action::Follow. Read more
Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
Source§

impl<V, T> VZip<V> for T
where V: MultiLane<T>,

Source§

fn vzip(self) -> V

Source§

impl<T> WithSubscriber for T

Source§

fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self>
where S: Into<Dispatch>,

Attaches the provided Subscriber to this type, returning a WithDispatch wrapper. Read more
Source§

fn with_current_subscriber(self) -> WithDispatch<Self>

Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more