# Storage Batch Operations V1 API - Class Google::Cloud::StorageBatchOperations::V1::StorageBatchOperations::Rest::Client (v0.10.0)

0.10.0 (latest) 0.9.0 0.8.1 0.7.0 0.6.0 0.5.0 0.4.1 0.3.0 0.2.0 0.1.3 Reference documentation and code samples for the Storage Batch Operations V1 API class Google::Cloud::StorageBatchOperations::V1::StorageBatchOperations::Rest::Client.

REST client for the StorageBatchOperations service.


<br />

Storage Batch Operations offers a managed experience to perform batch
operations on millions of Cloud Storage objects in a serverless fashion. With
this service, you can automate and simplify large scale API operations
performed on Cloud Storage objects.

## Inherits

- Object

## Includes

- [Google::Cloud::StorageBatchOperations::V1::StorageBatchOperations::Paths](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-storage_batch_operations-v1/latest/Google-Cloud-StorageBatchOperations-V1-StorageBatchOperations-Paths)

## Methods

### .configure

    def self.configure() { |config| ... } -> Client::Configuration

Configure the StorageBatchOperations Client class.


<br />

See [Configuration](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-storage_batch_operations-v1/latest/Google-Cloud-StorageBatchOperations-V1-StorageBatchOperations-Rest-Client-Configuration "Google::Cloud::StorageBatchOperations::V1::StorageBatchOperations::Rest::Client::Configuration (class)")
for a description of the configuration fields.
**Yields**

- (config) --- Configure the Client client.
**Yield Parameter**

- **config** ([Client::Configuration](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-storage_batch_operations-v1/latest/Google-Cloud-StorageBatchOperations-V1-StorageBatchOperations-Rest-Client-Configuration))
**Returns**

- ([Client::Configuration](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-storage_batch_operations-v1/latest/Google-Cloud-StorageBatchOperations-V1-StorageBatchOperations-Rest-Client-Configuration))
**Example**

```ruby
# Modify the configuration for all StorageBatchOperations clients
::Google::Cloud::StorageBatchOperations::V1::StorageBatchOperations::Rest::Client.configure do |config|
  config.timeout = 10.0
end
```

### #cancel_job

    def cancel_job(request, options = nil) -> ::Google::Cloud::StorageBatchOperations::V1::CancelJobResponse
    def cancel_job(name: nil, request_id: nil) -> ::Google::Cloud::StorageBatchOperations::V1::CancelJobResponse

Cancels a batch job.
**Overloads**

    def cancel_job(request, options = nil) -> ::Google::Cloud::StorageBatchOperations::V1::CancelJobResponse

Pass arguments to `cancel_job` via a request object, either of type [CancelJobRequest](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-storage_batch_operations-v1/latest/Google-Cloud-StorageBatchOperations-V1-CancelJobRequest "Google::Cloud::StorageBatchOperations::V1::CancelJobRequest (class)") or an equivalent Hash. **Parameters**

- **request** ([::Google::Cloud::StorageBatchOperations::V1::CancelJobRequest](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-storage_batch_operations-v1/latest/Google-Cloud-StorageBatchOperations-V1-CancelJobRequest), ::Hash) --- A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
- **options** (::Gapic::CallOptions, ::Hash) --- Overrides the default settings for this call, e.g, timeout, retries etc. Optional.

    def cancel_job(name: nil, request_id: nil) -> ::Google::Cloud::StorageBatchOperations::V1::CancelJobResponse

Pass arguments to `cancel_job` via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above). **Parameters**

- **name** (::String) --- Required. The `name` of the job to cancel. Format: projects/{project_id}/locations/global/jobs/{job_id}.
- **request_id** (::String) --- Optional. An optional request ID to identify requests. Specify a unique request ID in case you need to retry your request. Requests with same `request_id` will be ignored for at least 60 minutes since the first request. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000).
**Yields**

- (result, operation) --- Access the result along with the TransportOperation object
**Yield Parameters**

- **result** ([::Google::Cloud::StorageBatchOperations::V1::CancelJobResponse](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-storage_batch_operations-v1/latest/Google-Cloud-StorageBatchOperations-V1-CancelJobResponse))
- **operation** (::Gapic::Rest::TransportOperation)
**Returns**

