private UsersWorkspaceImpl doClone(UsersWorkspaceImpl workspace) { UsersWorkspaceImpl copyWorkspace = new UsersWorkspaceImpl( workspace.getId(), workspace.getName(), workspace.getOwner(), new HashMap<>(workspace.getAttributes()), new ArrayList<>(workspace.getCommands()), new ArrayList<>(workspace.getProjects()), new ArrayList<>(workspace.getEnvironments()), workspace.getDefaultEnv(), workspace.getDescription()); copyWorkspace.setStatus(workspace.getStatus()); copyWorkspace.setTemporary(workspace.isTemporary()); return copyWorkspace; }