Eclipse JDT
2.0

org.eclipse.jdt.launching
Class AbstractVMInstall

java.lang.Object
  |
  +--org.eclipse.jdt.launching.AbstractVMInstall
All Implemented Interfaces:
IVMInstall

public abstract class AbstractVMInstall
extends Object
implements IVMInstall

Abstract implementation of a VM install. *

* Clients implenmenting VM installs should subclass this class. *


Constructor Summary
AbstractVMInstall(IVMInstallType type, String id)
          Constructs a new VM install.
 
Method Summary
 String getId()
          Returns the id for this VM.
 File getInstallLocation()
          Returns the root directory of the install location of this VM.
 URL getJavadocLocation()
          Returns the Javadoc location associated with this VM install.
 LibraryLocation[] getLibraryLocations()
          Returns the library locations of this IVMInstall.
 String getName()
          Returns the display name of this VM.
 IVMInstallType getVMInstallType()
          Returns the VM type of this VM.
 IVMRunner getVMRunner(String mode)
          Returns a VM runner that runs this installed VM in the given mode.
 void setInstallLocation(File installLocation)
          Sets the root directory of the install location of this VM.
 void setJavadocLocation(URL url)
          Sets the Javadoc location associated with this VM install.
 void setLibraryLocations(LibraryLocation[] locations)
          Sets the library locations of this IVMInstall.
 void setName(String name)
          Sets the display name of this VM.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

AbstractVMInstall

public AbstractVMInstall(IVMInstallType type,
                         String id)
Constructs a new VM install. *

Parameters:
type - The type of this VM install. Must not be null
id - The unique identifier of this VM instance Must not be null.
Throws:
IllegalArgumentException - if any of the required parameters are null.
Method Detail

getId

public String getId()
Description copied from interface: IVMInstall
Returns the id for this VM. VM ids are unique within the VMs of a given VM type. The VM id is not intended to be presented to users.

Specified by:
getId in interface IVMInstall
Returns:
the VM identifier. Must not return null.

getName

public String getName()
Description copied from interface: IVMInstall
Returns the display name of this VM. The VM name is intended to be presented to users.

Specified by:
getName in interface IVMInstall
Returns:
the display name of this VM. May return null.

setName

public void setName(String name)
Description copied from interface: IVMInstall
Sets the display name of this VM. The VM name is intended to be presented to users.

Specified by:
setName in interface IVMInstall
Parameters:
name - the display name of this VM

getInstallLocation

public File getInstallLocation()
Description copied from interface: IVMInstall
Returns the root directory of the install location of this VM.

Specified by:
getInstallLocation in interface IVMInstall
Returns:
the root directory of this VM installation. May return null.

setInstallLocation

public void setInstallLocation(File installLocation)
Description copied from interface: IVMInstall
Sets the root directory of the install location of this VM.

Specified by:
setInstallLocation in interface IVMInstall
Parameters:
installLocation - the root directory of this VM installation

getVMInstallType

public IVMInstallType getVMInstallType()
Description copied from interface: IVMInstall
Returns the VM type of this VM.

Specified by:
getVMInstallType in interface IVMInstall
Returns:
the VM type that created this IVMInstall instance

getVMRunner

public IVMRunner getVMRunner(String mode)
Description copied from interface: IVMInstall
Returns a VM runner that runs this installed VM in the given mode.

Specified by:
getVMRunner in interface IVMInstall
Parameters:
mode - the mode the VM should be launched in; one of the constants declared in org.eclipse.debug.core.ILaunchManager
Returns:
a VMRunner for a given mode May return null if the given mode is not supported by this VM.
See Also:
ILaunchManager

getLibraryLocations

public LibraryLocation[] getLibraryLocations()
Description copied from interface: IVMInstall
Returns the library locations of this IVMInstall. Generally, clients should use JavaRuntime.getLibraryLocations(IVMInstall) to determine the libraries associated with this VM install.

Specified by:
getLibraryLocations in interface IVMInstall
Returns:
The library locations of this IVMInstall. Returns null to indicate that this VM install uses the default library locations associated with this VM's install type.
See Also:
IVMInstall.getLibraryLocations()

setLibraryLocations

public void setLibraryLocations(LibraryLocation[] locations)
Description copied from interface: IVMInstall
Sets the library locations of this IVMInstall.

Specified by:
setLibraryLocations in interface IVMInstall
Parameters:
locations - The LibraryLocations to associate with this IVMInstall. May be null to indicate that this VM install uses the default library locations associated with this VM's install type.
See Also:
IVMInstall.setLibraryLocations(LibraryLocation[])

getJavadocLocation

public URL getJavadocLocation()
Description copied from interface: IVMInstall
Returns the Javadoc location associated with this VM install.

Specified by:
getJavadocLocation in interface IVMInstall
Returns:
a url pointing to the Javadoc location associated with this VM install, or null if none
See Also:
IVMInstall.getJavadocLocation()

setJavadocLocation

public void setJavadocLocation(URL url)
Description copied from interface: IVMInstall
Sets the Javadoc location associated with this VM install.

Specified by:
setJavadocLocation in interface IVMInstall
Parameters:
url - a url pointing to the Javadoc location associated with this VM install
See Also:
IVMInstall.setJavadocLocation(URL)

Eclipse JDT
2.0

Copyright (c) IBM Corp. and others 2000, 2002. All Rights Reserved.