PASTEBIN
| #1 paste tool since 2002
create new paste
tools
api
archive
faq
PASTEBIN
create new paste
trending pastes
sign up
login
my alerts
my settings
my profile
Don't like ads?
PRO users
don't see any ads ;-)
Public Pastes
Untitled
0 sec ago
Untitled
1 sec ago
Untitled
1 sec ago
Untitled
5 sec ago
Untitled
7 sec ago
Untitled
JavaScript | 25 sec ago
Untitled
8 sec ago
Untitled
9 sec ago
Untitled
By: a guest on
Jun 2nd, 2012
| syntax:
None
| size: 0.28 KB | hits: 40 | expires: Never
download
|
raw
|
embed
|
report abuse
|
print
Text below is selected. Please press Ctrl+C to copy to your clipboard. (⌘+C on Mac)
FindBugs RV_ABSOLUTE_VALUE_OF_RANDOM_INT warning
public static String generateUUID(int base){
return String.valueOf(getCurrentTimeInNanos((long)base)) +
String.valueOf(Math.abs(random.nextInt()));
}
assertTrue( Math.abs(Integer.MIN_VALUE) < 0 );
create a
new version
of this paste
RAW Paste Data
FindBugs RV_ABSOLUTE_VALUE_OF_RANDOM_INT warning public static String generateUUID(int base){ return String.valueOf(getCurrentTimeInNanos((long)base)) + String.valueOf(Math.abs(random.nextInt())); } assertTrue( Math.abs(Integer.MIN_VALUE) < 0 );