- ([::Google::Cloud::StorageBatchOperations::V1::CancelJobResponse](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-storage_batch_operations-v1/latest/Google-Cloud-StorageBatchOperations-V1-CancelJobResponse))
**Raises**

- (::Google::Cloud::Error) --- if the REST call is aborted.
**Example**

Basic example

```ruby
require "google/cloud/storage_batch_operations/v1"

# Create a client object. The client can be reused for multiple calls.
client = Google::Cloud::StorageBatchOperations::V1::StorageBatchOperations::Rest::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Cloud::StorageBatchOperations::V1::CancelJobRequest.new

# Call the cancel_job method.
result = client.cancel_job request

# The returned object is of type Google::Cloud::StorageBatchOperations::V1::CancelJobResponse.
p result
```

### #configure

    def configure() { |config| ... } -> Client::Configuration

Configure the StorageBatchOperations Client instance.


The configuration is set to the derived mode, meaning that values can be changed,
but structural changes (adding new fields, etc.) are not allowed. Structural changes
should be made on [Client.configure](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-storage_batch_operations-v1/latest/Google-Cloud-StorageBatchOperations-V1-StorageBatchOperations-Rest-Client#Google__Cloud__StorageBatchOperations__V1__StorageBatchOperations__Rest__Client_configure_class_ "Google::Cloud::StorageBatchOperations::V1::StorageBatchOperations::Rest::Client.configure (method)").

<br />

See [Configuration](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-storage_batch_operations-v1/latest/Google-Cloud-StorageBatchOperations-V1-StorageBatchOperations-Rest-Client-Configuration "Google::Cloud::StorageBatchOperations::V1::StorageBatchOperations::Rest::Client::Configuration (class)")
for a description of the configuration fields.
**Yields**

- (config) --- Configure the Client client.
**Yield Parameter**

- **config** ([Client::Configuration](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-storage_batch_operations-v1/latest/Google-Cloud-StorageBatchOperations-V1-StorageBatchOperations-Rest-Client-Configuration))
**Returns**

- ([Client::Configuration](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-storage_batch_operations-v1/latest/Google-Cloud-StorageBatchOperations-V1-StorageBatchOperations-Rest-Client-Configuration))

### #create_job

    def create_job(request, options = nil) -> ::Gapic::Operation
    def create_job(parent: nil, job_id: nil, job: nil, request_id: nil) -> ::Gapic::Operation

Creates a batch job.
**Overloads**

    def create_job(request, options = nil) -> ::Gapic::Operation

Pass arguments to `create_job` via a request object, either of type [CreateJobRequest](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-storage_batch_operations-v1/latest/Google-Cloud-StorageBatchOperations-V1-CreateJobRequest "Google::Cloud::StorageBatchOperations::V1::CreateJobRequest (class)") or an equivalent Hash. **Parameters**

- **request** ([::Google::Cloud::StorageBatchOperations::V1::CreateJobRequest](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-storage_batch_operations-v1/latest/Google-Cloud-StorageBatchOperations-V1-CreateJobRequest), ::Hash) --- A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
- **options** (::Gapic::CallOptions, ::Hash) --- Overrides the default settings for this call, e.g, timeout, retries etc. Optional.

    def create_job(parent: nil, job_id: nil, job: nil, request_id: nil) -> ::Gapic::Operation

Pass arguments to `create_job` via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above). **Parameters**

- **parent** (::String) --- Required. Value for parent.
- **job_id** (::String) --- Required. The optional `job_id` for this Job . If not specified, an id is generated. `job_id` should be no more than 128 characters and must include only characters available in DNS names, as defined by RFC-1123.
- **job** ([::Google::Cloud::StorageBatchOperations::V1::Job](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-storage_batch_operations-v1/latest/Google-Cloud-StorageBatchOperations-V1-Job), ::Hash) --- Required. The resource being created
- **request_id** (::String) --- Optional. An optional request ID to identify requests. Specify a unique request ID in case you need to retry your request. Requests with same `request_id` will be ignored for at least 60 minutes since the first request. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000).
**Yields**

- (result, operation) --- Access the result along with the TransportOperation object
**Yield Parameters**

- **result** (::Gapic::Operation)
- **operation** (::Gapic::Rest::TransportOperation)
**Returns**

- (::Gapic::Operation)
**Raises**

- (::Google::Cloud::Error) --- if the REST call is aborted.
**Example**

Basic example

