package com.qianwen.smartman.modules.cps.convert; import java.util.ArrayList; import java.util.List; import com.qianwen.smartman.modules.cps.entity.WorkstationWorkbench; import com.qianwen.smartman.modules.cps.vo.WorkstationWorkbenchVO; /* loaded from: blade-api.jar:BOOT-INF/classes/org/springblade/modules/cps/convert/WorkstationWorkbenchConvertImpl.class */ public class WorkstationWorkbenchConvertImpl implements WorkstationWorkbenchConvert { @Override // org.springblade.modules.cps.convert.WorkstationWorkbenchConvert public WorkstationWorkbench convert(WorkstationWorkbenchVO workbenchVO) { if (workbenchVO == null) { return null; } WorkstationWorkbench workstationWorkbench = new WorkstationWorkbench(); workstationWorkbench.setId(workbenchVO.getId()); workstationWorkbench.setIsDeleted(workbenchVO.getIsDeleted()); workstationWorkbench.setWorkstationId(workbenchVO.getWorkstationId()); workstationWorkbench.setSort(workbenchVO.getSort()); workstationWorkbench.setName(workbenchVO.getName()); workstationWorkbench.setWorkbenchDefault(workbenchVO.getWorkbenchDefault()); return workstationWorkbench; } @Override // org.springblade.modules.cps.convert.WorkstationWorkbenchConvert public List convert(List workbenchVOList) { if (workbenchVOList == null) { return null; } List list = new ArrayList<>(workbenchVOList.size()); for (WorkstationWorkbenchVO workstationWorkbenchVO : workbenchVOList) { list.add(convert(workstationWorkbenchVO)); } return list; } @Override // org.springblade.modules.cps.convert.WorkstationWorkbenchConvert public WorkstationWorkbenchVO convertToVO(WorkstationWorkbench workbench) { if (workbench == null) { return null; } WorkstationWorkbenchVO workstationWorkbenchVO = new WorkstationWorkbenchVO(); workstationWorkbenchVO.setId(workbench.getId()); workstationWorkbenchVO.setWorkstationId(workbench.getWorkstationId()); workstationWorkbenchVO.setSort(workbench.getSort()); workstationWorkbenchVO.setName(workbench.getName()); workstationWorkbenchVO.setWorkbenchDefault(workbench.getWorkbenchDefault()); workstationWorkbenchVO.setIsDeleted(workbench.getIsDeleted()); return workstationWorkbenchVO; } @Override // org.springblade.modules.cps.convert.WorkstationWorkbenchConvert public List convertToVO(List workbenchList) { if (workbenchList == null) { return null; } List list = new ArrayList<>(workbenchList.size()); for (WorkstationWorkbench workstationWorkbench : workbenchList) { list.add(convertToVO(workstationWorkbench)); } return list; } }