Class: IBM::Cloud::SDK::Tags

Inherits:
IBM::Cloud::SDK::TAG::TagCollection show all
Defined in:
lib/ibm/cloud/sdk/tags.rb

Overview

A collection interface into the Tags API.

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods inherited from IBM::Cloud::SDK::TAG::TagCollection

#attached_to, #params, #reset_params, #total_count

Methods inherited from IBM::Cloud::SDKHTTP::BaseCollection

#all, #create, #data, #fetch, #params, #reset_params

Methods included from IBM::Cloud::SDKHTTP::BaseHTTPMixin

#adhoc, #delete, #get, #metadata, #patch, #post, #put, #unchecked_response, #url

Constructor Details

#initialize(connection, token, logger: nil) ⇒ Tags

rubocop:disable Lint/MissingSuper



12
13
14
15
16
17
18
# File 'lib/ibm/cloud/sdk/tags.rb', line 12

def initialize(connection, token, logger: nil) # rubocop:disable Lint/MissingSuper
  @token = token
  @connection = connection

  @logger = logger || Logger.new($stdout, level: :warn)
  @array_key = 'items'
end

Instance Attribute Details

#connectionObject (readonly)

Returns the value of attribute connection.



20
21
22
# File 'lib/ibm/cloud/sdk/tags.rb', line 20

def connection
  @connection
end

#loggerObject (readonly)

Returns the value of attribute logger.



20
21
22
# File 'lib/ibm/cloud/sdk/tags.rb', line 20

def logger
  @logger
end

#tokenObject (readonly)

Returns the value of attribute token.



20
21
22
# File 'lib/ibm/cloud/sdk/tags.rb', line 20

def token
  @token
end

Instance Method Details

#endpointObject



22
23
24
# File 'lib/ibm/cloud/sdk/tags.rb', line 22

def endpoint
  'https://tags.global-search-tagging.cloud.ibm.com/v3/tags'
end