```ruby
require "google/cloud/storage_batch_operations/v1"

# Create a client object. The client can be reused for multiple calls.
client = Google::Cloud::StorageBatchOperations::V1::StorageBatchOperations::Rest::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Cloud::StorageBatchOperations::V1::CreateJobRequest.new

# Call the create_job method.
result = client.create_job request

# The returned object is of type Gapic::Operation. You can use it to
# check the status of an operation, cancel it, or wait for results.
# Here is how to wait for a response.
result.wait_until_done! timeout: 60
if result.response?
  p result.response
else
  puts "No response received."
end
```

### #delete_job

    def delete_job(request, options = nil) -> ::Google::Protobuf::Empty
    def delete_job(name: nil, request_id: nil, force: nil) -> ::Google::Protobuf::Empty

Deletes a batch job.
**Overloads**

    def delete_job(request, options = nil) -> ::Google::Protobuf::Empty

Pass arguments to `delete_job` via a request object, either of type [DeleteJobRequest](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-storage_batch_operations-v1/latest/Google-Cloud-StorageBatchOperations-V1-DeleteJobRequest "Google::Cloud::StorageBatchOperations::V1::DeleteJobRequest (class)") or an equivalent Hash. **Parameters**

- **request** ([::Google::Cloud::StorageBatchOperations::V1::DeleteJobRequest](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-storage_batch_operations-v1/latest/Google-Cloud-StorageBatchOperations-V1-DeleteJobRequest), ::Hash) --- A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
- **options** (::Gapic::CallOptions, ::Hash) --- Overrides the default settings for this call, e.g, timeout, retries etc. Optional.

    def delete_job(name: nil, request_id: nil, force: nil) -> ::Google::Protobuf::Empty

Pass arguments to `delete_job` via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above). **Parameters**

- **name** (::String) --- Required. The `name` of the job to delete. Format: projects/{project_id}/locations/global/jobs/{job_id} .
- **request_id** (::String) --- Optional. An optional request ID to identify requests. Specify a unique request ID in case you need to retry your request. Requests with same `request_id` will be ignored for at least 60 minutes since the first request. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000).
- **force** (::Boolean) --- Optional. If set to true, any child bucket operations of the job will also be deleted. Highly recommended to be set to true by all clients. Users cannot mutate bucket operations directly, so only the jobs.delete permission is required to delete a job (and its child bucket operations).
**Yields**

- (result, operation) --- Access the result along with the TransportOperation object
**Yield Parameters**

- **result** ([::Google::Protobuf::Empty](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-storage_batch_operations-v1/latest/Google-Protobuf-Empty))
- **operation** (::Gapic::Rest::TransportOperation)
**Returns**

- ([::Google::Protobuf::Empty](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-storage_batch_operations-v1/latest/Google-Protobuf-Empty))
**Raises**

- (::Google::Cloud::Error) --- if the REST call is aborted.
**Example**

Basic example

```ruby
require "google/cloud/storage_batch_operations/v1"

# Create a client object. The client can be reused for multiple calls.
client = Google::Cloud::StorageBatchOperations::V1::StorageBatchOperations::Rest::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Cloud::StorageBatchOperations::V1::DeleteJobRequest.new

# Call the delete_job method.
result = client.delete_job request

# The returned object is of type Google::Protobuf::Empty.
p result
```

### #get_bucket_operation

    def get_bucket_operation(request, options = nil) -> ::Google::Cloud::StorageBatchOperations::V1::BucketOperation
    def get_bucket_operation(name: nil) -> ::Google::Cloud::StorageBatchOperations::V1::BucketOperation

Gets a BucketOperation.
**Overloads**

    def get_bucket_operation(request, options = nil) -> ::Google::Cloud::StorageBatchOperations::V1::BucketOperation

Pass arguments to `get_bucket_operation` via a request object, either of type [GetBucketOperationRequest](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-storage_batch_operations-v1/latest/Google-Cloud-StorageBatchOperations-V1-GetBucketOperationRequest "Google::Cloud::StorageBatchOperations::V1::GetBucketOperationRequest (class)") or an equivalent Hash. **Parameters**

