You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@deltaspike.apache.org by gp...@apache.org on 2012/06/14 00:47:21 UTC
git commit: DELTASPIKE-196 added TODOs (exception handling)
Updated Branches:
refs/heads/master c8407c237 -> 8deaf4a7d
DELTASPIKE-196 added TODOs (exception handling)
Project: http://git-wip-us.apache.org/repos/asf/incubator-deltaspike/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-deltaspike/commit/8deaf4a7
Tree: http://git-wip-us.apache.org/repos/asf/incubator-deltaspike/tree/8deaf4a7
Diff: http://git-wip-us.apache.org/repos/asf/incubator-deltaspike/diff/8deaf4a7
Branch: refs/heads/master
Commit: 8deaf4a7d5a7e5e6d3791992f326d639a348e240
Parents: c8407c2
Author: gpetracek <gp...@apache.org>
Authored: Thu Jun 14 00:44:43 2012 +0200
Committer: gpetracek <gp...@apache.org>
Committed: Thu Jun 14 00:44:43 2012 +0200
----------------------------------------------------------------------
.../impl/config/DefaultConfigPropertyProducer.java | 10 ++++++----
1 files changed, 6 insertions(+), 4 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/incubator-deltaspike/blob/8deaf4a7/deltaspike/core/impl/src/main/java/org/apache/deltaspike/core/impl/config/DefaultConfigPropertyProducer.java
----------------------------------------------------------------------
diff --git a/deltaspike/core/impl/src/main/java/org/apache/deltaspike/core/impl/config/DefaultConfigPropertyProducer.java b/deltaspike/core/impl/src/main/java/org/apache/deltaspike/core/impl/config/DefaultConfigPropertyProducer.java
index 56806c5..2295657 100644
--- a/deltaspike/core/impl/src/main/java/org/apache/deltaspike/core/impl/config/DefaultConfigPropertyProducer.java
+++ b/deltaspike/core/impl/src/main/java/org/apache/deltaspike/core/impl/config/DefaultConfigPropertyProducer.java
@@ -30,12 +30,12 @@ import org.apache.deltaspike.core.api.config.annotation.ConfigProperty;
* This class contains producer methods for injecting
* configuration provided with the {@link ConfigProperty}
* annotation.
- * TODO allow a custom implementation without a dependency to core-impl
*/
+//X TODO allow a custom implementation without a dependency to core-impl
@ApplicationScoped
+@SuppressWarnings("UnusedDeclaration")
public class DefaultConfigPropertyProducer extends BaseConfigPropertyProducer
{
-
@Produces
@Dependent
@ConfigProperty(name = "ignored") // we actually don't need the name
@@ -55,6 +55,7 @@ public class DefaultConfigPropertyProducer extends BaseConfigPropertyProducer
return null;
}
+ //X TODO integrate with the HandledHandler of DeltaSpike
return Integer.parseInt(configuredValue);
}
@@ -69,6 +70,7 @@ public class DefaultConfigPropertyProducer extends BaseConfigPropertyProducer
return null;
}
+ //X TODO integrate with the HandledHandler of DeltaSpike
return Long.parseLong(configuredValue);
}
@@ -100,14 +102,14 @@ public class DefaultConfigPropertyProducer extends BaseConfigPropertyProducer
public Float produceFloatConfiguration(InjectionPoint injectionPoint)
{
String configuredValue = getStringPropertyValue(injectionPoint);
+
if (configuredValue == null)
{
return null;
}
//X TODO think about something like @NumberFormat(...)
+ //X TODO integrate with the HandledHandler of DeltaSpike
return Float.parseFloat(configuredValue);
}
-
-
}