|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectice.util.AbstractVersion
ice.util.JavaVersion
This class provides some common operations relating to Java versioning for the
browser environment.
Simple checks that the current VM is at least v1.2 can be done with:
JavaVersion.isV12orGreater()
To compare two Version objects, use the Comparator classes provided in
ice.util
FullVersionComparator,
MajorMinorVersionComparator| Field Summary | |
static int |
BUILD_PART_ONE
Portion of build spec before the underscore |
static int |
BUILD_PART_TWO
Portion of build spec after underscore |
static boolean |
IS_MAC_OS
Public access to whether the system is considered to be running on a MAC. |
static int |
MAJOR_MINOR_LENGTH
Length of the major.minor version spec test |
static int |
MAJOR_PART
Major version part |
static int |
MINOR_PART
Minor version part |
static int |
VERSION_FULL_LENGTH
Number of version specification components |
| Fields inherited from class ice.util.AbstractVersion |
_versionParts |
| Method Summary | |
static JavaVersion |
getVersion(String versionString)
Retrieve an instance of the Version class from a version string of the format: |
static JavaVersion |
getVersionFromHex(String versionString)
Retrieve an instance of the Version class from a version string of the format: |
static JavaVersion |
getVMVersion()
Retrieve a Version object initialized with the value of the system property "java.version" |
static boolean |
isV12orGreater()
Convenience method to determine if this is at least a 1.2 compatible platform. |
static boolean |
isV13orGreater()
Convenience method to determine if this is at least a 1.3 compatible platform. |
static boolean |
isV14orGreater()
Convenience method to determine if this is at least a 1.4 compatible platform. |
static boolean |
isV15orGreater()
Convenience method to determine if this is at least a 1.5 compatible platform. |
String |
toString()
Retrieve a String representation of this Version |
| Methods inherited from class ice.util.AbstractVersion |
compareTo, getParts |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
public static final int MAJOR_PART
public static final int MINOR_PART
public static final int BUILD_PART_ONE
public static final int BUILD_PART_TWO
public static final int VERSION_FULL_LENGTH
public static final int MAJOR_MINOR_LENGTH
public static boolean IS_MAC_OS
| Method Detail |
public static JavaVersion getVMVersion()
public static JavaVersion getVersion(String versionString)
XX.YY.ZZ_AA
where:
versionString - The String containing the version specification
NumberFormatException - if any portion of the version
specification is unparsablepublic static JavaVersion getVersionFromHex(String versionString)
AAAA-BBBB-CCCC
where:
versionString - The String containing the version specification
NumberFormatException - If the format of the Version string is
invalidpublic static boolean isV12orGreater()
'java.version' is at least 1.2.0.0
- Returns:
- true if the VM is currently v1.2 or greater
public static boolean isV13orGreater()
'java.version' is at least 1.3.0.0
- Returns:
- true if the VM is currently v1.3 or greater
public static boolean isV14orGreater()
'java.version' is at least 1.4.0.0
- Returns:
- true if the VM is currently v1.4 or greater
public static boolean isV15orGreater()
'java.version' is at least 1.5.0.0
- Returns:
- true if the VM is currently v1.5 or greater
public String toString()
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||