Class: Google::Apis::ServicedirectoryV1::Namespace

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

Overview

A container for services. Namespaces allow administrators to group services together and define permissions for a collection of services.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ Namespace

Returns a new instance of Namespace.



487
488
489
# File 'lib/google/apis/servicedirectory_v1/classes.rb', line 487

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

Instance Attribute Details

#labelsHash<String,String>

Optional. Resource labels associated with this namespace. No more than 64 user labels can be associated with a given resource. Label keys and values can be no longer than 63 characters. Corresponds to the JSON property labels

Returns:

  • (Hash<String,String>)


473
474
475
# File 'lib/google/apis/servicedirectory_v1/classes.rb', line 473

def labels
  @labels
end

#nameString

Immutable. The resource name for the namespace in the format projects/*/ locations/*/namespaces/*. Corresponds to the JSON property name

Returns:

  • (String)


479
480
481
# File 'lib/google/apis/servicedirectory_v1/classes.rb', line 479

def name
  @name
end

#uidString

Output only. The globally unique identifier of the namespace in the UUID4 format. Corresponds to the JSON property uid

Returns:

  • (String)


485
486
487
# File 'lib/google/apis/servicedirectory_v1/classes.rb', line 485

def uid
  @uid
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



492
493
494
495
496
# File 'lib/google/apis/servicedirectory_v1/classes.rb', line 492

def update!(**args)
  @labels = args[:labels] if args.key?(:labels)
  @name = args[:name] if args.key?(:name)
  @uid = args[:uid] if args.key?(:uid)
end