public KeyManager[] wrap(KeyManager[] managers) {
if (managers==null) return null;
KeyManager[] result = new KeyManager[managers.length];
for (int i=0; i<result.length; i++) {
if (managers[i] instanceof X509KeyManager && getKeyAlias()!=null) {
result[i] = new NioX509KeyManager((X509KeyManager)managers[i],getKeyAlias());
} else {
result[i] = managers[i];
}
}
return result;