- **request** ([::Google::Cloud::StorageBatchOperations::V1::GetBucketOperationRequest](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-storage_batch_operations-v1/latest/Google-Cloud-StorageBatchOperations-V1-GetBucketOperationRequest), ::Hash) --- A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
- **options** (::Gapic::CallOptions, ::Hash) --- Overrides the default settings for this call, e.g, timeout, retries etc. Optional.

    def get_bucket_operation(name: nil) -> ::Google::Cloud::StorageBatchOperations::V1::BucketOperation

Pass arguments to `get_bucket_operation` via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above). **Parameter**

- **name** (::String) --- Required. `name` of the bucket operation to retrieve. Format: projects/{project_id}/locations/global/jobs/{job_id}/bucketOperations/{bucket_operation_id}.
**Yields**

- (result, operation) --- Access the result along with the TransportOperation object
**Yield Parameters**

- **result** ([::Google::Cloud::StorageBatchOperations::V1::BucketOperation](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-storage_batch_operations-v1/latest/Google-Cloud-StorageBatchOperations-V1-BucketOperation))
- **operation** (::Gapic::Rest::TransportOperation)
**Returns**

- ([::Google::Cloud::StorageBatchOperations::V1::BucketOperation](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-storage_batch_operations-v1/latest/Google-Cloud-StorageBatchOperations-V1-BucketOperation))
**Raises**

- (::Google::Cloud::Error) --- if the REST call is aborted.
**Example**

Basic example

```ruby
require "google/cloud/storage_batch_operations/v1"

# Create a client object. The client can be reused for multiple calls.
client = Google::Cloud::StorageBatchOperations::V1::StorageBatchOperations::Rest::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Cloud::StorageBatchOperations::V1::GetBucketOperationRequest.new

# Call the get_bucket_operation method.
result = client.get_bucket_operation request

# The returned object is of type Google::Cloud::StorageBatchOperations::V1::BucketOperation.
p result
```

### #get_job

    def get_job(request, options = nil) -> ::Google::Cloud::StorageBatchOperations::V1::Job
    def get_job(name: nil) -> ::Google::Cloud::StorageBatchOperations::V1::Job

Gets a batch job.
**Overloads**

    def get_job(request, options = nil) -> ::Google::Cloud::StorageBatchOperations::V1::Job

Pass arguments to `get_job` via a request object, either of type [GetJobRequest](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-storage_batch_operations-v1/latest/Google-Cloud-StorageBatchOperations-V1-GetJobRequest "Google::Cloud::StorageBatchOperations::V1::GetJobRequest (class)") or an equivalent Hash. **Parameters**

- **request** ([::Google::Cloud::StorageBatchOperations::V1::GetJobRequest](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-storage_batch_operations-v1/latest/Google-Cloud-StorageBatchOperations-V1-GetJobRequest), ::Hash) --- A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
- **options** (::Gapic::CallOptions, ::Hash) --- Overrides the default settings for this call, e.g, timeout, retries etc. Optional.

    def get_job(name: nil) -> ::Google::Cloud::StorageBatchOperations::V1::Job

Pass arguments to `get_job` via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above). **Parameter**

- **name** (::String) --- Required. `name` of the job to retrieve. Format: projects/{project_id}/locations/global/jobs/{job_id} .
**Yields**

- (result, operation) --- Access the result along with the TransportOperation object
**Yield Parameters**

- **result** ([::Google::Cloud::StorageBatchOperations::V1::Job](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-storage_batch_operations-v1/latest/Google-Cloud-StorageBatchOperations-V1-Job))
- **operation** (::Gapic::Rest::TransportOperation)
**Returns**

- ([::Google::Cloud::StorageBatchOperations::V1::Job](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-storage_batch_operations-v1/latest/Google-Cloud-StorageBatchOperations-V1-Job))
**Raises**

- (::Google::Cloud::Error) --- if the REST call is aborted.
**Example**

Basic example

```ruby
require "google/cloud/storage_batch_operations/v1"

# Create a client object. The client can be reused for multiple calls.
client = Google::Cloud::StorageBatchOperations::V1::StorageBatchOperations::Rest::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Cloud::StorageBatchOperations::V1::GetJobRequest.new

# Call the get_job method.
result = client.get_job request

# The returned object is of type Google::Cloud::StorageBatchOperations::V1::Job.
p result
```

### #initialize

    def initialize() { |config| ... } -> Client

Create a new StorageBatchOperations REST client object.
**Yields**

- (config) --- Configure the StorageBatchOperations client.
**Yield Parameter**

