Class: TencentCloud::Cvm::V20170312::AllocateHostsRequest

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

Overview

AllocateHosts请求参数结构体

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(placement = nil, clienttoken = nil, hostchargeprepaid = nil, hostchargetype = nil, hosttype = nil, hostcount = nil, tagspecification = nil) ⇒ AllocateHostsRequest



168
169
170
171
172
173
174
175
176
# File 'lib/v20170312/models.rb', line 168

def initialize(placement=nil, clienttoken=nil, hostchargeprepaid=nil, hostchargetype=nil, hosttype=nil, hostcount=nil, tagspecification=nil)
  @Placement = placement
  @ClientToken = clienttoken
  @HostChargePrepaid = hostchargeprepaid
  @HostChargeType = hostchargetype
  @HostType = hosttype
  @HostCount = hostcount
  @TagSpecification = tagspecification
end

Instance Attribute Details

#ClientToken ⇒ Object



166
167
168
# File 'lib/v20170312/models.rb', line 166

def ClientToken
  @ClientToken
end

#HostChargePrepaid ⇒ Object



166
167
168
# File 'lib/v20170312/models.rb', line 166

def HostChargePrepaid
  @HostChargePrepaid
end

#HostChargeType ⇒ Object



166
167
168
# File 'lib/v20170312/models.rb', line 166

def HostChargeType
  @HostChargeType
end

#HostCount ⇒ Object



166
167
168
# File 'lib/v20170312/models.rb', line 166

def HostCount
  @HostCount
end

#HostType ⇒ Object



166
167
168
# File 'lib/v20170312/models.rb', line 166

def HostType
  @HostType
end

#Placement ⇒ Object



166
167
168
# File 'lib/v20170312/models.rb', line 166

def Placement
  @Placement
end

#TagSpecification ⇒ Object



166
167
168
# File 'lib/v20170312/models.rb', line 166

def TagSpecification
  @TagSpecification
end

Instance Method Details

#deserialize(params) ⇒ Object



178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
# File 'lib/v20170312/models.rb', line 178

def deserialize(params)
  unless params['Placement'].nil?
    @Placement = Placement.new
    @Placement.deserialize(params['Placement'])
  end
  @ClientToken = params['ClientToken']
  unless params['HostChargePrepaid'].nil?
    @HostChargePrepaid = ChargePrepaid.new
    @HostChargePrepaid.deserialize(params['HostChargePrepaid'])
  end
  @HostChargeType = params['HostChargeType']
  @HostType = params['HostType']
  @HostCount = params['HostCount']
  unless params['TagSpecification'].nil?
    @TagSpecification = []
    params['TagSpecification'].each do |i|
      tagspecification_tmp = TagSpecification.new
      tagspecification_tmp.deserialize(i)
      @TagSpecification << tagspecification_tmp
    end
  end
end