Class: Google::Apis::ServicecontrolV2::ResourceInfo

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

Overview

Describes a resource referenced in the request.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ ResourceInfo

Returns a new instance of ResourceInfo.



1152
1153
1154
# File 'lib/google/apis/servicecontrol_v2/classes.rb', line 1152

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

Instance Attribute Details

#containerString

Optional. The identifier of the container of this resource. For Google Cloud APIs, the resource container must be one of the following formats: - projects/ - folders/ - organizations/ Required for the policy enforcement on the container level (e.g. VPCSC, Location Policy check, Org Policy check). Corresponds to the JSON property container

Returns:

  • (String)


1127
1128
1129
# File 'lib/google/apis/servicecontrol_v2/classes.rb', line 1127

def container
  @container
end

#locationString

Optional. The location of the resource, it must be a valid zone, region or multiregion, for example: "europe-west4", "northamerica-northeast1-a". Required for location policy check. Corresponds to the JSON property location

Returns:

  • (String)


1134
1135
1136
# File 'lib/google/apis/servicecontrol_v2/classes.rb', line 1134

def location
  @location
end

#nameString

The name of the resource referenced in the request. Corresponds to the JSON property name

Returns:

  • (String)


1139
1140
1141
# File 'lib/google/apis/servicecontrol_v2/classes.rb', line 1139

def name
  @name
end

#permissionString

The resource permission needed for this request. The format must be "service/ plural.verb". Corresponds to the JSON property permission

Returns:

  • (String)


1145
1146
1147
# File 'lib/google/apis/servicecontrol_v2/classes.rb', line 1145

def permission
  @permission
end

#typeString

The resource type in the format of "service/kind". Corresponds to the JSON property type

Returns:

  • (String)


1150
1151
1152
# File 'lib/google/apis/servicecontrol_v2/classes.rb', line 1150

def type
  @type
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



1157
1158
1159
1160
1161
1162
1163
# File 'lib/google/apis/servicecontrol_v2/classes.rb', line 1157

def update!(**args)
  @container = args[:container] if args.key?(:container)
  @location = args[:location] if args.key?(:location)
  @name = args[:name] if args.key?(:name)
  @permission = args[:permission] if args.key?(:permission)
  @type = args[:type] if args.key?(:type)
end