Class: TencentCloud::Teo::V20220901::ClientIpCountry

Inherits:
Common::AbstractModel
  • Object
show all
Defined in:
lib/v20220901/models.rb

Overview

回源时携带客户端IP所属地域信息,值的格式为ISO-3166-1两位字母代码。

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(switch = nil, headername = nil) ⇒ ClientIpCountry

Returns a new instance of ClientIpCountry.



3243
3244
3245
3246
# File 'lib/v20220901/models.rb', line 3243

def initialize(switch=nil, headername=nil)
  @Switch = switch
  @HeaderName = headername
end

Instance Attribute Details

#HeaderNameObject

<li>on:开启;</li> <li>off:关闭。</li> 为空则使用默认值:EO-Client-IPCountry。

Parameters:

  • Switch:

    配置开关,取值有:

  • HeaderName:

    存放客户端 IP 所属地域信息的请求头名称,当 Switch=on 时有效。



3241
3242
3243
# File 'lib/v20220901/models.rb', line 3241

def HeaderName
  @HeaderName
end

#SwitchObject

<li>on:开启;</li> <li>off:关闭。</li> 为空则使用默认值:EO-Client-IPCountry。

Parameters:

  • Switch:

    配置开关,取值有:

  • HeaderName:

    存放客户端 IP 所属地域信息的请求头名称,当 Switch=on 时有效。



3241
3242
3243
# File 'lib/v20220901/models.rb', line 3241

def Switch
  @Switch
end

Instance Method Details

#deserialize(params) ⇒ Object



3248
3249
3250
3251
# File 'lib/v20220901/models.rb', line 3248

def deserialize(params)
  @Switch = params['Switch']
  @HeaderName = params['HeaderName']
end