@Test public void testMask() throws Exception { final String source = "unmasked"; final String masked = masker.mask(source); Assert.assertNotNull(masked); Assert.assertTrue(masked.length() > 0); }
@Override public String mask(String value) throws MaskException { try { return Base64.encodeBase64String(value.getBytes("UTF-8")); } catch (UnsupportedEncodingException e) { throw new MaskException("UTF-8 is not supported", e); } }
DefaultMasker implements Masker { @Override public String mask(String value) throws MaskException { try { return Base64.encodeBase64String(value.getBytes("UTF-8")); } catch (UnsupportedEncodingException e) { throw new MaskException("UTF-8 is not supported", e); } } }
DefaultMasker implements Masker { @Override public String mask(String value) throws MaskException { try { return Base64.encodeBase64String(value.getBytes("UTF-8")); } catch (UnsupportedEncodingException e) { throw new MaskException("UTF-8 is not supported", e); } }  }
DefaultMasker implements Masker { @Override public String mask(String value) throws MaskException { try { return Base64.encodeBase64String(value.getBytes("UTF-8")); } catch (UnsupportedEncodingException e) { throw new MaskException("UTF-8 is not supported", e); } }  @Override String mask(String value); @Override String unmask(String value); }
DefaultMasker implements Masker { @Override public String mask(String value) throws MaskException { try { return Base64.encodeBase64String(value.getBytes("UTF-8")); } catch (UnsupportedEncodingException e) { throw new MaskException("UTF-8 is not supported", e); } }  @Override String mask(String value); @Override String unmask(String value);  }