public class VcsHistoryUtil
extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
static Key<Pair<FilePath,VcsRevisionNumber>> |
REVISION_INFO_KEY
Deprecated.
|
Modifier and Type | Method and Description |
---|---|
static int |
compare(VcsFileRevision first,
VcsFileRevision second) |
static int |
compareNumbers(VcsFileRevision first,
VcsFileRevision second) |
static boolean |
isEmpty(VcsFileRevision revision) |
static DiffContent |
loadContentForDiff(Project project,
FilePath path,
VcsFileRevision revision) |
static byte [] |
loadRevisionContent(VcsFileRevision revision) |
static java.lang.String |
loadRevisionContentGuessEncoding(VcsFileRevision revision,
VirtualFile file,
Project project) |
static void |
showDiff(Project project,
FilePath path,
VcsFileRevision revision1,
VcsFileRevision revision2,
java.lang.String title1,
java.lang.String title2)
Invokes
DiffManager.getDiffTool() to show difference between the given revisions of the given file. |
static void |
showDifferencesInBackground(Project project,
FilePath filePath,
VcsFileRevision older,
VcsFileRevision newer)
Shows difference between two revisions of a file in a diff tool.
|
@Deprecated public static final Key<Pair<FilePath,VcsRevisionNumber>> REVISION_INFO_KEY
public static int compare(VcsFileRevision first, VcsFileRevision second)
public static int compareNumbers(VcsFileRevision first, VcsFileRevision second)
public static void showDiff(Project project, FilePath path, VcsFileRevision revision1, VcsFileRevision revision2, java.lang.String title1, java.lang.String title2) throws VcsException, java.io.IOException
DiffManager.getDiffTool()
to show difference between the given revisions of the given file.project
- project under vcs control.path
- file which revisions are compared.revision1
- first revision - 'before', to the left.revision2
- second revision - 'after', to the right.VcsException
java.io.IOException
public static DiffContent loadContentForDiff(Project project, FilePath path, VcsFileRevision revision) throws java.io.IOException, VcsException
java.io.IOException
VcsException
public static byte [] loadRevisionContent(VcsFileRevision revision) throws VcsException, java.io.IOException
VcsException
java.io.IOException
public static java.lang.String loadRevisionContentGuessEncoding(VcsFileRevision revision, VirtualFile file, Project project) throws VcsException, java.io.IOException
VcsException
java.io.IOException
public static boolean isEmpty(VcsFileRevision revision)
public static void showDifferencesInBackground(Project project, FilePath filePath, VcsFileRevision older, VcsFileRevision newer)