MCPcopy Create free account
hub / github.com/FongMi/TV / random

Method random

thunder/src/main/java/com/xunlei/downloadlib/android/XLUtil.java:24–29  ·  view source on GitHub ↗
(String base, int length)

Source from the content-addressed store, hash-verified

22 }
23
24 private static String random(String base, int length) {
25 SecureRandom random = new SecureRandom();
26 StringBuilder sb = new StringBuilder();
27 for (int i = 0; i < length; i++) sb.append(base.charAt(random.nextInt(base.length())));
28 return sb.toString();
29 }
30
31 public static String getGuid() {
32 return getIMEI() + "_" + getMAC();

Callers 7

getMACMethod · 0.95
getIMEIMethod · 0.95
cheerio.min.jsFile · 0.80
cat.jsFile · 0.80
crypto-js.jsFile · 0.80
jquery.min.jsFile · 0.80
neFunction · 0.80

Calls 2

appendMethod · 0.45
toStringMethod · 0.45

Tested by

no test coverage detected