case INSTALL:
resourceTasks.add(new InstallTask(resource));
break;
case UPDATE:
Resource existed = registry.getResource(resource.getName());
resourceTasks.add(new UpdateTask(resource, existed));
break;
case REMOVE:
resourceTasks.add(new RemoveTask(resource));
}
}