comparison src/com/tmate/hgkit/ll/Changeset.java @ 38:50dfc69c108e

Nodeid is confusing, denote it's reference to manifest
author Artem Tikhomirov <tikhomirov.artem@gmail.com>
date Fri, 14 Jan 2011 00:52:19 +0100
parents fc265ddeab26
children 21e26da142fa
comparison
equal deleted inserted replaced
37:e45e75e22523 38:50dfc69c108e
1 /** 1 /*
2 * Copyright (c) 2010 Artem Tikhomirov 2 * Copyright (c) 2010, 2011 Artem Tikhomirov
3 */ 3 */
4 package com.tmate.hgkit.ll; 4 package com.tmate.hgkit.ll;
5 5
6 import java.io.UnsupportedEncodingException; 6 import java.io.UnsupportedEncodingException;
7 import java.util.ArrayList; 7 import java.util.ArrayList;
22 * </pre> 22 * </pre>
23 * @author artem 23 * @author artem
24 */ 24 */
25 public class Changeset { 25 public class Changeset {
26 // TODO immutable 26 // TODO immutable
27 private /*final*/ Nodeid nodeid; 27 private /*final*/ Nodeid manifest;
28 private String user; 28 private String user;
29 private String comment; 29 private String comment;
30 private ArrayList<String> files; 30 private ArrayList<String> files;
31 private String timezone; // FIXME 31 private String timezone; // FIXME
32 32
33 public void dump() { 33 public void dump() {
34 System.out.println("User:" + user); 34 System.out.println("User:" + user);
35 System.out.println("Comment:" + comment); 35 System.out.println("Comment:" + comment);
36 System.out.println("Nodeid:" + nodeid); 36 System.out.println("Manifest:" + manifest);
37 System.out.println("Date:" + timezone); 37 System.out.println("Date:" + timezone);
38 System.out.println("Files: " + files.size()); 38 System.out.println("Files: " + files.size());
39 for (String s : files) { 39 for (String s : files) {
40 System.out.print('\t'); 40 System.out.print('\t');
41 System.out.println(s); 41 System.out.println(s);
90 } catch (UnsupportedEncodingException ex) { 90 } catch (UnsupportedEncodingException ex) {
91 _comment = ""; 91 _comment = "";
92 throw new IllegalStateException("Could hardly happen"); 92 throw new IllegalStateException("Could hardly happen");
93 } 93 }
94 // change this instance at once, don't leave it partially changes in case of error 94 // change this instance at once, don't leave it partially changes in case of error
95 this.nodeid = _nodeid; 95 this.manifest = _nodeid;
96 this.user = _user; 96 this.user = _user;
97 this.timezone = _timezone; 97 this.timezone = _timezone;
98 this.files = _files; 98 this.files = _files;
99 this.comment = _comment; 99 this.comment = _comment;
100 } 100 }