Added javadoc
Project: http://git-wip-us.apache.org/repos/asf/tomee/repo Commit: http://git-wip-us.apache.org/repos/asf/tomee/commit/004ad511 Tree: http://git-wip-us.apache.org/repos/asf/tomee/tree/004ad511 Diff: http://git-wip-us.apache.org/repos/asf/tomee/diff/004ad511 Branch: refs/heads/master Commit: 004ad5118c5cb2b91ca17ceca1ecca5860921fe4 Parents: 231faf4 Author: Daniel Cunha (soro) <daniels...@apache.org> Authored: Mon Dec 10 08:31:12 2018 -0300 Committer: Roberto Cortez <radcor...@yahoo.com> Committed: Tue Dec 11 00:31:54 2018 +0000 ---------------------------------------------------------------------- .../org/superbiz/config/PropertiesRest.java | 21 ++++++++++++++++++++ 1 file changed, 21 insertions(+) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/tomee/blob/004ad511/examples/mp-config-example/src/main/java/org/superbiz/config/PropertiesRest.java ---------------------------------------------------------------------- diff --git a/examples/mp-config-example/src/main/java/org/superbiz/config/PropertiesRest.java b/examples/mp-config-example/src/main/java/org/superbiz/config/PropertiesRest.java index fe98a37..db50894 100644 --- a/examples/mp-config-example/src/main/java/org/superbiz/config/PropertiesRest.java +++ b/examples/mp-config-example/src/main/java/org/superbiz/config/PropertiesRest.java @@ -39,18 +39,39 @@ public class PropertiesRest { @ConfigProperty(name = "java.runtime.version") private String javaVersion; + /** + * + * Get the default value configured on @ConfigProperty, that because + * the property defaultProperty doesn't exists, so it will get the value + * configured on defaultValue + * + * @return defaultValue from @ConfigProperty + */ @GET @Path("defaultProperty") public String getDefaultProperty() { return defaultProperty; } + /** + * + * Get the value from property java.runtime.version, but in this case + * it shows how you can get the value using Config class. + * + * @return javaVersion from Config.getValue + */ @GET @Path("javaVersion") public String getJavaVersionPropertyFromSystemProperties() { return config.getValue("java.runtime.version", String.class); } + /** + * Get the value from property java.runtime.version, but in this case + * it shows how you can get value injected using @ConfigProperty. + * + * @return javaVersion injected from Config + */ @GET @Path("injectedJavaVersion") public String getJavaVersionWithInjection() {