commit | f3fc34e7e0acaf2c84cc32fcf5f0c85b5ad15285 | [log] [tgz] |
---|---|---|
author | Richard S. Hall <rickhall@apache.org> | Sun Oct 04 09:49:19 2009 +0000 |
committer | Richard S. Hall <rickhall@apache.org> | Sun Oct 04 09:49:19 2009 +0000 |
tree | 28bc6691933fbd188133d062f2fd6be7c685296c | |
parent | 78d2d355d01cc5f40ab4564073f22f5005d3cc3c [diff] |
Get framework version in implementation-independent way. (FELIX-1699) git-svn-id: https://svn.apache.org/repos/asf/felix/trunk@821492 13f79535-47bb-0310-9956-ffa450edef68
diff --git a/shell/src/main/java/org/apache/felix/shell/impl/VersionCommandImpl.java b/shell/src/main/java/org/apache/felix/shell/impl/VersionCommandImpl.java index 8d1bc53..8f0a6f5 100644 --- a/shell/src/main/java/org/apache/felix/shell/impl/VersionCommandImpl.java +++ b/shell/src/main/java/org/apache/felix/shell/impl/VersionCommandImpl.java
@@ -22,6 +22,7 @@ import org.apache.felix.shell.Command; import org.osgi.framework.BundleContext; +import org.osgi.framework.Constants; public class VersionCommandImpl implements Command { @@ -49,6 +50,6 @@ public void execute(String s, PrintStream out, PrintStream err) { - out.println(m_context.getProperty("felix.version")); + out.println(m_context.getBundle(0).getHeaders(Constants.BUNDLE_VERSION)); } -} +} \ No newline at end of file