Skip to main content

ClientSubnetPoolsExt

Trait ClientSubnetPoolsExt 

Source
pub trait ClientSubnetPoolsExt {
    // Required methods
    fn subnet_pool_list(&self) -> SubnetPoolList<'_>;
    fn subnet_pool_view(&self) -> SubnetPoolView<'_>;
}
Expand description

Subnet pools are collections of external subnets that can be allocated and attached to instances.

Required Methods§

Source

fn subnet_pool_list(&self) -> SubnetPoolList<'_>

List subnet pools

Sends a GET request to /v1/subnet-pools

Arguments:

  • limit: Maximum number of items returned by a single call
  • page_token: Token returned by previous call to retrieve the subsequent page
  • sort_by
let response = client.subnet_pool_list()
   .limit(limit)
   .page_token(page_token)
   .sort_by(sort_by)
   .send()
   .await;
Source

fn subnet_pool_view(&self) -> SubnetPoolView<'_>

Fetch subnet pool

Sends a GET request to /v1/subnet-pools/{pool}

Arguments:

  • pool: Name or ID of the subnet pool
let response = client.subnet_pool_view()
   .pool(pool)
   .send()
   .await;

Implementors§