Class EncryptionSpecServiceClient (2.30.0)

Manages encryption spec settings for Dialogflow and Agent Assist.

Equality

Instances of this class created via copy-construction or copy-assignment always compare equal. Instances created with equal std::shared_ptr<*Connection> objects compare equal. Objects that compare equal share the same underlying resources.

Performance

Creating a new instance of this class is a relatively expensive operation, new objects establish new connections to the service. In contrast, copy-construction, move-construction, and the corresponding assignment operations are relatively efficient as the copies share all underlying resources.

Thread Safety

Concurrent access to different instances of this class, even if they compare equal, is guaranteed to work. Two or more threads operating on the same instance of this class is not guaranteed to work. Since copy-construction and move-construction is a relatively efficient operation, consider using such a copy when using this class from multiple threads.

Constructors

EncryptionSpecServiceClient(EncryptionSpecServiceClient const &)

Copy and move support

Parameter
Name Description
EncryptionSpecServiceClient const &

EncryptionSpecServiceClient(EncryptionSpecServiceClient &&)

Copy and move support

Parameter
Name Description
EncryptionSpecServiceClient &&

EncryptionSpecServiceClient(std::shared_ptr< EncryptionSpecServiceConnection >, Options)

Parameters
Name Description
connection std::shared_ptr< EncryptionSpecServiceConnection >
opts Options

Operators

operator=(EncryptionSpecServiceClient const &)

Copy and move support

Parameter
Name Description
EncryptionSpecServiceClient const &
Returns
Type Description
EncryptionSpecServiceClient &

operator=(EncryptionSpecServiceClient &&)

Copy and move support

Parameter
Name Description
EncryptionSpecServiceClient &&
Returns
Type Description
EncryptionSpecServiceClient &

Functions

GetEncryptionSpec(std::string const &, Options)

Gets location-level encryption key specification.

Parameters
Name Description
name std::string const &

Required. The name of the encryption spec resource to get.

opts Options

Optional. Override the class-level options, such as retry and backoff policies.

Returns
Type Description
StatusOr< google::cloud::dialogflow::v2::EncryptionSpec >

the result of the RPC. The response message type (google.cloud.dialogflow.v2.EncryptionSpec) is mapped to a C++ class using the Protobuf mapping rules. If the request fails, the StatusOr contains the error details.

GetEncryptionSpec(google::cloud::dialogflow::v2::GetEncryptionSpecRequest const &, Options)

Gets location-level encryption key specification.

Parameters
Name Description
request google::cloud::dialogflow::v2::GetEncryptionSpecRequest const &

Unary RPCs, such as the one wrapped by this function, receive a single request proto message which includes all the inputs for the RPC. In this case, the proto message is a google.cloud.dialogflow.v2.GetEncryptionSpecRequest. Proto messages are converted to C++ classes by Protobuf, using the Protobuf mapping rules.

opts Options

Optional. Override the class-level options, such as retry and backoff policies.

Returns
Type Description
StatusOr< google::cloud::dialogflow::v2::EncryptionSpec >

the result of the RPC. The response message type (google.cloud.dialogflow.v2.EncryptionSpec) is mapped to a C++ class using the Protobuf mapping rules. If the request fails, the StatusOr contains the error details.

InitializeEncryptionSpec(google::cloud::dialogflow::v2::EncryptionSpec const &, Options)

Initializes a location-level encryption key specification.

An error will be thrown if the location has resources already created before the initialization. Once the encryption specification is initialized at a location, it is immutable and all newly created resources under the location will be encrypted with the existing specification.

Parameters
Name Description
encryption_spec google::cloud::dialogflow::v2::EncryptionSpec const &

Required. The encryption spec used for CMEK encryption. It is required that the kms key is in the same region as the endpoint. The same key will be used for all provisioned resources, if encryption is available. If the kms_key_name is left empty, no encryption will be enforced.

opts Options

Optional. Override the class-level options, such as retry and backoff policies.

Returns
Type Description
future< StatusOr< google::cloud::dialogflow::v2::InitializeEncryptionSpecResponse > >

A future that becomes satisfied when the LRO (Long Running Operation) completes or the polling policy in effect for this call is exhausted. The future is satisfied with an error if the LRO completes with an error or the polling policy is exhausted. In this case the StatusOr returned by the future contains the error. If the LRO completes successfully the value of the future contains the LRO's result. For this RPC the result is a google.cloud.dialogflow.v2.InitializeEncryptionSpecResponse proto message. The C++ class representing this message is created by Protobuf, using the Protobuf mapping rules.

InitializeEncryptionSpec(NoAwaitTag, google::cloud::dialogflow::v2::EncryptionSpec const &, Options)

Initializes a location-level encryption key specification.

Specifying the NoAwaitTag immediately returns the [google::longrunning::Operation] that corresponds to the Long Running Operation that has been started. No polling for operation status occurs.

Parameters
Name Description
NoAwaitTag
encryption_spec google::cloud::dialogflow::v2::EncryptionSpec const &
opts Options
Returns
Type Description
StatusOr< google::longrunning::Operation >

InitializeEncryptionSpec(google::cloud::dialogflow::v2::InitializeEncryptionSpecRequest const &, Options)

Initializes a location-level encryption key specification.

An error will be thrown if the location has resources already created before the initialization. Once the encryption specification is initialized at a location, it is immutable and all newly created resources under the location will be encrypted with the existing specification.

Parameters
Name Description
request google::cloud::dialogflow::v2::InitializeEncryptionSpecRequest const &

Unary RPCs, such as the one wrapped by this function, receive a single request proto message which includes all the inputs for the RPC. In this case, the proto message is a google.cloud.dialogflow.v2.InitializeEncryptionSpecRequest. Proto messages are converted to C++ classes by Protobuf, using the Protobuf mapping rules.

opts Options

Optional. Override the class-level options, such as retry and backoff policies.

Returns
Type Description
future< StatusOr< google::cloud::dialogflow::v2::InitializeEncryptionSpecResponse > >

A future that becomes satisfied when the LRO (Long Running Operation) completes or the polling policy in effect for this call is exhausted. The future is satisfied with an error if the LRO completes with an error or the polling policy is exhausted. In this case the StatusOr returned by the future contains the error. If the LRO completes successfully the value of the future contains the LRO's result. For this RPC the result is a google.cloud.dialogflow.v2.InitializeEncryptionSpecResponse proto message. The C++ class representing this message is created by Protobuf, using the Protobuf mapping rules.

InitializeEncryptionSpec(NoAwaitTag, google::cloud::dialogflow::v2::InitializeEncryptionSpecRequest const &, Options)

Initializes a location-level encryption key specification.

Specifying the NoAwaitTag immediately returns the [google::longrunning::Operation] that corresponds to the Long Running Operation that has been started. No polling for operation status occurs.

Parameters
Name Description
NoAwaitTag
request google::cloud::dialogflow::v2::InitializeEncryptionSpecRequest const &
opts Options
Returns
Type Description
StatusOr< google::longrunning::Operation >

InitializeEncryptionSpec(google::longrunning::Operation const &, Options)

Initializes a location-level encryption key specification.

This method accepts a google::longrunning::Operation that corresponds to a previously started Long Running Operation (LRO) and polls the status of the LRO in the background.

Parameters
Name Description
operation google::longrunning::Operation const &
opts Options
Returns
Type Description
future< StatusOr< google::cloud::dialogflow::v2::InitializeEncryptionSpecResponse > >