0.9.0 (latest) 0.8.0 0.7.0 0.6.0 0.5.0 0.4.0 0.3.1 0.2.0 0.1.0 Reference documentation and code samples for the Chronicle V1 API class Google::Cloud::Chronicle::V1::Rule.

The Rule resource represents a user-created rule.
NEXT TAG: 21

## Inherits

- Object

## Extended By

- Google::Protobuf::MessageExts::ClassMethods

## Includes

- Google::Protobuf::MessageExts

## Methods

### #allowed_run_frequencies

    def allowed_run_frequencies() -> ::Array<::Google::Cloud::Chronicle::V1::RunFrequency>

**Returns**

- (::Array\<[::Google::Cloud::Chronicle::V1::RunFrequency](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-chronicle-v1/latest/Google-Cloud-Chronicle-V1-RunFrequency)\>) --- Output only. The run frequencies that are allowed for the rule. Populated in BASIC view and FULL view.

### #author

    def author() -> ::String

**Returns**

- (::String) --- Output only. The author of the rule. Extracted from the meta section of text. Populated in BASIC view and FULL view.

### #compilation_diagnostics

    def compilation_diagnostics() -> ::Array<::Google::Cloud::Chronicle::V1::CompilationDiagnostic>

**Returns**

- (::Array\<[::Google::Cloud::Chronicle::V1::CompilationDiagnostic](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-chronicle-v1/latest/Google-Cloud-Chronicle-V1-CompilationDiagnostic)\>) --- Output only. A list of a rule's corresponding compilation diagnostic messages such as compilation errors and compilation warnings. Populated in FULL view.

### #compilation_state

    def compilation_state() -> ::Google::Cloud::Chronicle::V1::Rule::CompilationState

**Returns**

- ([::Google::Cloud::Chronicle::V1::Rule::CompilationState](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-chronicle-v1/latest/Google-Cloud-Chronicle-V1-Rule-CompilationState)) --- Output only. The current compilation state of the rule. Populated in FULL view.

### #create_time

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

**Returns**

- ([::Google::Protobuf::Timestamp](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-chronicle-v1/latest/Google-Protobuf-Timestamp)) --- Output only. The timestamp of when the rule was created. Populated in FULL view.

### #display_name

    def display_name() -> ::String

**Returns**

- (::String) --- Output only. Display name of the rule. Populated in BASIC view and FULL view.

### #etag

    def etag() -> ::String

**Returns**

- (::String) --- The etag for this rule. If this is provided on update, the request will succeed if and only if it matches the server-computed value, and will fail with an ABORTED error otherwise. Populated in BASIC view and FULL view.

### #etag=

    def etag=(value) -> ::String

**Parameter**

- **value** (::String) --- The etag for this rule. If this is provided on update, the request will succeed if and only if it matches the server-computed value, and will fail with an ABORTED error otherwise. Populated in BASIC view and FULL view.
**Returns**

- (::String) --- The etag for this rule. If this is provided on update, the request will succeed if and only if it matches the server-computed value, and will fail with an ABORTED error otherwise. Populated in BASIC view and FULL view.

### #inputs_used

    def inputs_used() -> ::Google::Cloud::Chronicle::V1::InputsUsed

**Returns**

- ([::Google::Cloud::Chronicle::V1::InputsUsed](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-chronicle-v1/latest/Google-Cloud-Chronicle-V1-InputsUsed)) --- Output only. The set of inputs used in the rule. For example, if the rule uses $e.principal.hostname, then the uses_udm field will be true.

### #metadata

    def metadata() -> ::Google::Protobuf::Map{::String => ::String}

**Returns**

- (::Google::Protobuf::Map{::String =\> ::String}) --- Output only. Additional metadata specified in the meta section of text. Populated in FULL view.

### #name

    def name() -> ::String

**Returns**

- (::String) --- Identifier. Full resource name for the rule. Format: `projects/{project}/locations/{location}/instances/{instance}/rules/{rule}`

### #name=

    def name=(value) -> ::String

**Parameter**

- **value** (::String) --- Identifier. Full resource name for the rule. Format: `projects/{project}/locations/{location}/instances/{instance}/rules/{rule}`
**Returns**

- (::String) --- Identifier. Full resource name for the rule. Format: `projects/{project}/locations/{location}/instances/{instance}/rules/{rule}`

### #near_real_time_live_rule_eligible

    def near_real_time_live_rule_eligible() -> ::Boolean

**Returns**

- (::Boolean) --- Output only. Indicate the rule can run in near real time live rule. If this is true, the rule uses the near real time live rule when the run frequency is set to LIVE.

### #reference_lists

    def reference_lists() -> ::Array<::String>

**Returns**

- (::Array\<::String\>) --- Output only. Resource names of the reference lists used in this rule. Populated in FULL view.

### #revision_create_time

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

**Returns**

- ([::Google::Protobuf::Timestamp](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-chronicle-v1/latest/Google-Protobuf-Timestamp)) --- Output only. The timestamp of when the rule revision was created. Populated in FULL, REVISION_METADATA_ONLY views.

### #revision_id

    def revision_id() -> ::String

**Returns**

- (::String) --- Output only. The revision ID of the rule. A new revision is created whenever the rule text is changed in any way. Format: `v_{10 digits}_{9 digits}` Populated in REVISION_METADATA_ONLY view and FULL view.

### #scope

    def scope() -> ::String

**Returns**

- (::String) --- Resource name of the DataAccessScope bound to this rule. Populated in BASIC view and FULL view. If reference lists are used in the rule, validations will be performed against this scope to ensure that the reference lists are compatible with both the user's and the rule's scopes. The scope should be in the format: `projects/{project}/locations/{location}/instances/{instance}/dataAccessScopes/{scope}`.

### #scope=

    def scope=(value) -> ::String

**Parameter**

- **value** (::String) --- Resource name of the DataAccessScope bound to this rule. Populated in BASIC view and FULL view. If reference lists are used in the rule, validations will be performed against this scope to ensure that the reference lists are compatible with both the user's and the rule's scopes. The scope should be in the format: `projects/{project}/locations/{location}/instances/{instance}/dataAccessScopes/{scope}`.
**Returns**

- (::String) --- Resource name of the DataAccessScope bound to this rule. Populated in BASIC view and FULL view. If reference lists are used in the rule, validations will be performed against this scope to ensure that the reference lists are compatible with both the user's and the rule's scopes. The scope should be in the format: `projects/{project}/locations/{location}/instances/{instance}/dataAccessScopes/{scope}`.

### #severity

    def severity() -> ::Google::Cloud::Chronicle::V1::Severity

**Returns**

- ([::Google::Cloud::Chronicle::V1::Severity](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-chronicle-v1/latest/Google-Cloud-Chronicle-V1-Severity)) --- Output only. The severity of the rule as specified in the meta section of text. Populated in BASIC view and FULL view.

### #text

    def text() -> ::String

**Returns**

- (::String) --- The YARA-L content of the rule. Populated in FULL view.

### #text=

    def text=(value) -> ::String

**Parameter**

- **value** (::String) --- The YARA-L content of the rule. Populated in FULL view.
**Returns**

- (::String) --- The YARA-L content of the rule. Populated in FULL view.

### #type

    def type() -> ::Google::Cloud::Chronicle::V1::RuleType

**Returns**

- ([::Google::Cloud::Chronicle::V1::RuleType](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-chronicle-v1/latest/Google-Cloud-Chronicle-V1-RuleType)) --- Output only. User-facing type of the rule. Extracted from the events section of rule text. Populated in BASIC view and FULL view.