cddvd.go
func (v *VM) CDDVD(ID string) (*CDDVDDrive, error) {
	err := v.vmxfile.Read()
	if err != nil {
		return nil, err
	}

	model := v.vmxfile.model
	bus := BusTypeFromID(ID)

	var filename string
	found := model.FindDevice(func(d vmx.Device) bool {
		if ID == d.VMXID {
			filename = d.Filename
		}
		return ID == d.VMXID
	}, bus)

	if !found {
		return nil, nil
	}

	return &CDDVDDrive{Bus: bus, Filename: filename}, nil
}
func (v *VM) CDDVD(ID string) (*CDDVDDrive, error) {
	err := v.vmxfile.Read()
	if err != nil {
		return nil, err
	}

	model := v.vmxfile.model
	bus := BusTypeFromID(ID)

	var filename string
	found := model.FindDevice(func(d vmx.Device) bool {
		if ID == d.VMXID {
			filename = d.Filename
		}
		return ID == d.VMXID
	}, bus)

	if !found {
		return nil, nil
	}

	return &CDDVDDrive{Bus: bus, Filename: filename}, nil
}
// CDDVD returns the CD/DVD drive identified by ID.
// This function depends entirely on how GoVMX identifies slice's elements