Class: Sem4r::AdGroupBids
- Inherits:
-
Object
- Object
- Sem4r::AdGroupBids
- Includes:
- Sem4rSoap::SoapAttributes
- Defined in:
- lib/sem4r/ad_group/ad_group_bids.rb
Direct Known Subclasses
BudgetOptimizerAdGroupBids, ConversionOptimizerAdGroupBids, ManualCPCAdGroupBids, ManualCPMAdGroupBids
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(&block) ⇒ AdGroupBids
constructor
g_accessor :type.
- #to_s ⇒ Object
Methods included from Sem4rSoap::SoapAttributes
#_from_element, #_to_s, #_to_xml, included
Constructor Details
#initialize(&block) ⇒ AdGroupBids
g_accessor :type
36 37 38 39 40 |
# File 'lib/sem4r/ad_group/ad_group_bids.rb', line 36 def initialize(&block) if block_given? block.arity < 1 ? instance_eval(&block) : block.call(self) end end |
Class Method Details
.from_element(el) ⇒ Object
42 43 44 45 46 |
# File 'lib/sem4r/ad_group/ad_group_bids.rb', line 42 def self.from_element(el) type = el.at_xpath("AdGroupBids.Type").text.strip klass = Module::const_get(type) klass.from_element(el) end |
Instance Method Details
#to_s ⇒ Object
48 49 50 |
# File 'lib/sem4r/ad_group/ad_group_bids.rb', line 48 def to_s "#{@maxcpc / 10000} cents" end |