public class IUnattended extends IUnknown
IVirtualBox.createUnattendedInstaller()
to create the objectgetIsoPath()
and calldetectIsoOS()
getDetectedOSTypeId()
and the other detectedOS* attributes.getMachine()
to the new IMachine instance.prepare()
for the object to check the
attribute values and create an internal installer instance.constructMedia()
to create additional
media files (ISO/floppy) needed.reconfigureVM()
to reconfigure the VM
with the installation ISO, additional media files and whatnotdone()
to destroy the internal
installer and allow restarting from the second step.Constructor and Description |
---|
IUnattended(java.lang.String wrapped,
org.virtualbox_6_1.ObjectRefManager objMgr,
org.virtualbox_6_1.jaxws.VboxPortType port) |
Modifier and Type | Method and Description |
---|---|
void |
constructMedia()
Constructors the necessary ISO/VISO/Floppy images, with unattended scripts
and all necessary bits on them.
|
void |
detectIsoOS()
Detects the OS on the ISO given by
getIsoPath() and setsgetDetectedOSTypeId() ,getDetectedOSVersion() getDetectedOSFlavor() ,getDetectedOSLanguages() ,
andgetDetectedOSHints() . |
void |
done()
Done - time to start the VM.
|
java.lang.String |
getAdditionsIsoPath()
Guest Additions ISO image path.
|
java.lang.String |
getAuxiliaryBasePath()
The path + basename for auxiliary files generated by the unattended
installation.
|
java.lang.String |
getCountry()
The 2 upper case letter country identifier, ISO 3166-1 alpha-2.
|
java.lang.String |
getDetectedOSFlavor()
The detected OS flavor (e.g.
|
java.lang.String |
getDetectedOSHints()
Space separated list of other stuff detected about the OS and the
installation ISO.
|
java.lang.String |
getDetectedOSLanguages()
The space separated list of (Windows) installation UI languages we detected (lang.ini).
|
java.lang.String |
getDetectedOSTypeId()
The detected OS type ID (
IGuestOSType.getId() ). |
java.lang.String |
getDetectedOSVersion()
The detected OS version string.
|
java.lang.String |
getExtraInstallKernelParameters()
Extra kernel arguments passed to the install kernel of some guests.
|
java.lang.String |
getFullUserName()
The full name of the user.
|
java.lang.String |
getHostname()
The fully qualified guest hostname.
|
java.lang.Long |
getImageIndex()
The image index on installation CD/DVD used to install.
|
java.lang.Boolean |
getInstallGuestAdditions()
Indicates whether the guest additions should be installed or not.
|
java.lang.Boolean |
getInstallTestExecService()
Indicates whether the test execution service (TXS) from the VBox
ValidationKit should be installed.
|
java.lang.String |
getIsoPath()
Guest operating system ISO image
|
java.lang.String |
getLanguage()
This is more or less a Windows specific setting for choosing the UI language
setting of the installer.
|
java.lang.String |
getLocale()
The 5 letter locale identifier, no codesets or such.
|
IMachine |
getMachine()
The associated machine object.
|
java.lang.String |
getPackageSelectionAdjustments()
Guest OS specific package selection adjustments.
|
java.lang.String |
getPassword()
Assign a password to the user.
|
java.lang.String |
getPostInstallCommand()
Custom post installation command.
|
java.lang.String |
getPostInstallScriptTemplatePath()
The post installation (shell/batch) script template file.
|
java.lang.String |
getProductKey()
Any key which is used as authorization of access to install genuine OS
|
java.lang.String |
getProxy()
Proxy incantation to pass on to the guest OS installer.
|
java.lang.String |
getScriptTemplatePath()
The unattended installation script template file.
|
java.lang.String |
getTimeZone()
The guest time zone specifier.
|
java.lang.String |
getUser()
Assign an user login name.
|
java.lang.String |
getValidationKitIsoPath()
VirtualBox ValidationKit ISO image path.
|
void |
prepare()
Prepare for running the unattended process of installation.
|
static IUnattended |
queryInterface(IUnknown obj) |
void |
reconfigureVM()
Reconfigures the machine to start the installation.
|
void |
setAdditionsIsoPath(java.lang.String value)
Guest Additions ISO image path.
|
void |
setAuxiliaryBasePath(java.lang.String value)
The path + basename for auxiliary files generated by the unattended
installation.
|
void |
setCountry(java.lang.String value)
The 2 upper case letter country identifier, ISO 3166-1 alpha-2.
|
void |
setExtraInstallKernelParameters(java.lang.String value)
Extra kernel arguments passed to the install kernel of some guests.
|
void |
setFullUserName(java.lang.String value)
The full name of the user.
|
void |
setHostname(java.lang.String value)
The fully qualified guest hostname.
|
void |
setImageIndex(java.lang.Long value)
The image index on installation CD/DVD used to install.
|
void |
setInstallGuestAdditions(java.lang.Boolean value)
Indicates whether the guest additions should be installed or not.
|
void |
setInstallTestExecService(java.lang.Boolean value)
Indicates whether the test execution service (TXS) from the VBox
ValidationKit should be installed.
|
void |
setIsoPath(java.lang.String value)
Guest operating system ISO image
|
void |
setLanguage(java.lang.String value)
This is more or less a Windows specific setting for choosing the UI language
setting of the installer.
|
void |
setLocale(java.lang.String value)
The 5 letter locale identifier, no codesets or such.
|
void |
setMachine(IMachine value)
The associated machine object.
|
void |
setPackageSelectionAdjustments(java.lang.String value)
Guest OS specific package selection adjustments.
|
void |
setPassword(java.lang.String value)
Assign a password to the user.
|
void |
setPostInstallCommand(java.lang.String value)
Custom post installation command.
|
void |
setPostInstallScriptTemplatePath(java.lang.String value)
The post installation (shell/batch) script template file.
|
void |
setProductKey(java.lang.String value)
Any key which is used as authorization of access to install genuine OS
|
void |
setProxy(java.lang.String value)
Proxy incantation to pass on to the guest OS installer.
|
void |
setScriptTemplatePath(java.lang.String value)
The unattended installation script template file.
|
void |
setTimeZone(java.lang.String value)
The guest time zone specifier.
|
void |
setUser(java.lang.String value)
Assign an user login name.
|
void |
setValidationKitIsoPath(java.lang.String value)
VirtualBox ValidationKit ISO image path.
|
getObjMgr, getRemoteWSPort, getWrapped, releaseRemote
public IUnattended(java.lang.String wrapped, org.virtualbox_6_1.ObjectRefManager objMgr, org.virtualbox_6_1.jaxws.VboxPortType port)
public java.lang.String getIsoPath()
public void setIsoPath(java.lang.String value)
value
- Stringpublic IMachine getMachine()
prepare()
is called.
The VM must be registered.public void setMachine(IMachine value)
prepare()
is called.
The VM must be registered.value
- org.virtualbox_6_1.IMachinepublic java.lang.String getUser()
public void setUser(java.lang.String value)
value
- Stringpublic java.lang.String getPassword()
public void setPassword(java.lang.String value)
value
- Stringpublic java.lang.String getFullUserName()
getUser()
. Please note that not all guests picks
up this attribute.public void setFullUserName(java.lang.String value)
getUser()
. Please note that not all guests picks
up this attribute.value
- Stringpublic java.lang.String getProductKey()
public void setProductKey(java.lang.String value)
value
- Stringpublic java.lang.String getAdditionsIsoPath()
ISystemProperties.getDefaultAdditionsISO()
when the Unattended
object is instantiated.
This property is ignored whengetInstallGuestAdditions()
is false.public void setAdditionsIsoPath(java.lang.String value)
ISystemProperties.getDefaultAdditionsISO()
when the Unattended
object is instantiated.
This property is ignored whengetInstallGuestAdditions()
is false.value
- Stringpublic java.lang.Boolean getInstallGuestAdditions()
getAdditionsIsoPath()
.public void setInstallGuestAdditions(java.lang.Boolean value)
getAdditionsIsoPath()
.value
- Booleanpublic java.lang.String getValidationKitIsoPath()
getInstallTestExecService()
is set to true.public void setValidationKitIsoPath(java.lang.String value)
getInstallTestExecService()
is set to true.value
- Stringpublic java.lang.Boolean getInstallTestExecService()
getValidationKitIsoPath()
.public void setInstallTestExecService(java.lang.Boolean value)
getValidationKitIsoPath()
.value
- Booleanpublic java.lang.String getTimeZone()
public void setTimeZone(java.lang.String value)
value
- Stringpublic java.lang.String getLocale()
public void setLocale(java.lang.String value)
value
- Stringpublic java.lang.String getLanguage()
getDetectedOSLanguages()
.
The typical format is {language-code}-{COUNTRY} but windows may also use
{16-bit code}:{32-bit code} or insert another component between the language
and country codes. We consider the format guest OS specific.
Note that it is crucial that this is correctly specified for Windows
installations. If an unsupported value is given the installer will ask
for an installation language and wait for user input. Best to leave it
to the default value.
The default is the first one fromgetDetectedOSLanguages()
.public void setLanguage(java.lang.String value)
getDetectedOSLanguages()
.
The typical format is {language-code}-{COUNTRY} but windows may also use
{16-bit code}:{32-bit code} or insert another component between the language
and country codes. We consider the format guest OS specific.
Note that it is crucial that this is correctly specified for Windows
installations. If an unsupported value is given the installer will ask
for an installation language and wait for user input. Best to leave it
to the default value.
The default is the first one fromgetDetectedOSLanguages()
.value
- Stringpublic java.lang.String getCountry()
getLocale()
.public void setCountry(java.lang.String value)
getLocale()
.value
- Stringpublic java.lang.String getProxy()
public void setProxy(java.lang.String value)
value
- Stringpublic java.lang.String getPackageSelectionAdjustments()
public void setPackageSelectionAdjustments(java.lang.String value)
value
- Stringpublic java.lang.String getHostname()
public void setHostname(java.lang.String value)
value
- Stringpublic java.lang.String getAuxiliaryBasePath()
public void setAuxiliaryBasePath(java.lang.String value)
value
- Stringpublic java.lang.Long getImageIndex()
public void setImageIndex(java.lang.Long value)
value
- Longpublic java.lang.String getScriptTemplatePath()
prepare()
is invoked.
Most users will want the defaults.
Afterprepare()
is called, it can be read to see
which file is being used.public void setScriptTemplatePath(java.lang.String value)
prepare()
is invoked.
Most users will want the defaults.
Afterprepare()
is called, it can be read to see
which file is being used.value
- Stringpublic java.lang.String getPostInstallScriptTemplatePath()
prepare()
is invoked.
Most users will want the defaults.
Afterprepare()
is called, it can be read to see
which file is being used.public void setPostInstallScriptTemplatePath(java.lang.String value)
prepare()
is invoked.
Most users will want the defaults.
Afterprepare()
is called, it can be read to see
which file is being used.value
- Stringpublic java.lang.String getPostInstallCommand()
getPostInstallScriptTemplatePath()
).
Most users will not need to set this attribute.public void setPostInstallCommand(java.lang.String value)
getPostInstallScriptTemplatePath()
).
Most users will not need to set this attribute.value
- Stringpublic java.lang.String getExtraInstallKernelParameters()
prepare()
is called, it can be read to see
which parameters are being used.public void setExtraInstallKernelParameters(java.lang.String value)
prepare()
is called, it can be read to see
which parameters are being used.value
- Stringpublic java.lang.String getDetectedOSTypeId()
IGuestOSType.getId()
).
Set bydetectIsoOS()
orprepare()
.
Not yet implemented.public java.lang.String getDetectedOSVersion()
detectIsoOS()
orprepare()
.
Not yet implemented.public java.lang.String getDetectedOSFlavor()
detectIsoOS()
orprepare()
.
Not yet implemented.public java.lang.String getDetectedOSLanguages()
getLanguage()
.
Set bydetectIsoOS()
orprepare()
.
Partially implemented.public java.lang.String getDetectedOSHints()
detectIsoOS()
orprepare()
.
Not yet implemented.public static IUnattended queryInterface(IUnknown obj)
public void detectIsoOS()
getIsoPath()
and setsgetDetectedOSTypeId()
,getDetectedOSVersion()
getDetectedOSFlavor()
,getDetectedOSLanguages()
,
andgetDetectedOSHints()
.
Not really yet implemented.public void prepare()
IMachine.getOSTypeId()
). It will also
performdetectIsoOS()
if not yet called on the
currentgetIsoPath()
value.public void constructMedia()
public void reconfigureVM()
constructMedia()
, attaching new DVD and floppy
drives as necessary, and possibly modifying the boot order.public void done()