pub struct VpnConnectionClient { /* private fields */ }Expand description
Calls VpnConnectionService.
VPN connections: a site-to-site VPN tunnel between a VPN gateway, a VPC’s end, and a customer gateway, the far end in your own network. A connection carries traffic between the VPC and the prefixes it names behind the far end.
Implementations§
Source§impl VpnConnectionClient
impl VpnConnectionClient
Sourcepub fn new(client: &Client) -> Self
pub fn new(client: &Client) -> Self
Returns a client of VpnConnectionService 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_vpn_connection(
&self,
request: GetVpnConnectionRequest,
) -> Result<VpnConnection, Error>
pub async fn get_vpn_connection( &self, request: GetVpnConnectionRequest, ) -> Result<VpnConnection, Error>
Returns a VPN connection.
Sourcepub async fn list_vpn_connections(
&self,
request: ListVpnConnectionsRequest,
) -> Result<ListVpnConnectionsResponse, Error>
pub async fn list_vpn_connections( &self, request: ListVpnConnectionsRequest, ) -> Result<ListVpnConnectionsResponse, Error>
Lists the VPN connections in a zone, oldest first.
Sourcepub fn all_vpn_connections(
&self,
request: ListVpnConnectionsRequest,
) -> Pages<VpnConnection>
pub fn all_vpn_connections( &self, request: ListVpnConnectionsRequest, ) -> Pages<VpnConnection>
Returns everything list_vpn_connections 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_vpn_connection(
&self,
request: CreateVpnConnectionRequest,
) -> Result<Operation<VpnConnection>, Error>
pub async fn create_vpn_connection( &self, request: CreateVpnConnectionRequest, ) -> Result<Operation<VpnConnection>, Error>
Creates a VPN connection between a VPN gateway of the zone and a
customer gateway of the same project, in the zone’s region. Refused
with INVALID_ARGUMENT when the customer gateway doesn’t suit the
type, and for remote prefixes that aren’t allowed. The operation is
done once the change is recorded.
It answers with an operation to wait on: Operation::wait returns the VpnConnection once the change is done.
Sourcepub async fn update_vpn_connection(
&self,
request: UpdateVpnConnectionRequest,
) -> Result<Operation<VpnConnection>, Error>
pub async fn update_vpn_connection( &self, request: UpdateVpnConnectionRequest, ) -> Result<Operation<VpnConnection>, Error>
Changes a VPN connection’s remote prefixes, IPsec profile and tags. The operation is done once the change is recorded.
It answers with an operation to wait on: Operation::wait returns the VpnConnection once the change is done.
Sourcepub async fn delete_vpn_connection(
&self,
request: DeleteVpnConnectionRequest,
) -> Result<Operation<Empty>, Error>
pub async fn delete_vpn_connection( &self, request: DeleteVpnConnectionRequest, ) -> Result<Operation<Empty>, Error>
Deletes a VPN connection. Routes to its VPN gateway stay. 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.