com.credibledoc.iso8583packer.masking.AnyMasker Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of iso-8583-packer Show documentation
Show all versions of iso-8583-packer Show documentation
Helps to define message structure in ISO 8583 and other formats.
package com.credibledoc.iso8583packer.masking;
import com.credibledoc.iso8583packer.string.StringUtils;
/**
* Replace all bytes with '99' and value.toString() with '*'.
*
* @author Kyrylo Semenko
*/
public class AnyMasker implements Masker {
@Override
public String maskHex(String hex) {
return StringUtils.leftPad("", hex.length(), '9');
}
@Override
public String maskValue(Object value) {
return StringUtils.leftPad("", value.toString().length(), '*');
}
}