1 | /* $Id: CloudProviderManagerImpl.h 75663 2018-11-22 14:00:59Z vboxsync $ */
|
---|
2 | /** @file
|
---|
3 | * VirtualBox COM class implementation
|
---|
4 | */
|
---|
5 |
|
---|
6 | /*
|
---|
7 | * Copyright (C) 2018 Oracle Corporation
|
---|
8 | *
|
---|
9 | * This file is part of VirtualBox Open Source Edition (OSE), as
|
---|
10 | * available from http://www.virtualbox.org. This file is free software;
|
---|
11 | * you can redistribute it and/or modify it under the terms of the GNU
|
---|
12 | * General Public License (GPL) as published by the Free Software
|
---|
13 | * Foundation, in version 2 as it comes in the "COPYING" file of the
|
---|
14 | * VirtualBox OSE distribution. VirtualBox OSE is distributed in the
|
---|
15 | * hope that it will be useful, but WITHOUT ANY WARRANTY of any kind.
|
---|
16 | */
|
---|
17 |
|
---|
18 |
|
---|
19 | #ifndef ____H_CLOUDPROVIDERMANAGERIMPL
|
---|
20 | #define ____H_CLOUDPROVIDERMANAGERIMPL
|
---|
21 |
|
---|
22 | #include "CloudProviderManagerWrap.h"
|
---|
23 |
|
---|
24 |
|
---|
25 | class ATL_NO_VTABLE CloudProviderManager
|
---|
26 | : public CloudProviderManagerWrap
|
---|
27 | {
|
---|
28 | public:
|
---|
29 | DECLARE_EMPTY_CTOR_DTOR(CloudProviderManager)
|
---|
30 |
|
---|
31 | HRESULT FinalConstruct();
|
---|
32 | void FinalRelease();
|
---|
33 |
|
---|
34 | HRESULT init();
|
---|
35 | void uninit();
|
---|
36 |
|
---|
37 | #ifdef VBOX_WITH_EXTPACK
|
---|
38 | // Safe helpers, take care of caller and lock themselves.
|
---|
39 | bool i_canRemoveExtPack(IExtPack *aExtPack);
|
---|
40 | void i_addExtPack(IExtPack *aExtPack);
|
---|
41 | #endif
|
---|
42 |
|
---|
43 | private:
|
---|
44 | // wrapped ICloudProviderManager attributes and methods
|
---|
45 | HRESULT getProviders(std::vector<ComPtr<ICloudProvider> > &aProviders);
|
---|
46 | HRESULT getProviderById(const com::Guid &aProviderId,
|
---|
47 | ComPtr<ICloudProvider> &aProvider);
|
---|
48 | HRESULT getProviderByShortName(const com::Utf8Str &aProviderName,
|
---|
49 | ComPtr<ICloudProvider> &aProvider);
|
---|
50 | HRESULT getProviderByName(const com::Utf8Str &aProviderName,
|
---|
51 | ComPtr<ICloudProvider> &aProvider);
|
---|
52 |
|
---|
53 | private:
|
---|
54 | #ifdef VBOX_WITH_EXTPACK
|
---|
55 | typedef std::map<com::Utf8Str, ComPtr<ICloudProviderManager> > ExtPackNameCloudProviderManagerMap;
|
---|
56 | ExtPackNameCloudProviderManagerMap m_mapCloudProviderManagers;
|
---|
57 | typedef std::vector<com::Utf8Str> ExtPackNameVec;
|
---|
58 | ExtPackNameVec m_astrExtPackNames;
|
---|
59 | #endif
|
---|
60 |
|
---|
61 | typedef std::vector<ComPtr<ICloudProvider> > CloudProviderVec;
|
---|
62 | CloudProviderVec m_apCloudProviders;
|
---|
63 | };
|
---|
64 |
|
---|
65 | #endif // !____H_CLOUDPROVIDERMANAGERIMPL
|
---|
66 |
|
---|
67 | /* vi: set tabstop=4 shiftwidth=4 expandtab: */
|
---|