/* 1203 */ return rh == null ? null : (NegotiableCapabilitySet)rh.get(JAI.KEY_NEGOTIATION_PREFERENCES);
/* */ }
/* */
/* */ private NegotiableCapabilitySet negotiate(NegotiableCapabilitySet prefs)
/* */ {
/* 1210 */ OperationRegistry registry = this.nodeSupport.getRegistry();
/* */
/* 1212 */ NegotiableCapabilitySet serverCap = null;
/* */
/* 1215 */ RemoteDescriptor descriptor = (RemoteDescriptor)registry.getDescriptor(RemoteDescriptor.class, this.protocolName);
/* */
/* 1218 */ if (descriptor == null) {
/* 1219 */ Object[] msgArg0 = { new String(this.protocolName) };
/* 1220 */ MessageFormat formatter = new MessageFormat("");
/* 1221 */ formatter.setLocale(Locale.getDefault());
/* 1222 */ formatter.applyPattern(JaiI18N.getString("RemoteJAI16"));
/* 1223 */ throw new ImagingException(formatter.format(msgArg0));
/* */ }
/* */
/* 1226 */ int count = 0;
/* 1227 */ int numRetries = getNumRetries();
/* 1228 */ int retryInterval = getRetryInterval();
/* */
/* 1230 */ Exception rieSave = null;
/* 1231 */ while (count++ < numRetries) {
/* */ try {
/* 1233 */ serverCap = descriptor.getServerCapabilities(this.serverName);
/* */ }
/* */ catch (RemoteImagingException rie)
/* */ {
/* 1237 */ System.err.println(JaiI18N.getString("RemoteJAI24"));
/* 1238 */ rieSave = rie;
/* */ try
/* */ {
/* 1241 */ Thread.sleep(retryInterval);
/* */ }
/* */ catch (InterruptedException ie) {
/* 1244 */ sendExceptionToListener(JaiI18N.getString("Generic5"), new ImagingException(JaiI18N.getString("Generic5"), ie));
/* */ }
/* */ }
/* */
/* */ }
/* */
/* 1250 */ if ((serverCap == null) && (count > numRetries)) {
/* 1251 */ sendExceptionToListener(JaiI18N.getString("RemoteJAI18"), rieSave);
/* */ }
/* */
/* 1255 */ RemoteRIF rrif = (RemoteRIF)registry.getFactory("remoteRendered", this.protocolName);
/* */
/* 1258 */ return RemoteJAI.negotiate(prefs, serverCap, rrif.getClientCapabilities());
/* */ }