ApplianceImpl.h revision d91dc86210d602f51a4701762488a5e696c80a45
8184f68cdef3c26869cdebc6a18829c854d0d17dvboxsync * VirtualBox COM class implementation
8184f68cdef3c26869cdebc6a18829c854d0d17dvboxsync * Copyright (C) 2006-2009 Sun Microsystems, Inc.
8184f68cdef3c26869cdebc6a18829c854d0d17dvboxsync * This file is part of VirtualBox Open Source Edition (OSE), as
8184f68cdef3c26869cdebc6a18829c854d0d17dvboxsync * available from http://www.virtualbox.org. This file is free software;
8184f68cdef3c26869cdebc6a18829c854d0d17dvboxsync * you can redistribute it and/or modify it under the terms of the GNU
8184f68cdef3c26869cdebc6a18829c854d0d17dvboxsync * General Public License (GPL) as published by the Free Software
8184f68cdef3c26869cdebc6a18829c854d0d17dvboxsync * Foundation, in version 2 as it comes in the "COPYING" file of the
8184f68cdef3c26869cdebc6a18829c854d0d17dvboxsync * VirtualBox OSE distribution. VirtualBox OSE is distributed in the
8184f68cdef3c26869cdebc6a18829c854d0d17dvboxsync * hope that it will be useful, but WITHOUT ANY WARRANTY of any kind.
8184f68cdef3c26869cdebc6a18829c854d0d17dvboxsync * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa
8184f68cdef3c26869cdebc6a18829c854d0d17dvboxsync * Clara, CA 95054 USA or visit http://www.sun.com if you need
8184f68cdef3c26869cdebc6a18829c854d0d17dvboxsync * additional information or have any questions.
d91dc86210d602f51a4701762488a5e696c80a45vboxsync// #include <string>
8184f68cdef3c26869cdebc6a18829c854d0d17dvboxsync public VirtualBoxSupportErrorInfoImpl <Appliance, IAppliance>,
8184f68cdef3c26869cdebc6a18829c854d0d17dvboxsync // public initializer/uninitializer for internal purposes only
ee5869bb73f07de9c139dc6a608836a7b5767933vboxsync HRESULT init(VirtualBox *aVirtualBox, IN_BSTR &path);
8184f68cdef3c26869cdebc6a18829c854d0d17dvboxsync // for VirtualBoxSupportErrorInfoImpl
8184f68cdef3c26869cdebc6a18829c854d0d17dvboxsync static const wchar_t *getComponentName() { return L"Appliance"; }
8184f68cdef3c26869cdebc6a18829c854d0d17dvboxsync /* IAppliance properties */
f6dde23cd488aee26203b38ec67220270f5c4273vboxsync STDMETHOD(COMGETTER(Disks))(ComSafeArrayOut(BSTR, aDisks));
f6dde23cd488aee26203b38ec67220270f5c4273vboxsync STDMETHOD(COMGETTER(VirtualSystemDescriptions))(ComSafeArrayOut(IVirtualSystemDescription*, aVirtualSystemDescriptions));
8184f68cdef3c26869cdebc6a18829c854d0d17dvboxsync /* IAppliance methods */
ee5869bb73f07de9c139dc6a608836a7b5767933vboxsync /* void interpret (); */
8184f68cdef3c26869cdebc6a18829c854d0d17dvboxsync /* public methods only for internal purposes */
8184f68cdef3c26869cdebc6a18829c854d0d17dvboxsync /* private instance data */
482a222498aae619afda0255a7edf4ebda97268cvboxsync /** weak VirtualBox parent */
482a222498aae619afda0255a7edf4ebda97268cvboxsync const ComObjPtr <VirtualBox, ComWeakRef> mVirtualBox;
8184f68cdef3c26869cdebc6a18829c854d0d17dvboxsync struct Data; // obscure, defined in AppliannceImpl.cpp
8184f68cdef3c26869cdebc6a18829c854d0d17dvboxsync HRESULT LoopThruSections(const char *pcszPath, const xml::Node *pReferencesElem, const xml::Node *pCurElem);
8184f68cdef3c26869cdebc6a18829c854d0d17dvboxsync HRESULT HandleDiskSection(const char *pcszPath, const xml::Node *pReferencesElem, const xml::Node *pSectionElem);
8184f68cdef3c26869cdebc6a18829c854d0d17dvboxsync HRESULT HandleNetworkSection(const char *pcszPath, const xml::Node *pSectionElem);
8184f68cdef3c26869cdebc6a18829c854d0d17dvboxsync HRESULT HandleVirtualSystemContent(const char *pcszPath, const xml::Node *pContentElem);
d91dc86210d602f51a4701762488a5e696c80a45vboxsync HRESULT searchUniqueDiskImageFilePath(Utf8Str& aName) const;
8184f68cdef3c26869cdebc6a18829c854d0d17dvboxsync VirtualSystemDescriptionType_T type; /* Of which type is this value */
d91dc86210d602f51a4701762488a5e696c80a45vboxsync Utf8Str strRef; /* Reference value to the internal implementation */
d91dc86210d602f51a4701762488a5e696c80a45vboxsync Utf8Str strOriginalValue; /* The original OVF value */
d91dc86210d602f51a4701762488a5e696c80a45vboxsync Utf8Str strAutoValue; /* The value which VBox suggest */
d91dc86210d602f51a4701762488a5e696c80a45vboxsync Utf8Str strFinalValue; /* The value the user select */
d91dc86210d602f51a4701762488a5e696c80a45vboxsync Utf8Str strConfiguration; /* Additional configuration data for this type */
8184f68cdef3c26869cdebc6a18829c854d0d17dvboxsync public VirtualBoxSupportErrorInfoImpl <VirtualSystemDescription, IVirtualSystemDescription>,
8184f68cdef3c26869cdebc6a18829c854d0d17dvboxsync public VirtualBoxSupportTranslation <VirtualSystemDescription>,
8184f68cdef3c26869cdebc6a18829c854d0d17dvboxsync VIRTUALBOXBASE_ADD_ERRORINFO_SUPPORT (VirtualSystemDescription)
8184f68cdef3c26869cdebc6a18829c854d0d17dvboxsync // public initializer/uninitializer for internal purposes only
8184f68cdef3c26869cdebc6a18829c854d0d17dvboxsync // for VirtualBoxSupportErrorInfoImpl
8184f68cdef3c26869cdebc6a18829c854d0d17dvboxsync static const wchar_t *getComponentName() { return L"VirtualSystemDescription"; }
8184f68cdef3c26869cdebc6a18829c854d0d17dvboxsync /* IVirtualSystemDescription properties */
8184f68cdef3c26869cdebc6a18829c854d0d17dvboxsync /* IVirtualSystemDescription methods */
f6dde23cd488aee26203b38ec67220270f5c4273vboxsync STDMETHOD(GetDescription)(ComSafeArrayOut(VirtualSystemDescriptionType_T, aTypes),
f6dde23cd488aee26203b38ec67220270f5c4273vboxsync STDMETHOD(SetFinalValues)(ComSafeArrayIn(IN_BSTR, aFinalValues));
8184f68cdef3c26869cdebc6a18829c854d0d17dvboxsync /* public methods only for internal purposes */
8184f68cdef3c26869cdebc6a18829c854d0d17dvboxsync /* private instance data */
f9cac318205d74ee5b35dabcf2bd39118f6293d7vboxsync void addEntry(VirtualSystemDescriptionType_T aType,
f9cac318205d74ee5b35dabcf2bd39118f6293d7vboxsync std::list<VirtualSystemDescriptionEntry*> findByType(VirtualSystemDescriptionType_T aType);
8184f68cdef3c26869cdebc6a18829c854d0d17dvboxsync#endif // ____H_APPLIANCEIMPL