parameters: (self, jardir, jarbase, jarname, chromebasepath, register, doZip=True)
docstring: Helper method to write out the chrome registration entries to
           jarfile.manifest or chrome.manifest, or both.
  
          The actual file processing is done in updateManifest.
docstring_summary: Helper method to write out the chrome registration entries to
           jarfile.manifest or chrome.manifest, or both.
docstring_tokens: Helper method to write out the chrome registration entries to jarfile . manifest or chrome . manifest or both .
function: def finalizeJar(self, jardir, jarbase, jarname, chromebasepath, register, doZip=True):
          '''Helper method to write out the chrome registration entries to
           jarfile.manifest or chrome.manifest, or both.
  
          The actual file processing is done in updateManifest.
          '''
  
          # rewrite the manifest, if entries given
          if not register:
              return
  
          chromeManifest = os.path.join(jardir, jarbase, 'chrome.manifest')
  
          if self.useJarfileManifest:
              self.updateManifest(os.path.join(jardir, jarbase,
                                               jarname + '.manifest'),
                                  chromebasepath.format(''), register)
              if jarname != 'chrome':
                  addEntriesToListFile(chromeManifest,
                                       ['manifest {0}.manifest'.format(jarname)])
          if self.useChromeManifest:
              chromebase = os.path.dirname(jarname) + '/'
              self.updateManifest(chromeManifest,
                                  chromebasepath.format(chromebase), register)
  
          # If requested, add a root chrome manifest entry (assumed to be in the parent directory
          # of chromeManifest) with the application specific id. In cases where we're building
          # lang packs, the root manifest must know about application sub directories.
  
          if self.rootManifestAppId:
              rootChromeManifest = \
                  os.path.join(os.path.normpath(os.path.dirname(chromeManifest)),
                               '..', 'chrome.manifest')
              rootChromeManifest = os.path.normpath(rootChromeManifest)
              chromeDir = \
                  os.path.basename(os.path.dirname(os.path.normpath(chromeManifest)))
              logging.info("adding '%s' entry to root chrome manifest appid=%s"
                            % (chromeDir, self.rootManifestAppId))
              addEntriesToListFile(rootChromeManifest,
                                   ['manifest %s/chrome.manifest application=%s'
                                    % (chromeDir,
                                   self.rootManifestAppId)])
function_tokens: def finalizeJar ( self , jardir , jarbase , jarname , chromebasepath , register , doZip = True ) : # rewrite the manifest, if entries given if not register : return chromeManifest = os . path . join ( jardir , jarbase , 'chrome.manifest' ) if self . useJarfileManifest : self . updateManifest ( os . path . join ( jardir , jarbase , jarname + '.manifest' ) , chromebasepath . format ( '' ) , register ) if jarname != 'chrome' : addEntriesToListFile ( chromeManifest , [ 'manifest {0}.manifest' . format ( jarname ) ] ) if self . useChromeManifest : chromebase = os . path . dirname ( jarname ) + '/' self . updateManifest ( chromeManifest , chromebasepath . format ( chromebase ) , register ) # If requested, add a root chrome manifest entry (assumed to be in the parent directory # of chromeManifest) with the application specific id. In cases where we're building # lang packs, the root manifest must know about application sub directories. if self . rootManifestAppId : rootChromeManifest = os . path . join ( os . path . normpath ( os . path . dirname ( chromeManifest ) ) , '..' , 'chrome.manifest' ) rootChromeManifest = os . path . normpath ( rootChromeManifest ) chromeDir = os . path . basename ( os . path . dirname ( os . path . normpath ( chromeManifest ) ) ) logging . info ( "adding '%s' entry to root chrome manifest appid=%s" % ( chromeDir , self . rootManifestAppId ) ) addEntriesToListFile ( rootChromeManifest , [ 'manifest %s/chrome.manifest application=%s' % ( chromeDir , self . rootManifestAppId ) ] )