- **config** ([Client::Configuration](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-storage_batch_operations-v1/latest/Google-Cloud-StorageBatchOperations-V1-StorageBatchOperations-Rest-Client-Configuration))
**Returns**

- ([Client](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-storage_batch_operations-v1/latest/Google-Cloud-StorageBatchOperations-V1-StorageBatchOperations-Rest-Client)) --- a new instance of Client
**Example**

```ruby
# Create a client using the default configuration
client = ::Google::Cloud::StorageBatchOperations::V1::StorageBatchOperations::Rest::Client.new

# Create a client using a custom configuration
client = ::Google::Cloud::StorageBatchOperations::V1::StorageBatchOperations::Rest::Client.new do |config|
  config.timeout = 10.0
end
```

### #list_bucket_operations

    def list_bucket_operations(request, options = nil) -> ::Gapic::Rest::PagedEnumerable<::Google::Cloud::StorageBatchOperations::V1::BucketOperation>
    def list_bucket_operations(parent: nil, filter: nil, page_size: nil, page_token: nil, order_by: nil) -> ::Gapic::Rest::PagedEnumerable<::Google::Cloud::StorageBatchOperations::V1::BucketOperation>

Lists BucketOperations in a given project and job.
**Overloads**

    def list_bucket_operations(request, options = nil) -> ::Gapic::Rest::PagedEnumerable<::Google::Cloud::StorageBatchOperations::V1::BucketOperation>

Pass arguments to `list_bucket_operations` via a request object, either of type [ListBucketOperationsRequest](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-storage_batch_operations-v1/latest/Google-Cloud-StorageBatchOperations-V1-ListBucketOperationsRequest "Google::Cloud::StorageBatchOperations::V1::ListBucketOperationsRequest (class)") or an equivalent Hash. **Parameters**

- **request** ([::Google::Cloud::StorageBatchOperations::V1::ListBucketOperationsRequest](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-storage_batch_operations-v1/latest/Google-Cloud-StorageBatchOperations-V1-ListBucketOperationsRequest), ::Hash) --- A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
- **options** (::Gapic::CallOptions, ::Hash) --- Overrides the default settings for this call, e.g, timeout, retries etc. Optional.

    def list_bucket_operations(parent: nil, filter: nil, page_size: nil, page_token: nil, order_by: nil) -> ::Gapic::Rest::PagedEnumerable<::Google::Cloud::StorageBatchOperations::V1::BucketOperation>

Pass arguments to `list_bucket_operations` via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above). **Parameters**

- **parent** (::String) --- Required. Format: projects/{project_id}/locations/global/jobs/{job_id}.
- **filter** (::String) --- Optional. Filters results as defined by https://google.aip.dev/160.
- **page_size** (::Integer) --- Optional. The list page size. Default page size is 100.
- **page_token** (::String) --- Optional. The list page token.
- **order_by** (::String) --- Optional. Field to sort by. Supported fields are name, create_time.
**Yields**

- (result, operation) --- Access the result along with the TransportOperation object
**Yield Parameters**

- **result** (::Gapic::Rest::PagedEnumerable\<[::Google::Cloud::StorageBatchOperations::V1::BucketOperation](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-storage_batch_operations-v1/latest/Google-Cloud-StorageBatchOperations-V1-BucketOperation)\>)
- **operation** (::Gapic::Rest::TransportOperation)
**Returns**

- (::Gapic::Rest::PagedEnumerable\<[::Google::Cloud::StorageBatchOperations::V1::BucketOperation](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-storage_batch_operations-v1/latest/Google-Cloud-StorageBatchOperations-V1-BucketOperation)\>)
**Raises**

- (::Google::Cloud::Error) --- if the REST call is aborted.
**Example**

Basic example

```ruby
require "google/cloud/storage_batch_operations/v1"

# Create a client object. The client can be reused for multiple calls.
client = Google::Cloud::StorageBatchOperations::V1::StorageBatchOperations::Rest::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Cloud::StorageBatchOperations::V1::ListBucketOperationsRequest.new

# Call the list_bucket_operations method.
result = client.list_bucket_operations request

# The returned object is of type Gapic::PagedEnumerable. You can iterate
# over elements, and API calls will be issued to fetch pages as needed.
result.each do |item|
  # Each element is of type ::Google::Cloud::StorageBatchOperations::V1::BucketOperation.
  p item
end
```

