KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > netbeans > modules > subversion > ui > blame > AnnotateLine


1 /*
2  * The contents of this file are subject to the terms of the Common Development
3  * and Distribution License (the License). You may not use this file except in
4  * compliance with the License.
5  *
6  * You can obtain a copy of the License at http://www.netbeans.org/cddl.html
7  * or http://www.netbeans.org/cddl.txt.
8  *
9  * When distributing Covered Code, include this CDDL Header Notice in each file
10  * and include the License file at http://www.netbeans.org/cddl.txt.
11  * If applicable, add the following below the CDDL Header, with the fields
12  * enclosed by brackets [] replaced by your own identifying information:
13  * "Portions Copyrighted [year] [name of copyright owner]"
14  *
15  * The Original Software is NetBeans. The Initial Developer of the Original
16  * Software is Sun Microsystems, Inc. Portions Copyright 1997-2006 Sun
17  * Microsystems, Inc. All Rights Reserved.
18  */

19 package org.netbeans.modules.subversion.ui.blame;
20
21 import org.tigris.subversion.svnclientadapter.ISVNLogMessageChangePath;
22
23 import java.util.*;
24
25 /**
26  * One line of annotation, this is copied from CVS so that other support classes stay the same.
27  *
28  * @author Maros Sandor
29  */

30 public class AnnotateLine {
31
32     private String JavaDoc author;
33     private String JavaDoc revision;
34     private Date date;
35     private String JavaDoc content;
36     private int lineNum;
37
38     private String JavaDoc commitMessage;
39     
40     /**
41      * The default is true to enable rollback even if we were unable to determine the correct value.
42      */

43     private boolean canBeRolledBack = true;
44
45     private ISVNLogMessageChangePath [] changedPaths;
46
47     public String JavaDoc getCommitMessage() {
48         return commitMessage;
49     }
50
51     public void setCommitMessage(String JavaDoc commitMessage) {
52         this.commitMessage = commitMessage;
53     }
54
55     public ISVNLogMessageChangePath[] getChangedPaths() {
56         return changedPaths;
57     }
58
59     public void setChangedPaths(ISVNLogMessageChangePath[] changedPaths) {
60         this.changedPaths = changedPaths;
61     }
62
63     /**
64      * Returns the author of this line.
65      */

66     public String JavaDoc getAuthor() {
67         return author;
68     }
69
70     /**
71      * Sets the author of this line.
72      */

73     public void setAuthor(String JavaDoc author) {
74         this.author = author;
75     }
76
77     /**
78      * Returns the revision of this line.
79      */

80     public String JavaDoc getRevision() {
81         return revision;
82     }
83
84     /**
85      * Sets the revision of this line.
86      */

87     public void setRevision(String JavaDoc revision) {
88         this.revision = revision;
89     }
90
91     /**
92      * Returns the date of this line.
93      */

94     public Date getDate() {
95         return date;
96     }
97
98     public void setDate(Date date) {
99         this.date = date;
100     }
101     
102     /**
103      * Return the line's content.
104      */

105     public String JavaDoc getContent() {
106         return content;
107     }
108
109     /**
110      * Sets the line's content.
111      */

112     public void setContent(String JavaDoc content) {
113         this.content = content;
114     }
115
116     /**
117      * Returns the line's number. It's 1 based.
118      */

119     public int getLineNum() {
120         return lineNum;
121     }
122
123     /**
124      * Returns the line's number.
125      */

126     public Integer JavaDoc getLineNumInteger() {
127         return new Integer JavaDoc(lineNum);
128     }
129
130     /**
131      * Sets the line's number.
132      */

133     public void setLineNum(int lineNum) {
134         this.lineNum = lineNum;
135     }
136
137     /**
138      * @return false if the file was added to repository (created) in this revision, true otherwise
139      */

140     public boolean canBeRolledBack() {
141         return this.canBeRolledBack;
142     }
143
144     public void setCanBeRolledBack(boolean canBeRolledBack) {
145         this.canBeRolledBack = canBeRolledBack;
146     }
147 }
Popular Tags