diff src/org/tmatesoft/hg/repo/ext/MqManager.java @ 475:0e34b8f3946a

Tests for MqManager
author Artem Tikhomirov <tikhomirov.artem@gmail.com>
date Thu, 12 Jul 2012 16:57:40 +0200
parents 7bcfbc255f48
children f3fab7a20841
line wrap: on
line diff
--- a/src/org/tmatesoft/hg/repo/ext/MqManager.java	Thu Jul 12 15:36:21 2012 +0200
+++ b/src/org/tmatesoft/hg/repo/ext/MqManager.java	Thu Jul 12 16:57:40 2012 +0200
@@ -198,7 +198,7 @@
 		return Collections.unmodifiableList(queueNames);
 	}
 	
-	public class PatchRecord {
+	public final class PatchRecord {
 		private final Nodeid nodeid;
 		private final String name;
 		private final Path location;
@@ -238,6 +238,13 @@
 		public Path getPatchLocation() {
 			return location;
 		}
+		
+		@Override
+		public String toString() {
+			String fmt = "mq.PatchRecord[name:%s; %spath:%s]";
+			String ni = nodeid != null ? String.format("applied as: %s; ", nodeid.shortNotation()) : "";
+			return String.format(fmt, name, ni, location);
+		}
 	}
 
 	// TODO refine API and extract into separate classes