### #list_jobs

    def list_jobs(request, options = nil) -> ::Gapic::Rest::PagedEnumerable<::Google::Cloud::StorageBatchOperations::V1::Job>
    def list_jobs(parent: nil, filter: nil, page_size: nil, page_token: nil, order_by: nil) -> ::Gapic::Rest::PagedEnumerable<::Google::Cloud::StorageBatchOperations::V1::Job>

Lists Jobs in a given project.
**Overloads**

    def list_jobs(request, options = nil) -> ::Gapic::Rest::PagedEnumerable<::Google::Cloud::StorageBatchOperations::V1::Job>

Pass arguments to `list_jobs` via a request object, either of type [ListJobsRequest](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-storage_batch_operations-v1/latest/Google-Cloud-StorageBatchOperations-V1-ListJobsRequest "Google::Cloud::StorageBatchOperations::V1::ListJobsRequest (class)") or an equivalent Hash. **Parameters**

- **request** ([::Google::Cloud::StorageBatchOperations::V1::ListJobsRequest](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-storage_batch_operations-v1/latest/Google-Cloud-StorageBatchOperations-V1-ListJobsRequest), ::Hash) --- A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.
- **options** (::Gapic::CallOptions, ::Hash) --- Overrides the default settings for this call, e.g, timeout, retries etc. Optional.

    def list_jobs(parent: nil, filter: nil, page_size: nil, page_token: nil, order_by: nil) -> ::Gapic::Rest::PagedEnumerable<::Google::Cloud::StorageBatchOperations::V1::Job>

Pass arguments to `list_jobs` via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above). **Parameters**

- **parent** (::String) --- Required. Format: projects/{project_id}/locations/global.
- **filter** (::String) --- Optional. Filters results as defined by https://google.aip.dev/160.
- **page_size** (::Integer) --- Optional. The list page size. default page size is 100.
- **page_token** (::String) --- Optional. The list page token.
- **order_by** (::String) --- Optional. Field to sort by. Supported fields are name, create_time.
**Yields**

- (result, operation) --- Access the result along with the TransportOperation object
**Yield Parameters**

- **result** (::Gapic::Rest::PagedEnumerable\<[::Google::Cloud::StorageBatchOperations::V1::Job](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-storage_batch_operations-v1/latest/Google-Cloud-StorageBatchOperations-V1-Job)\>)
- **operation** (::Gapic::Rest::TransportOperation)
**Returns**

- (::Gapic::Rest::PagedEnumerable\<[::Google::Cloud::StorageBatchOperations::V1::Job](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-storage_batch_operations-v1/latest/Google-Cloud-StorageBatchOperations-V1-Job)\>)
**Raises**

- (::Google::Cloud::Error) --- if the REST call is aborted.
**Example**

Basic example

```ruby
require "google/cloud/storage_batch_operations/v1"

# Create a client object. The client can be reused for multiple calls.
client = Google::Cloud::StorageBatchOperations::V1::StorageBatchOperations::Rest::Client.new

# Create a request. To set request fields, pass in keyword arguments.
request = Google::Cloud::StorageBatchOperations::V1::ListJobsRequest.new

# Call the list_jobs method.
result = client.list_jobs request

# The returned object is of type Gapic::PagedEnumerable. You can iterate
# over elements, and API calls will be issued to fetch pages as needed.
result.each do |item|
  # Each element is of type ::Google::Cloud::StorageBatchOperations::V1::Job.
  p item
end
```

### #location_client

    def location_client() -> Google::Cloud::Location::Locations::Rest::Client

Get the associated client for mix-in of the Locations.
**Returns**

- (Google::Cloud::Location::Locations::Rest::Client)

### #logger

    def logger() -> Logger

The logger used for request/response debug logging.
**Returns**

- (Logger)

### #operations_client

    def operations_client() -> ::Google::Cloud::StorageBatchOperations::V1::StorageBatchOperations::Rest::Operations

Get the associated client for long-running operations.
**Returns**

- ([::Google::Cloud::StorageBatchOperations::V1::StorageBatchOperations::Rest::Operations](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-storage_batch_operations-v1/latest/Google-Cloud-StorageBatchOperations-V1-StorageBatchOperations-Rest-Operations))

### #universe_domain

    def universe_domain() -> String

The effective universe domain
**Returns**

- (String)