public class SystemUtils
extends Object
| Modifier and Type | Class | Description |
|---|---|---|
static class |
SystemUtils.ReplaceItem |
| Modifier and Type | Field | Description |
|---|---|---|
static java.util.Locale |
defaultLocale |
|
static java.util.TimeZone |
defaultTimeZone |
|
static java.util.TimeZone |
gmtTimeZone |
|
protected static long |
msb0baseTime |
|
protected static long |
msb1baseTime |
| Constructor | Description |
|---|---|
SystemUtils() |
| Modifier and Type | Method | Description |
|---|---|---|
static void |
addBouncyCastleSecurityProvider() |
Load bouncy castle providers, Internal use.
|
static String[] |
execCommandGetResult(String cmdStr) |
|
static String[] |
execCommandGetResult(String[] cmdStr) |
|
static String |
expandEnvironmentVariables(String inValue) |
Expand system level Java properties in a String in the form ${property-name}
|
static String |
expandEnvironmentVariables(String inValue,
java.util.Map valueMap) |
Expand system level Java properties in a String in the form ${property-name}.
|
static long |
getCpuTime() |
Get CPU time in nanoseconds.
|
static String |
getLinuxSocketParam(String cmdStr) |
|
static byte[] |
getMACAddress() |
Get MAC address of localhost interface (only works on Java 6 or greater)
|
static long |
getSystemTime() |
Get system time in nanoseconds.
|
static long |
getUserTime() |
Get user time in nanoseconds.
|
static long |
toNTPTime(long t) |
Convert a timecode value in milliseconds to NTP time
|
public static final java.util.Locale defaultLocale
public static final java.util.TimeZone defaultTimeZone
public static final java.util.TimeZone gmtTimeZone
protected static final long msb0baseTime
protected static final long msb1baseTime
public static void addBouncyCastleSecurityProvider()
public static String[] execCommandGetResult(String cmdStr)
public static String[] execCommandGetResult(String[] cmdStr)
public static String expandEnvironmentVariables(String inValue)
inValue - string with propertiespublic static String expandEnvironmentVariables(String inValue,
java.util.Map valueMap)
inValue - string with propertiesvalueMap - name/value pair mappublic static long getCpuTime()
public static String getLinuxSocketParam(String cmdStr)
public static byte[] getMACAddress()
public static long getSystemTime()
public static long getUserTime()
public static long toNTPTime(long t)
t - timecode value in milliseconds