3.16.0 (latest) 3.15.0 3.14.0 3.13.0 3.12.0 3.11.0 3.10.0 3.8.0 3.7.0 3.6.0 3.5.0 3.4.0 3.3.0 3.2.0 3.1.0 3.0.0 2.4.0 2.3.0 2.2.0

    public class ContainerAnalysis.ContainerAnalysisClient : ClientBase<ContainerAnalysis.ContainerAnalysisClient>

Reference documentation and code samples for the Google Container Analysis v1 API class ContainerAnalysis.ContainerAnalysisClient.

Client for ContainerAnalysis

## Inheritance

[object](https://learn.microsoft.com/dotnet/api/system.object) \> [ClientBase](https://docs.cloud.google.com/dotnet/docs/reference/Grpc.Core/latest/Grpc.Core.ClientBase.md.txt) \> [ClientBase](https://docs.cloud.google.com/dotnet/docs/reference/Grpc.Core/latest/Grpc.Core.ClientBase-1.md.txt)[ContainerAnalysis](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DevTools.ContainerAnalysis.V1/latest/Google.Cloud.DevTools.ContainerAnalysis.V1.ContainerAnalysis.md.txt)[ContainerAnalysisClient](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DevTools.ContainerAnalysis.V1/latest/Google.Cloud.DevTools.ContainerAnalysis.V1.ContainerAnalysis.ContainerAnalysisClient.md.txt) \> ContainerAnalysis.ContainerAnalysisClient

## Inherited Members

[ClientBase\<ContainerAnalysis.ContainerAnalysisClient\>.WithHost(string)](https://docs.cloud.google.com/dotnet/docs/reference/Grpc.Core/latest/Grpc.Core.ClientBase-1.md.txt#Grpc_Core_ClientBase_1_WithHost_System_String_) [ClientBase.CallInvoker](https://docs.cloud.google.com/dotnet/docs/reference/Grpc.Core/latest/Grpc.Core.ClientBase.md.txt#Grpc_Core_ClientBase_CallInvoker) [object.GetHashCode()](https://learn.microsoft.com/dotnet/api/system.object.gethashcode) [object.GetType()](https://learn.microsoft.com/dotnet/api/system.object.gettype) [object.MemberwiseClone()](https://learn.microsoft.com/dotnet/api/system.object.memberwiseclone) [object.ToString()](https://learn.microsoft.com/dotnet/api/system.object.tostring)

## Namespace

[Google.Cloud.DevTools.ContainerAnalysis.V1](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DevTools.ContainerAnalysis.V1/latest/Google.Cloud.DevTools.ContainerAnalysis.V1.md.txt)

## Assembly

Google.Cloud.DevTools.ContainerAnalysis.V1.dll

## Constructors

### ContainerAnalysisClient()

    protected ContainerAnalysisClient()

Protected parameterless constructor to allow creation of test doubles.

### ContainerAnalysisClient(CallInvoker)

    public ContainerAnalysisClient(CallInvoker callInvoker)

Creates a new client for ContainerAnalysis that uses a custom `CallInvoker`.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `callInvoker` | `CallInvoker` The callInvoker to use to make remote calls. |

### ContainerAnalysisClient(ChannelBase)

    public ContainerAnalysisClient(ChannelBase channel)

Creates a new client for ContainerAnalysis

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `channel` | `ChannelBase` The channel to use to make remote calls. |

### ContainerAnalysisClient(ClientBaseConfiguration)

    protected ContainerAnalysisClient(ClientBase.ClientBaseConfiguration configuration)

Protected constructor to allow creation of configured clients.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `configuration` | `ClientBaseClientBaseConfiguration` The client configuration. |

## Methods

### ExportSBOM(ExportSBOMRequest, CallOptions)

    public virtual ExportSBOMResponse ExportSBOM(ExportSBOMRequest request, CallOptions options)

Generates an SBOM for the given resource.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `ExportSBOMRequest` The request to send to the server. |
| `options` | `CallOptions` The options for the call. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `ExportSBOMResponse` | The response received from the server. |

### ExportSBOM(ExportSBOMRequest, Metadata, DateTime?, CancellationToken)

    public virtual ExportSBOMResponse ExportSBOM(ExportSBOMRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default)

Generates an SBOM for the given resource.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `ExportSBOMRequest` The request to send to the server. |
| `headers` | `Metadata` The initial metadata to send with the call. This parameter is optional. |
| `deadline` | `System.DateTime` An optional deadline for the call. The call will be cancelled if deadline is hit. |
| `cancellationToken` | `CancellationToken` An optional token for canceling the call. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `ExportSBOMResponse` | The response received from the server. |

### ExportSBOMAsync(ExportSBOMRequest, CallOptions)

    public virtual AsyncUnaryCall<ExportSBOMResponse> ExportSBOMAsync(ExportSBOMRequest request, CallOptions options)

Generates an SBOM for the given resource.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `ExportSBOMRequest` The request to send to the server. |
| `options` | `CallOptions` The options for the call. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `AsyncUnaryCallExportSBOMResponse` | The call object. |

### ExportSBOMAsync(ExportSBOMRequest, Metadata, DateTime?, CancellationToken)

    public virtual AsyncUnaryCall<ExportSBOMResponse> ExportSBOMAsync(ExportSBOMRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default)

Generates an SBOM for the given resource.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `ExportSBOMRequest` The request to send to the server. |
| `headers` | `Metadata` The initial metadata to send with the call. This parameter is optional. |
| `deadline` | `System.DateTime` An optional deadline for the call. The call will be cancelled if deadline is hit. |
| `cancellationToken` | `CancellationToken` An optional token for canceling the call. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `AsyncUnaryCallExportSBOMResponse` | The call object. |

### GetIamPolicy(GetIamPolicyRequest, CallOptions)

    public virtual Policy GetIamPolicy(GetIamPolicyRequest request, CallOptions options)

Gets the access control policy for a note or an occurrence resource.
Requires `containeranalysis.notes.setIamPolicy` or
`containeranalysis.occurrences.setIamPolicy` permission if the resource is
a note or occurrence, respectively.

The resource takes the format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for
notes and `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for
occurrences.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `GetIamPolicyRequest` The request to send to the server. |
| `options` | `CallOptions` The options for the call. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `Policy` | The response received from the server. |

### GetIamPolicy(GetIamPolicyRequest, Metadata, DateTime?, CancellationToken)

    public virtual Policy GetIamPolicy(GetIamPolicyRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default)

Gets the access control policy for a note or an occurrence resource.
Requires `containeranalysis.notes.setIamPolicy` or
`containeranalysis.occurrences.setIamPolicy` permission if the resource is
a note or occurrence, respectively.

The resource takes the format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for
notes and `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for
occurrences.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `GetIamPolicyRequest` The request to send to the server. |
| `headers` | `Metadata` The initial metadata to send with the call. This parameter is optional. |
| `deadline` | `System.DateTime` An optional deadline for the call. The call will be cancelled if deadline is hit. |
| `cancellationToken` | `CancellationToken` An optional token for canceling the call. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `Policy` | The response received from the server. |

### GetIamPolicyAsync(GetIamPolicyRequest, CallOptions)

    public virtual AsyncUnaryCall<Policy> GetIamPolicyAsync(GetIamPolicyRequest request, CallOptions options)

Gets the access control policy for a note or an occurrence resource.
Requires `containeranalysis.notes.setIamPolicy` or
`containeranalysis.occurrences.setIamPolicy` permission if the resource is
a note or occurrence, respectively.

The resource takes the format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for
notes and `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for
occurrences.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `GetIamPolicyRequest` The request to send to the server. |
| `options` | `CallOptions` The options for the call. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `AsyncUnaryCallPolicy` | The call object. |

### GetIamPolicyAsync(GetIamPolicyRequest, Metadata, DateTime?, CancellationToken)

    public virtual AsyncUnaryCall<Policy> GetIamPolicyAsync(GetIamPolicyRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default)

Gets the access control policy for a note or an occurrence resource.
Requires `containeranalysis.notes.setIamPolicy` or
`containeranalysis.occurrences.setIamPolicy` permission if the resource is
a note or occurrence, respectively.

The resource takes the format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for
notes and `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for
occurrences.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `GetIamPolicyRequest` The request to send to the server. |
| `headers` | `Metadata` The initial metadata to send with the call. This parameter is optional. |
| `deadline` | `System.DateTime` An optional deadline for the call. The call will be cancelled if deadline is hit. |
| `cancellationToken` | `CancellationToken` An optional token for canceling the call. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `AsyncUnaryCallPolicy` | The call object. |

### GetVulnerabilityOccurrencesSummary(GetVulnerabilityOccurrencesSummaryRequest, CallOptions)

    public virtual VulnerabilityOccurrencesSummary GetVulnerabilityOccurrencesSummary(GetVulnerabilityOccurrencesSummaryRequest request, CallOptions options)

Gets a summary of the number and severity of occurrences.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `GetVulnerabilityOccurrencesSummaryRequest` The request to send to the server. |
| `options` | `CallOptions` The options for the call. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `VulnerabilityOccurrencesSummary` | The response received from the server. |

### GetVulnerabilityOccurrencesSummary(GetVulnerabilityOccurrencesSummaryRequest, Metadata, DateTime?, CancellationToken)

    public virtual VulnerabilityOccurrencesSummary GetVulnerabilityOccurrencesSummary(GetVulnerabilityOccurrencesSummaryRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default)

Gets a summary of the number and severity of occurrences.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `GetVulnerabilityOccurrencesSummaryRequest` The request to send to the server. |
| `headers` | `Metadata` The initial metadata to send with the call. This parameter is optional. |
| `deadline` | `System.DateTime` An optional deadline for the call. The call will be cancelled if deadline is hit. |
| `cancellationToken` | `CancellationToken` An optional token for canceling the call. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `VulnerabilityOccurrencesSummary` | The response received from the server. |

### GetVulnerabilityOccurrencesSummaryAsync(GetVulnerabilityOccurrencesSummaryRequest, CallOptions)

    public virtual AsyncUnaryCall<VulnerabilityOccurrencesSummary> GetVulnerabilityOccurrencesSummaryAsync(GetVulnerabilityOccurrencesSummaryRequest request, CallOptions options)

Gets a summary of the number and severity of occurrences.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `GetVulnerabilityOccurrencesSummaryRequest` The request to send to the server. |
| `options` | `CallOptions` The options for the call. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `AsyncUnaryCallVulnerabilityOccurrencesSummary` | The call object. |

### GetVulnerabilityOccurrencesSummaryAsync(GetVulnerabilityOccurrencesSummaryRequest, Metadata, DateTime?, CancellationToken)

    public virtual AsyncUnaryCall<VulnerabilityOccurrencesSummary> GetVulnerabilityOccurrencesSummaryAsync(GetVulnerabilityOccurrencesSummaryRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default)

Gets a summary of the number and severity of occurrences.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `GetVulnerabilityOccurrencesSummaryRequest` The request to send to the server. |
| `headers` | `Metadata` The initial metadata to send with the call. This parameter is optional. |
| `deadline` | `System.DateTime` An optional deadline for the call. The call will be cancelled if deadline is hit. |
| `cancellationToken` | `CancellationToken` An optional token for canceling the call. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `AsyncUnaryCallVulnerabilityOccurrencesSummary` | The call object. |

### NewInstance(ClientBaseConfiguration)

    protected override ContainerAnalysis.ContainerAnalysisClient NewInstance(ClientBase.ClientBaseConfiguration configuration)

Creates a new instance of client from given `ClientBaseConfiguration`.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `configuration` | `ClientBaseClientBaseConfiguration` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `ContainerAnalysisContainerAnalysisClient` |   |

**Overrides** Grpc.Core.ClientBase\<Google.Cloud.DevTools.ContainerAnalysis.V1.ContainerAnalysis.ContainerAnalysisClient\>.NewInstance(Grpc.Core.ClientBase.ClientBaseConfiguration)

### SetIamPolicy(SetIamPolicyRequest, CallOptions)

    public virtual Policy SetIamPolicy(SetIamPolicyRequest request, CallOptions options)

Sets the access control policy on the specified note or occurrence.
Requires `containeranalysis.notes.setIamPolicy` or
`containeranalysis.occurrences.setIamPolicy` permission if the resource is
a note or an occurrence, respectively.

The resource takes the format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for
notes and `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for
occurrences.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `SetIamPolicyRequest` The request to send to the server. |
| `options` | `CallOptions` The options for the call. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `Policy` | The response received from the server. |

### SetIamPolicy(SetIamPolicyRequest, Metadata, DateTime?, CancellationToken)

    public virtual Policy SetIamPolicy(SetIamPolicyRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default)

Sets the access control policy on the specified note or occurrence.
Requires `containeranalysis.notes.setIamPolicy` or
`containeranalysis.occurrences.setIamPolicy` permission if the resource is
a note or an occurrence, respectively.

The resource takes the format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for
notes and `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for
occurrences.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `SetIamPolicyRequest` The request to send to the server. |
| `headers` | `Metadata` The initial metadata to send with the call. This parameter is optional. |
| `deadline` | `System.DateTime` An optional deadline for the call. The call will be cancelled if deadline is hit. |
| `cancellationToken` | `CancellationToken` An optional token for canceling the call. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `Policy` | The response received from the server. |

### SetIamPolicyAsync(SetIamPolicyRequest, CallOptions)

    public virtual AsyncUnaryCall<Policy> SetIamPolicyAsync(SetIamPolicyRequest request, CallOptions options)

Sets the access control policy on the specified note or occurrence.
Requires `containeranalysis.notes.setIamPolicy` or
`containeranalysis.occurrences.setIamPolicy` permission if the resource is
a note or an occurrence, respectively.

The resource takes the format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for
notes and `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for
occurrences.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `SetIamPolicyRequest` The request to send to the server. |
| `options` | `CallOptions` The options for the call. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `AsyncUnaryCallPolicy` | The call object. |

### SetIamPolicyAsync(SetIamPolicyRequest, Metadata, DateTime?, CancellationToken)

    public virtual AsyncUnaryCall<Policy> SetIamPolicyAsync(SetIamPolicyRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default)

Sets the access control policy on the specified note or occurrence.
Requires `containeranalysis.notes.setIamPolicy` or
`containeranalysis.occurrences.setIamPolicy` permission if the resource is
a note or an occurrence, respectively.

The resource takes the format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for
notes and `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for
occurrences.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `SetIamPolicyRequest` The request to send to the server. |
| `headers` | `Metadata` The initial metadata to send with the call. This parameter is optional. |
| `deadline` | `System.DateTime` An optional deadline for the call. The call will be cancelled if deadline is hit. |
| `cancellationToken` | `CancellationToken` An optional token for canceling the call. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `AsyncUnaryCallPolicy` | The call object. |

### TestIamPermissions(TestIamPermissionsRequest, CallOptions)

    public virtual TestIamPermissionsResponse TestIamPermissions(TestIamPermissionsRequest request, CallOptions options)

Returns the permissions that a caller has on the specified note or
occurrence. Requires list permission on the project (for example,
`containeranalysis.notes.list`).

The resource takes the format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for
notes and `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for
occurrences.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `TestIamPermissionsRequest` The request to send to the server. |
| `options` | `CallOptions` The options for the call. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `TestIamPermissionsResponse` | The response received from the server. |

### TestIamPermissions(TestIamPermissionsRequest, Metadata, DateTime?, CancellationToken)

    public virtual TestIamPermissionsResponse TestIamPermissions(TestIamPermissionsRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default)

Returns the permissions that a caller has on the specified note or
occurrence. Requires list permission on the project (for example,
`containeranalysis.notes.list`).

The resource takes the format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for
notes and `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for
occurrences.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `TestIamPermissionsRequest` The request to send to the server. |
| `headers` | `Metadata` The initial metadata to send with the call. This parameter is optional. |
| `deadline` | `System.DateTime` An optional deadline for the call. The call will be cancelled if deadline is hit. |
| `cancellationToken` | `CancellationToken` An optional token for canceling the call. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `TestIamPermissionsResponse` | The response received from the server. |

### TestIamPermissionsAsync(TestIamPermissionsRequest, CallOptions)

    public virtual AsyncUnaryCall<TestIamPermissionsResponse> TestIamPermissionsAsync(TestIamPermissionsRequest request, CallOptions options)

Returns the permissions that a caller has on the specified note or
occurrence. Requires list permission on the project (for example,
`containeranalysis.notes.list`).

The resource takes the format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for
notes and `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for
occurrences.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `TestIamPermissionsRequest` The request to send to the server. |
| `options` | `CallOptions` The options for the call. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `AsyncUnaryCallTestIamPermissionsResponse` | The call object. |

### TestIamPermissionsAsync(TestIamPermissionsRequest, Metadata, DateTime?, CancellationToken)

    public virtual AsyncUnaryCall<TestIamPermissionsResponse> TestIamPermissionsAsync(TestIamPermissionsRequest request, Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default)

Returns the permissions that a caller has on the specified note or
occurrence. Requires list permission on the project (for example,
`containeranalysis.notes.list`).

The resource takes the format `projects/[PROJECT_ID]/notes/[NOTE_ID]` for
notes and `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]` for
occurrences.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `TestIamPermissionsRequest` The request to send to the server. |
| `headers` | `Metadata` The initial metadata to send with the call. This parameter is optional. |
| `deadline` | `System.DateTime` An optional deadline for the call. The call will be cancelled if deadline is hit. |
| `cancellationToken` | `CancellationToken` An optional token for canceling the call. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `AsyncUnaryCallTestIamPermissionsResponse` | The call object. |