Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.apache.struts2.osgi
Class OsgiUtil

    java.lang.Object
      org.apache.struts2.osgi.OsgiUtil

    public class OsgiUtil

extends Object

Constructor Summary
`OsgiUtil()`

Method Summary
`static boolean` | `containsBean(Object beanFactory, String beanId)` Calls containsBean on the passed object using refelection.
`static Object` | `getBean(Object beanFactory, String beanId)` Calls getBean() on the passed object using refelection.
`static URL` | `translateBundleURLToJarURL(URL bundleUrl, org.osgi.framework.Bundle bundle)` A bundle is a jar, and a bunble URL will be useless to clients, this method translates a URL to a resource inside a bundle from "bundle:something/path" to "jar:file:bundlelocation!/path"

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### OsgiUtil

    public OsgiUtil()

Method Detail

### translateBundleURLToJarURL

    public static URL translateBundleURLToJarURL(URL bundleUrl,
                                                 org.osgi.framework.Bundle bundle)
                                          throws MalformedURLException

  A bundle is a jar, and a bunble URL will be useless to clients, this method translates a URL to a resource inside a bundle from "bundle:something/path" to "jar:file:bundlelocation!/path"

  Throws:
    `MalformedURLException`

### getBean

    public static Object getBean(Object beanFactory,
                                 String beanId)

  Calls getBean() on the passed object using refelection. Used on Spring context because they are loaded from bundles (in anothe class loader)

### containsBean

    public static boolean containsBean(Object beanFactory,
                                       String beanId)

  Calls containsBean on the passed object using refelection. Used on Spring context because they are loaded from bundles (in anothe class loader)

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2000–2018 Apache Software Foundation. All rights reserved.