# Grafeas V1 API - Class Grafeas::V1::DiscoveryOccurrence (v1.9.0)

1.9.0 (latest) 1.8.0 1.7.0 1.6.0 1.5.1 1.4.0 1.3.1 1.2.0 1.1.1 1.0.0 0.16.1 0.15.0 0.14.2 0.13.0 0.12.1 0.11.0 0.10.0 0.9.0 0.8.0 0.7.0 0.6.1 0.5.0 0.4.0 0.3.1 Reference documentation and code samples for the Grafeas V1 API class Grafeas::V1::DiscoveryOccurrence.

Provides information about the analysis status of a discovered resource.

## Inherits

- Object

## Extended By

- Google::Protobuf::MessageExts::ClassMethods

## Includes

- Google::Protobuf::MessageExts

## Methods

### #analysis_completed

    def analysis_completed() -> ::Grafeas::V1::DiscoveryOccurrence::AnalysisCompleted

**Returns**

- ([::Grafeas::V1::DiscoveryOccurrence::AnalysisCompleted](https://docs.cloud.google.com/ruby/docs/reference/grafeas-v1/latest/Grafeas-V1-DiscoveryOccurrence-AnalysisCompleted))

### #analysis_completed=

    def analysis_completed=(value) -> ::Grafeas::V1::DiscoveryOccurrence::AnalysisCompleted

**Parameter**

- **value** ([::Grafeas::V1::DiscoveryOccurrence::AnalysisCompleted](https://docs.cloud.google.com/ruby/docs/reference/grafeas-v1/latest/Grafeas-V1-DiscoveryOccurrence-AnalysisCompleted))
**Returns**

- ([::Grafeas::V1::DiscoveryOccurrence::AnalysisCompleted](https://docs.cloud.google.com/ruby/docs/reference/grafeas-v1/latest/Grafeas-V1-DiscoveryOccurrence-AnalysisCompleted))

### #analysis_error

    def analysis_error() -> ::Array<::Google::Rpc::Status>

**Returns**

- (::Array\<[::Google::Rpc::Status](https://docs.cloud.google.com/ruby/docs/reference/grafeas-v1/latest/Google-Rpc-Status)\>) --- Indicates any errors encountered during analysis of a resource. There could be 0 or more of these errors.

### #analysis_error=

    def analysis_error=(value) -> ::Array<::Google::Rpc::Status>

**Parameter**

- **value** (::Array\<[::Google::Rpc::Status](https://docs.cloud.google.com/ruby/docs/reference/grafeas-v1/latest/Google-Rpc-Status)\>) --- Indicates any errors encountered during analysis of a resource. There could be 0 or more of these errors.
**Returns**

- (::Array\<[::Google::Rpc::Status](https://docs.cloud.google.com/ruby/docs/reference/grafeas-v1/latest/Google-Rpc-Status)\>) --- Indicates any errors encountered during analysis of a resource. There could be 0 or more of these errors.

### #analysis_status

    def analysis_status() -> ::Grafeas::V1::DiscoveryOccurrence::AnalysisStatus

**Returns**

- ([::Grafeas::V1::DiscoveryOccurrence::AnalysisStatus](https://docs.cloud.google.com/ruby/docs/reference/grafeas-v1/latest/Grafeas-V1-DiscoveryOccurrence-AnalysisStatus)) --- The status of discovery for the resource.

### #analysis_status=

    def analysis_status=(value) -> ::Grafeas::V1::DiscoveryOccurrence::AnalysisStatus

**Parameter**

- **value** ([::Grafeas::V1::DiscoveryOccurrence::AnalysisStatus](https://docs.cloud.google.com/ruby/docs/reference/grafeas-v1/latest/Grafeas-V1-DiscoveryOccurrence-AnalysisStatus)) --- The status of discovery for the resource.
**Returns**

- ([::Grafeas::V1::DiscoveryOccurrence::AnalysisStatus](https://docs.cloud.google.com/ruby/docs/reference/grafeas-v1/latest/Grafeas-V1-DiscoveryOccurrence-AnalysisStatus)) --- The status of discovery for the resource.

### #analysis_status_error

    def analysis_status_error() -> ::Google::Rpc::Status

**Returns**

- ([::Google::Rpc::Status](https://docs.cloud.google.com/ruby/docs/reference/grafeas-v1/latest/Google-Rpc-Status)) --- When an error is encountered this will contain a LocalizedMessage under details to show to the user. The LocalizedMessage is output only and populated by the API.

### #analysis_status_error=

    def analysis_status_error=(value) -> ::Google::Rpc::Status

**Parameter**

- **value** ([::Google::Rpc::Status](https://docs.cloud.google.com/ruby/docs/reference/grafeas-v1/latest/Google-Rpc-Status)) --- When an error is encountered this will contain a LocalizedMessage under details to show to the user. The LocalizedMessage is output only and populated by the API.
**Returns**

- ([::Google::Rpc::Status](https://docs.cloud.google.com/ruby/docs/reference/grafeas-v1/latest/Google-Rpc-Status)) --- When an error is encountered this will contain a LocalizedMessage under details to show to the user. The LocalizedMessage is output only and populated by the API.

### #archive_time

    def archive_time() -> ::Google::Protobuf::Timestamp

**Returns**

- ([::Google::Protobuf::Timestamp](https://docs.cloud.google.com/ruby/docs/reference/grafeas-v1/latest/Google-Protobuf-Timestamp)) --- The time occurrences related to this discovery occurrence were archived.

### #continuous_analysis

    def continuous_analysis() -> ::Grafeas::V1::DiscoveryOccurrence::ContinuousAnalysis

**Returns**

- ([::Grafeas::V1::DiscoveryOccurrence::ContinuousAnalysis](https://docs.cloud.google.com/ruby/docs/reference/grafeas-v1/latest/Grafeas-V1-DiscoveryOccurrence-ContinuousAnalysis)) --- Whether the resource is continuously analyzed.

### #continuous_analysis=

    def continuous_analysis=(value) -> ::Grafeas::V1::DiscoveryOccurrence::ContinuousAnalysis

**Parameter**

- **value** ([::Grafeas::V1::DiscoveryOccurrence::ContinuousAnalysis](https://docs.cloud.google.com/ruby/docs/reference/grafeas-v1/latest/Grafeas-V1-DiscoveryOccurrence-ContinuousAnalysis)) --- Whether the resource is continuously analyzed.
**Returns**

- ([::Grafeas::V1::DiscoveryOccurrence::ContinuousAnalysis](https://docs.cloud.google.com/ruby/docs/reference/grafeas-v1/latest/Grafeas-V1-DiscoveryOccurrence-ContinuousAnalysis)) --- Whether the resource is continuously analyzed.

### #cpe

    def cpe() -> ::String

**Returns**

- (::String) --- The CPE of the resource being scanned.

### #cpe=

    def cpe=(value) -> ::String

**Parameter**

- **value** (::String) --- The CPE of the resource being scanned.
**Returns**

- (::String) --- The CPE of the resource being scanned.

### #files

    def files() -> ::Array<::Grafeas::V1::DiscoveryOccurrence::File>

**Returns**

- (::Array\<[::Grafeas::V1::DiscoveryOccurrence::File](https://docs.cloud.google.com/ruby/docs/reference/grafeas-v1/latest/Grafeas-V1-DiscoveryOccurrence-File)\>) --- Files that make up the resource described by the occurrence.

### #files=

    def files=(value) -> ::Array<::Grafeas::V1::DiscoveryOccurrence::File>

**Parameter**

- **value** (::Array\<[::Grafeas::V1::DiscoveryOccurrence::File](https://docs.cloud.google.com/ruby/docs/reference/grafeas-v1/latest/Grafeas-V1-DiscoveryOccurrence-File)\>) --- Files that make up the resource described by the occurrence.
**Returns**

- (::Array\<[::Grafeas::V1::DiscoveryOccurrence::File](https://docs.cloud.google.com/ruby/docs/reference/grafeas-v1/latest/Grafeas-V1-DiscoveryOccurrence-File)\>) --- Files that make up the resource described by the occurrence.

### #last_scan_time

    def last_scan_time() -> ::Google::Protobuf::Timestamp

**Returns**

- ([::Google::Protobuf::Timestamp](https://docs.cloud.google.com/ruby/docs/reference/grafeas-v1/latest/Google-Protobuf-Timestamp)) --- The last time this resource was scanned.

### #last_scan_time=

    def last_scan_time=(value) -> ::Google::Protobuf::Timestamp

**Parameter**

- **value** ([::Google::Protobuf::Timestamp](https://docs.cloud.google.com/ruby/docs/reference/grafeas-v1/latest/Google-Protobuf-Timestamp)) --- The last time this resource was scanned.
**Returns**

- ([::Google::Protobuf::Timestamp](https://docs.cloud.google.com/ruby/docs/reference/grafeas-v1/latest/Google-Protobuf-Timestamp)) --- The last time this resource was scanned.

### #last_vulnerability_update_time

    def last_vulnerability_update_time() -> ::Google::Protobuf::Timestamp

**Returns**

- ([::Google::Protobuf::Timestamp](https://docs.cloud.google.com/ruby/docs/reference/grafeas-v1/latest/Google-Protobuf-Timestamp)) --- The last time vulnerability scan results changed.

### #last_vulnerability_update_time=

    def last_vulnerability_update_time=(value) -> ::Google::Protobuf::Timestamp

**Parameter**

- **value** ([::Google::Protobuf::Timestamp](https://docs.cloud.google.com/ruby/docs/reference/grafeas-v1/latest/Google-Protobuf-Timestamp)) --- The last time vulnerability scan results changed.
**Returns**

- ([::Google::Protobuf::Timestamp](https://docs.cloud.google.com/ruby/docs/reference/grafeas-v1/latest/Google-Protobuf-Timestamp)) --- The last time vulnerability scan results changed.

### #sbom_status

    def sbom_status() -> ::Grafeas::V1::DiscoveryOccurrence::SBOMStatus

**Returns**

- ([::Grafeas::V1::DiscoveryOccurrence::SBOMStatus](https://docs.cloud.google.com/ruby/docs/reference/grafeas-v1/latest/Grafeas-V1-DiscoveryOccurrence-SBOMStatus)) --- The status of an SBOM generation.

### #sbom_status=

    def sbom_status=(value) -> ::Grafeas::V1::DiscoveryOccurrence::SBOMStatus

**Parameter**

- **value** ([::Grafeas::V1::DiscoveryOccurrence::SBOMStatus](https://docs.cloud.google.com/ruby/docs/reference/grafeas-v1/latest/Grafeas-V1-DiscoveryOccurrence-SBOMStatus)) --- The status of an SBOM generation.
**Returns**

- ([::Grafeas::V1::DiscoveryOccurrence::SBOMStatus](https://docs.cloud.google.com/ruby/docs/reference/grafeas-v1/latest/Grafeas-V1-DiscoveryOccurrence-SBOMStatus)) --- The status of an SBOM generation.

### #vulnerability_attestation

    def vulnerability_attestation() -> ::Grafeas::V1::DiscoveryOccurrence::VulnerabilityAttestation

**Returns**

- ([::Grafeas::V1::DiscoveryOccurrence::VulnerabilityAttestation](https://docs.cloud.google.com/ruby/docs/reference/grafeas-v1/latest/Grafeas-V1-DiscoveryOccurrence-VulnerabilityAttestation)) --- The status of an vulnerability attestation generation.

### #vulnerability_attestation=

    def vulnerability_attestation=(value) -> ::Grafeas::V1::DiscoveryOccurrence::VulnerabilityAttestation

**Parameter**

- **value** ([::Grafeas::V1::DiscoveryOccurrence::VulnerabilityAttestation](https://docs.cloud.google.com/ruby/docs/reference/grafeas-v1/latest/Grafeas-V1-DiscoveryOccurrence-VulnerabilityAttestation)) --- The status of an vulnerability attestation generation.
**Returns**

- ([::Grafeas::V1::DiscoveryOccurrence::VulnerabilityAttestation](https://docs.cloud.google.com/ruby/docs/reference/grafeas-v1/latest/Grafeas-V1-DiscoveryOccurrence-VulnerabilityAttestation)) --- The status of an vulnerability attestation generation.