Class RepositoryManagerClient (2.31.0-rc)

Manages connections to source code repositories.

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

RepositoryManagerClient(RepositoryManagerClient const &)

Copy and move support

Parameter
Name Description
RepositoryManagerClient const &

RepositoryManagerClient(RepositoryManagerClient &&)

Copy and move support

Parameter
Name Description
RepositoryManagerClient &&

RepositoryManagerClient(std::shared_ptr< RepositoryManagerConnection >, Options)

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

Operators

operator=(RepositoryManagerClient const &)

Copy and move support

Parameter
Name Description
RepositoryManagerClient const &
Returns
Type Description
RepositoryManagerClient &

operator=(RepositoryManagerClient &&)

Copy and move support

Parameter
Name Description
RepositoryManagerClient &&
Returns
Type Description
RepositoryManagerClient &

Functions

CreateConnection(std::string const &, google::devtools::cloudbuild::v2::Connection const &, std::string const &, Options)

Creates a Connection.

Parameters
Name Description
parent std::string const &

Required. Project and location where the connection will be created. Format: projects/*/locations/*.

connection google::devtools::cloudbuild::v2::Connection const &

Required. The Connection to create.

connection_id std::string const &

Required. The ID to use for the Connection, which will become the final component of the Connection's resource name. Names must be unique per-project per-location. Allows alphanumeric characters and any of -._~%!$&'()*+,;=.

opts Options

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

Returns
Type Description
future< StatusOr< google::devtools::cloudbuild::v2::Connection > >

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.devtools.cloudbuild.v2.Connection proto message. The C++ class representing this message is created by Protobuf, using the Protobuf mapping rules.

CreateConnection(NoAwaitTag, std::string const &, google::devtools::cloudbuild::v2::Connection const &, std::string const &, Options)

Creates a Connection.

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
parent std::string const &
connection google::devtools::cloudbuild::v2::Connection const &
connection_id std::string const &
opts Options
Returns
Type Description
StatusOr< google::longrunning::Operation >

CreateConnection(google::devtools::cloudbuild::v2::CreateConnectionRequest const &, Options)

Creates a Connection.

Parameters
Name Description
request google::devtools::cloudbuild::v2::CreateConnectionRequest 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.devtools.cloudbuild.v2.CreateConnectionRequest. 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::devtools::cloudbuild::v2::Connection > >

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.devtools.cloudbuild.v2.Connection proto message. The C++ class representing this message is created by Protobuf, using the Protobuf mapping rules.

CreateConnection(NoAwaitTag, google::devtools::cloudbuild::v2::CreateConnectionRequest const &, Options)

Creates a Connection.

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::devtools::cloudbuild::v2::CreateConnectionRequest const &
opts Options
Returns
Type Description
StatusOr< google::longrunning::Operation >

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

Creates a Connection.

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::devtools::cloudbuild::v2::Connection > >

GetConnection(std::string const &, Options)

Gets details of a single connection.

Parameters
Name Description
name std::string const &

Required. The name of the Connection to retrieve. Format: projects/*/locations/*/connections/*.

opts Options

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

Returns
Type Description
StatusOr< google::devtools::cloudbuild::v2::Connection >

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

GetConnection(google::devtools::cloudbuild::v2::GetConnectionRequest const &, Options)

Gets details of a single connection.

Parameters
Name Description
request google::devtools::cloudbuild::v2::GetConnectionRequest 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.devtools.cloudbuild.v2.GetConnectionRequest. 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::devtools::cloudbuild::v2::Connection >

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

ListConnections(std::string const &, Options)

Lists Connections in a given project and location.

Parameters
Name Description
parent std::string const &

Required. The parent, which owns this collection of Connections. Format: projects/*/locations/*.

opts Options

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

Returns
Type Description
StreamRange< google::devtools::cloudbuild::v2::Connection >

a StreamRange to iterate of the results. See the documentation of this type for details. In brief, this class has begin() and end() member functions returning a iterator class meeting the input iterator requirements. The value type for this iterator is a StatusOr as the iteration may fail even after some values are retrieved successfully, for example, if there is a network disconnect. An empty set of results does not indicate an error, it indicates that there are no resources meeting the request criteria. On a successful iteration the StatusOr<T> contains elements of type google.devtools.cloudbuild.v2.Connection, or rather, the C++ class generated by Protobuf from that type. Please consult the Protobuf documentation for details on the Protobuf mapping rules.

ListConnections(google::devtools::cloudbuild::v2::ListConnectionsRequest, Options)

Lists Connections in a given project and location.

Parameters
Name Description
request google::devtools::cloudbuild::v2::ListConnectionsRequest

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.devtools.cloudbuild.v2.ListConnectionsRequest. 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
StreamRange< google::devtools::cloudbuild::v2::Connection >

a StreamRange to iterate of the results. See the documentation of this type for details. In brief, this class has begin() and end() member functions returning a iterator class meeting the input iterator requirements. The value type for this iterator is a StatusOr as the iteration may fail even after some values are retrieved successfully, for example, if there is a network disconnect. An empty set of results does not indicate an error, it indicates that there are no resources meeting the request criteria. On a successful iteration the StatusOr<T> contains elements of type google.devtools.cloudbuild.v2.Connection, or rather, the C++ class generated by Protobuf from that type. Please consult the Protobuf documentation for details on the Protobuf mapping rules.

UpdateConnection(google::devtools::cloudbuild::v2::Connection const &, google::protobuf::FieldMask const &, Options)

Updates a single connection.

Parameters
Name Description
connection google::devtools::cloudbuild::v2::Connection const &

Required. The Connection to update.

update_mask google::protobuf::FieldMask const &

The list of fields to be updated.

opts Options

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

Returns
Type Description
future< StatusOr< google::devtools::cloudbuild::v2::Connection > >

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.devtools.cloudbuild.v2.Connection proto message. The C++ class representing this message is created by Protobuf, using the Protobuf mapping rules.

UpdateConnection(NoAwaitTag, google::devtools::cloudbuild::v2::Connection const &, google::protobuf::FieldMask const &, Options)

Updates a single connection.

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
connection google::devtools::cloudbuild::v2::Connection const &
update_mask google::protobuf::FieldMask const &
opts Options
Returns
Type Description
StatusOr< google::longrunning::Operation >

UpdateConnection(google::devtools::cloudbuild::v2::UpdateConnectionRequest const &, Options)

Updates a single connection.

Parameters
Name Description
request google::devtools::cloudbuild::v2::UpdateConnectionRequest 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.devtools.cloudbuild.v2.UpdateConnectionRequest. 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::devtools::cloudbuild::v2::Connection > >

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.devtools.cloudbuild.v2.Connection proto message. The C++ class representing this message is created by Protobuf, using the Protobuf mapping rules.

UpdateConnection(NoAwaitTag, google::devtools::cloudbuild::v2::UpdateConnectionRequest const &, Options)

Updates a single connection.

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::devtools::cloudbuild::v2::UpdateConnectionRequest const &
opts Options
Returns
Type Description
StatusOr< google::longrunning::Operation >

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

Updates a single connection.

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::devtools::cloudbuild::v2::Connection > >

DeleteConnection(std::string const &, Options)

Deletes a single connection.

Parameters
Name Description
name std::string const &

Required. The name of the Connection to delete. Format: projects/*/locations/*/connections/*.

opts Options

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

Returns
Type Description
future< StatusOr< google::devtools::cloudbuild::v2::OperationMetadata > >

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.devtools.cloudbuild.v2.OperationMetadata proto message. The C++ class representing this message is created by Protobuf, using the Protobuf mapping rules.

DeleteConnection(NoAwaitTag, std::string const &, Options)

Deletes a single connection.

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
name std::string const &
opts Options
Returns
Type Description
StatusOr< google::longrunning::Operation >

DeleteConnection(google::devtools::cloudbuild::v2::DeleteConnectionRequest const &, Options)

Deletes a single connection.

Parameters
Name Description
request google::devtools::cloudbuild::v2::DeleteConnectionRequest 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.devtools.cloudbuild.v2.DeleteConnectionRequest. 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::devtools::cloudbuild::v2::OperationMetadata > >

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.devtools.cloudbuild.v2.OperationMetadata proto message. The C++ class representing this message is created by Protobuf, using the Protobuf mapping rules.

DeleteConnection(NoAwaitTag, google::devtools::cloudbuild::v2::DeleteConnectionRequest const &, Options)

Deletes a single connection.

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::devtools::cloudbuild::v2::DeleteConnectionRequest const &
opts Options
Returns
Type Description
StatusOr< google::longrunning::Operation >

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

Deletes a single connection.

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::devtools::cloudbuild::v2::OperationMetadata > >

CreateRepository(std::string const &, google::devtools::cloudbuild::v2::Repository const &, std::string const &, Options)

Creates a Repository.

Parameters
Name Description
parent std::string const &

Required. The connection to contain the repository. If the request is part of a BatchCreateRepositoriesRequest, this field should be empty or match the parent specified there.

repository google::devtools::cloudbuild::v2::Repository const &

Required. The repository to create.

repository_id std::string const &

Required. The ID to use for the repository, which will become the final component of the repository's resource name. This ID should be unique in the connection. Allows alphanumeric characters and any of -._~%!$&'()*+,;=.

opts Options

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

Returns
Type Description
future< StatusOr< google::devtools::cloudbuild::v2::Repository > >

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.devtools.cloudbuild.v2.Repository proto message. The C++ class representing this message is created by Protobuf, using the Protobuf mapping rules.

CreateRepository(NoAwaitTag, std::string const &, google::devtools::cloudbuild::v2::Repository const &, std::string const &, Options)

Creates a Repository.

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
parent std::string const &
repository google::devtools::cloudbuild::v2::Repository const &
repository_id std::string const &
opts Options
Returns
Type Description
StatusOr< google::longrunning::Operation >

CreateRepository(google::devtools::cloudbuild::v2::CreateRepositoryRequest const &, Options)

Creates a Repository.

Parameters
Name Description
request google::devtools::cloudbuild::v2::CreateRepositoryRequest 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.devtools.cloudbuild.v2.CreateRepositoryRequest. 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::devtools::cloudbuild::v2::Repository > >

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.devtools.cloudbuild.v2.Repository proto message. The C++ class representing this message is created by Protobuf, using the Protobuf mapping rules.

CreateRepository(NoAwaitTag, google::devtools::cloudbuild::v2::CreateRepositoryRequest const &, Options)

Creates a Repository.

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::devtools::cloudbuild::v2::CreateRepositoryRequest const &
opts Options
Returns
Type Description
StatusOr< google::longrunning::Operation >

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

Creates a Repository.

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::devtools::cloudbuild::v2::Repository > >

BatchCreateRepositories(std::string const &, std::vector< google::devtools::cloudbuild::v2::CreateRepositoryRequest > const &, Options)

Creates multiple repositories inside a connection.

Parameters
Name Description
parent std::string const &

Required. The connection to contain all the repositories being created. Format: projects//locations//connections/* The parent field in the CreateRepositoryRequest messages must either be empty or match this field.

requests std::vector< google::devtools::cloudbuild::v2::CreateRepositoryRequest > const &

Required. The request messages specifying the repositories to create.

opts Options

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

Returns
Type Description
future< StatusOr< google::devtools::cloudbuild::v2::BatchCreateRepositoriesResponse > >

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.devtools.cloudbuild.v2.BatchCreateRepositoriesResponse proto message. The C++ class representing this message is created by Protobuf, using the Protobuf mapping rules.

BatchCreateRepositories(NoAwaitTag, std::string const &, std::vector< google::devtools::cloudbuild::v2::CreateRepositoryRequest > const &, Options)

Creates multiple repositories inside a connection.

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
parent std::string const &
requests std::vector< google::devtools::cloudbuild::v2::CreateRepositoryRequest > const &
opts Options
Returns
Type Description
StatusOr< google::longrunning::Operation >

BatchCreateRepositories(google::devtools::cloudbuild::v2::BatchCreateRepositoriesRequest const &, Options)

Creates multiple repositories inside a connection.

Parameters
Name Description
request google::devtools::cloudbuild::v2::BatchCreateRepositoriesRequest 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.devtools.cloudbuild.v2.BatchCreateRepositoriesRequest. 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::devtools::cloudbuild::v2::BatchCreateRepositoriesResponse > >

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.devtools.cloudbuild.v2.BatchCreateRepositoriesResponse proto message. The C++ class representing this message is created by Protobuf, using the Protobuf mapping rules.

BatchCreateRepositories(NoAwaitTag, google::devtools::cloudbuild::v2::BatchCreateRepositoriesRequest const &, Options)

Creates multiple repositories inside a connection.

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::devtools::cloudbuild::v2::BatchCreateRepositoriesRequest const &
opts Options
Returns
Type Description
StatusOr< google::longrunning::Operation >

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

Creates multiple repositories inside a connection.

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::devtools::cloudbuild::v2::BatchCreateRepositoriesResponse > >

GetRepository(std::string const &, Options)

Gets details of a single repository.

Parameters
Name Description
name std::string const &

Required. The name of the Repository to retrieve. Format: projects/*/locations/*/connections/*/repositories/*.

opts Options

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

Returns
Type Description
StatusOr< google::devtools::cloudbuild::v2::Repository >

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

GetRepository(google::devtools::cloudbuild::v2::GetRepositoryRequest const &, Options)

Gets details of a single repository.

Parameters
Name Description
request google::devtools::cloudbuild::v2::GetRepositoryRequest 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.devtools.cloudbuild.v2.GetRepositoryRequest. 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::devtools::cloudbuild::v2::Repository >

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

ListRepositories(std::string const &, Options)

Lists Repositories in a given connection.

Parameters
Name Description
parent std::string const &

Required. The parent, which owns this collection of Repositories. Format: projects/*/locations/*/connections/*.

opts Options

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

Returns
Type Description
StreamRange< google::devtools::cloudbuild::v2::Repository >

a StreamRange to iterate of the results. See the documentation of this type for details. In brief, this class has begin() and end() member functions returning a iterator class meeting the input iterator requirements. The value type for this iterator is a StatusOr as the iteration may fail even after some values are retrieved successfully, for example, if there is a network disconnect. An empty set of results does not indicate an error, it indicates that there are no resources meeting the request criteria. On a successful iteration the StatusOr<T> contains elements of type google.devtools.cloudbuild.v2.Repository, or rather, the C++ class generated by Protobuf from that type. Please consult the Protobuf documentation for details on the Protobuf mapping rules.

ListRepositories(google::devtools::cloudbuild::v2::ListRepositoriesRequest, Options)

Lists Repositories in a given connection.

Parameters
Name Description
request google::devtools::cloudbuild::v2::ListRepositoriesRequest

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.devtools.cloudbuild.v2.ListRepositoriesRequest. 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
StreamRange< google::devtools::cloudbuild::v2::Repository >

a StreamRange to iterate of the results. See the documentation of this type for details. In brief, this class has begin() and end() member functions returning a iterator class meeting the input iterator requirements. The value type for this iterator is a StatusOr as the iteration may fail even after some values are retrieved successfully, for example, if there is a network disconnect. An empty set of results does not indicate an error, it indicates that there are no resources meeting the request criteria. On a successful iteration the StatusOr<T> contains elements of type google.devtools.cloudbuild.v2.Repository, or rather, the C++ class generated by Protobuf from that type. Please consult the Protobuf documentation for details on the Protobuf mapping rules.

DeleteRepository(std::string const &, Options)

Deletes a single repository.

Parameters
Name Description
name std::string const &

Required. The name of the Repository to delete. Format: projects/*/locations/*/connections/*/repositories/*.

opts Options

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

Returns
Type Description
future< StatusOr< google::devtools::cloudbuild::v2::OperationMetadata > >

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.devtools.cloudbuild.v2.OperationMetadata proto message. The C++ class representing this message is created by Protobuf, using the Protobuf mapping rules.

DeleteRepository(NoAwaitTag, std::string const &, Options)

Deletes a single repository.

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
name std::string const &
opts Options
Returns
Type Description
StatusOr< google::longrunning::Operation >

DeleteRepository(google::devtools::cloudbuild::v2::DeleteRepositoryRequest const &, Options)

Deletes a single repository.

Parameters
Name Description
request google::devtools::cloudbuild::v2::DeleteRepositoryRequest 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.devtools.cloudbuild.v2.DeleteRepositoryRequest. 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::devtools::cloudbuild::v2::OperationMetadata > >

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.devtools.cloudbuild.v2.OperationMetadata proto message. The C++ class representing this message is created by Protobuf, using the Protobuf mapping rules.

DeleteRepository(NoAwaitTag, google::devtools::cloudbuild::v2::DeleteRepositoryRequest const &, Options)

Deletes a single repository.

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::devtools::cloudbuild::v2::DeleteRepositoryRequest const &
opts Options
Returns
Type Description
StatusOr< google::longrunning::Operation >

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

Deletes a single repository.

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::devtools::cloudbuild::v2::OperationMetadata > >

FetchReadWriteToken(std::string const &, Options)

Fetches read/write token of a given repository.

Parameters
Name Description
repository std::string const &

Required. The resource name of the repository in the format projects/*/locations/*/connections/*/repositories/*.

opts Options

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

Returns
Type Description
StatusOr< google::devtools::cloudbuild::v2::FetchReadWriteTokenResponse >

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

FetchReadWriteToken(google::devtools::cloudbuild::v2::FetchReadWriteTokenRequest const &, Options)

Fetches read/write token of a given repository.

Parameters
Name Description
request google::devtools::cloudbuild::v2::FetchReadWriteTokenRequest 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.devtools.cloudbuild.v2.FetchReadWriteTokenRequest. 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::devtools::cloudbuild::v2::FetchReadWriteTokenResponse >

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

FetchReadToken(std::string const &, Options)

Fetches read token of a given repository.

Parameters
Name Description
repository std::string const &

Required. The resource name of the repository in the format projects/*/locations/*/connections/*/repositories/*.

opts Options

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

Returns
Type Description
StatusOr< google::devtools::cloudbuild::v2::FetchReadTokenResponse >

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

FetchReadToken(google::devtools::cloudbuild::v2::FetchReadTokenRequest const &, Options)

Fetches read token of a given repository.

Parameters
Name Description
request google::devtools::cloudbuild::v2::FetchReadTokenRequest 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.devtools.cloudbuild.v2.FetchReadTokenRequest. 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::devtools::cloudbuild::v2::FetchReadTokenResponse >

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

FetchLinkableRepositories(google::devtools::cloudbuild::v2::FetchLinkableRepositoriesRequest, Options)

FetchLinkableRepositories get repositories from SCM that are accessible and could be added to the connection.

Parameters
Name Description
request google::devtools::cloudbuild::v2::FetchLinkableRepositoriesRequest

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.devtools.cloudbuild.v2.FetchLinkableRepositoriesRequest. 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
StreamRange< google::devtools::cloudbuild::v2::Repository >

a StreamRange to iterate of the results. See the documentation of this type for details. In brief, this class has begin() and end() member functions returning a iterator class meeting the input iterator requirements. The value type for this iterator is a StatusOr as the iteration may fail even after some values are retrieved successfully, for example, if there is a network disconnect. An empty set of results does not indicate an error, it indicates that there are no resources meeting the request criteria. On a successful iteration the StatusOr<T> contains elements of type google.devtools.cloudbuild.v2.Repository, or rather, the C++ class generated by Protobuf from that type. Please consult the Protobuf documentation for details on the Protobuf mapping rules.

FetchGitRefs(std::string const &, Options)

Fetch the list of branches or tags for a given repository.

Parameters
Name Description
repository std::string const &

Required. The resource name of the repository in the format projects/*/locations/*/connections/*/repositories/*.

opts Options

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

Returns
Type Description
StatusOr< google::devtools::cloudbuild::v2::FetchGitRefsResponse >

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

FetchGitRefs(google::devtools::cloudbuild::v2::FetchGitRefsRequest const &, Options)

Fetch the list of branches or tags for a given repository.

Parameters
Name Description
request google::devtools::cloudbuild::v2::FetchGitRefsRequest 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.devtools.cloudbuild.v2.FetchGitRefsRequest. 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::devtools::cloudbuild::v2::FetchGitRefsResponse >

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

SetIamPolicy(google::iam::v1::SetIamPolicyRequest const &, Options)

Sets the access control policy on the specified resource.

Replaces any existing policy.

Can return NOT_FOUND, INVALID_ARGUMENT, and PERMISSION_DENIED errors.

Parameters
Name Description
request google::iam::v1::SetIamPolicyRequest 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.iam.v1.SetIamPolicyRequest. 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::iam::v1::Policy >

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

GetIamPolicy(google::iam::v1::GetIamPolicyRequest const &, Options)

Gets the access control policy for a resource.

Returns an empty policy if the resource exists and does not have a policy set.

Parameters
Name Description
request google::iam::v1::GetIamPolicyRequest 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.iam.v1.GetIamPolicyRequest. 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::iam::v1::Policy >

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

TestIamPermissions(google::iam::v1::TestIamPermissionsRequest const &, Options)

Returns permissions that a caller has on the specified resource.

If the resource does not exist, this will return an empty set of permissions, not a NOT_FOUND error.

Note: This operation is designed to be used for building permission-aware UIs and command-line tools, not for authorization checking. This operation may "fail open" without warning.

Parameters
Name Description
request google::iam::v1::TestIamPermissionsRequest 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.iam.v1.TestIamPermissionsRequest. 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::iam::v1::TestIamPermissionsResponse >

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

GetOperation(std::string const &, Options)

Gets the latest state of a long-running operation.

Clients can use this method to poll the operation result at intervals as recommended by the API service.

Parameters
Name Description
name std::string const &

The name of the operation resource.

opts Options

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

Returns
Type Description
StatusOr< google::longrunning::Operation >

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

GetOperation(google::longrunning::GetOperationRequest const &, Options)

Gets the latest state of a long-running operation.

Clients can use this method to poll the operation result at intervals as recommended by the API service.

Parameters
Name Description
request google::longrunning::GetOperationRequest 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.longrunning.GetOperationRequest. 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::longrunning::Operation >

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

CancelOperation(std::string const &, Options)

Starts asynchronous cancellation on a long-running operation.

The server makes a best effort to cancel the operation, but success is not guaranteed. If the server doesn't support this method, it returns google.rpc.Code.UNIMPLEMENTED. Clients can use Operations.GetOperation or other methods to check whether the cancellation succeeded or whether the operation completed despite cancellation. On successful cancellation, the operation is not deleted; instead, it becomes an operation with an Operation.error value with a google.rpc.Status.code of 1, corresponding to Code.CANCELLED.

Parameters
Name Description
name std::string const &

The name of the operation resource to be cancelled.

opts Options

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

Returns
Type Description
Status

a Status object. If the request failed, the status contains the details of the failure.

CancelOperation(google::longrunning::CancelOperationRequest const &, Options)

Starts asynchronous cancellation on a long-running operation.

The server makes a best effort to cancel the operation, but success is not guaranteed. If the server doesn't support this method, it returns google.rpc.Code.UNIMPLEMENTED. Clients can use Operations.GetOperation or other methods to check whether the cancellation succeeded or whether the operation completed despite cancellation. On successful cancellation, the operation is not deleted; instead, it becomes an operation with an Operation.error value with a google.rpc.Status.code of 1, corresponding to Code.CANCELLED.

Parameters
Name Description
request google::longrunning::CancelOperationRequest 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.longrunning.CancelOperationRequest. 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
Status

a Status object. If the request failed, the status contains the details of the failure.