Class SnapshotsConnection (2.28.0)

This interface defines virtual methods for each of the user-facing overload sets in SnapshotsClient. This allows users to inject custom behavior (e.g., with a Google Mock object) when writing tests that use objects of type SnapshotsClient.

To create a concrete instance, see MakeSnapshotsConnection().

For mocking, see compute_snapshots_v1_mocks::MockSnapshotsConnection.

Functions

virtual options()

Returns
Type Description
Options

virtual DeleteSnapshot(google::cloud::cpp::compute::snapshots::v1::DeleteSnapshotRequest const &)

Parameter
Name Description
request google::cloud::cpp::compute::snapshots::v1::DeleteSnapshotRequest const &
Returns
Type Description
future< StatusOr< google::cloud::cpp::compute::v1::Operation > >

virtual DeleteSnapshot(NoAwaitTag, google::cloud::cpp::compute::snapshots::v1::DeleteSnapshotRequest const &)

Parameters
Name Description
NoAwaitTag
request google::cloud::cpp::compute::snapshots::v1::DeleteSnapshotRequest const &
Returns
Type Description
StatusOr< google::cloud::cpp::compute::v1::Operation >

virtual DeleteSnapshot(google::cloud::cpp::compute::v1::Operation const &)

Parameter
Name Description
operation google::cloud::cpp::compute::v1::Operation const &
Returns
Type Description
future< StatusOr< google::cloud::cpp::compute::v1::Operation > >

virtual GetSnapshot(google::cloud::cpp::compute::snapshots::v1::GetSnapshotRequest const &)

Parameter
Name Description
request google::cloud::cpp::compute::snapshots::v1::GetSnapshotRequest const &
Returns
Type Description
StatusOr< google::cloud::cpp::compute::v1::Snapshot >

virtual GetIamPolicy(google::cloud::cpp::compute::snapshots::v1::GetIamPolicyRequest const &)

Parameter
Name Description
request google::cloud::cpp::compute::snapshots::v1::GetIamPolicyRequest const &
Returns
Type Description
StatusOr< google::cloud::cpp::compute::v1::Policy >

virtual InsertSnapshot(google::cloud::cpp::compute::snapshots::v1::InsertSnapshotRequest const &)

Parameter
Name Description
request google::cloud::cpp::compute::snapshots::v1::InsertSnapshotRequest const &
Returns
Type Description
future< StatusOr< google::cloud::cpp::compute::v1::Operation > >

virtual InsertSnapshot(NoAwaitTag, google::cloud::cpp::compute::snapshots::v1::InsertSnapshotRequest const &)

Parameters
Name Description
NoAwaitTag
request google::cloud::cpp::compute::snapshots::v1::InsertSnapshotRequest const &
Returns
Type Description
StatusOr< google::cloud::cpp::compute::v1::Operation >

virtual InsertSnapshot(google::cloud::cpp::compute::v1::Operation const &)

Parameter
Name Description
operation google::cloud::cpp::compute::v1::Operation const &
Returns
Type Description
future< StatusOr< google::cloud::cpp::compute::v1::Operation > >

virtual ListSnapshots(google::cloud::cpp::compute::snapshots::v1::ListSnapshotsRequest)

Parameter
Name Description
request google::cloud::cpp::compute::snapshots::v1::ListSnapshotsRequest
Returns
Type Description
StreamRange< google::cloud::cpp::compute::v1::Snapshot >

virtual SetIamPolicy(google::cloud::cpp::compute::snapshots::v1::SetIamPolicyRequest const &)

Parameter
Name Description
request google::cloud::cpp::compute::snapshots::v1::SetIamPolicyRequest const &
Returns
Type Description
StatusOr< google::cloud::cpp::compute::v1::Policy >

virtual SetLabels(google::cloud::cpp::compute::snapshots::v1::SetLabelsRequest const &)

Parameter
Name Description
request google::cloud::cpp::compute::snapshots::v1::SetLabelsRequest const &
Returns
Type Description
future< StatusOr< google::cloud::cpp::compute::v1::Operation > >

virtual SetLabels(NoAwaitTag, google::cloud::cpp::compute::snapshots::v1::SetLabelsRequest const &)

Parameters
Name Description
NoAwaitTag
request google::cloud::cpp::compute::snapshots::v1::SetLabelsRequest const &
Returns
Type Description
StatusOr< google::cloud::cpp::compute::v1::Operation >

virtual SetLabels(google::cloud::cpp::compute::v1::Operation const &)

Parameter
Name Description
operation google::cloud::cpp::compute::v1::Operation const &
Returns
Type Description
future< StatusOr< google::cloud::cpp::compute::v1::Operation > >

virtual TestIamPermissions(google::cloud::cpp::compute::snapshots::v1::TestIamPermissionsRequest const &)

Parameter
Name Description
request google::cloud::cpp::compute::snapshots::v1::TestIamPermissionsRequest const &
Returns
Type Description
StatusOr< google::cloud::cpp::compute::v1::TestPermissionsResponse >