Created
June 27, 2013 07:47
-
-
Save sormuras/5874676 to your computer and use it in GitHub Desktop.
Commander - Interfacing Prevayler
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class AppendChar implements Transaction<Appendable> { | |
private final char c; | |
public AppendChar(char c) { | |
this.c = c; | |
} | |
public void executeOn(Appendable prevalentSystem, Date executionTime) { | |
prevalentSystem.append(c); | |
} | |
} | |
prevayler.execute(new AppendChar('x')); | |
prevayler.execute(new AppendChar('y')); | |
prevayler.execute(new AppendChar('z')); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment