/** * */ package com.perforce.p4java.core.file; /** * Describes the various type of file version diffs and related whitespace options * available through the relevant content diff, resolve, annotate, etc., methods, * corresponding loosely to the "-d" series of options to the p4 command line app.<p> * * The diff types are explained in detail in the main Perforce documentation and will not be * detailed here. */ public enum DiffType { RCS_DIFF, CONTEXT_DIFF, SUMMARY_DIFF, UNIFIED_DIFF, IGNORE_WS_CHANGES, IGNORE_WS, IGNORE_LINE_ENDINGS; private static String[] argMap = { "n", "c", "s", "u", "b", "w", "l" }; /** * Return the value in p4 command single character form. * * @return single-char String representing the diff format as used by the various P4 commands. */ public String toArgString() { return argMap[this.ordinal()]; } /** * Return true if this is a "whitespace option", i.e. one of the -db, -dl, or -dw options. * * @return true iff this is a whitespace diff option. */ public boolean isWsOption() { switch (this) { case IGNORE_WS_CHANGES: case IGNORE_WS: case IGNORE_LINE_ENDINGS: return true; } return false; } }
# | Change | User | Description | Committed | |
---|---|---|---|---|---|
#1 | 19903 | stuartrowe |
Branching //guest/perforce_software/p4java/... to //guest/stuartrowe/p4java/... |
||
//guest/perforce_software/p4java/r14.1/src/main/java/com/perforce/p4java/core/file/DiffType.java | |||||
#1 | 12541 | Matt Attaway | Initial add of the 14.1 p4java source code |