B2G/gecko/browser/components/feeds/src/WebContentConverter.js
/**
   * Update the content type -> handler map. This mapping is not persisted, use
   * registerContentHandler or _saveContentHandlerToPrefs for that purpose.
   * @param   contentType
   *          The content Type being handled
   * @param   uri
   *          The uri of the web service
   * @param   title
   *          The human readable name of the web service
   */
Update the content type -> handler map. This mapping is not persisted, use
registerContentHandler or _saveContentHandlerToPrefs for that purpose.
@param   contentType
The content Type being handled
@param   uri
The uri of the web service
@param   title
The human readable name of the web service
Update the content type - > handler map . This mapping is not persisted use registerContentHandler or _saveContentHandlerToPrefs for that purpose . @param contentType The content Type being handled @param uri The uri of the web service @param title The human readable name of the web service
function WCCR__updateContentTypeHandlerMap(contentType, uri, title) {
    if (!(contentType in this._contentTypes))
      this._contentTypes[contentType] = [];
    if (this._typeIsRegistered(contentType, uri)) 
      return;
    this._contentTypes[contentType].push(new ServiceInfo(contentType, uri, title));
    if (!(contentType in this._blockedTypes)) {
      var converterContractID = this._getConverterContractID(contentType);
      var cr = Components.manager.QueryInterface(Ci.nsIComponentRegistrar);
      cr.registerFactory(WCC_CLASSID, WCC_CLASSNAME, converterContractID, 
                         WebContentConverterFactory);
    }
  }
function WCCR__updateContentTypeHandlerMap ( contentType , uri , title ) { if ( ! ( contentType in this . _contentTypes ) ) this . _contentTypes [ contentType ] = [ ] ; if ( this . _typeIsRegistered ( contentType , uri ) ) return ; this . _contentTypes [ contentType ] . push ( new ServiceInfo ( contentType , uri , title ) ) ; if ( ! ( contentType in this . _blockedTypes ) ) { var converterContractID = this . _getConverterContractID ( contentType ) ; var cr = Components . manager . QueryInterface ( Ci . nsIComponentRegistrar ) ; cr . registerFactory ( WCC_CLASSID , WCC_CLASSNAME , converterContractID , WebContentConverterFactory ) ; } }
Update the content type -> handler map.
Update the content type - > handler map .
// Avoid adding duplicates