class Saklient::Cloud::Resources::RouterPlan
ルータ帯域プラン情報の1レコードに対応するクラス.
Attributes
帯域幅
@return [Fixnum]
ID
@return [String]
帯域幅
@return [Fixnum]
ID
@return [String]
名前
@return [String]
サービスクラス
@return [String]
@return [bool]
@return [bool]
@return [bool]
@return [bool]
名前
@return [String]
サービスクラス
@return [String]
Public Class Methods
@private @param [Saklient::Cloud::Client] client @param [any] obj @param [bool] wrapped
Saklient::Cloud::Resources::Resource::new
# File lib/saklient/cloud/resources/router_plan.rb, line 72 def initialize(client, obj, wrapped = false) super(client) Saklient::Util::validate_type(client, 'Saklient::Cloud::Client') Saklient::Util::validate_type(wrapped, 'bool') api_deserialize(obj, wrapped) end
Public Instance Methods
@private @return [String]
# File lib/saklient/cloud/resources/router_plan.rb, line 58 def _class_name return 'RouterPlan' end
@private @return [String]
# File lib/saklient/cloud/resources/router_plan.rb, line 64 def _id return get_id end
Protected Instance Methods
@private @return [String]
# File lib/saklient/cloud/resources/router_plan.rb, line 38 def _api_path return '/product/internet' end
@private @return [String]
# File lib/saklient/cloud/resources/router_plan.rb, line 44 def _root_key return 'InternetPlan' end
@private @return [String]
# File lib/saklient/cloud/resources/router_plan.rb, line 50 def _root_key_m return 'InternetPlans' end
(This method is generated in Translator_default#buildImpl)
@param [any] r
# File lib/saklient/cloud/resources/router_plan.rb, line 180 def api_deserialize_impl(r) @is_new = (r).nil? r = {} if @is_new @is_incomplete = false if Saklient::Util::exists_path(r, 'ID') @m_id = (Saklient::Util::get_by_path(r, 'ID')).nil? ? nil : Saklient::Util::get_by_path(r, 'ID').to_s else @m_id = nil @is_incomplete = true end @n_id = false if Saklient::Util::exists_path(r, 'Name') @m_name = (Saklient::Util::get_by_path(r, 'Name')).nil? ? nil : Saklient::Util::get_by_path(r, 'Name').to_s else @m_name = nil @is_incomplete = true end @n_name = false if Saklient::Util::exists_path(r, 'BandWidthMbps') @m_band_width_mbps = (Saklient::Util::get_by_path(r, 'BandWidthMbps')).nil? ? nil : (Saklient::Util::get_by_path(r, 'BandWidthMbps').to_s).to_s().to_i(10) else @m_band_width_mbps = nil @is_incomplete = true end @n_band_width_mbps = false if Saklient::Util::exists_path(r, 'ServiceClass') @m_service_class = (Saklient::Util::get_by_path(r, 'ServiceClass')).nil? ? nil : Saklient::Util::get_by_path(r, 'ServiceClass').to_s else @m_service_class = nil @is_incomplete = true end @n_service_class = false end
@private @param [bool] withClean @return [any]
# File lib/saklient/cloud/resources/router_plan.rb, line 217 def api_serialize_impl(withClean = false) Saklient::Util::validate_type(withClean, 'bool') ret = {} Saklient::Util::set_by_path(ret, 'ID', @m_id) if withClean || @n_id Saklient::Util::set_by_path(ret, 'Name', @m_name) if withClean || @n_name Saklient::Util::set_by_path(ret, 'BandWidthMbps', @m_band_width_mbps) if withClean || @n_band_width_mbps Saklient::Util::set_by_path(ret, 'ServiceClass', @m_service_class) if withClean || @n_service_class return ret end
(This method is generated in Translator_default#buildImpl)
@private @return [Fixnum]
# File lib/saklient/cloud/resources/router_plan.rb, line 136 def get_band_width_mbps return @m_band_width_mbps end
(This method is generated in Translator_default#buildImpl)
@private @return [String]
# File lib/saklient/cloud/resources/router_plan.rb, line 88 def get_id return @m_id end
(This method is generated in Translator_default#buildImpl)
@private @return [String]
# File lib/saklient/cloud/resources/router_plan.rb, line 112 def get_name return @m_name end
(This method is generated in Translator_default#buildImpl)
@private @return [String]
# File lib/saklient/cloud/resources/router_plan.rb, line 160 def get_service_class return @m_service_class end