Class EncryptionKeyVersionUnknownExceptionData

java.lang.Object
org.fuin.ddd4j.jaxb.EncryptionKeyVersionUnknownExceptionData
All Implemented Interfaces:
Serializable, org.fuin.ddd4j.core.ExceptionData<org.fuin.ddd4j.core.EncryptionKeyVersionUnknownException>, org.fuin.objects4j.common.ToExceptionCapable<org.fuin.ddd4j.core.EncryptionKeyVersionUnknownException>, org.fuin.objects4j.common.ValueObject

public class EncryptionKeyVersionUnknownExceptionData extends Object implements org.fuin.ddd4j.core.ExceptionData<org.fuin.ddd4j.core.EncryptionKeyVersionUnknownException>
Stores the data from a EncryptionKeyVersionUnknownException for marshalling and allows recreating it after unmarshalling. The idea is to transport an exception from the server to the client (without stack trace) and recreate it to be thrown on the client.
See Also:
  • Constructor Details

    • EncryptionKeyVersionUnknownExceptionData

      protected EncryptionKeyVersionUnknownExceptionData()
      Constructor only for marshalling/unmarshalling.
    • EncryptionKeyVersionUnknownExceptionData

      public EncryptionKeyVersionUnknownExceptionData(@NotNull @NotNull org.fuin.ddd4j.core.EncryptionKeyVersionUnknownException ex)
      Constructor with all data.
      Parameters:
      ex - Exception to copy data from.
  • Method Details

    • getDataElement

      public String getDataElement()
      Specified by:
      getDataElement in interface org.fuin.ddd4j.core.ExceptionData<org.fuin.ddd4j.core.EncryptionKeyVersionUnknownException>
    • getMessage

      public final String getMessage()
      Returns the exception message.
      Returns:
      Message.
    • getShortId

      public String getShortId()
      Returns the unique short identifier of the contained exception.
      Returns:
      Unique and human readable identifier.
    • getKeyVersion

      public String getKeyVersion()
      Returns the key version that caused the problem.
      Returns:
      Key version.
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • equals

      public boolean equals(Object obj)
      Overrides:
      equals in class Object
    • toString

      public String toString()
      Overrides:
      toString in class Object
    • toException

      public org.fuin.ddd4j.core.EncryptionKeyVersionUnknownException toException()
      Specified by:
      toException in interface org.fuin.objects4j.common.ToExceptionCapable<org.fuin.ddd4j.core.EncryptionKeyVersionUnknownException>