Class: Google::Apis::LoggingV2::LogScope

Inherits:
Object
  • Object
show all
Includes:
Core::Hashable, Core::JsonObjectSupport
Defined in:
lib/google/apis/logging_v2/classes.rb,
lib/google/apis/logging_v2/representations.rb,
lib/google/apis/logging_v2/representations.rb

Overview

Describes a group of resources to read log entries from.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ LogScope

Returns a new instance of LogScope.



2479
2480
2481
# File 'lib/google/apis/logging_v2/classes.rb', line 2479

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

Instance Attribute Details

#create_timeString

Output only. The creation timestamp of the log scope. Corresponds to the JSON property createTime

Returns:

  • (String)


2451
2452
2453
# File 'lib/google/apis/logging_v2/classes.rb', line 2451

def create_time
  @create_time
end

#descriptionString

Optional. Describes this log scope.The maximum length of the description is 8000 characters. Corresponds to the JSON property description

Returns:

  • (String)


2457
2458
2459
# File 'lib/google/apis/logging_v2/classes.rb', line 2457

def description
  @description
end

#nameString

Output only. The resource name of the log scope.Log scopes are only available in the global location. For example:projects/my-project/locations/global/ logScopes/my-log-scope Corresponds to the JSON property name

Returns:

  • (String)


2464
2465
2466
# File 'lib/google/apis/logging_v2/classes.rb', line 2464

def name
  @name
end

#resource_namesArray<String>

Required. Names of one or more parent resources: projects/[PROJECT_ID]May alternatively be one or more views: projects/[PROJECT_ID]/locations/[ LOCATION_ID]/buckets/[BUCKET_ID]/views/[VIEW_ID]A log scope can include a maximum of 5 projects and a maximum of 100 resources in total. Corresponds to the JSON property resourceNames

Returns:

  • (Array<String>)


2472
2473
2474
# File 'lib/google/apis/logging_v2/classes.rb', line 2472

def resource_names
  @resource_names
end

#update_timeString

Output only. The last update timestamp of the log scope. Corresponds to the JSON property updateTime

Returns:

  • (String)


2477
2478
2479
# File 'lib/google/apis/logging_v2/classes.rb', line 2477

def update_time
  @update_time
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



2484
2485
2486
2487
2488
2489
2490
# File 'lib/google/apis/logging_v2/classes.rb', line 2484

def update!(**args)
  @create_time = args[:create_time] if args.key?(:create_time)
  @description = args[:description] if args.key?(:description)
  @name = args[:name] if args.key?(:name)
  @resource_names = args[:resource_names] if args.key?(:resource_names)
  @update_time = args[:update_time] if args.key?(:update_time)
end