lib/adwords4r/v13/KeywordToolServiceWrapper.rb in adwords4r-16.0.0 vs lib/adwords4r/v13/KeywordToolServiceWrapper.rb in adwords4r-17.0.0
- old
+ new
@@ -1,6 +1,6 @@
-# This file was automatically generated during the "rake generate" step of the
+# This file was automatically generated during the "rake generate" step of
# library setup.
require 'adwords4r/v13/KeywordToolServiceDriver.rb'
module AdWords
module V13
@@ -8,13 +8,22 @@
# Wrapper class for the v13 KeywordTool service.
# This class is automatically generated.
class KeywordToolServiceWrapper
- # Holds the AdWords::API object to which the wrapper belongs
+ # Holds the AdWords::API object to which the wrapper belongs.
attr_reader :api
+ # Holds a shortcut to the parent module.
+ # Use this to avoid typing the full class name when creating classes
+ # belonging to this service, e.g.
+ # service_object.module::ClassName
+ # instead of
+ # AdWords::V13::KeywordToolService::ClassName
+ # This will make it easier to migrate your code between API versions.
+ attr_reader :module
+
public
# Constructor for KeywordToolServiceWrapper.
#
# Args:
@@ -23,9 +32,10 @@
# - api: the AdWords::API object to which the wrapper belongs
#
def initialize(driver, api)
@driver = driver
@api = api
+ @module = AdWords::V13::KeywordToolService
end
# Calls the {getKeywordVariations}[http://code.google.com/apis/adwords/docs/developer/KeywordToolService.html#getKeywordVariations] method of the KeywordTool service.
# Check {the online documentation for this method}[http://code.google.com/apis/adwords/docs/developer/KeywordToolService.html#getKeywordVariations].
#