/** * */ package journal.reader; import java.util.EnumSet; import journal.action.Action; public enum ActionType { PUT_VALUE("pv") { void invoke(Action action, JournalEntry entry) throws Exception { action.putValue((DataJournalEntry) entry); } }, REPLACE_VALUE("rv") { void invoke(Action action, JournalEntry entry) throws Exception { action.replaceValue((DataJournalEntry) entry); } }, DELETE_VALUE("dv") { void invoke(Action action, JournalEntry entry) throws Exception { action.deleteValue((DataJournalEntry) entry); } }, VERIFY_VALUE("vv") { void invoke(Action action, JournalEntry entry) throws Exception { action.verifyValue((DataJournalEntry) entry); } }, FLUSH_MARKER("mx") { void invoke(Action action, JournalEntry entry) throws Exception { action.flushMarker((TransactionJournalEntry) entry); } }, COMMIT_MARKER("ex") { void invoke(Action action, JournalEntry entry) throws Exception { action.commitMarker((TransactionJournalEntry) entry); } }, NOTE_MARKER("nx") { void invoke(Action action, JournalEntry entry) throws Exception { action.journalMarker((NoteJournalEntry) entry); } }, DELETE_MARKER("dl") { void invoke(Action action, JournalEntry entry) throws Exception { action.deleteMarker((DeleteJournalEntry) entry); } }; final String symbol; static public final EnumSet<ActionType> TransactionAction = EnumSet.of(FLUSH_MARKER, COMMIT_MARKER); public String symbol() { return symbol; } ActionType(String symbol) { this.symbol = symbol; } abstract void invoke(Action action, JournalEntry entry) throws Exception; }
# | Change | User | Description | Committed | |
---|---|---|---|---|---|
#1 | 24773 | Norman Morse |
Moving journalReader from sven's private branch to perforce_software. This is because journalReader is used in the perfsplit test harness, and should be updated over time. Merging //guest/sven_erik_knop/java/JournalReader/... to //guest/perforce_software/journalReader/... |
||
//guest/sven_erik_knop/java/JournalReader/src/journal/reader/ActionType.java | |||||
#4 | 8296 | Sven Erik Knop |
Clean-up: instead of casting in every action, cast only once in the dispatcher. Should make code saner and safer. No functional change. |
||
#3 | 8200 | Sven Erik Knop |
JournalReader can now process delete records (@dl@). Also fixed processing of type 12 note records = journaldbchecksum |
||
#2 | 7874 | Sven Erik Knop | Upgrade to 2010.2 including new JournalNotes. | ||
#1 | 7589 | Sven Erik Knop | Rescue attempt to recover missing files from the JournalReader | ||
//guest/sven_erik_knop/JournalReader/src/journal/reader/ActionType.java | |||||
#2 | 7375 | Sven Erik Knop |
Major update of the JournalReader. Complete rewrite of the command line parsing Change in the options parsing within the journal reader New SQLLoader action. Currently only against MySQL (needs MySQL JDBC driver) with fixed database and user name. This will be replaced by a config file at some stage. |
||
#1 | 7374 | Sven Erik Knop | Rename/move file(s) - correct location for Eclipse project | ||
//guest/sven_erik_knop/JournalReader/journal/reader/ActionType.java | |||||
#1 | 6467 | Sven Erik Knop |
Added JournalReader, a Java library of useful tools to read and process checkpoints and journals. Added are a readme.txt to explain some details, and a jar file that contains the compiled class files. The programs will need Java 1.6 to run. |