public class PlatformRegistry
extends java.lang.Object
| Modifier and Type | Class and Description | 
|---|---|
static class  | 
PlatformRegistry.VersionMatch  | 
| Modifier and Type | Method and Description | 
|---|---|
static Platform | 
getDefaultPlatform()  | 
static Platform | 
getPlatform(PlatformType type,
           PlatformVersion version)
Get a platform matching the type and version supplied. 
 | 
static Platform | 
getPlatform(PlatformType type,
           PlatformVersion version,
           PlatformRegistry.VersionMatch matchType)
Returns the best matching Platform depending on matchType. 
 | 
static Platform | 
getPlatform(PlatformType type,
           java.lang.String version)
Constructs a PlatformVersion from a version string in its canonical form (e.g "10.1.3")
 and calls the preceding version of getPlatform() 
 | 
static Platform[] | 
getPlatforms()
Retrieve all platforms in the registry. 
 | 
static Platform[] | 
getPlatforms(PlatformType filterOnType)
Retrieve all registerd platforms of a type. 
 | 
static Platform[] | 
getPlatforms(PlatformType filterOnType,
            boolean includeSubTypes)
This version of getPlatforms() takes a boolean parameter which specifies whether
 subtypes (or extensions) of filterOnType should be included in the result. 
 | 
static void | 
registerPlatform(Platform platform)  | 
static void | 
setDefaultPlatform(Platform platform)  | 
public static void setDefaultPlatform(Platform platform) throws MetadataException
MetadataExceptionpublic static Platform getDefaultPlatform()
public static void registerPlatform(Platform platform)
public static Platform getPlatform(PlatformType type, PlatformVersion version) throws MetadataException
type - one of the constants defined in PlatformTypeversion - MetadataException - if the specified version cannot be found. 
 Use the version of getPlatform() that takes a matchType if you do not wish
 an exception to be thrown.public static Platform getPlatform(PlatformType type, java.lang.String version) throws MetadataException
version - the version as a canonical String.MetadataExceptionpublic static Platform getPlatform(PlatformType type, PlatformVersion version, PlatformRegistry.VersionMatch matchType)
type - the Platform typeversion - the version requested. Can be null if matchType is MATCH_NONEmatchType - the accuracy of the desired match.public static Platform[] getPlatforms()
public static Platform[] getPlatforms(PlatformType filterOnType)
filterOnType - The type of platform to filter on. This should be one of the
 constants in PlatformType.public static Platform[] getPlatforms(PlatformType filterOnType, boolean includeSubTypes)
filterOnType - includeSubTypes - if true, include PlatformTypes that are an extension of filterOnType, 
 for example, getPlatforms(PlatformType.J2EE, true) would return all J2EE platforms including
 OC4J, WebLogic, etc.