org.ops4j.pax.runner.handler.internal
Class URLUtils

java.lang.Object
  extended by org.ops4j.pax.runner.handler.internal.URLUtils

public class URLUtils
extends java.lang.Object

Utilities related to URL's.

Since:
0.5.6, December 13, 2007
Author:
Alin Dreghiciu
See Also:
URLStreamHandlerFactory

Method Summary
static java.net.URLStreamHandlerFactory getURLStreamHandlerFactory()
          Return the current URLStreamHandlerFactory.
static java.net.URLStreamHandlerFactory resetURLStreamHandlerFactory()
          Resets the current URLStreamHandlerFactory and returns the current factory.
static void setURLStreamHandlerFactory(java.net.URLStreamHandlerFactory urlStreamHandlerFactory)
          Sets the URL stream handler factory even if the URLSStreamHandler factory is already set in the URL.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

setURLStreamHandlerFactory

public static void setURLStreamHandlerFactory(java.net.URLStreamHandlerFactory urlStreamHandlerFactory)
Sets the URL stream handler factory even if the URLSStreamHandler factory is already set in the URL. URL permits setting of the factory only once pe JVM. If the factory is already set it will set the field via reflection and will keep the already set handler for delegation.

See Also:
URL.setURLStreamHandlerFactory(java.net.URLStreamHandlerFactory)

resetURLStreamHandlerFactory

public static java.net.URLStreamHandlerFactory resetURLStreamHandlerFactory()
Resets the current URLStreamHandlerFactory and returns the current factory.

Returns:
current factory

getURLStreamHandlerFactory

public static java.net.URLStreamHandlerFactory getURLStreamHandlerFactory()
Return the current URLStreamHandlerFactory.

Returns:
current factory


Copyright © 2006-2012 OPS4J - Open Participation Software for Java. All Rights Reserved.