public abstract class AbstractVMInstallType extends java.lang.Object implements IVMInstallType
IVMInstall doCreateVMInstall(String id)
String getName()
IStatus validateInstallLocation(File installLocation)
Clients implementing VM install types should subclass this class.
Provisional API: This class/interface is part of an interim API that is still under development and expected to change significantly before reaching stability. It is being made available at this early stage to solicit feedback from pioneering adopters on the understanding that any code that uses this API will almost certainly be broken (repeatedly) as the API evolves.Modifier | Constructor and Description |
---|---|
protected |
AbstractVMInstallType()
Constructs a new VM install type.
|
Modifier and Type | Method and Description |
---|---|
IVMInstall |
createVMInstall(java.lang.String id)
Creates a new instance of this VM Install type.
|
void |
disposeVMInstall(java.lang.String id)
Remove the VM associated with the given id from the set of VMs managed by
this VM type.
|
protected abstract IVMInstall |
doCreateVMInstall(java.lang.String id)
Subclasses should return a new instance of the appropriate
IVMInstall subclass from this method. |
IVMInstall |
findVMInstall(java.lang.String id)
Finds the VM with the given id.
|
IVMInstall |
findVMInstallByName(java.lang.String name)
Finds the VM with the given name.
|
java.net.URL |
getDefaultJavadocLocation(java.io.File installLocation)
Returns a URL for the default jsdoc location of a VM installed at the
given home location, or
null if none. |
java.lang.String |
getId()
Returns the globally unique id of this VM type.
|
IVMInstall[] |
getVMInstalls()
Returns all VM instances managed by this VM type.
|
void |
setInitializationData(IConfigurationElement config,
java.lang.String propertyName,
java.lang.Object data)
Initializes the id parameter from the "id" attribute
in the configuration markup.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
detectInstallLocation, getDefaultLibraryLocations, getName, validateInstallLocation
protected AbstractVMInstallType()
public IVMInstall[] getVMInstalls()
IVMInstallType
getVMInstalls
in interface IVMInstallType
public void disposeVMInstall(java.lang.String id)
IVMInstallType
disposeVMInstall
in interface IVMInstallType
id
- the id of the VM to be disposed.public IVMInstall findVMInstall(java.lang.String id)
IVMInstallType
findVMInstall
in interface IVMInstallType
id
- the VM idnull
if not foundpublic IVMInstall createVMInstall(java.lang.String id) throws java.lang.IllegalArgumentException
IVMInstallType
createVMInstall
in interface IVMInstallType
id
- An id String that must be unique within this IVMInstallType.java.lang.IllegalArgumentException
- If the id exists already.protected abstract IVMInstall doCreateVMInstall(java.lang.String id)
IVMInstall
subclass from this method.id
- The vm's id. The IVMInstall
instance that is created must
return id
from its getId()
method.
Must not be null
.null
.public void setInitializationData(IConfigurationElement config, java.lang.String propertyName, java.lang.Object data)
config
- the configuration element used to trigger this execution.
It can be queried by the executable extension for specific
configuration propertiespropertyName
- the name of an attribute of the configuration element
used on the createExecutableExtension(String)
call. This
argument can be used in the cases where a single configuration element
is used to define multiple executable extensions.data
- adapter data in the form of a String
,
a Hashtable
, or null
.org.eclipse.core.runtime.IExecutableExtension#setInitializationData(org.eclipse.core.runtime.IConfigurationElement, java.lang.String, java.lang.Object)
public java.lang.String getId()
IVMInstallType
getId
in interface IVMInstallType
public IVMInstall findVMInstallByName(java.lang.String name)
IVMInstallType
findVMInstallByName
in interface IVMInstallType
name
- the VM namenull
if not foundpublic java.net.URL getDefaultJavadocLocation(java.io.File installLocation)
null
if none. The default
implementation returns null
, subclasses must override as
appropriate.
Note, this method would ideally be added to IVMInstallType
,
but it would have been a breaking API change between 2.0 and 2.1. Thus,
it has been added to the abstract base class that VM install types should
subclass.
installLocation
- home locationnull
Copyright (c) IBM Corp. and others 2000, 2010. All Rights Reserved.