Class: Google::Apis::ComputeAlpha::Permission

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

Overview

All fields defined in a permission are ANDed.

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) ⇒ Permission

Returns a new instance of Permission



23214
23215
23216
# File 'generated/google/apis/compute_alpha/classes.rb', line 23214

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

Instance Attribute Details

#constraintsArray<Google::Apis::ComputeAlpha::PermissionConstraint>

Extra custom constraints. The constraints are ANDed together. Corresponds to the JSON property constraints



23170
23171
23172
# File 'generated/google/apis/compute_alpha/classes.rb', line 23170

def constraints
  @constraints
end

#hostsArray<String>

Used in Ingress or Egress Gateway cases to specify hosts that the policy applies to. Exact match, prefix match, and suffix match are supported. Corresponds to the JSON property hosts

Returns:

  • (Array<String>)


23176
23177
23178
# File 'generated/google/apis/compute_alpha/classes.rb', line 23176

def hosts
  @hosts
end

#methods_propArray<String>

HTTP method. Corresponds to the JSON property methods

Returns:

  • (Array<String>)


23181
23182
23183
# File 'generated/google/apis/compute_alpha/classes.rb', line 23181

def methods_prop
  @methods_prop
end

#not_hostsArray<String>

Negate of hosts. Specifies exclusions. Corresponds to the JSON property notHosts

Returns:

  • (Array<String>)


23186
23187
23188
# File 'generated/google/apis/compute_alpha/classes.rb', line 23186

def not_hosts
  @not_hosts
end

#not_methodsArray<String>

Negate of methods. Specifies exclusions. Corresponds to the JSON property notMethods

Returns:

  • (Array<String>)


23191
23192
23193
# File 'generated/google/apis/compute_alpha/classes.rb', line 23191

def not_methods
  @not_methods
end

#not_pathsArray<String>

Negate of paths. Specifies exclusions. Corresponds to the JSON property notPaths

Returns:

  • (Array<String>)


23196
23197
23198
# File 'generated/google/apis/compute_alpha/classes.rb', line 23196

def not_paths
  @not_paths
end

#not_portsArray<String>

Negate of ports. Specifies exclusions. Corresponds to the JSON property notPorts

Returns:

  • (Array<String>)


23201
23202
23203
# File 'generated/google/apis/compute_alpha/classes.rb', line 23201

def not_ports
  @not_ports
end

#pathsArray<String>

HTTP request paths or gRPC methods. Exact match, prefix match, and suffix match are supported. Corresponds to the JSON property paths

Returns:

  • (Array<String>)


23207
23208
23209
# File 'generated/google/apis/compute_alpha/classes.rb', line 23207

def paths
  @paths
end

#portsArray<String>

Port names or numbers. Corresponds to the JSON property ports

Returns:

  • (Array<String>)


23212
23213
23214
# File 'generated/google/apis/compute_alpha/classes.rb', line 23212

def ports
  @ports
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



23219
23220
23221
23222
23223
23224
23225
23226
23227
23228
23229
# File 'generated/google/apis/compute_alpha/classes.rb', line 23219

def update!(**args)
  @constraints = args[:constraints] if args.key?(:constraints)
  @hosts = args[:hosts] if args.key?(:hosts)
  @methods_prop = args[:methods_prop] if args.key?(:methods_prop)
  @not_hosts = args[:not_hosts] if args.key?(:not_hosts)
  @not_methods = args[:not_methods] if args.key?(:not_methods)
  @not_paths = args[:not_paths] if args.key?(:not_paths)
  @not_ports = args[:not_ports] if args.key?(:not_ports)
  @paths = args[:paths] if args.key?(:paths)
  @ports = args[:ports] if args.key?(:ports)
end