Sha256: 324effe5519ae5fe027151b9e1aeba1ccaa5cc1083c0cc96d2986f8ae1395ac7

Contents?: true

Size: 1.11 KB

Versions: 16

Compression:

Stored size: 1.11 KB

Contents

/**
 * @file
 * Declares the Windows virtualization fact resolver.
 */
#pragma once

#include "../resolvers/virtualization_resolver.hpp"
#include <leatherman/windows/wmi.hpp>
#include <string>
#include <memory>

namespace facter { namespace facts { namespace windows {

    /**
     * Responsible for resolving virtualization facts.
     */
    struct virtualization_resolver : resolvers::virtualization_resolver
    {
        /**
         * Constructs the virtualization_resolver.
         * @param wmi_conn The WMI connection to use when resolving facts.
         */
        virtualization_resolver(std::shared_ptr<leatherman::windows::wmi> wmi_conn = std::make_shared<leatherman::windows::wmi>());

     protected:
        /**
         * Gets the name of the hypervisor.
         * @param facts The fact collection that is resolving facts.
         * @return Returns the name of the hypervisor or empty string if no hypervisor.
         */
        virtual std::string get_hypervisor(collection& facts) override;

     private:
        std::shared_ptr<leatherman::windows::wmi> _wmi;
    };

}}}  // namespace facter::facts::windows

Version data entries

16 entries across 16 versions & 2 rubygems

Version Path
facter-3.12.2.cfacter.20181217 ext/facter/facter/lib/inc/internal/facts/windows/virtualization_resolver.hpp
facter-3.12.1.cfacter.20181031 ext/facter/facter/lib/inc/internal/facts/windows/virtualization_resolver.hpp
facter-3.11.6.cfacter.20181031 ext/facter/facter/lib/inc/internal/facts/windows/virtualization_resolver.hpp
facter-3.12.1.cfacter.20181023 ext/facter/facter/lib/inc/internal/facts/windows/virtualization_resolver.hpp
facter-3.11.5.cfacter.20181022 ext/facter/facter/lib/inc/internal/facts/windows/virtualization_resolver.hpp
facter-3.12.0.cfacter.20181004 ext/facter/facter/lib/inc/internal/facts/windows/virtualization_resolver.hpp
facter-3.12.0.cfacter.20181001 ext/facter/facter/lib/inc/internal/facts/windows/virtualization_resolver.hpp
facter-3.12.0.cfacter.20180918 ext/facter/facter/lib/inc/internal/facts/windows/virtualization_resolver.hpp
facter-3.11.4.cfacter.20180821 ext/facter/facter/lib/inc/internal/facts/windows/virtualization_resolver.hpp
facter-3.11.3.cfacter.20180716 ext/facter/facter/lib/inc/internal/facts/windows/virtualization_resolver.hpp
facter-3.11.2.cfacter.20180612 ext/facter/facter/lib/inc/internal/facts/windows/virtualization_resolver.hpp
facter-3.9.6.cfacter.20180612 ext/facter/facter/lib/inc/internal/facts/windows/virtualization_resolver.hpp
facter-3.11.2.cfacter.20180606 ext/facter/facter/lib/inc/internal/facts/windows/virtualization_resolver.hpp
facter-3.9.6.cfacter.20180606 ext/facter/facter/lib/inc/internal/facts/windows/virtualization_resolver.hpp
facter-3.11.0.cfacter.20180319 ext/facter/facter/lib/inc/internal/facts/windows/virtualization_resolver.hpp
cfacter-3.11.0.rc.20180314 ext/facter/facter/lib/inc/internal/facts/windows/virtualization_resolver.hpp