}
if (protocol == null)
throw new ProtocolException("Failed to get appropriate protocol for "
+ remoteSite);
} else {
connect(protocol = protocolFactory.newInstance(), remoteSite, false);
}
if (allowReuse)
this.reuseProtocols.put(remoteSite.getURL(), protocol);
}
return protocol;