(self, package_writer, path_replacements=None,
                      extra_defines=None)
Generate the entire package of an API library.

    Overrides superclass.

    Args:
      package_writer: (LibraryPackage) output package
      path_replacements: (dict) dict holding elements which should be replaced
        if found in a path. (See generator.WalkTemplateTree for details.)
      extra_defines: (dict) Dictionary of extra definitions to provide to the
        templates
Generate the entire package of an API library.
Generate the entire package of an API library .
def GeneratePackage(self, package_writer, path_replacements=None,
                      extra_defines=None):
    """Generate the entire package of an API library.

    Overrides superclass.

    Args:
      package_writer: (LibraryPackage) output package
      path_replacements: (dict) dict holding elements which should be replaced
        if found in a path. (See generator.WalkTemplateTree for details.)
      extra_defines: (dict) Dictionary of extra definitions to provide to the
        templates
    """
    api = self._api
    self.AnnotateApiForLanguage(api)

    self._BuildPathReplacements(path_replacements)
    self._top_level_defines = {'api': api.values}
    self._top_level_defines.update(extra_defines or {})

    self._GenerateLibrarySource(api, package_writer)
    if self._options.get('include_dependencies'):
      self.WalkTemplateTree('dependencies', self._path_replacements, {},
                            self._top_level_defines, package_writer)
def GeneratePackage ( self , package_writer , path_replacements = None , extra_defines = None ) : api = self . _api self . AnnotateApiForLanguage ( api ) self . _BuildPathReplacements ( path_replacements ) self . _top_level_defines = { 'api' : api . values } self . _top_level_defines . update ( extra_defines or { } ) self . _GenerateLibrarySource ( api , package_writer ) if self . _options . get ( 'include_dependencies' ) : self . WalkTemplateTree ( 'dependencies' , self . _path_replacements , { } , self . _top_level_defines , package_writer )