pub struct CustomerGatewayClient { /* private fields */ }Expand description
Calls CustomerGatewayService.
Customer gateways: the far end of a site-to-site VPN tunnel, a router or firewall of your own network outside the platform. A customer gateway describes the device; VPN connections in any zone of its region can use it.
Implementations§
Source§impl CustomerGatewayClient
impl CustomerGatewayClient
Sourcepub fn new(client: &Client) -> Self
pub fn new(client: &Client) -> Self
Returns a client of CustomerGatewayService that sends its calls through client.
Sourcepub fn service(&self) -> &Service
pub fn service(&self) -> &Service
The endpoint the client sends its calls to, which also serves the operations its methods answer with.
Sourcepub fn with_options(&self, options: CallOptions) -> Self
pub fn with_options(&self, options: CallOptions) -> Self
The same client, whose calls are sent as options says instead of as the Client’s settings do, such as a mutation that must not be sent twice: .with_options(CallOptions::new().max_attempts(1)). See CallOptions.
Sourcepub async fn get_customer_gateway(
&self,
request: GetCustomerGatewayRequest,
) -> Result<CustomerGateway, Error>
pub async fn get_customer_gateway( &self, request: GetCustomerGatewayRequest, ) -> Result<CustomerGateway, Error>
Returns a customer gateway.
Sourcepub async fn list_customer_gateways(
&self,
request: ListCustomerGatewaysRequest,
) -> Result<ListCustomerGatewaysResponse, Error>
pub async fn list_customer_gateways( &self, request: ListCustomerGatewaysRequest, ) -> Result<ListCustomerGatewaysResponse, Error>
Lists the customer gateways in a region, oldest first.
Sourcepub fn all_customer_gateways(
&self,
request: ListCustomerGatewaysRequest,
) -> Pages<CustomerGateway>
pub fn all_customer_gateways( &self, request: ListCustomerGatewaysRequest, ) -> Pages<CustomerGateway>
Returns everything list_customer_gateways lists from request’s page on, fetching the next page as the stream reaches it. A page that fails ends the stream with its error.
Sourcepub async fn create_customer_gateway(
&self,
request: CreateCustomerGatewayRequest,
) -> Result<Operation<CustomerGateway>, Error>
pub async fn create_customer_gateway( &self, request: CreateCustomerGatewayRequest, ) -> Result<Operation<CustomerGateway>, Error>
Creates a customer gateway with a public IPv4 address, a WireGuard
public key, or both. Refused with INVALID_ARGUMENT for an address in
a private, shared, reserved or platform range, for a key that isn’t
a WireGuard public key, and for a WireGuard port outside 1 to 65535 or
without a key and an address. The operation is done once the change is
recorded.
It answers with an operation to wait on: Operation::wait returns the CustomerGateway once the change is done.
Sourcepub async fn update_customer_gateway(
&self,
request: UpdateCustomerGatewayRequest,
) -> Result<Operation<CustomerGateway>, Error>
pub async fn update_customer_gateway( &self, request: UpdateCustomerGatewayRequest, ) -> Result<Operation<CustomerGateway>, Error>
Changes a customer gateway’s display name and tags. The operation is done once the change is recorded.
It answers with an operation to wait on: Operation::wait returns the CustomerGateway once the change is done.
Sourcepub async fn delete_customer_gateway(
&self,
request: DeleteCustomerGatewayRequest,
) -> Result<Operation<Empty>, Error>
pub async fn delete_customer_gateway( &self, request: DeleteCustomerGatewayRequest, ) -> Result<Operation<Empty>, Error>
Deletes a customer gateway. Refused with FAILED_PRECONDITION while a
VPN connection names it. The operation is done once the change is
recorded.
It answers with an operation to wait on, which has no result: Operation::wait returns once the change is done.