func (hType *HypervisorType) Set(value string) error {
	switch value {
	case "qemu":
		*hType = QemuHypervisor
		return nil
	case "mock":
		*hType = MockHypervisor
		return nil
	default:
		return fmt.Errorf("Unknown hypervisor type %s", value)
	}
}
Set sets an hypervisor type based on the input string.
package virtcontainers
import (
	"bufio"
	"fmt"
	"os"
	"runtime"
	"strconv"
	"strings"
)
type HypervisorType string
const (
	QemuHypervisor HypervisorType = "qemu"
	MockHypervisor HypervisorType = "mock"
)
const (
	procMemInfo = "/proc/meminfo"
	procCPUInfo = "/proc/cpuinfo"
)
const (
	defaultVCPUs = 1
	defaultMemSzMiB = 2048
	defaultBridges = 1
	defaultBlockDriver = VirtioSCSI
)
var defaultMaxQemuVCPUs = maxQemuVCPUs()
type deviceType int
const (
	imgDev deviceType = iota
	fsDev
	netDev
	serialDev
	blockDev
	consoleDev
	serialPortDev
	vfioDev
	vhostuserDev
	cpuDev
)