Skip to content
Snippets Groups Projects
Commit 07f54cbd authored by Leonard Kupper's avatar Leonard Kupper
Browse files

Fix old comment and catch empty include filename.

parent 1a8680fc
No related branches found
No related tags found
1 merge request!19Feat/configparser update 29
...@@ -13,7 +13,6 @@ import java.util.Stack; ...@@ -13,7 +13,6 @@ import java.util.Stack;
*/ */
public final class JavaPropertiesConfigurationParser extends ConfigurationParser { public final class JavaPropertiesConfigurationParser extends ConfigurationParser {
//ArrayList<String> mInclusionStack;
Stack<File> mInclusionStack = new Stack<>(); Stack<File> mInclusionStack = new Stack<>();
/** /**
...@@ -86,6 +85,10 @@ public final class JavaPropertiesConfigurationParser extends ConfigurationParser ...@@ -86,6 +85,10 @@ public final class JavaPropertiesConfigurationParser extends ConfigurationParser
abstractPath = new File(findIncludePath + ".properties"); abstractPath = new File(findIncludePath + ".properties");
} }
includeFile = abstractPath.getCanonicalFile(); includeFile = abstractPath.getCanonicalFile();
if (!includeFile.isFile()) {
throw new ConfigurationParsingException("Given include path is not a file: " + includeFile);
}
System.out.println("Include file: " + includeFile);
} catch (IOException e) { } catch (IOException e) {
throw new ConfigurationParsingException("Can not find include file.", e); throw new ConfigurationParsingException("Can not find include file.", e);
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment