Class c=Class.forName( classN );
conn=(ServerConnector)c.newInstance();
} catch(Exception ex) {
ex.printStackTrace();
// return new HttpServerConnector();
return new HttpAdapter();
}
if( conn != null ) {
// set all the connector.x properties to the connector
int off=key.length();
Enumeration e=props.keys();
while( e.hasMoreElements() ) {
String n=(String)e.nextElement();
if( n.startsWith( key )) {
String pn=n.substring( off );
conn.setProperty( pn, props.getProperty( n ) );
//System.out.println("Set " + pn + " = " + props.getProperty(n ));
}
}
return conn;
}
}
// default
// HttpServerConnector con=new HttpServerConnector();
return new HttpAdapter();
}