tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "eugeny-a.smirnov" <eugeny-a.smir...@db.com>
Subject Re: Custom URL handlers in Tomcat web app
Date Fri, 04 Dec 2009 16:52:29 GMT

Hi

I've resolved this issue in this way:

  URLStreamHandlerFactoryImpl.termspecProtocolHandler = handlerClass;
        try {
            for (final Field field : URL.class.getDeclaredFields()) {
                if ("factory".equalsIgnoreCase(field.getName()) ) {
                    field.setAccessible(true);
                    field.set(null, new
URLStreamHandlerFactoryImpl((URLStreamHandlerFactory) field.get(null)));
                }
            }
        } catch (Throwable e) {
            logger.error(e);
        }
-- 
View this message in context: http://old.nabble.com/Custom-URL-handlers-in-Tomcat-web-app-tp15629476p26636133.html
Sent from the Tomcat - User mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Mime
View raw message