001: /**
002: * @copyright
003: * ====================================================================
004: * Copyright (c) 2003-2004 CollabNet. All rights reserved.
005: *
006: * This software is licensed as described in the file COPYING, which
007: * you should have received as part of this distribution. The terms
008: * are also available at http://subversion.tigris.org/license-1.html.
009: * If newer versions of this license are posted there, you may use a
010: * newer version instead, at your option.
011: *
012: * This software consists of voluntary contributions made by many
013: * individuals. For exact contribution history, see the revision
014: * history and logs, available at http://subversion.tigris.org/.
015: * ====================================================================
016: * @endcopyright
017: */package org.tigris.subversion.javahl;
018:
019: import java.util.Date;
020:
021: /**
022: * Give information about one subversion item (file or directory) in the
023: * working copy
024: */
025: public class Info {
026: /** the name of the item */
027: private String name;
028:
029: /** the url of the item */
030: private String url;
031:
032: /** the uuid of the repository */
033: private String uuid;
034:
035: /** the repository url */
036: private String repository;
037:
038: /** the schedule on the next commit (see NodeKind) */
039: private int schedule;
040:
041: /** the kind of node (file or directory or unknown */
042: private int nodeKind;
043:
044: /** the author of the last commit before base */
045: private String author;
046:
047: /** the last revision this item was updated */
048: private long revision;
049:
050: /** the last revision the item before base */
051: private long lastChangedRevision;
052:
053: /** the date of the last commit */
054: private Date lastChangedDate;
055:
056: /** the last up-to-date time for the text context */
057: private Date lastDateTextUpdate;
058:
059: /** the last up-to-date time for the properties */
060: private Date lastDatePropsUpdate;
061:
062: /** the item was copied */
063: private boolean copied;
064:
065: /** the item was deleted */
066: private boolean deleted;
067:
068: /** the item is absent */
069: private boolean absent;
070:
071: /** the item is incomplete */
072: private boolean incomplete;
073:
074: /** the copy source revision */
075: private long copyRev;
076:
077: /** the copy source url */
078: private String copyUrl;
079:
080: /**
081: * Constructor to be called only by the native code
082: * @param name name of the item
083: * @param url url of the item
084: * @param uuid uuid of the repository
085: * @param repository url of the repository
086: * @param author author of the last change
087: * @param revision revision of the last update
088: * @param lastChangedRevision revision of the last change
089: * @param lastChangedDate the date of the last change
090: * @param lastDateTextUpdate the date of the last text change
091: * @param lastDatePropsUpdate the date of the last property change
092: * @param copied is the item copied
093: * @param deleted is the item deleted
094: * @param absent is the item absent
095: * @param incomplete is the item incomplete
096: * @param copyRev copy source revision
097: * @param copyUrl copy source url
098: */
099: Info(String name, String url, String uuid, String repository,
100: int schedule, int nodeKind, String author, long revision,
101: long lastChangedRevision, Date lastChangedDate,
102: Date lastDateTextUpdate, Date lastDatePropsUpdate,
103: boolean copied, boolean deleted, boolean absent,
104: boolean incomplete, long copyRev, String copyUrl) {
105: this .name = name;
106: this .url = url;
107: this .uuid = uuid;
108: this .repository = repository;
109: this .schedule = schedule;
110: this .nodeKind = nodeKind;
111: this .author = author;
112: this .revision = revision;
113: this .lastChangedRevision = lastChangedRevision;
114: this .lastChangedDate = lastChangedDate;
115: this .lastDateTextUpdate = lastDateTextUpdate;
116: this .lastDatePropsUpdate = lastDatePropsUpdate;
117: this .copied = copied;
118: this .deleted = deleted;
119: this .absent = absent;
120: this .incomplete = incomplete;
121: this .copyRev = copyRev;
122: this .copyUrl = copyUrl;
123: }
124:
125: /**
126: * Retrieves the name of the item
127: * @return name of the item
128: */
129: public String getName() {
130: return name;
131: }
132:
133: /**
134: * Retrieves the url of the item
135: * @return url of the item
136: */
137: public String getUrl() {
138: return url;
139: }
140:
141: /**
142: * Retrieves the uuid of the repository
143: * @return uuid of the repository
144: */
145: public String getUuid() {
146: return uuid;
147: }
148:
149: /**
150: * Retrieves the url of the repository
151: * @return url of the repository
152: */
153: public String getRepository() {
154: return repository;
155: }
156:
157: /**
158: * Retrieves the schedule of the next commit
159: * @return schedule of the next commit
160: */
161: public int getSchedule() {
162: return schedule;
163: }
164:
165: /**
166: * Retrieves the nodeKind
167: * @return nodeKind
168: */
169: public int getNodeKind() {
170: return nodeKind;
171: }
172:
173: /**
174: * Retrieves the author of the last commit
175: * @return author of the last commit
176: */
177: public String getAuthor() {
178: return author;
179: }
180:
181: /**
182: * Retrieves the last revision the item was updated to
183: * @return last revision the item was updated to
184: */
185: public long getRevision() {
186: return revision;
187: }
188:
189: /**
190: * Retrieves the revision of the last commit
191: * @return the revision of the last commit
192: */
193: public long getLastChangedRevision() {
194: return lastChangedRevision;
195: }
196:
197: /**
198: * Retrieves the date of the last commit
199: * @return the date of the last commit
200: */
201: public Date getLastChangedDate() {
202: return lastChangedDate;
203: }
204:
205: /**
206: * Retrieves the last date the text content was changed
207: * @return last date the text content was changed
208: */
209: public Date getLastDateTextUpdate() {
210: return lastDateTextUpdate;
211: }
212:
213: /**
214: * Retrieves the last date the properties were changed
215: * @return last date the properties were changed
216: */
217: public Date getLastDatePropsUpdate() {
218: return lastDatePropsUpdate;
219: }
220:
221: /**
222: * Retrieve if the item was copied
223: * @return the item was copied
224: */
225: public boolean isCopied() {
226: return copied;
227: }
228:
229: /**
230: * Retrieve if the item was deleted
231: * @return the item was deleted
232: */
233: public boolean isDeleted() {
234: return deleted;
235: }
236:
237: /**
238: * Retrieve if the item is absent
239: * @return the item is absent
240: */
241: public boolean isAbsent() {
242: return absent;
243: }
244:
245: /**
246: * Retrieve if the item is incomplete
247: * @return the item is incomplete
248: */
249: public boolean isIncomplete() {
250: return incomplete;
251: }
252:
253: /**
254: * Retrieves the copy source revision
255: * @return copy source revision
256: */
257: public long getCopyRev() {
258: return copyRev;
259: }
260:
261: /**
262: * Retrieves the copy source url
263: * @return copy source url
264: */
265: public String getCopyUrl() {
266: return copyUrl;
267: }
268: }
|