2 * Copyright 2000-2009 JetBrains s.r.o.
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
8 * http://www.apache.org/licenses/LICENSE-2.0
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
16 package org
.jetbrains
.idea
.svn
;
18 import com
.intellij
.openapi
.vcs
.FilePath
;
19 import com
.intellij
.openapi
.vcs
.FileStatus
;
20 import com
.intellij
.openapi
.vcs
.changes
.Change
;
21 import com
.intellij
.openapi
.vcs
.changes
.ContentRevision
;
25 public class ConflictedSvnChange
extends Change
{
26 private final ConflictState myConflictState
;
28 private final FilePath myTreeConflictMarkHolder
;
30 public ConflictedSvnChange(ContentRevision beforeRevision
, ContentRevision afterRevision
, final ConflictState conflictState
,
31 final FilePath treeConflictMarkHolder
) {
32 super(beforeRevision
, afterRevision
);
33 myConflictState
= conflictState
;
34 myTreeConflictMarkHolder
= treeConflictMarkHolder
;
37 public ConflictedSvnChange(ContentRevision beforeRevision
, ContentRevision afterRevision
, FileStatus fileStatus
,
38 final ConflictState conflictState
, final FilePath treeConflictMarkHolder
) {
39 super(beforeRevision
, afterRevision
, fileStatus
);
40 myConflictState
= conflictState
;
41 myTreeConflictMarkHolder
= treeConflictMarkHolder
;
44 public ConflictState
getConflictState() {
45 return myConflictState
;
49 public Icon
getAdditionalIcon() {
50 return myConflictState
.getIcon();
54 public String
getDescription() {
55 final String description
= myConflictState
.getDescription();
56 if (description
!= null) {
57 return SvnBundle
.message("svn.changeview.item.in.conflict.text", description
);
62 public FilePath
getTreeConflictMarkHolder() {
63 return myTreeConflictMarkHolder
;