#[non_exhaustive]pub struct ListPowerpacksOptionalParams {
pub page_limit: Option<i64>,
pub page_offset: Option<i64>,
}
Expand description
ListPowerpacksOptionalParams is a struct for passing parameters to the method PowerpackAPI::list_powerpacks
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.page_limit: Option<i64>
Maximum number of powerpacks in the response.
page_offset: Option<i64>
Specific offset to use as the beginning of the returned page.
Implementations§
source§impl ListPowerpacksOptionalParams
impl ListPowerpacksOptionalParams
sourcepub fn page_limit(self, value: i64) -> Self
pub fn page_limit(self, value: i64) -> Self
Maximum number of powerpacks in the response.
Examples found in repository?
examples/v2_powerpack_list_powerpacks.rs (line 11)
7 8 9 10 11 12 13 14 15 16 17 18
async fn main() {
let configuration = datadog::Configuration::new();
let api = PowerpackAPI::with_config(configuration);
let resp = api
.list_powerpacks(ListPowerpacksOptionalParams::default().page_limit(1000))
.await;
if let Ok(value) = resp {
println!("{:#?}", value);
} else {
println!("{:#?}", resp.unwrap_err());
}
}
More examples
examples/v2_powerpack_list_powerpacks_1173755071.rs (line 13)
9 10 11 12 13 14 15 16 17 18 19 20 21 22
async fn main() {
let configuration = datadog::Configuration::new();
let api = PowerpackAPI::with_config(configuration);
let response =
api.list_powerpacks_with_pagination(ListPowerpacksOptionalParams::default().page_limit(2));
pin_mut!(response);
while let Some(resp) = response.next().await {
if let Ok(value) = resp {
println!("{:#?}", value);
} else {
println!("{:#?}", resp.unwrap_err());
}
}
}
sourcepub fn page_offset(self, value: i64) -> Self
pub fn page_offset(self, value: i64) -> Self
Specific offset to use as the beginning of the returned page.
Trait Implementations§
source§impl Clone for ListPowerpacksOptionalParams
impl Clone for ListPowerpacksOptionalParams
source§fn clone(&self) -> ListPowerpacksOptionalParams
fn clone(&self) -> ListPowerpacksOptionalParams
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresource§impl Debug for ListPowerpacksOptionalParams
impl Debug for ListPowerpacksOptionalParams
source§impl Default for ListPowerpacksOptionalParams
impl Default for ListPowerpacksOptionalParams
source§fn default() -> ListPowerpacksOptionalParams
fn default() -> ListPowerpacksOptionalParams
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl Freeze for ListPowerpacksOptionalParams
impl RefUnwindSafe for ListPowerpacksOptionalParams
impl Send for ListPowerpacksOptionalParams
impl Sync for ListPowerpacksOptionalParams
impl Unpin for ListPowerpacksOptionalParams
impl UnwindSafe for ListPowerpacksOptionalParams
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
Mutably borrows from an owned value. Read more
source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
source§default unsafe fn clone_to_uninit(&self, dst: *mut T)
default unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)