Class ProtectedStringType

    • Field Detail

      • COMPLEX_TYPE

        public static final QName COMPLEX_TYPE
    • Constructor Detail

      • ProtectedStringType

        public ProtectedStringType()
    • Method Detail

      • equals

        public boolean equals​(Object obj)
        Description copied from class: ProtectedDataType
        Indicates whether some other object is "equal to" this one. This is standard Java equality comparison. I.e. it will return true if the Java objects contain the same data. This means that both object must use the same protection mechanism (enctyption,hash), same keys must be used, ciphertext or hashes must be the same and so on. If this method returns true then obviously also the cleartext data are the same. However, if this method returns false then no information about the cleartext data can be inferred. Cleartext data may still be the same in both objects. Therefore this method is not suitable for almost any practical purpose. It is here mostly just to keep the Java interface contract. See the methods of Protector for a more practical comparison algorithms.
        Overrides:
        equals in class ProtectedDataType<String>
        See Also:
        Protector#compareCleartext(ProtectedStringType, ProtectedStringType), Protector#areEquivalent(ProtectedStringType, ProtectedStringType)
      • bytesToString

        public static String bytesToString​(byte[] clearBytes)