diff options
author | James Ahlborn <jtahlborn@yahoo.com> | 2017-05-11 04:05:28 +0000 |
---|---|---|
committer | James Ahlborn <jtahlborn@yahoo.com> | 2017-05-11 04:05:28 +0000 |
commit | 0b1a53e9c4c1cbb0c9379bde5be0c83387a8a8a0 (patch) | |
tree | 3fb48b6ce678b6fbddc0819f3aac5b6eb0c0d8ad | |
parent | ae032248c90651dfe64ffe6c072660fea0e2b352 (diff) | |
download | jackcess-0b1a53e9c4c1cbb0c9379bde5be0c83387a8a8a0.tar.gz jackcess-0b1a53e9c4c1cbb0c9379bde5be0c83387a8a8a0.zip |
provide accessors for defaults config
git-svn-id: https://svn.code.sf.net/p/jackcess/code/jackcess/trunk@1096 f203690c-595d-4dc9-a70b-905162fa7fd2
-rw-r--r-- | src/main/java/com/healthmarketscience/jackcess/util/CustomLinkResolver.java | 20 |
1 files changed, 16 insertions, 4 deletions
diff --git a/src/main/java/com/healthmarketscience/jackcess/util/CustomLinkResolver.java b/src/main/java/com/healthmarketscience/jackcess/util/CustomLinkResolver.java index 9f4cace..7992d71 100644 --- a/src/main/java/com/healthmarketscience/jackcess/util/CustomLinkResolver.java +++ b/src/main/java/com/healthmarketscience/jackcess/util/CustomLinkResolver.java @@ -100,6 +100,18 @@ public abstract class CustomLinkResolver implements LinkResolver _defaultTempDir = defaultTempDir; } + protected FileFormat getDefaultFormat() { + return _defaultFormat; + } + + protected boolean isDefaultInMemory() { + return _defaultInMemory; + } + + protected File getDefaultTempDirectory() { + return _defaultTempDir; + } + /** * Custom implementation is: * <pre> @@ -108,8 +120,8 @@ public abstract class CustomLinkResolver implements LinkResolver * * if(customFile != null) { * // this is a custom file, create and return relevant temp db - * return createTempDb(customFile, _defaultFormat, _defaultInMemory, - * _defaultTempDir); + * return createTempDb(customFile, getDefaultFormat(), isDefaultInMemory(), + * getDefaultTempDirectory()); * } * * // not a custmom file, load using the default behavior @@ -125,8 +137,8 @@ public abstract class CustomLinkResolver implements LinkResolver { Object customFile = loadCustomFile(linkerDb, linkeeFileName); if(customFile != null) { - return createTempDb(customFile, _defaultFormat, _defaultInMemory, - _defaultTempDir); + return createTempDb(customFile, getDefaultFormat(), isDefaultInMemory(), + getDefaultTempDirectory()); } return LinkResolver.DEFAULT.resolveLinkedDatabase(linkerDb, linkeeFileName); } |