git://source.jalview.org
/
jalview.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
JAL-629 Firm up bootstrapArgs. Correct '-colour' in test. Separate --headless and...
[jalview.git]
/
src
/
jalview
/
bin
/
ArgParser.java
diff --git
a/src/jalview/bin/ArgParser.java
b/src/jalview/bin/ArgParser.java
index
3dc7921
..
be2c07f
100644
(file)
--- a/
src/jalview/bin/ArgParser.java
+++ b/
src/jalview/bin/ArgParser.java
@@
-878,14
+878,14
@@
public class ArgParser
}
}
}
}
- private static final Collection<String> bootstrapArgs = new ArrayList(
- Arrays.asList("props", "debug"));
+ private static final Collection<Arg> bootstrapArgs = new ArrayList(
+ Arrays.asList(Arg.PROPS, Arg.DEBUG));
- public static Map<String, String> bootstrapArgs(String[] args)
+ public static Map<Arg, String> bootstrapArgs(String[] args)
{
{
- Map<String, String> argMap = new HashMap<>();
+ Map<Arg, String> bootstrapArgMap = new HashMap<>();
if (args == null)
if (args == null)
- return argMap;
+ return bootstrapArgMap;
Enumeration<String> argE = Collections.enumeration(Arrays.asList(args));
while (argE.hasMoreElements())
{
Enumeration<String> argE = Collections.enumeration(Arrays.asList(args));
while (argE.hasMoreElements())
{
@@
-904,10
+904,11
@@
public class ArgParser
{
argName = arg.substring(2);
}
{
argName = arg.substring(2);
}
- if (bootstrapArgs.contains(argName))
- argMap.put(argName, val);
+ Arg a = argMap.get(argName);
+ if (a != null && bootstrapArgs.contains(a))
+ bootstrapArgMap.put(a, val);
}
}
}
}
- return argMap;
+ return bootstrapArgMap;
}
}
\ No newline at end of file
}
}
\ No newline at end of file