org.ops4j.pax.url.commons.handler
Interface ConnectionFactory<T>


public interface ConnectionFactory<T>

URL connection factory.

Since:
0.1.0, January 13, 2008
Author:
Alin Dreghiciu

Method Summary
 java.net.URLConnection createConection(org.osgi.framework.BundleContext bundleContext, java.net.URL url, T config)
          Creates a handler specific conection.
 T createConfiguration(org.ops4j.util.property.PropertyResolver propertyResolver)
          Creates a handler specific configuration.
 

Method Detail

createConection

java.net.URLConnection createConection(org.osgi.framework.BundleContext bundleContext,
                                       java.net.URL url,
                                       T config)
                                       throws java.io.IOException
Creates a handler specific conection.

Parameters:
bundleContext - bundle context
url - url to be handled
config - protocol specific configuration
Returns:
URLConnection protocol specific connection
Throws:
java.io.IOException - if a malformed url is encountered. Protocol specific.

createConfiguration

T createConfiguration(org.ops4j.util.property.PropertyResolver propertyResolver)
Creates a handler specific configuration.

Parameters:
propertyResolver - configuration propertyResolver
Returns:
T protocol specific configuration


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