commit | 7d84ea6954319cfd237496504d4412c0aa2f8aab | [log] [tgz] |
---|---|---|
author | Clement Escoffier <clement@apache.org> | Fri Nov 29 13:52:03 2013 +0000 |
committer | Clement Escoffier <clement@apache.org> | Fri Nov 29 13:52:03 2013 +0000 |
tree | c31f38fce1234587475f53393c90eda4c5885221 | |
parent | f98142e7ac7d2638074bc5c0d579671633d04ac1 [diff] |
Fix FELIX-4335 (https://issues.apache.org/jira/browse/FELIX-4335) Add a method to retrieve the current value of a property as object. git-svn-id: https://svn.apache.org/repos/asf/felix/trunk@1546561 13f79535-47bb-0310-9956-ffa450edef68
diff --git a/ipojo/runtime/core/src/main/java/org/apache/felix/ipojo/architecture/PropertyDescription.java b/ipojo/runtime/core/src/main/java/org/apache/felix/ipojo/architecture/PropertyDescription.java index a5a528f..4f356fb 100644 --- a/ipojo/runtime/core/src/main/java/org/apache/felix/ipojo/architecture/PropertyDescription.java +++ b/ipojo/runtime/core/src/main/java/org/apache/felix/ipojo/architecture/PropertyDescription.java
@@ -189,7 +189,7 @@ if (m_value == null) { return null; } - + Class type = null; try { type = Property.computeType(m_type, context); @@ -199,4 +199,17 @@ } } + /** + * Gets the current value of the property as object. + * @return the current value + * @since 1.11.1 + */ + public Object getCurrentValue() { + if (m_property == null) { + return m_value; + } else { + return m_property.getValue(); + } + } + }