clazz = Class.forName(name);
clazz = secureAction.forName(name);
	public URLStreamHandler createURLStreamHandler(String protocol) {		//first check for built in handlers		String builtInHandlers = System.getProperty(PROTOCOL_HANDLER_PKGS);		builtInHandlers = builtInHandlers == null ? DEFAULT_VM_PROTOCOL_HANDLERS : DEFAULT_VM_PROTOCOL_HANDLERS + '|' + builtInHandlers;		Class clazz = null;		if (builtInHandlers != null) {			StringTokenizer tok = new StringTokenizer(builtInHandlers, "|"); //$NON-NLS-1$			while (tok.hasMoreElements()) {				StringBuffer name = new StringBuffer();				name.append(tok.nextToken());				name.append("."); //$NON-NLS-1$				name.append(protocol);				name.append(".Handler"); //$NON-NLS-1$				try {					clazz = secureAction.forName(name.toString());					if (clazz != null) {						return (null); //this class exists, it is a built in handler, let the JVM handle it						}				} catch (ClassNotFoundException ex) {				} //keep looking 			}		}		//internal protocol handlers		String name = INTERNAL_PROTOCOL_HANDLER_PKG + protocol + ".Handler"; //$NON-NLS-1$		try {			clazz = Class.forName(name);		}		//Now we check the service registry		catch (Throwable t) {			//first check to see if the handler is in the cache			URLStreamHandlerProxy handler = (URLStreamHandlerProxy) proxies.get(protocol);			if (handler != null) {				return (handler);			}			//TODO avoid deep nesting of control structures - return early			//look through the service registry for a URLStramHandler registered for this protocol			org.osgi.framework.ServiceReference[] serviceReferences = handlerTracker.getServiceReferences();			if (serviceReferences != null) {				for (int i = 0; i < serviceReferences.length; i++) {					Object prop = serviceReferences[i].getProperty(URLConstants.URL_HANDLER_PROTOCOL);					if (prop != null && prop instanceof String[]) {						String[] protocols = (String[]) prop;						for (int j = 0; j < protocols.length; j++) {							if (protocols[j].equals(protocol)) {								handler = new URLStreamHandlerProxy(protocol, serviceReferences[i], context);								proxies.put(protocol, handler);								return (handler);							}						}					}				}			}			return (null);		}		if (clazz == null) {			return null;		}		try {			URLStreamHandler handler = (URLStreamHandler) clazz.newInstance();			if (handler instanceof ProtocolActivator) {				((ProtocolActivator) handler).start(context, adaptor);			}			return handler;		} catch (Exception e) {			return null;		}	}