use of org.eclipse.che.api.project.shared.dto.event.ProjectTreeStateUpdateDto in project che by eclipse.
the class ProjectTreeTracker method getDeleteOperation.
private Consumer<String> getDeleteOperation(String endpointId) {
return it -> {
timers.add(it);
new Timer().schedule(new TimerTask() {
@Override
public void run() {
if (timers.contains(it)) {
timers.remove(it);
ProjectTreeStateUpdateDto params = newDto(ProjectTreeStateUpdateDto.class).withPath(it).withType(DELETED);
transmitter.transmitOneToNone(endpointId, OUTGOING_METHOD, params);
}
}
}, 1_000L);
};
}
Aggregations