diff src/org/tmatesoft/hg/repo/Revlog.java @ 115:c0cc2535462c

Introduced channels to pipeline (and easily filter) data streams
author Artem Tikhomirov <tikhomirov.artem@gmail.com>
date Thu, 03 Feb 2011 23:32:08 +0100
parents a3a2e5deb320
children 3959bffb14e9
line wrap: on
line diff
--- a/src/org/tmatesoft/hg/repo/Revlog.java	Thu Feb 03 22:13:55 2011 +0100
+++ b/src/org/tmatesoft/hg/repo/Revlog.java	Thu Feb 03 23:32:08 2011 +0100
@@ -38,22 +38,28 @@
  */
 abstract class Revlog {
 
-	private final HgRepository hgRepo;
+	private final HgRepository repo;
 	protected final RevlogStream content;
 
-	protected Revlog(HgRepository hgRepo, RevlogStream content) {
+	protected Revlog(HgRepository hgRepo, RevlogStream contentStream) {
 		if (hgRepo == null) {
 			throw new IllegalArgumentException();
 		}
-		if (content == null) {
+		if (contentStream == null) {
 			throw new IllegalArgumentException();
 		}
-		this.hgRepo = hgRepo;
-		this.content = content;
+		repo = hgRepo;
+		content = contentStream;
+	}
+	
+	// invalid Revlog
+	protected Revlog(HgRepository hgRepo) {
+		repo = hgRepo;
+		content = null;
 	}
 
 	public final HgRepository getRepo() {
-		return hgRepo;
+		return repo;
 	}
 
 	public int getRevisionCount() {