@Test public void testGuardedStr() { Object o = RandomGenerator.generate("\\a\\h###\\s\\h", GuardedString.class); assertTrue(o instanceof GuardedString); GuardedString pass = (GuardedString) o; pass.access((char[] clearChars) -> { final String result = new String(clearChars); assertTrue(result.startsWith("ah")); assertTrue(result.endsWith("sh")); }); }
public static String generate(String pattern) { return createRandomString(pattern, getDefaultCharacterSetMap()); }
RandomGenerator { public static String generate(String pattern) { return createRandomString(pattern, getDefaultCharacterSetMap()); } }
RandomGenerator { public static String generate(String pattern) { return createRandomString(pattern, getDefaultCharacterSetMap()); }  }
RandomGenerator { public static String generate(String pattern) { return createRandomString(pattern, getDefaultCharacterSetMap()); }  static String generate(String pattern); static Object generate(String pattern, Class<?> clazz); }
RandomGenerator { public static String generate(String pattern) { return createRandomString(pattern, getDefaultCharacterSetMap()); }  static String generate(String pattern); static Object generate(String pattern, Class<?> clazz);  }