Class: K3CloudWebapiSdk::Model::Identity

Inherits:
Object
  • Object
show all
Defined in:
lib/k3cloud_webapi_sdk/model/identity.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(server_url, dcid, user_name, app_id, app_secret, org_num, lcid = 2052, pwd = '') ⇒ Identity



6
7
8
9
10
11
12
13
14
15
# File 'lib/k3cloud_webapi_sdk/model/identity.rb', line 6

def initialize(server_url, dcid, user_name, app_id, app_secret, org_num, lcid = 2052, pwd = '')
  @server_url = server_url
  @dcid = dcid
  @lcid = lcid
  @user_name = user_name
  @pwd = pwd
  @app_id = app_id
  @app_secret = app_secret
  @org_num = org_num
end

Instance Attribute Details

#app_idObject

Returns the value of attribute app_id.



4
5
6
# File 'lib/k3cloud_webapi_sdk/model/identity.rb', line 4

def app_id
  @app_id
end

#app_secretObject

Returns the value of attribute app_secret.



4
5
6
# File 'lib/k3cloud_webapi_sdk/model/identity.rb', line 4

def app_secret
  @app_secret
end

#dcidObject

Returns the value of attribute dcid.



4
5
6
# File 'lib/k3cloud_webapi_sdk/model/identity.rb', line 4

def dcid
  @dcid
end

#lcidObject

Returns the value of attribute lcid.



4
5
6
# File 'lib/k3cloud_webapi_sdk/model/identity.rb', line 4

def lcid
  @lcid
end

#org_numObject

Returns the value of attribute org_num.



4
5
6
# File 'lib/k3cloud_webapi_sdk/model/identity.rb', line 4

def org_num
  @org_num
end

#pwdObject

Returns the value of attribute pwd.



4
5
6
# File 'lib/k3cloud_webapi_sdk/model/identity.rb', line 4

def pwd
  @pwd
end

#server_urlObject

Returns the value of attribute server_url.



4
5
6
# File 'lib/k3cloud_webapi_sdk/model/identity.rb', line 4

def server_url
  @server_url
end

#user_nameObject

Returns the value of attribute user_name.



4
5
6
# File 'lib/k3cloud_webapi_sdk/model/identity.rb', line 4

def user_name
  @user_name
end

Instance Method Details

#to_hObject



17
18
19
20
21
22
23
24
25
26
27
28
# File 'lib/k3cloud_webapi_sdk/model/identity.rb', line 17

def to_h
  {
    server_url: @server_url,
    dcid: @dcid,
    lcid: @lcid,
    user_name: @user_name,
    pwd: @pwd,
    app_id: @app_id,
    app_secret: @app_secret,
    org_num: @org_num
  }
end