Class SoftMaskedAlphabet.MaskingDetector.DefaultMaskingDetector

    • Constructor Detail

      • DefaultMaskingDetector

        public DefaultMaskingDetector()
    • Method Detail

      • isMasked

        public boolean isMasked​(java.lang.String token)
        Default Behaivour is that if the whole token is lower case it is masked.
        Specified by:
        isMasked in interface SoftMaskedAlphabet.MaskingDetector
        Parameters:
        token - the String to check for masking
        Returns:
        true is it is all lower case, otherwise false.
      • mask

        public java.lang.String mask​(java.lang.String token)
        Masks a token by making it lowercase
        Specified by:
        mask in interface SoftMaskedAlphabet.MaskingDetector
        Parameters:
        token - the String to mask
        Returns:
        a lower case String
      • unmask

        public java.lang.String unmask​(java.lang.String token)
        Un-masks the token by making it upper case.
        Specified by:
        unmask in interface SoftMaskedAlphabet.MaskingDetector
        Parameters:
        token - the String to unmask
        Returns:
        the upper case String