@Mapping(from = BootSequence.class, to = Boot.class) public static Boot map(BootSequence bootSequence, Boot template) { Boot boot = template != null ? template : new Boot(); Boot.DevicesList list = new Boot.DevicesList(); boot.setDevices(list); List<BootDevice> devices = list.getDevices();
if (from.isSetBoot()) { Boot toBoot = new Boot(); Boot.DevicesList toDevicesList = new Boot.DevicesList(); List<BootDevice> toDevices = toDevicesList.getDevices(); from.getBoot().stream()
@Test public void testStartWithBootDev() { setUpWindowsGetEntityExpectations(1, false); setUriInfo(setUpActionExpectations(ActionType.RunVmOnce, RunVmOnceParams.class, new String[] { "VmId", "BootSequence" }, new Object[] { GUIDS[0], BootSequence.N })); Action action = new Action(); action.setVm(new Vm()); action.getVm().setOs(new OperatingSystem()); action.getVm().getOs().setBoot(new Boot()); action.getVm().getOs().getBoot().setDevices(new Boot.DevicesList()); action.getVm().getOs().getBoot().getDevices().getDevices().add(BootDevice.NETWORK); verifyActionResponse(resource.start(action)); }
/** * Create an instance of {@link Boot.DevicesList } * */ public Boot.DevicesList createBootDevicesList() { return new Boot.DevicesList(); }