@@ -0,0 +1,423 @@
+package editor.util;%0A%0Aimport java.util.function.Supplier;%0A%0Apublic class UndoableAction%3CU, R%3E%0A%7B%0A    private final Supplier%3CR%3E forward;%0A    private final Supplier%3CU%3E reverse;%0A%0A    public UndoableAction(final Supplier%3CR%3E f, final Supplier%3CU%3E r)%0A    %7B%0A        forward = f;%0A        reverse = r;%0A    %7D%0A%0A    public U undo()%0A    %7B%0A        return reverse.get();%0A    %7D%0A%0A    public R redo()%0A    %7B%0A        return forward.get();%0A    %7D%0A%7D

Add class for undoing generic actions