|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectorg.annolab.tt4j.PlatformDetector
public class PlatformDetector
Detect platform information and normalize it.
| Field Summary | |
|---|---|
static java.lang.String |
ARCH_PPC
|
static java.lang.String |
ARCH_SPARC
|
static java.lang.String |
ARCH_X86_32
|
static java.lang.String |
ARCH_X86_64
|
static java.lang.String |
OS_LINUX
|
static java.lang.String |
OS_OSX
|
static java.lang.String |
OS_SOLARIS
|
static java.lang.String |
OS_WINDOWS
|
| Constructor Summary | |
|---|---|
PlatformDetector()
|
|
| Method Summary | |
|---|---|
java.lang.String |
getArch()
Get the platform architecture. |
java.lang.String |
getByteOrder()
Get the byte order. |
java.lang.String[] |
getChmodCmd()
Get the chmod (change permissions) command for the current platform (if one is necessary). |
java.lang.String |
getExecutableSuffix()
Get the file suffix used for executable files on the currently configured platform. |
java.lang.String |
getOs()
Get the operating system. |
java.lang.String |
getPlatformId()
Get the platform ID which is getOs() and getArch()
separated by a "-" (dash). |
void |
setArch(java.lang.String aArch)
Override the architecture. |
void |
setByteOrder(java.nio.ByteOrder aByteOrder)
Set the byte order. |
void |
setOs(java.lang.String aOs)
Override the operating system name. |
void |
updatePlatform(java.lang.String aOs,
java.lang.String aArch,
java.nio.ByteOrder aByteOrder)
Updates the platform-specific settings and normalizes them. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static java.lang.String OS_WINDOWS
public static java.lang.String OS_OSX
public static java.lang.String OS_SOLARIS
public static java.lang.String OS_LINUX
public static java.lang.String ARCH_PPC
public static java.lang.String ARCH_X86_32
public static java.lang.String ARCH_X86_64
public static java.lang.String ARCH_SPARC
| Constructor Detail |
|---|
public PlatformDetector()
| Method Detail |
|---|
public void setOs(java.lang.String aOs)
aOs - an OS name as could be found in the os.name system
property.public java.lang.String getOs()
public void setArch(java.lang.String aArch)
aArch - "big-endian" for PowerPC or Sparc systems or
"little-endian" for x86 systems.public java.lang.String getArch()
public void setByteOrder(java.nio.ByteOrder aByteOrder)
aByteOrder - the byte order.public java.lang.String getExecutableSuffix()
public java.lang.String getByteOrder()
public java.lang.String getPlatformId()
getOs() and getArch()
separated by a "-" (dash).
public void updatePlatform(java.lang.String aOs,
java.lang.String aArch,
java.nio.ByteOrder aByteOrder)
aOs - the operating system string.aArch - the architecture string.aByteOrder - the byte-order string.public java.lang.String[] getChmodCmd()
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||