protected void setEncoders(EndpointConfig endpointConfig)
throws DeploymentException {
encoderEntries.clear();
for (Class<? extends Encoder> encoderClazz :
endpointConfig.getEncoders()) {
Encoder instance;
try {
instance = encoderClazz.newInstance();
instance.init(endpointConfig);
} catch (InstantiationException | IllegalAccessException e) {
throw new DeploymentException(
sm.getString("wsRemoteEndpoint.invalidEncoder",
encoderClazz.getName()), e);
}