Fix: Use Java 6 syntax in JUL examples
A message that is not in the archive (sent off-list or not yet received): [email protected]
Mathieu Desnoyers
Appliedmerged, thanks!
Mathieu
Quoted 28 lines · ----- On Feb 15, 2016, at 2:29 PM, Michael Jeanson [email protected] wrote:
Signed-off-by Michael Jeanson <[email protected]>---
doc/examples/java-jul/ApplicationContextExample.java | 7 +++----1 file changed, 3 insertions(+), 4 deletions(-)doc/examples/java-jul/ApplicationContextExample.java +3
-5@@ -67,12 +67,11 @@ public class ApplicationContextExample { @Override public Object retrieveContextInfo(String key) { - switch (key) { - case CONTEXT_NAME_SHORT: + if (CONTEXT_NAME_SHORT.equals(key)) { return (short) 42; - case CONTEXT_NAME_STRING: + } else if (CONTEXT_NAME_STRING.equals(key)) { return "context-value!"; - default: + } else { return null; } } --2.7.0
Signature · 3 lines
Mathieu Desnoyers EfficiOS Inc. http://www.efficios.com
Alexandre Montplaisir
Reviewed-byReviewed-by Alexandre Montplaisir <[email protected]>
Quoted 25 lines · Michael Jeanson
Signed-off-by Michael Jeanson <[email protected]>--- doc/examples/java-jul/ApplicationContextExample.java | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-)doc/examples/java-jul/ApplicationContextExample.java +3
-4@@ -67,12 +67,11 @@ public class ApplicationContextExample { @Override public Object retrieveContextInfo(String key) { - switch (key) { - case CONTEXT_NAME_SHORT: + if (CONTEXT_NAME_SHORT.equals(key)) { return (short) 42; - case CONTEXT_NAME_STRING: + } else if (CONTEXT_NAME_STRING.equals(key)) { return "context-value!"; - default: + } else { return null; } }