code: protected String getNBRBundleName(URI uri) {
  		String ret = null;
  
  		String host = uri.getHost();
  		String authority;
  		if (host != null) {
  			ret = host;
  		} else if ((authority = uri.getAuthority()) != null) {
  			ret = authority;
  		} else {
  			String path = uri.getPath();
  			if (path.startsWith("/")) //$NON-NLS-1$
  				path = path.substring(1);
  			ret = path.substring(0, path.indexOf('/'));
  		}
  
  		return ret;
  	}
docs: Extracts the bundle's symbolic name from a uri with the <code>namedbundleresource<code> scheme.
  
  Supports backwards compatibility for names from 1.0.0 release (for now).
  
  @param uri The uri with a <code>namedbundleresource<code> scheme.
  @return The bundle's symbolic name within the uri.