1 package org.apache.maven.scm;
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22 import java.io.Serializable;
23
24
25
26
27
28
29
30
31
32 public class ChangeFile
33 implements Serializable
34 {
35 private static final long serialVersionUID = 6294855290542668753L;
36
37
38
39
40 private String name;
41
42
43
44
45 private String revision;
46
47
48
49
50
51
52 private ScmFileStatus action;
53
54
55
56
57
58 private String originalName;
59
60
61
62
63
64 private String originalRevision;
65
66
67
68
69
70
71 public ChangeFile( String name )
72 {
73 setName( name );
74 }
75
76
77
78
79
80
81
82 public ChangeFile( String name, String rev )
83 {
84 setName( name );
85
86 setRevision( rev );
87 }
88
89
90
91
92
93
94 public String getName()
95 {
96 return name;
97 }
98
99
100
101
102
103
104 public void setName( String name )
105 {
106 this.name = name;
107 }
108
109 public String getOriginalName()
110 {
111 return originalName;
112 }
113
114 public void setOriginalName( String originalName )
115 {
116
117 this.originalName = originalName;
118 }
119
120 public String getOriginalRevision()
121 {
122 return originalRevision;
123 }
124
125 public void setOriginalRevision( String originalRevision )
126 {
127 this.originalRevision = originalRevision;
128 }
129
130
131
132
133
134
135 public String getRevision()
136 {
137 return revision;
138 }
139
140
141
142
143
144
145 public void setRevision( String revision )
146 {
147 this.revision = revision;
148 }
149
150 public ScmFileStatus getAction()
151 {
152 return action;
153 }
154
155 public void setAction( ScmFileStatus action )
156 {
157 this.action = action;
158 }
159
160
161
162
163
164
165 public String toString()
166 {
167 StringBuilder buffer = new StringBuilder( );
168
169 if ( getAction() != null )
170 {
171 buffer.append( "[" ).append( getAction() ).append( "]:" );
172 }
173
174 buffer.append( getName() );
175 if ( getRevision() != null )
176 {
177 buffer.append( ", " ).append( getRevision() );
178 }
179
180 if ( getOriginalName() != null )
181 {
182 buffer.append( ", originalName=" ).append( getOriginalName() );
183 }
184
185 if ( getOriginalRevision() != null )
186 {
187 buffer.append( ", originalRevision=" ).append( getOriginalRevision() );
188 }
189
190 return buffer.toString();
191 }
192 }