diff options
author | 2017-09-14 15:56:43 +0200 | |
---|---|---|
committer | 2017-09-14 18:48:16 +0200 | |
commit | 5fe8e6629e09ce44c6835d1b8f3a36bc3d69f131 (patch) | |
tree | daf3564fe43f6585d3287b6c2f559f2beb7d478b /src/main/java/com/google/devtools/common/options/OptionDefinition.java | |
parent | 28d3d2a96e95b2e26e6f864a52177864b0fa8e01 (diff) |
Consolidate the "unparsed" option value tracking.
In preparation for linking the parsed and unparsed values of options, consolidate and standardize our representation of the flag values as we received them (what is meant by "unparsed" values in this case). This was being done separately in ParseOptionResult, which, with extra context added, is being folded into UnparsedOptionValueDescription. We now track how an option was provided and where it came from for all option parsing.
RELNOTES: None.
PiperOrigin-RevId: 168682082
Diffstat (limited to 'src/main/java/com/google/devtools/common/options/OptionDefinition.java')
-rw-r--r-- | src/main/java/com/google/devtools/common/options/OptionDefinition.java | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/main/java/com/google/devtools/common/options/OptionDefinition.java b/src/main/java/com/google/devtools/common/options/OptionDefinition.java index a42a624cf7..e2ea084791 100644 --- a/src/main/java/com/google/devtools/common/options/OptionDefinition.java +++ b/src/main/java/com/google/devtools/common/options/OptionDefinition.java @@ -210,7 +210,7 @@ public class OptionDefinition { * * <p>Memoizes the converter-finding logic to avoid repeating the computation. */ - Converter<?> getConverter() { + public Converter<?> getConverter() { if (converter != null) { return converter; } @@ -240,7 +240,7 @@ public class OptionDefinition { * * <p>Can be used for usage help and controlling whether the "no" prefix is allowed. */ - boolean isBooleanField() { + public boolean usesBooleanValueSyntax() { return getType().equals(boolean.class) || getType().equals(TriState.class) || getConverter() instanceof BoolOrEnumConverter; |