MCPcopy Create free account
hub / github.com/DiUS/java-faker / randomDigit

Method randomDigit

src/main/java/com/github/javafaker/Number.java:15–17  ·  view source on GitHub ↗

Returns a random number from 0-9 (both inclusive)

()

Source from the content-addressed store, hash-verified

13 * Returns a random number from 0-9 (both inclusive)
14 */
15 public int randomDigit() {
16 return decimalBetween(0,10).intValue();
17 }
18
19 /**
20 * Returns a random number from 1-9 (both inclusive)

Callers 2

digitsMethod · 0.95
testRandomDigitMethod · 0.80

Calls 1

decimalBetweenMethod · 0.95

Tested by 1

testRandomDigitMethod · 0.64