diff options
Diffstat (limited to 'src/main/java/at/gv/egiz/moazs/scheme/NotificationResponse.java')
-rw-r--r-- | src/main/java/at/gv/egiz/moazs/scheme/NotificationResponse.java | 20 |
1 files changed, 5 insertions, 15 deletions
diff --git a/src/main/java/at/gv/egiz/moazs/scheme/NotificationResponse.java b/src/main/java/at/gv/egiz/moazs/scheme/NotificationResponse.java index f465a28..7670ab7 100644 --- a/src/main/java/at/gv/egiz/moazs/scheme/NotificationResponse.java +++ b/src/main/java/at/gv/egiz/moazs/scheme/NotificationResponse.java @@ -6,24 +6,18 @@ import at.gv.zustellung.msg.xsd.DeliveryNotificationType; import static at.gv.zustellung.msg.xsd.DeliveryNotificationType.deliveryNotificationTypeBuilder; -public class NotificationResponse implements MsgResponse<DeliveryNotificationType> { +public class NotificationResponse extends MsgResponse<DeliveryNotificationType> { private final DeliveryNotificationType notification; - private final String id; - private static final String ID_SUFFIX = ".NO"; + private final static String ID_SUFFIX = ".NO"; public NotificationResponse(DeliveryNotificationType notification) { + super.id = createResponseId(notification.getAppDeliveryID(), ID_SUFFIX); this.notification = notification; - this.id = getId(notification.getAppDeliveryID()); } - @Override - public String getResponseID() { - return this.id; - } - - public static String getId(String appDeliveryID) { - return appDeliveryID + ID_SUFFIX; + public static String getResponseID(String appDeliveryID) { + return createResponseId(appDeliveryID, ID_SUFFIX); } @Override @@ -60,8 +54,4 @@ public class NotificationResponse implements MsgResponse<DeliveryNotificationTyp return new NotificationResponse(notification); } - - public static String getIdSuffix() { - return ID_SUFFIX; - } } |