Class BundleClassSpace

    • Constructor Detail

      • BundleClassSpace

        public BundleClassSpace​(org.osgi.framework.Bundle bundle)
    • Method Detail

      • getResource

        public URL getResource​(String name)
        Description copied from interface: ClassSpace
        Queries the surrounding class space for the resource with the given name.
        Specified by:
        getResource in interface ClassSpace
        Parameters:
        name - The resource name
        Returns:
        URL pointing to the resource; null if it wasn't found
        See Also:
        ClassLoader.getResource(String)
      • findEntries

        public Enumeration<URL> findEntries​(String path,
                                            String glob,
                                            boolean recurse)
        Description copied from interface: ClassSpace
        Queries local class space content for entries matching the given pattern.
        Specified by:
        findEntries in interface ClassSpace
        Parameters:
        path - The initial search directory; for example "META-INF"
        glob - The filename glob pattern; for example "*.xml"
        recurse - If true recurse into sub-directories; otherwise only search initial directory
        Returns:
        Sequence of URLs, one for each matching entry
        See Also:
        Bundle.findEntries(String, String, boolean)
      • getBundle

        public org.osgi.framework.Bundle getBundle()
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class Object