You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
tasks/app/src/main/java/org/tasks/Event.java

20 lines
271 B
Java

package org.tasks;
public class Event<T> {
private final T value;
private boolean handled;
public Event(T value) {
this.value = value;
}
public T getIfUnhandled() {
if (handled) {
return null;
}
handled = true;
return value;
}
}