diff src/org/tmatesoft/hg/internal/DataAccessProvider.java @ 608:e1b29756f901

Clean, organize and resolve some TODOs and FIXMEs: minor refactorings and comments
author Artem Tikhomirov <tikhomirov.artem@gmail.com>
date Tue, 07 May 2013 21:27:51 +0200
parents 5daa42067e7c
children 65c01508f002
line wrap: on
line diff
--- a/src/org/tmatesoft/hg/internal/DataAccessProvider.java	Tue May 07 16:52:46 2013 +0200
+++ b/src/org/tmatesoft/hg/internal/DataAccessProvider.java	Tue May 07 21:27:51 2013 +0200
@@ -54,8 +54,6 @@
 	private final int mapioMagicBoundary;
 	private final int bufferSize, mapioBufSize;
 	private final SessionContext context;
-	// not the right place for the property, but DAP is the only place currently available to RevlogStream to get the value
-	private final boolean shallMergePatches;
 	
 	public DataAccessProvider(SessionContext ctx) {
 		context = ctx;
@@ -63,7 +61,6 @@
 		mapioMagicBoundary = mapioBoundaryValue(pm.getInt(CFG_PROPERTY_MAPIO_LIMIT, DEFAULT_MAPIO_LIMIT));
 		bufferSize = pm.getInt(CFG_PROPERTY_FILE_BUFFER_SIZE, DEFAULT_FILE_BUFFER);
 		mapioBufSize = pm.getInt(CFG_PROPERTY_MAPIO_BUFFER_SIZE, DEFAULT_MAPIO_BUFFER);
-		shallMergePatches = pm.getBoolean(Internals.CFG_PROPERTY_PATCH_MERGE, false);
 	}
 	
 	public DataAccessProvider(SessionContext ctx, int mapioBoundary, int regularBufferSize, int mapioBufferSize) {
@@ -71,14 +68,8 @@
 		mapioMagicBoundary = mapioBoundaryValue(mapioBoundary);
 		bufferSize = regularBufferSize;
 		mapioBufSize = mapioBufferSize;
-		shallMergePatches = new PropertyMarshal(ctx).getBoolean(Internals.CFG_PROPERTY_PATCH_MERGE, false);
 	}
 	
-	// TODO [post-1.1] find a better place for this option, it's unrelated to the DAP
-	public boolean shallMergePatches() {
-		return shallMergePatches;
-	}
-
 	// ensure contract of CFG_PROPERTY_MAPIO_LIMIT, for mapioBoundary == 0 use MAX_VALUE so that no file is memmap-ed
 	private static int mapioBoundaryValue(int mapioBoundary) {
 		return mapioBoundary == 0 ? Integer.MAX_VALUE : mapioBoundary;