Class: Google::Apis::CloudassetV1::Feed

Inherits:
Object
  • Object
show all
Includes:
Google::Apis::Core::Hashable, Google::Apis::Core::JsonObjectSupport
Defined in:
generated/google/apis/cloudasset_v1/classes.rb,
generated/google/apis/cloudasset_v1/representations.rb,
generated/google/apis/cloudasset_v1/representations.rb

Overview

An asset feed used to export asset updates to a destinations. An asset feed filter controls what updates are exported. The asset feed must be created within a project, organization, or folder. Supported destinations are: Pub/Sub topics.

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods included from Google::Apis::Core::JsonObjectSupport

#to_json

Methods included from Google::Apis::Core::Hashable

process_value, #to_h

Constructor Details

#initialize(**args) ⇒ Feed

Returns a new instance of Feed.


598
599
600
# File 'generated/google/apis/cloudasset_v1/classes.rb', line 598

def initialize(**args)
   update!(**args)
end

Instance Attribute Details

#asset_namesArray<String>

A list of the full names of the assets to receive updates. You must specify either or both of asset_names and asset_types. Only asset updates matching specified asset_names or asset_types are exported to the feed. Example: // compute.googleapis.com/projects/my_project_123/zones/zone1/instances/instance1 . See Resource Names for more info. Corresponds to the JSON property assetNames

Returns:

  • (Array<String>)

548
549
550
# File 'generated/google/apis/cloudasset_v1/classes.rb', line 548

def asset_names
  @asset_names
end

#asset_typesArray<String>

A list of types of the assets to receive updates. You must specify either or both of asset_names and asset_types. Only asset updates matching specified asset_names or asset_types are exported to the feed. Example: "compute. googleapis.com/Disk" See this topic for a list of all supported asset types. Corresponds to the JSON property assetTypes

Returns:

  • (Array<String>)

557
558
559
# File 'generated/google/apis/cloudasset_v1/classes.rb', line 557

def asset_types
  @asset_types
end

#conditionGoogle::Apis::CloudassetV1::Expr

Represents a textual expression in the Common Expression Language (CEL) syntax. CEL is a C-like expression language. The syntax and semantics of CEL are documented at https://github.com/google/cel-spec. Example (Comparison): title: "Summary size limit" description: "Determines if a summary is less than 100 chars" expression: "document.summary.size() < 100" Example (Equality): title: " Requestor is owner" description: "Determines if requestor is the document owner" expression: "document.owner == request.auth.claims.email" Example ( Logic): title: "Public documents" description: "Determine whether the document should be publicly visible" expression: "document.type != 'private' && document.type != 'internal'" Example (Data Manipulation): title: "Notification string" description: "Create a notification string with a timestamp." expression: "'New message received at ' + string(document.create_time)" The exact variables and functions that may be referenced within an expression are determined by the service that evaluates it. See the service documentation for additional information. Corresponds to the JSON property condition


576
577
578
# File 'generated/google/apis/cloudasset_v1/classes.rb', line 576

def condition
  @condition
end

#content_typeString

Asset content type. If not specified, no content but the asset name and type will be returned. Corresponds to the JSON property contentType

Returns:

  • (String)

582
583
584
# File 'generated/google/apis/cloudasset_v1/classes.rb', line 582

def content_type
  @content_type
end

#feed_output_configGoogle::Apis::CloudassetV1::FeedOutputConfig

Output configuration for asset feed destination. Corresponds to the JSON property feedOutputConfig


587
588
589
# File 'generated/google/apis/cloudasset_v1/classes.rb', line 587

def feed_output_config
  @feed_output_config
end

#nameString

Required. The format will be projects/project_number/feeds/client- assigned_feed_identifier or folders/folder_number/feeds/client- assigned_feed_identifier or organizations/organization_number/feeds/client- assigned_feed_identifier The client-assigned feed identifier must be unique within the parent project/folder/organization. Corresponds to the JSON property name

Returns:

  • (String)

596
597
598
# File 'generated/google/apis/cloudasset_v1/classes.rb', line 596

def name
  @name
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object


603
604
605
606
607
608
609
610
# File 'generated/google/apis/cloudasset_v1/classes.rb', line 603

def update!(**args)
  @asset_names = args[:asset_names] if args.key?(:asset_names)
  @asset_types = args[:asset_types] if args.key?(:asset_types)
  @condition = args[:condition] if args.key?(:condition)
  @content_type = args[:content_type] if args.key?(:content_type)
  @feed_output_config = args[:feed_output_config] if args.key?(:feed_output_config)
  @name = args[:name] if args.key?(:name)
end