// (z.Bsp. vom Payment-Server) automatisch beantwortet werden kann.
QueryMessage msg = new QueryMessage(passport);
Application.getMessagingFactory().getMessagingQueue("hibiscus.passport.rdh.hbciversion").sendSyncMessage(msg);
Object data = msg.getData();
if (data == null || !(data instanceof String))
throw new ApplicationException(i18n.tr("HBCI-Version nicht ermittelbar"));
String version = (String)msg.getData();
Logger.info("using hbci version: " + version);
handler = new HBCIHandler(version,passport);
handler.close();
handler = null;
Application.getMessagingFactory().sendMessage(new StatusBarMessage(i18n.tr("Schl�ssel erfolgreich erstellt"), StatusBarMessage.TYPE_SUCCESS));
return key;
}
catch (ApplicationException ae)
{
throw ae;
}
catch (OperationCanceledException oce)
{
throw oce;
}
catch (Exception e)
{
OperationCanceledException oce = (OperationCanceledException) HBCIProperties.getCause(e,OperationCanceledException.class);
if (oce != null)
throw oce;
ApplicationException ae = (ApplicationException) HBCIProperties.getCause(e,ApplicationException.class);
if (ae != null)
throw ae;
NeedKeyAckException ack = (NeedKeyAckException) HBCIProperties.getCause(e,NeedKeyAckException.class);
if (ack != null)
{
Application.getMessagingFactory().sendMessage(new StatusBarMessage(i18n.tr("Schl�ssel erfolgreich erstellt"), StatusBarMessage.TYPE_SUCCESS));
String msg = i18n.tr("Bitte senden Sie den INI-Brief an Ihre Bank\nund warten Sie auf die Freischaltung durch die Bank.");
try
{
Application.getCallback().notifyUser(msg);
}
catch (Exception e2)
{
Logger.error("unable to notify user",e2);
Application.getMessagingFactory().sendMessage(new StatusBarMessage(msg, StatusBarMessage.TYPE_SUCCESS));
}
return key;
}
Logger.error("unable to create key " + file.getAbsolutePath(),e);
throw new ApplicationException(i18n.tr("Fehler beim Erstellen des Schl�ssels: {0}",e.getMessage()));
}
finally
{
try
{