Remove obsolete modules for R4 (core, foundation, compendium) and javax.servlet 2.1
git-svn-id: https://svn.apache.org/repos/asf/felix/trunk@1693695 13f79535-47bb-0310-9956-ffa450edef68
diff --git a/.DS_Store b/.DS_Store
index 65b3cb2..d5fb9e2 100644
--- a/.DS_Store
+++ b/.DS_Store
Binary files differ
diff --git a/coordinator/pom.xml b/coordinator/pom.xml
index bd798c2..cde5e43 100644
--- a/coordinator/pom.xml
+++ b/coordinator/pom.xml
@@ -22,7 +22,7 @@
<parent>
<groupId>org.apache.felix</groupId>
<artifactId>felix-parent</artifactId>
- <version>2.1</version>
+ <version>3</version>
<relativePath>../pom/pom.xml</relativePath>
</parent>
@@ -44,13 +44,6 @@
<build>
<plugins>
<plugin>
- <artifactId>maven-compiler-plugin</artifactId>
- <configuration>
- <source>5</source>
- <target>jsr14</target>
- </configuration>
- </plugin>
- <plugin>
<groupId>org.apache.felix</groupId>
<artifactId>maven-bundle-plugin</artifactId>
<extensions>true</extensions>
diff --git a/coordinator/src/main/java/org/apache/felix/coordinator/impl/CoordinationImpl.java b/coordinator/src/main/java/org/apache/felix/coordinator/impl/CoordinationImpl.java
index 152b422..587dd11 100644
--- a/coordinator/src/main/java/org/apache/felix/coordinator/impl/CoordinationImpl.java
+++ b/coordinator/src/main/java/org/apache/felix/coordinator/impl/CoordinationImpl.java
@@ -58,7 +58,7 @@
private final String name;
- private long deadLine;
+ private volatile long deadLine;
/**
* Access to this field must be synchronized as long as the expected state
@@ -68,15 +68,17 @@
*/
private volatile State state;
- private Throwable failReason;
+ private volatile Throwable failReason;
private final ArrayList<Participant> participants;
private final Map<Class<?>, Object> variables;
- private TimerTask timeoutTask;
+ private volatile TimerTask timeoutTask;
- private Thread associatedThread;
+ private volatile Thread associatedThread;
+
+ private volatile CoordinationHolder threadAssociatedRef;
private final Object waitLock = new Object();
@@ -537,8 +539,17 @@
return id == other.id;
}
- void setAssociatedThread(final Thread t) {
+ void setAssociatedThread(final Thread t)
+ {
this.associatedThread = t;
+ if ( t != null )
+ {
+ this.threadAssociatedRef = this.holderRef.get();
+ }
+ else
+ {
+ this.threadAssociatedRef = null;
+ }
}
public Coordination getHolder() {
diff --git a/coordinator/src/test/java/org/apache/felix/coordinator/impl/CoordinatorImplTest.java b/coordinator/src/test/java/org/apache/felix/coordinator/impl/CoordinatorImplTest.java
index e6b4382..540d947 100644
--- a/coordinator/src/test/java/org/apache/felix/coordinator/impl/CoordinatorImplTest.java
+++ b/coordinator/src/test/java/org/apache/felix/coordinator/impl/CoordinatorImplTest.java
@@ -126,6 +126,16 @@
assertNull(coordinator.peek());
}
+ /**
+ * Regression test for FELIX-4976
+ */
+ public void test_coordinationOrphanedBug()
+ {
+ coordinator.begin("test", 0);
+ System.gc();
+ coordinator.pop().end();
+ }
+
public void test_beginCoordination_stack()
{
final String name = "test";
diff --git a/javax.servlet/LICENSE b/javax.servlet/LICENSE
deleted file mode 100644
index d645695..0000000
--- a/javax.servlet/LICENSE
+++ /dev/null
@@ -1,202 +0,0 @@
-
- Apache License
- Version 2.0, January 2004
- http://www.apache.org/licenses/
-
- TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
-
- 1. Definitions.
-
- "License" shall mean the terms and conditions for use, reproduction,
- and distribution as defined by Sections 1 through 9 of this document.
-
- "Licensor" shall mean the copyright owner or entity authorized by
- the copyright owner that is granting the License.
-
- "Legal Entity" shall mean the union of the acting entity and all
- other entities that control, are controlled by, or are under common
- control with that entity. For the purposes of this definition,
- "control" means (i) the power, direct or indirect, to cause the
- direction or management of such entity, whether by contract or
- otherwise, or (ii) ownership of fifty percent (50%) or more of the
- outstanding shares, or (iii) beneficial ownership of such entity.
-
- "You" (or "Your") shall mean an individual or Legal Entity
- exercising permissions granted by this License.
-
- "Source" form shall mean the preferred form for making modifications,
- including but not limited to software source code, documentation
- source, and configuration files.
-
- "Object" form shall mean any form resulting from mechanical
- transformation or translation of a Source form, including but
- not limited to compiled object code, generated documentation,
- and conversions to other media types.
-
- "Work" shall mean the work of authorship, whether in Source or
- Object form, made available under the License, as indicated by a
- copyright notice that is included in or attached to the work
- (an example is provided in the Appendix below).
-
- "Derivative Works" shall mean any work, whether in Source or Object
- form, that is based on (or derived from) the Work and for which the
- editorial revisions, annotations, elaborations, or other modifications
- represent, as a whole, an original work of authorship. For the purposes
- of this License, Derivative Works shall not include works that remain
- separable from, or merely link (or bind by name) to the interfaces of,
- the Work and Derivative Works thereof.
-
- "Contribution" shall mean any work of authorship, including
- the original version of the Work and any modifications or additions
- to that Work or Derivative Works thereof, that is intentionally
- submitted to Licensor for inclusion in the Work by the copyright owner
- or by an individual or Legal Entity authorized to submit on behalf of
- the copyright owner. For the purposes of this definition, "submitted"
- means any form of electronic, verbal, or written communication sent
- to the Licensor or its representatives, including but not limited to
- communication on electronic mailing lists, source code control systems,
- and issue tracking systems that are managed by, or on behalf of, the
- Licensor for the purpose of discussing and improving the Work, but
- excluding communication that is conspicuously marked or otherwise
- designated in writing by the copyright owner as "Not a Contribution."
-
- "Contributor" shall mean Licensor and any individual or Legal Entity
- on behalf of whom a Contribution has been received by Licensor and
- subsequently incorporated within the Work.
-
- 2. Grant of Copyright License. Subject to the terms and conditions of
- this License, each Contributor hereby grants to You a perpetual,
- worldwide, non-exclusive, no-charge, royalty-free, irrevocable
- copyright license to reproduce, prepare Derivative Works of,
- publicly display, publicly perform, sublicense, and distribute the
- Work and such Derivative Works in Source or Object form.
-
- 3. Grant of Patent License. Subject to the terms and conditions of
- this License, each Contributor hereby grants to You a perpetual,
- worldwide, non-exclusive, no-charge, royalty-free, irrevocable
- (except as stated in this section) patent license to make, have made,
- use, offer to sell, sell, import, and otherwise transfer the Work,
- where such license applies only to those patent claims licensable
- by such Contributor that are necessarily infringed by their
- Contribution(s) alone or by combination of their Contribution(s)
- with the Work to which such Contribution(s) was submitted. If You
- institute patent litigation against any entity (including a
- cross-claim or counterclaim in a lawsuit) alleging that the Work
- or a Contribution incorporated within the Work constitutes direct
- or contributory patent infringement, then any patent licenses
- granted to You under this License for that Work shall terminate
- as of the date such litigation is filed.
-
- 4. Redistribution. You may reproduce and distribute copies of the
- Work or Derivative Works thereof in any medium, with or without
- modifications, and in Source or Object form, provided that You
- meet the following conditions:
-
- (a) You must give any other recipients of the Work or
- Derivative Works a copy of this License; and
-
- (b) You must cause any modified files to carry prominent notices
- stating that You changed the files; and
-
- (c) You must retain, in the Source form of any Derivative Works
- that You distribute, all copyright, patent, trademark, and
- attribution notices from the Source form of the Work,
- excluding those notices that do not pertain to any part of
- the Derivative Works; and
-
- (d) If the Work includes a "NOTICE" text file as part of its
- distribution, then any Derivative Works that You distribute must
- include a readable copy of the attribution notices contained
- within such NOTICE file, excluding those notices that do not
- pertain to any part of the Derivative Works, in at least one
- of the following places: within a NOTICE text file distributed
- as part of the Derivative Works; within the Source form or
- documentation, if provided along with the Derivative Works; or,
- within a display generated by the Derivative Works, if and
- wherever such third-party notices normally appear. The contents
- of the NOTICE file are for informational purposes only and
- do not modify the License. You may add Your own attribution
- notices within Derivative Works that You distribute, alongside
- or as an addendum to the NOTICE text from the Work, provided
- that such additional attribution notices cannot be construed
- as modifying the License.
-
- You may add Your own copyright statement to Your modifications and
- may provide additional or different license terms and conditions
- for use, reproduction, or distribution of Your modifications, or
- for any such Derivative Works as a whole, provided Your use,
- reproduction, and distribution of the Work otherwise complies with
- the conditions stated in this License.
-
- 5. Submission of Contributions. Unless You explicitly state otherwise,
- any Contribution intentionally submitted for inclusion in the Work
- by You to the Licensor shall be under the terms and conditions of
- this License, without any additional terms or conditions.
- Notwithstanding the above, nothing herein shall supersede or modify
- the terms of any separate license agreement you may have executed
- with Licensor regarding such Contributions.
-
- 6. Trademarks. This License does not grant permission to use the trade
- names, trademarks, service marks, or product names of the Licensor,
- except as required for reasonable and customary use in describing the
- origin of the Work and reproducing the content of the NOTICE file.
-
- 7. Disclaimer of Warranty. Unless required by applicable law or
- agreed to in writing, Licensor provides the Work (and each
- Contributor provides its Contributions) on an "AS IS" BASIS,
- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
- implied, including, without limitation, any warranties or conditions
- of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
- PARTICULAR PURPOSE. You are solely responsible for determining the
- appropriateness of using or redistributing the Work and assume any
- risks associated with Your exercise of permissions under this License.
-
- 8. Limitation of Liability. In no event and under no legal theory,
- whether in tort (including negligence), contract, or otherwise,
- unless required by applicable law (such as deliberate and grossly
- negligent acts) or agreed to in writing, shall any Contributor be
- liable to You for damages, including any direct, indirect, special,
- incidental, or consequential damages of any character arising as a
- result of this License or out of the use or inability to use the
- Work (including but not limited to damages for loss of goodwill,
- work stoppage, computer failure or malfunction, or any and all
- other commercial damages or losses), even if such Contributor
- has been advised of the possibility of such damages.
-
- 9. Accepting Warranty or Additional Liability. While redistributing
- the Work or Derivative Works thereof, You may choose to offer,
- and charge a fee for, acceptance of support, warranty, indemnity,
- or other liability obligations and/or rights consistent with this
- License. However, in accepting such obligations, You may act only
- on Your own behalf and on Your sole responsibility, not on behalf
- of any other Contributor, and only if You agree to indemnify,
- defend, and hold each Contributor harmless for any liability
- incurred by, or claims asserted against, such Contributor by reason
- of your accepting any such warranty or additional liability.
-
- END OF TERMS AND CONDITIONS
-
- APPENDIX: How to apply the Apache License to your work.
-
- To apply the Apache License to your work, attach the following
- boilerplate notice, with the fields enclosed by brackets "[]"
- replaced with your own identifying information. (Don't include
- the brackets!) The text should be enclosed in the appropriate
- comment syntax for the file format. We also recommend that a
- file or class name and description of purpose be included on the
- same "printed page" as the copyright notice for easier
- identification within third-party archives.
-
- Copyright [yyyy] [name of copyright owner]
-
- Licensed under the Apache License, Version 2.0 (the "License");
- you may not use this file except in compliance with the License.
- You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
- Unless required by applicable law or agreed to in writing, software
- distributed under the License is distributed on an "AS IS" BASIS,
- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- See the License for the specific language governing permissions and
- limitations under the License.
diff --git a/javax.servlet/NOTICE b/javax.servlet/NOTICE
deleted file mode 100644
index 4f02a58..0000000
--- a/javax.servlet/NOTICE
+++ /dev/null
@@ -1,5 +0,0 @@
-Apache Felix Servlet API
-Copyright 2006 The Apache Software Foundation
-
-This product includes software developed at
-The Apache Software Foundation (http://www.apache.org/).
diff --git a/javax.servlet/pom.xml b/javax.servlet/pom.xml
deleted file mode 100644
index 4ebd990..0000000
--- a/javax.servlet/pom.xml
+++ /dev/null
@@ -1,51 +0,0 @@
-<!--
- Licensed to the Apache Software Foundation (ASF) under one
- or more contributor license agreements. See the NOTICE file
- distributed with this work for additional information
- regarding copyright ownership. The ASF licenses this file
- to you under the Apache License, Version 2.0 (the
- "License"); you may not use this file except in compliance
- with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
- Unless required by applicable law or agreed to in writing,
- software distributed under the License is distributed on an
- "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- KIND, either express or implied. See the License for the
- specific language governing permissions and limitations
- under the License.
--->
-<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
- <parent>
- <groupId>org.apache.felix</groupId>
- <artifactId>felix</artifactId>
- <version>1.0.4</version>
- <relativePath>../pom/pom.xml</relativePath>
- </parent>
- <modelVersion>4.0.0</modelVersion>
- <name>Servlet 2.1 API</name>
- <description>Servlet 2.1 API</description>
- <version>1.0.1-SNAPSHOT</version>
- <artifactId>javax.servlet</artifactId>
- <packaging>bundle</packaging>
- <build>
- <plugins>
- <plugin>
- <groupId>org.apache.felix</groupId>
- <artifactId>maven-bundle-plugin</artifactId>
- <version>2.0.0</version>
- <extensions>true</extensions>
- <configuration>
- <instructions>
- <Bundle-Copyright>Copyright 1999,2005 The Apache Software Foundation</Bundle-Copyright>
- <Bundle-Vendor>The Apache Software Foundation</Bundle-Vendor>
- <Bundle-Category>servlet</Bundle-Category>
- <Export-Package>javax.servlet;specification-version="2.1",javax.servlet.http;specification-version="2.1"</Export-Package>
- <Import-Package>!javax.servlet.*,*</Import-Package>
- </instructions>
- </configuration>
- </plugin>
- </plugins>
- </build>
-</project>
diff --git a/javax.servlet/src/main/java/javax/servlet/GenericServlet.java b/javax.servlet/src/main/java/javax/servlet/GenericServlet.java
deleted file mode 100644
index 487b256..0000000
--- a/javax.servlet/src/main/java/javax/servlet/GenericServlet.java
+++ /dev/null
@@ -1,308 +0,0 @@
-/*
- * Copyright 1999,2005 The Apache Software Foundation.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package javax.servlet;
-
-import java.io.IOException;
-import java.util.Enumeration;
-
-/**
- *
- * Defines a generic, protocol-independent
- * servlet. To write an HTTP servlet for use on the
- * Web, extend {@link javax.servlet.http.HttpServlet} instead.
- *
- * <p><code>GenericServlet</code> implements the <code>Servlet</code>
- * and <code>ServletConfig</code> interfaces. <code>GenericServlet</code>
- * may be directly extended by a servlet, although it's more common to extend
- * a protocol-specific subclass such as <code>HttpServlet</code>.
- *
- * <p><code>GenericServlet</code> makes writing servlets
- * easier. It provides simple versions of the lifecycle methods
- * <code>init</code> and <code>destroy</code> and of the methods
- * in the <code>ServletConfig</code> interface. <code>GenericServlet</code>
- * also implements the <code>log</code> method, declared in the
- * <code>ServletContext</code> interface.
- *
- * <p>To write a generic servlet, you need only
- * override the abstract <code>service</code> method.
- *
- *
- * @author Various
- * @version $Version$
- *
- *
- *
- */
-
-
-public abstract class GenericServlet
- implements Servlet, ServletConfig, java.io.Serializable
-{
-
- private transient ServletConfig config;
-
-
- /**
- *
- * Does nothing. All of the servlet initialization
- * is done by one of the <code>init</code> methods.
- *
- */
-
- public GenericServlet() { }
-
-
-
- /**
- * Called by the servlet container to indicate to a servlet that the
- * servlet is being taken out of service. See {@link Servlet#destroy}.
- *
- *
- */
-
- public void destroy() {
- }
-
-
-
- /**
- * Returns a <code>String</code> containing the value of the named
- * initialization parameter, or <code>null</code> if the parameter does
- * not exist. See {@link ServletConfig#getInitParameter}.
- *
- * <p>This method is supplied for convenience. It gets the
- * value of the named parameter from the servlet's
- * <code>ServletConfig</code> object.
- *
- * @param name a <code>String</code> specifying the name
- * of the initialization parameter
- *
- * @return String a <code>String</code> containing the value
- * of the initalization parameter
- *
- */
-
- public String getInitParameter(String name) {
- return getServletConfig().getInitParameter(name);
- }
-
-
-
- /**
- * Returns the names of the servlet's initialization parameters
- * as an <code>Enumeration</code> of <code>String</code> objects,
- * or an empty <code>Enumeration</code> if the servlet has no
- * initialization parameters. See {@link
- * ServletConfig#getInitParameterNames}.
- *
- * <p>This method is supplied for convenience. It gets the
- * parameter names from the servlet's <code>ServletConfig</code> object.
- *
- *
- * @return Enumeration an enumeration of <code>String</code>
- * objects containing the names of
- * the servlet's initialization parameters
- *
- */
-
- public Enumeration getInitParameterNames() {
- return getServletConfig().getInitParameterNames();
- }
-
-
-
-
-
- /**
- * Returns this servlet's {@link ServletConfig} object.
- *
- * @return ServletConfig the <code>ServletConfig</code> object
- * that initialized this servlet
- *
- */
-
- public ServletConfig getServletConfig() {
- return config;
- }
-
-
-
-
- /**
- * Returns a reference to the {@link ServletContext} in which this servlet
- * is running. See {@link ServletConfig#getServletContext}.
- *
- * <p>This method is supplied for convenience. It gets the
- * context from the servlet's <code>ServletConfig</code> object.
- *
- *
- * @return ServletContext the <code>ServletContext</code> object
- * passed to this servlet by the <code>init</code>
- * method
- *
- */
-
- public ServletContext getServletContext() {
- return getServletConfig().getServletContext();
- }
-
-
-
-
-
- /**
- * Returns information about the servlet, such as
- * author, version, and copyright.
- * By default, this method returns an empty string. Override this method
- * to have it return a meaningful value. See {@link
- * Servlet#getServletInfo}.
- *
- *
- * @return String information about this servlet, by default an
- * empty string
- *
- */
-
- public String getServletInfo() {
- return "";
- }
-
-
-
-
- /**
- *
- * Called by the servlet container to indicate to a servlet that the
- * servlet is being placed into service. See {@link Servlet#init}.
- *
- * <p>This implementation stores the {@link ServletConfig}
- * object it receives from the servlet container for later use.
- * When overriding this form of the method, call
- * <code>super.init(config)</code>.
- *
- * @param config the <code>ServletConfig</code> object
- * that contains configutation
- * information for this servlet
- *
- * @exception ServletException if an exception occurs that
- * interrupts the servlet's normal
- * operation
- *
- *
- * @see UnavailableException
- *
- */
-
- public void init(ServletConfig config) throws ServletException {
- this.config = config;
- this.init();
- }
-
-
-
-
-
- /**
- *
- * A convenience method which can be overridden so that there's no need
- * to call <code>super.init(config)</code>.
- *
- * <p>Instead of overriding {@link #init(ServletConfig)}, simply override
- * this method and it will be called by
- * <code>GenericServlet.init(ServletConfig config)</code>.
- * The <code>ServletConfig</code> object can still be retrieved via {@link
- * #getServletConfig}.
- *
- * @exception ServletException if an exception occurs that
- * interrupts the servlet's
- * normal operation
- *
- */
-
- public void init() throws ServletException {
-
- }
-
-
-
-
- /**
- *
- * Writes the specified message to a servlet log file, prepended by the
- * servlet's name. See {@link ServletContext#log(String)}.
- *
- * @param msg a <code>String</code> specifying
- * the message to be written to the log file
- *
- */
-
- public void log(String msg) {
- getServletContext().log(getClass().getName() + ": "+ msg);
- }
-
-
-
-
- /**
- * Writes an explanatory message and a stack trace
- * for a given <code>Throwable</code> exception
- * to the servlet log file, prepended by the servlet's name.
- * See {@link ServletContext#log(String, Throwable)}.
- *
- *
- * @param message a <code>String</code> that describes
- * the error or exception
- *
- * @param t the <code>java.lang.Throwable</code> error
- * or exception
- *
- *
- */
-
- public void log(String message, Throwable t) {
- getServletContext().log(getClass().getName() + ": " + message, t);
- }
-
-
-
- /**
- * Called by the servlet container to allow the servlet to respond to
- * a request. See {@link Servlet#service}.
- *
- * <p>This method is declared abstract so subclasses, such as
- * <code>HttpServlet</code>, must override it.
- *
- *
- *
- * @param req the <code>ServletRequest</code> object
- * that contains the client's request
- *
- * @param res the <code>ServletResponse</code> object
- * that will contain the servlet's response
- *
- * @exception ServletException if an exception occurs that
- * interferes with the servlet's
- * normal operation occurred
- *
- * @exception IOException if an input or output
- * exception occurs
- *
- */
-
- public abstract void service(ServletRequest req, ServletResponse res)
- throws ServletException, IOException;
-}
diff --git a/javax.servlet/src/main/java/javax/servlet/RequestDispatcher.java b/javax.servlet/src/main/java/javax/servlet/RequestDispatcher.java
deleted file mode 100644
index 73687a1..0000000
--- a/javax.servlet/src/main/java/javax/servlet/RequestDispatcher.java
+++ /dev/null
@@ -1,132 +0,0 @@
-/*
- * Copyright 1999,2005 The Apache Software Foundation.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-
-package javax.servlet;
-
-import java.io.IOException;
-
-
-/**
- * Defines an object that receives requests from the client
- * and sends them to any resource (such as a servlet,
- * HTML file, or JSP file) on the server. The servlet
- * container creates the <code>RequestDispatcher</code> object,
- * which is used as a wrapper around a server resource located
- * at a particular path or given by a particular name.
- *
- * <p>This interface is intended to wrap servlets,
- * but a servlet container can create <code>RequestDispatcher</code>
- * objects to wrap any type of resource.
- *
- * @author Various
- * @version $Version$
- *
- * @see ServletContext#getRequestDispatcher(java.lang.String)
- *
- */
-
-public interface RequestDispatcher {
-
-
-
-
-
-/**
- * Forwards a request from
- * a servlet to another resource (servlet, JSP file, or
- * HTML file) on the server. This method allows
- * one servlet to do preliminary processing of
- * a request and another resource to generate
- * the response.
- *
- * <p>For a <code>RequestDispatcher</code> obtained via
- * <code>getRequestDispatcher()</code>, the <code>ServletRequest</code>
- * object has its path elements and parameters adjusted to match
- * the path of the target resource.
- *
- * <p><code>forward</code> should be called before the response has been
- * committed to the client (before response body output has been flushed).
- * If the response already has been committed, this method throws
- * an <code>IllegalStateException</code>.
- * Uncommitted output in the response buffer is automatically cleared
- * before the forward.
- *
- * <p>The request and response parameters must be the same
- * objects as were passed to the calling servlet's service method.
- *
- *
- * @param request a {@link ServletRequest} object
- * that represents the request the client
- * makes of the servlet
- *
- * @param response a {@link ServletResponse} object
- * that represents the response the servlet
- * returns to the client
- *
- * @exception ServletException if the target resource throws this exception
- *
- * @exception IOException if the target resource throws this exception
- *
- * @exception IllegalStateException if the response was already committed
- *
- */
-
- public void forward(ServletRequest request, ServletResponse response)
- throws ServletException, IOException;
-
-
-
-
- /**
- *
- * Includes the content of a resource (servlet, JSP page,
- * HTML file) in the response. In essence, this method enables
- * programmatic server-side includes.
- *
- * <p>The {@link ServletResponse} object has its path elements
- * and parameters remain unchanged from the caller's. The included
- * servlet cannot change the response status code or set headers;
- * any attempt to make a change is ignored.
- *
- * <p>The request and response parameters must be the same
- * objects as were passed to the calling servlet's service method.
- *
- *
- * @param request a {@link ServletRequest} object
- * that contains the client's request
- *
- * @param response a {@link ServletResponse} object
- * that contains the servlet's response
- *
- * @exception ServletException if the included resource throws this exception
- *
- * @exception IOException if the included resource throws this exception
- *
- *
- */
-
- public void include(ServletRequest request, ServletResponse response)
- throws ServletException, IOException;
-}
-
-
-
-
-
-
-
-
diff --git a/javax.servlet/src/main/java/javax/servlet/Servlet.java b/javax.servlet/src/main/java/javax/servlet/Servlet.java
deleted file mode 100644
index 1d267a7..0000000
--- a/javax.servlet/src/main/java/javax/servlet/Servlet.java
+++ /dev/null
@@ -1,192 +0,0 @@
-/*
- * Copyright 1999,2005 The Apache Software Foundation.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package javax.servlet;
-
-import java.io.IOException;
-
-
-/**
- * Defines methods that all servlets must implement.
- *
- * <p>A servlet is a small Java program that runs within a Web server.
- * Servlets receive and respond to requests from Web clients,
- * usually across HTTP, the HyperText Transfer Protocol.
- *
- * <p>To implement this interface, you can write a generic servlet
- * that extends
- * <code>javax.servlet.GenericServlet</code> or an HTTP servlet that
- * extends <code>javax.servlet.http.HttpServlet</code>.
- *
- * <p>This interface defines methods to initialize a servlet,
- * to service requests, and to remove a servlet from the server.
- * These are known as life-cycle methods and are called in the
- * following sequence:
- * <ol>
- * <li>The servlet is constructed, then initialized with the <code>init</code> method.
- * <li>Any calls from clients to the <code>service</code> method are handled.
- * <li>The servlet is taken out of service, then destroyed with the
- * <code>destroy</code> method, then garbage collected and finalized.
- * </ol>
- *
- * <p>In addition to the life-cycle methods, this interface
- * provides the <code>getServletConfig</code> method, which the servlet
- * can use to get any startup information, and the <code>getServletInfo</code>
- * method, which allows the servlet to return basic information about itself,
- * such as author, version, and copyright.
- *
- * @author Various
- * @version $Version$
- *
- * @see GenericServlet
- * @see javax.servlet.http.HttpServlet
- *
- */
-
-
-public interface Servlet {
-
- /**
- * Called by the servlet container to indicate to a servlet that the
- * servlet is being placed into service.
- *
- * <p>The servlet container calls the <code>init</code>
- * method exactly once after instantiating the servlet.
- * The <code>init</code> method must complete successfully
- * before the servlet can receive any requests.
- *
- * <p>The servlet container cannot place the servlet into service
- * if the <code>init</code> method
- * <ol>
- * <li>Throws a <code>ServletException</code>
- * <li>Does not return within a time period defined by the Web server
- * </ol>
- *
- *
- * @param config a <code>ServletConfig</code> object
- * containing the servlet's
- * configuration and initialization parameters
- *
- * @exception ServletException if an exception has occurred that
- * interferes with the servlet's normal
- * operation
- *
- * @see UnavailableException
- * @see #getServletConfig
- *
- */
-
- public void init(ServletConfig config) throws ServletException;
-
-
-
- /**
- *
- * Returns a {@link ServletConfig} object, which contains
- * initialization and startup parameters for this servlet.
- * The <code>ServletConfig</code> object returned is the one
- * passed to the <code>init</code> method.
- *
- * <p>Implementations of this interface are responsible for storing the
- * <code>ServletConfig</code> object so that this
- * method can return it. The {@link GenericServlet}
- * class, which implements this interface, already does this.
- *
- * @return the <code>ServletConfig</code> object
- * that initializes this servlet
- *
- * @see #init
- *
- */
-
- public ServletConfig getServletConfig();
-
-
-
- /**
- * Called by the servlet container to allow the servlet to respond to
- * a request.
- *
- * <p>This method is only called after the servlet's <code>init()</code>
- * method has completed successfully.
- *
- * <p> The status code of the response always should be set for a servlet
- * that throws or sends an error.
- *
- *
- * <p>Servlets typically run inside multithreaded servlet containers
- * that can handle multiple requests concurrently. Developers must
- * be aware to synchronize access to any shared resources such as files,
- * network connections, and as well as the servlet's class and instance
- * variables.
- * More information on multithreaded programming in Java is available in
- * <a href="http://java.sun.com/Series/Tutorial/java/threads/multithreaded.html">
- * the Java tutorial on multi-threaded programming</a>.
- *
- *
- * @param req the <code>ServletRequest</code> object that contains
- * the client's request
- *
- * @param res the <code>ServletResponse</code> object that contains
- * the servlet's response
- *
- * @exception ServletException if an exception occurs that interferes
- * with the servlet's normal operation
- *
- * @exception IOException if an input or output exception occurs
- *
- */
-
- public void service(ServletRequest req, ServletResponse res)
- throws ServletException, IOException;
-
-
-
- /**
- * Returns information about the servlet, such
- * as author, version, and copyright.
- *
- * <p>The string that this method returns should
- * be plain text and not markup of any kind (such as HTML, XML,
- * etc.).
- *
- * @return a <code>String</code> containing servlet information
- *
- */
-
- public String getServletInfo();
-
-
-
- /**
- *
- * Called by the servlet container to indicate to a servlet that the
- * servlet is being taken out of service. This method is
- * only called once all threads within the servlet's
- * <code>service</code> method have exited or after a timeout
- * period has passed. After the servlet container calls this
- * method, it will not call the <code>service</code> method again
- * on this servlet.
- *
- * <p>This method gives the servlet an opportunity
- * to clean up any resources that are being held (for example, memory,
- * file handles, threads) and make sure that any persistent state is
- * synchronized with the servlet's current state in memory.
- *
- */
-
- public void destroy();
-}
diff --git a/javax.servlet/src/main/java/javax/servlet/ServletConfig.java b/javax.servlet/src/main/java/javax/servlet/ServletConfig.java
deleted file mode 100644
index 347720a..0000000
--- a/javax.servlet/src/main/java/javax/servlet/ServletConfig.java
+++ /dev/null
@@ -1,81 +0,0 @@
-/*
- * Copyright 1999,2005 The Apache Software Foundation.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package javax.servlet;
-
-import java.util.Enumeration;
-
-
-
-/**
- *
- * A servlet configuration object used by a servlet container
- * used to pass information to a servlet during initialization.
- *
- */
-
-public interface ServletConfig {
-
-
- /**
- * Returns a reference to the {@link ServletContext} in which the caller
- * is executing.
- *
- *
- * @return a {@link ServletContext} object, used
- * by the caller to interact with its servlet
- * container
- *
- * @see ServletContext
- *
- */
-
- public ServletContext getServletContext();
-
- /**
- * Returns a <code>String</code> containing the value of the
- * named initialization parameter, or <code>null</code> if
- * the parameter does not exist.
- *
- * @param name a <code>String</code> specifying the name
- * of the initialization parameter
- *
- * @return a <code>String</code> containing the value
- * of the initialization parameter
- *
- */
-
- public String getInitParameter(String name);
-
-
- /**
- * Returns the names of the servlet's initialization parameters
- * as an <code>Enumeration</code> of <code>String</code> objects,
- * or an empty <code>Enumeration</code> if the servlet has
- * no initialization parameters.
- *
- * @return an <code>Enumeration</code> of <code>String</code>
- * objects containing the names of the servlet's
- * initialization parameters
- *
- *
- *
- */
-
- public Enumeration getInitParameterNames();
-
-
-}
diff --git a/javax.servlet/src/main/java/javax/servlet/ServletContext.java b/javax.servlet/src/main/java/javax/servlet/ServletContext.java
deleted file mode 100644
index 5c7b170..0000000
--- a/javax.servlet/src/main/java/javax/servlet/ServletContext.java
+++ /dev/null
@@ -1,516 +0,0 @@
-/*
- * Copyright 1999,2005 The Apache Software Foundation.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package javax.servlet;
-
-import java.io.InputStream;
-import java.net.URL;
-import java.net.MalformedURLException;
-import java.util.Enumeration;
-
-
-/**
- *
- * Defines a set of methods that a servlet uses to communicate with its
- * servlet container, for example, to get the MIME type of a file, dispatch
- * requests, or write to a log file.
- *
- * <p>There is one context per "web application" per Java Virtual Machine. (A
- * "web application" is a collection of servlets and content installed under a
- * specific subset of the server's URL namespace such as <code>/catalog</code>
- * and possibly installed via a <code>.war</code> file.)
- *
- * <p>In the case of a web
- * application marked "distributed" in its deployment descriptor, there will
- * be one context instance for each virtual machine. In this situation, the
- * context cannot be used as a location to share global information (because
- * the information won't be truly global). Use an external resource like
- * a database instead.
- *
- * <p>The <code>ServletContext</code> object is contained within
- * the {@link ServletConfig} object, which the Web server provides the
- * servlet when the servlet is initialized.
- *
- * @author Various
- * @version $Version$
- *
- * @see Servlet#getServletConfig
- * @see ServletConfig#getServletContext
- *
- */
-
-public interface ServletContext {
-
-
- /**
- * Returns a <code>ServletContext</code> object that
- * corresponds to a specified URL on the server.
- *
- * <p>This method allows servlets to gain
- * access to the context for various parts of the server, and as
- * needed obtain {@link RequestDispatcher} objects from the context.
- * The given path must be begin with "/", is interpreted relative
- * to the server's document root and is matched against the context roots of
- * other web applications hosted on this container.
- *
- * <p>In a security conscious environment, the servlet container may
- * return <code>null</code> for a given URL.
- *
- * @param uripath a <code>String</code> specifying the context path of
- * another web application in the container.
- * @return the <code>ServletContext</code> object that
- * corresponds to the named URL, or null if either
- none exists or the container wishes to restrict
- * this access.
- *
- * @see RequestDispatcher
- *
- */
-
- public ServletContext getContext(String uripath);
-
-
-
- /**
- * Returns the major version of the Java Servlet API that this
- * servlet container supports. All implementations that comply
- * with Version 2.1 must have this method
- * return the integer 2.
- *
- * @return 2
- *
- */
-
- public int getMajorVersion();
-
-
-
- /**
- * Returns the minor version of the Servlet API that this
- * servlet container supports. All implementations that comply
- * with Version 2.1 must have this method
- * return the integer 1.
- *
- * @return 1
- *
- */
-
- public int getMinorVersion();
-
-
-
- /**
- * Returns the MIME type of the specified file, or <code>null</code> if
- * the MIME type is not known. The MIME type is determined
- * by the configuration of the servlet container, and may be specified
- * in a web application deployment descriptor. Common MIME
- * types are <code>"text/html"</code> and <code>"image/gif"</code>.
- *
- *
- * @param file a <code>String</code> specifying the name
- * of a file
- *
- * @return a <code>String</code> specifying the file's MIME type
- *
- */
-
- public String getMimeType(String file);
-
- /**
- * Returns a URL to the resource that is mapped to a specified
- * path. The path must begin with a "/" and is interpreted
- * as relative to the current context root.
- *
- * <p>This method allows the servlet container to make a resource
- * available to servlets from any source. Resources
- * can be located on a local or remote
- * file system, in a database, or in a <code>.war</code> file.
- *
- * <p>The servlet container must implement the URL handlers
- * and <code>URLConnection</code> objects that are necessary
- * to access the resource.
- *
- * <p>This method returns <code>null</code>
- * if no resource is mapped to the pathname.
- *
- * <p>Some containers may allow writing to the URL returned by
- * this method using the methods of the URL class.
- *
- * <p>The resource content is returned directly, so be aware that
- * requesting a <code>.jsp</code> page returns the JSP source code.
- * Use a <code>RequestDispatcher</code> instead to include results of
- * an execution.
- *
- * <p>This method has a different purpose than
- * <code>java.lang.Class.getResource</code>,
- * which looks up resources based on a class loader. This
- * method does not use class loaders.
- *
- * @param path a <code>String</code> specifying
- * the path to the resource
- *
- * @return the resource located at the named path,
- * or <code>null</code> if there is no resource
- * at that path
- *
- * @exception MalformedURLException if the pathname is not given in
- * the correct form
- *
- */
-
- public URL getResource(String path) throws MalformedURLException;
-
-
-
- /**
- * Returns the resource located at the named path as
- * an <code>InputStream</code> object.
- *
- * <p>The data in the <code>InputStream</code> can be
- * of any type or length. The path must be specified according
- * to the rules given in <code>getResource</code>.
- * This method returns <code>null</code> if no resource exists at
- * the specified path.
- *
- * <p>Meta-information such as content length and content type
- * that is available via <code>getResource</code>
- * method is lost when using this method.
- *
- * <p>The servlet container must implement the URL handlers
- * and <code>URLConnection</code> objects necessary to access
- * the resource.
- *
- * <p>This method is different from
- * <code>java.lang.Class.getResourceAsStream</code>,
- * which uses a class loader. This method allows servlet containers
- * to make a resource available
- * to a servlet from any location, without using a class loader.
- *
- *
- * @param path a <code>String</code> specifying the path
- * to the resource
- *
- * @return the <code>InputStream</code> returned to the
- * servlet, or <code>null</code> if no resource
- * exists at the specified path
- *
- *
- */
-
- public InputStream getResourceAsStream(String path);
-
-
-
-
- /**
- *
- * Returns a {@link RequestDispatcher} object that acts
- * as a wrapper for the resource located at the given path.
- * A <code>RequestDispatcher</code> object can be used to forward
- * a request to the resource or to include the resource in a response.
- * The resource can be dynamic or static.
- *
- * <p>The pathname must begin with a "/" and is interpreted as relative
- * to the current context root. Use <code>getContext</code> to obtain
- * a <code>RequestDispatcher</code> for resources in foreign contexts.
- * This method returns <code>null</code> if the <code>ServletContext</code>
- * cannot return a <code>RequestDispatcher</code>.
- *
- * @param path a <code>String</code> specifying the pathname
- * to the resource
- *
- * @return a <code>RequestDispatcher</code> object
- * that acts as a wrapper for the resource
- * at the specified path
- *
- * @see RequestDispatcher
- * @see ServletContext#getContext
- *
- */
-
- public RequestDispatcher getRequestDispatcher(String path);
-
-
-
- /**
- *
- * @deprecated As of Java Servlet API 2.1, with no direct replacement.
- *
- * <p>This method was originally defined to retrieve a servlet
- * from a <code>ServletContext</code>. In this version, this method
- * always returns <code>null</code> and remains only to preserve
- * binary compatibility. This method will be permanently removed
- * in a future version of the Java Servlet API.
- *
- * <p>In lieu of this method, servlets can share information using the
- * <code>ServletContext</code> class and can perform shared business logic
- * by invoking methods on common non-servlet classes.
- *
- */
-
- public Servlet getServlet(String name) throws ServletException;
-
-
-
-
-
-
- /**
- *
- * @deprecated As of Java Servlet API 2.0, with no replacement.
- *
- * <p>This method was originally defined to return an <code>Enumeration</code>
- * of all the servlets known to this servlet context. In this
- * version, this method always returns an empty enumeration and
- * remains only to preserve binary compatibility. This method
- * will be permanently removed in a future version of the Java
- * Servlet API.
- *
- */
-
- public Enumeration getServlets();
-
-
-
-
-
-
- /**
- * @deprecated As of Java Servlet API 2.1, with no replacement.
- *
- * <p>This method was originally defined to return an
- * <code>Enumeration</code>
- * of all the servlet names known to this context. In this version,
- * this method always returns an empty <code>Enumeration</code> and
- * remains only to preserve binary compatibility. This method will
- * be permanently removed in a future version of the Java Servlet API.
- *
- */
-
- public Enumeration getServletNames();
-
-
-
-
-
- /**
- *
- * Writes the specified message to a servlet log file, usually
- * an event log. The name and type of the servlet log file is
- * specific to the servlet container.
- *
- *
- * @param msg a <code>String</code> specifying the
- * message to be written to the log file
- *
- */
-
- public void log(String msg);
-
-
-
-
-
- /**
- * @deprecated As of Java Servlet API 2.1, use
- * {@link #log(String message, Throwable throwable)}
- * instead.
- *
- * <p>This method was originally defined to write an
- * exception's stack trace and an explanatory error message
- * to the servlet log file.
- *
- */
-
- public void log(Exception exception, String msg);
-
-
-
-
-
- /**
- * Writes an explanatory message and a stack trace
- * for a given <code>Throwable</code> exception
- * to the servlet log file. The name and type of the servlet log
- * file is specific to the servlet container, usually an event log.
- *
- *
- * @param message a <code>String</code> that
- * describes the error or exception
- *
- * @param throwable the <code>Throwable</code> error
- * or exception
- *
- */
-
- public void log(String message, Throwable throwable);
-
-
-
-
-
- /**
- * Returns a <code>String</code> containing the real path
- * for a given virtual path. For example, the path "/index.html"
- * returns the absolute file path on the server's filesystem would be
- * served by a request for "http://host/contextPath/index.html",
- * where contextPath is the context path of this ServletContext..
- *
- * <p>The real path returned will be in a form
- * appropriate to the computer and operating system on
- * which the servlet container is running, including the
- * proper path separators. This method returns <code>null</code>
- * if the servlet container cannot translate the virtual path
- * to a real path for any reason (such as when the content is
- * being made available from a <code>.war</code> archive).
- *
- *
- * @param path a <code>String</code> specifying a virtual path
- *
- *
- * @return a <code>String</code> specifying the real path,
- * or null if the translation cannot be performed
- *
- *
- */
-
- public String getRealPath(String path);
-
-
-
-
- /**
- * Returns the name and version of the servlet container on which
- * the servlet is running.
- *
- * <p>The form of the returned string is
- * <i>servername</i>/<i>versionnumber</i>.
- * For example, the JavaServer Web Development Kit may return the string
- * <code>JavaServer Web Dev Kit/1.0</code>.
- *
- * <p>The servlet container may return other optional information
- * after the primary string in parentheses, for example,
- * <code>JavaServer Web Dev Kit/1.0 (JDK 1.1.6; Windows NT 4.0 x86)</code>.
- *
- *
- * @return a <code>String</code> containing at least the
- * servlet container name and version number
- *
- */
-
- public String getServerInfo();
-
-
-
-
- /**
- * Returns the servlet container attribute with the given name,
- * or <code>null</code> if there is no attribute by that name.
- * An attribute allows a servlet container to give the
- * servlet additional information not
- * already provided by this interface. See your
- * server documentation for information about its attributes.
- * A list of supported attributes can be retrieved using
- * <code>getAttributeNames</code>.
- *
- * <p>The attribute is returned as a <code>java.lang.Object</code>
- * or some subclass.
- * Attribute names should follow the same convention as package
- * names. The Java Servlet API specification reserves names
- * matching <code>java.*</code>, <code>javax.*</code>,
- * and <code>sun.*</code>.
- *
- *
- * @param name a <code>String</code> specifying the name
- * of the attribute
- *
- * @return an <code>Object</code> containing the value
- * of the attribute, or <code>null</code>
- * if no attribute exists matching the given
- * name
- *
- * @see ServletContext#getAttributeNames
- *
- */
-
- public Object getAttribute(String name);
-
-
-
-
- /**
- * Returns an <code>Enumeration</code> containing the
- * attribute names available
- * within this servlet context. Use the
- * {@link #getAttribute} method with an attribute name
- * to get the value of an attribute.
- *
- * @return an <code>Enumeration</code> of attribute
- * names
- *
- * @see #getAttribute
- *
- */
-
- public Enumeration getAttributeNames();
-
-
-
-
- /**
- *
- * Binds an object to a given attribute name in this servlet context. If
- * the name specified is already used for an attribute, this
- * method will replace the attribute with the new to the new attribute.
- *
- * <p>Attribute names should follow the same convention as package
- * names. The Java Servlet API specification reserves names
- * matching <code>java.*</code>, <code>javax.*</code>, and
- * <code>sun.*</code>.
- *
- *
- * @param name a <code>String</code> specifying the name
- * of the attribute
- *
- * @param object an <code>Object</code> representing the
- * attribute to be bound
- *
- *
- *
- */
-
- public void setAttribute(String name, Object object);
-
-
-
-
-
- /**
- * Removes the attribute with the given name from
- * the servlet context. After removal, subsequent calls to
- * {@link #getAttribute} to retrieve the attribute's value
- * will return <code>null</code>.
- *
- *
- * @param name a <code>String</code> specifying the name
- * of the attribute to be removed
- *
- */
-
- public void removeAttribute(String name);
-}
-
-
diff --git a/javax.servlet/src/main/java/javax/servlet/ServletException.java b/javax.servlet/src/main/java/javax/servlet/ServletException.java
deleted file mode 100644
index b442440..0000000
--- a/javax.servlet/src/main/java/javax/servlet/ServletException.java
+++ /dev/null
@@ -1,142 +0,0 @@
-/*
- * Copyright 1999,2005 The Apache Software Foundation.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package javax.servlet;
-
-
-/**
- * Defines a general exception a servlet can throw when it
- * encounters difficulty.
- *
- * @author Various
- * @version $Version$
- *
- */
-
-
-public class ServletException extends Exception {
-
- private Throwable rootCause;
-
-
-
-
-
- /**
- * Constructs a new servlet exception.
- *
- */
-
- public ServletException() {
- super();
- }
-
-
-
-
-
- /**
- * Constructs a new servlet exception with the
- * specified message. The message can be written
- * to the server log and/or displayed for the user.
- *
- * @param message a <code>String</code>
- * specifying the text of
- * the exception message
- *
- */
-
- public ServletException(String message) {
- super(message);
- }
-
-
-
-
-
- /**
- * Constructs a new servlet exception when the servlet
- * needs to throw an exception and include a message
- * about the "root cause" exception that interfered with its
- * normal operation, including a description message.
- *
- *
- * @param message a <code>String</code> containing
- * the text of the exception message
- *
- * @param rootCause the <code>Throwable</code> exception
- * that interfered with the servlet's
- * normal operation, making this servlet
- * exception necessary
- *
- */
-
- public ServletException(String message, Throwable rootCause) {
- super(message);
- this.rootCause = rootCause;
- }
-
-
-
-
-
- /**
- * Constructs a new servlet exception when the servlet
- * needs to throw an exception and include a message
- * about the "root cause" exception that interfered with its
- * normal operation. The exception's message is based on the localized
- * message of the underlying exception.
- *
- * <p>This method calls the <code>getLocalizedMessage</code> method
- * on the <code>Throwable</code> exception to get a localized exception
- * message. When subclassing <code>ServletException</code>,
- * this method can be overridden to create an exception message
- * designed for a specific locale.
- *
- * @param rootCause the <code>Throwable</code> exception
- * that interfered with the servlet's
- * normal operation, making the servlet exception
- * necessary
- *
- */
-
- public ServletException(Throwable rootCause) {
- super(rootCause.getLocalizedMessage());
- this.rootCause = rootCause;
- }
-
-
-
-
-
- /**
- * Returns the exception that caused this servlet exception.
- *
- *
- * @return the <code>Throwable</code>
- * that caused this servlet exception
- *
- */
-
- public Throwable getRootCause() {
- return rootCause;
- }
-}
-
-
-
-
-
diff --git a/javax.servlet/src/main/java/javax/servlet/ServletInputStream.java b/javax.servlet/src/main/java/javax/servlet/ServletInputStream.java
deleted file mode 100644
index ba3ac20..0000000
--- a/javax.servlet/src/main/java/javax/servlet/ServletInputStream.java
+++ /dev/null
@@ -1,106 +0,0 @@
-/*
- * Copyright 1999,2005 The Apache Software Foundation.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package javax.servlet;
-
-import java.io.InputStream;
-import java.io.IOException;
-
-/**
- *
- * Provides an input stream for reading binary data from a client
- * request, including an efficient <code>readLine</code> method
- * for reading data one line at a time. With some protocols, such
- * as HTTP POST and PUT, a <code>ServletInputStream</code>
- * object can be used to read data sent from the client.
- *
- * <p>A <code>ServletInputStream</code> object is normally retrieved via
- * the {@link ServletRequest#getInputStream} method.
- *
- *
- * <p>This is an abstract class that a servlet container implements.
- * Subclasses of this class
- * must implement the <code>java.io.InputStream.read()</code> method.
- *
- *
- * @author Various
- * @version $Version$
- *
- * @see ServletRequest
- *
- */
-
-public abstract class ServletInputStream extends InputStream {
-
-
-
- /**
- * Does nothing, because this is an abstract class.
- *
- */
-
- protected ServletInputStream() { }
-
-
-
-
- /**
- *
- * Reads the input stream, one line at a time. Starting at an
- * offset, reads bytes into an array, until it reads a certain number
- * of bytes or reaches a newline character, which it reads into the
- * array as well.
- *
- * <p>This method returns -1 if it reaches the end of the input
- * stream before reading the maximum number of bytes.
- *
- *
- *
- * @param b an array of bytes into which data is read
- *
- * @param off an integer specifying the character at which
- * this method begins reading
- *
- * @param len an integer specifying the maximum number of
- * bytes to read
- *
- * @return an integer specifying the actual number of bytes
- * read, or -1 if the end of the stream is reached
- *
- * @exception IOException if an input or output exception has occurred
- *
- */
-
- public int readLine(byte[] b, int off, int len) throws IOException {
-
- if (len <= 0) {
- return 0;
- }
- int count = 0, c;
-
- while ((c = read()) != -1) {
- b[off++] = (byte)c;
- count++;
- if (c == '\n' || count == len) {
- break;
- }
- }
- return count > 0 ? count : -1;
- }
-}
-
-
-
diff --git a/javax.servlet/src/main/java/javax/servlet/ServletOutputStream.java b/javax.servlet/src/main/java/javax/servlet/ServletOutputStream.java
deleted file mode 100644
index c29e7cf..0000000
--- a/javax.servlet/src/main/java/javax/servlet/ServletOutputStream.java
+++ /dev/null
@@ -1,364 +0,0 @@
-/*
- * Copyright 1999,2005 The Apache Software Foundation.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package javax.servlet;
-
-import java.io.OutputStream;
-import java.io.IOException;
-import java.io.CharConversionException;
-import java.text.MessageFormat;
-import java.util.ResourceBundle;
-
-/**
- * Provides an output stream for sending binary data to the
- * client. A <code>ServletOutputStream</code> object is normally retrieved
- * via the {@link ServletResponse#getOutputStream} method.
- *
- * <p>This is an abstract class that the servlet container implements.
- * Subclasses of this class
- * must implement the <code>java.io.OutputStream.write(int)</code>
- * method.
- *
- *
- * @author Various
- * @version $Version$
- *
- * @see ServletResponse
- *
- */
-
-public abstract class ServletOutputStream extends OutputStream {
-
- private static final String LSTRING_FILE = "javax.servlet.LocalStrings";
- private static ResourceBundle lStrings =
- ResourceBundle.getBundle(LSTRING_FILE);
-
-
-
- /**
- *
- * Does nothing, because this is an abstract class.
- *
- */
-
- protected ServletOutputStream() { }
-
-
- /**
- * Writes a <code>String</code> to the client,
- * without a carriage return-line feed (CRLF)
- * character at the end.
- *
- *
- * @param s the <code>String</code to send to the client
- *
- * @exception IOException if an input or output exception occurred
- *
- */
-
- public void print(String s) throws IOException {
- if (s==null) s="null";
- int len = s.length();
- for (int i = 0; i < len; i++) {
- char c = s.charAt (i);
-
- //
- // XXX NOTE: This is clearly incorrect for many strings,
- // but is the only consistent approach within the current
- // servlet framework. It must suffice until servlet output
- // streams properly encode their output.
- //
- if ((c & 0xff00) != 0) { // high order byte must be zero
- String errMsg = lStrings.getString("err.not_iso8859_1");
- Object[] errArgs = new Object[1];
- errArgs[0] = new Character(c);
- errMsg = MessageFormat.format(errMsg, errArgs);
- throw new CharConversionException(errMsg);
- }
- write (c);
- }
- }
-
-
-
- /**
- * Writes a <code>boolean</code> value to the client,
- * with no carriage return-line feed (CRLF)
- * character at the end.
- *
- * @param b the <code>boolean</code> value
- * to send to the client
- *
- * @exception IOException if an input or output exception occurred
- *
- */
-
- public void print(boolean b) throws IOException {
- String msg;
- if (b) {
- msg = lStrings.getString("value.true");
- } else {
- msg = lStrings.getString("value.false");
- }
- print(msg);
- }
-
-
-
- /**
- * Writes a character to the client,
- * with no carriage return-line feed (CRLF)
- * at the end.
- *
- * @param c the character to send to the client
- *
- * @exception IOException if an input or output exception occurred
- *
- */
-
- public void print(char c) throws IOException {
- print(String.valueOf(c));
- }
-
-
-
-
- /**
- *
- * Writes an int to the client,
- * with no carriage return-line feed (CRLF)
- * at the end.
- *
- * @param i the int to send to the client
- *
- * @exception IOException if an input or output exception occurred
- *
- */
-
- public void print(int i) throws IOException {
- print(String.valueOf(i));
- }
-
-
-
-
- /**
- *
- * Writes a <code>long</code> value to the client,
- * with no carriage return-line feed (CRLF) at the end.
- *
- * @param l the <code>long</code> value
- * to send to the client
- *
- * @exception IOException if an input or output exception
- * occurred
- *
- */
-
- public void print(long l) throws IOException {
- print(String.valueOf(l));
- }
-
-
-
- /**
- *
- * Writes a <code>float</code> value to the client,
- * with no carriage return-line feed (CRLF) at the end.
- *
- * @param f the <code>float</code> value
- * to send to the client
- *
- * @exception IOException if an input or output exception occurred
- *
- *
- */
-
- public void print(float f) throws IOException {
- print(String.valueOf(f));
- }
-
-
-
- /**
- *
- * Writes a <code>double</code> value to the client,
- * with no carriage return-line feed (CRLF) at the end.
- *
- * @param d the <code>double</code> value
- * to send to the client
- *
- * @exception IOException if an input or output exception occurred
- *
- */
-
- public void print(double d) throws IOException {
- print(String.valueOf(d));
- }
-
-
-
- /**
- * Writes a carriage return-line feed (CRLF)
- * to the client.
- *
- *
- *
- * @exception IOException if an input or output exception occurred
- *
- */
-
- public void println() throws IOException {
- print("\r\n");
- }
-
-
-
- /**
- * Writes a <code>String</code> to the client,
- * followed by a carriage return-line feed (CRLF).
- *
- *
- * @param s the </code>String</code> to write to the client
- *
- * @exception IOException if an input or output exception occurred
- *
- */
-
- public void println(String s) throws IOException {
- print(s);
- println();
- }
-
-
-
-
- /**
- *
- * Writes a <code>boolean</code> value to the client,
- * followed by a
- * carriage return-line feed (CRLF).
- *
- *
- * @param b the <code>boolean</code> value
- * to write to the client
- *
- * @exception IOException if an input or output exception occurred
- *
- */
-
- public void println(boolean b) throws IOException {
- print(b);
- println();
- }
-
-
-
- /**
- *
- * Writes a character to the client, followed by a carriage
- * return-line feed (CRLF).
- *
- * @param c the character to write to the client
- *
- * @exception IOException if an input or output exception occurred
- *
- */
-
- public void println(char c) throws IOException {
- print(c);
- println();
- }
-
-
-
- /**
- *
- * Writes an int to the client, followed by a
- * carriage return-line feed (CRLF) character.
- *
- *
- * @param i the int to write to the client
- *
- * @exception IOException if an input or output exception occurred
- *
- */
-
- public void println(int i) throws IOException {
- print(i);
- println();
- }
-
-
-
- /**
- *
- * Writes a <code>long</code> value to the client, followed by a
- * carriage return-line feed (CRLF).
- *
- *
- * @param l the <code>long</code> value to write to the client
- *
- * @exception IOException if an input or output exception occurred
- *
- */
-
- public void println(long l) throws IOException {
- print(l);
- println();
- }
-
-
-
- /**
- *
- * Writes a <code>float</code> value to the client,
- * followed by a carriage return-line feed (CRLF).
- *
- * @param f the <code>float</code> value
- * to write to the client
- *
- *
- * @exception IOException if an input or output exception
- * occurred
- *
- */
-
- public void println(float f) throws IOException {
- print(f);
- println();
- }
-
-
-
- /**
- *
- * Writes a <code>double</code> value to the client,
- * followed by a carriage return-line feed (CRLF).
- *
- *
- * @param d the <code>double</code> value
- * to write to the client
- *
- * @exception IOException if an input or output exception occurred
- *
- */
-
- public void println(double d) throws IOException {
- print(d);
- println();
- }
-}
diff --git a/javax.servlet/src/main/java/javax/servlet/ServletRequest.java b/javax.servlet/src/main/java/javax/servlet/ServletRequest.java
deleted file mode 100644
index 039c222..0000000
--- a/javax.servlet/src/main/java/javax/servlet/ServletRequest.java
+++ /dev/null
@@ -1,393 +0,0 @@
-/*
- * Copyright 1999,2005 The Apache Software Foundation.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package javax.servlet;
-
-import java.io.BufferedReader;
-import java.io.IOException;
-import java.util.Enumeration;
-
-
-
-/**
- * Defines an object to provide client request information to a servlet. The
- * servlet container creates a <code>ServletRequest</code> object and passes
- * it as an argument to the servlet's <code>service</code> method.
- *
- * <p>A <code>ServletRequest</code> object provides data including
- * parameter name and values, attributes, and an input stream.
- * Interfaces that extend <code>ServletRequest</code> can provide
- * additional protocol-specific data (for example, HTTP data is
- * provided by {@link javax.servlet.http.HttpServletRequest}.
- *
- * @author Various
- * @version $Version$
- *
- * @see javax.servlet.http.HttpServletRequest
- *
- */
-
-public interface ServletRequest {
-
-
-
-
- /**
- *
- * Returns the value of the named attribute as an <code>Object</code>,
- * or <code>null</code> if no attribute of the given name exists.
- *
- * <p> Attributes can be set two ways. The servlet container may set
- * attributes to make available custom information about a request.
- * For example, for requests made using HTTPS, the attribute
- * <code>javax.servlet.request.X509Certificate</code> can be used to
- * retrieve information on the certificate of the client. Attributes
- * can also be set programatically using
- * {@link ServletRequest#setAttribute}. This allows information to be
- * embedded into a request before a {@link RequestDispatcher} call.
- *
- * <p>Attribute names should follow the same conventions as package
- * names. This specification reserves names matching <code>java.*</code>,
- * <code>javax.*</code>, and <code>sun.*</code>.
- *
- * @param name a <code>String</code> specifying the name of
- * the attribute
- *
- * @return an <code>Object</code> containing the value
- * of the attribute, or <code>null</code> if
- * the attribute does not exist
- *
- */
-
- public Object getAttribute(String name);
-
-
-
- /**
- * Returns an <code>Enumeration</code> containing the
- * names of the attributes available to this request.
- * This method returns an empty <code>Enumeration</code>
- * if the request has no attributes available to it.
- *
- *
- * @return an <code>Enumeration</code> of strings
- * containing the names
- * of the request's attributes
- *
- */
-
- public Enumeration getAttributeNames();
-
-
-
-
- /**
- * Returns the name of the character encoding used in the body of this
- * request. This method returns <code>null</code> if the request
- * does not specify a character encoding
- *
- *
- * @return a <code>String</code> containing the name of
- * the chararacter encoding, or <code>null</code>
- * if the request does not specify a character encoding
- *
- */
-
- public String getCharacterEncoding();
-
-
-
- /**
- * Returns the length, in bytes, of the request body
- * and made available by the input stream, or -1 if the
- * length is not known. For HTTP servlets, same as the value
- * of the CGI variable CONTENT_LENGTH.
- *
- * @return an integer containing the length of the
- * request body or -1 if the length is not known
- *
- */
-
- public int getContentLength();
-
-
-
-
- /**
- * Returns the MIME type of the body of the request, or
- * <code>null</code> if the type is not known. For HTTP servlets,
- * same as the value of the CGI variable CONTENT_TYPE.
- *
- * @return a <code>String</code> containing the name
- * of the MIME type of
- * the request, or null if the type is not known
- *
- */
-
- public String getContentType();
-
-
-
-
- /**
- * Retrieves the body of the request as binary data using
- * a {@link ServletInputStream}. Either this method or
- * {@link #getReader} may be called to read the body, not both.
- *
- * @return a {@link ServletInputStream} object containing
- * the body of the request
- *
- * @exception IllegalStateException if the {@link #getReader} method
- * has already been called for this request
- *
- * @exception IOException if an input or output exception occurred
- *
- */
-
- public ServletInputStream getInputStream() throws IOException;
-
-
-
-
- /**
- * Returns the value of a request parameter as a <code>String</code>,
- * or <code>null</code> if the parameter does not exist. Request parameters
- * are extra information sent with the request. For HTTP servlets,
- * parameters are contained in the query string or posted form data.
- *
- * <p>You should only use this method when you are sure the
- * parameter has only one value. If the parameter might have
- * more than one value, use {@link #getParameterValues}.
- *
- * <p>If you use this method with a multivalued
- * parameter, the value returned is equal to the first value
- * in the array returned by <code>getParameterValues</code>.
- *
- * <p>If the parameter data was sent in the request body, such as occurs
- * with an HTTP POST request, then reading the body directly via {@link
- * #getInputStream} or {@link #getReader} can interfere
- * with the execution of this method.
- *
- * @param name a <code>String</code> specifying the
- * name of the parameter
- *
- * @return a <code>String</code> representing the
- * single value of the parameter
- *
- * @see #getParameterValues
- *
- */
-
- public String getParameter(String name);
-
-
-
-
- /**
- *
- * Returns an <code>Enumeration</code> of <code>String</code>
- * objects containing the names of the parameters contained
- * in this request. If the request has
- * no parameters, the method returns an
- * empty <code>Enumeration</code>.
- *
- * @return an <code>Enumeration</code> of <code>String</code>
- * objects, each <code>String</code> containing
- * the name of a request parameter; or an
- * empty <code>Enumeration</code> if the
- * request has no parameters
- *
- */
-
- public Enumeration getParameterNames();
-
-
-
-
- /**
- * Returns an array of <code>String</code> objects containing
- * all of the values the given request parameter has, or
- * <code>null</code> if the parameter does not exist.
- *
- * <p>If the parameter has a single value, the array has a length
- * of 1.
- *
- * @param name a <code>String</code> containing the name of
- * the parameter whose value is requested
- *
- * @return an array of <code>String</code> objects
- * containing the parameter's values
- *
- * @see #getParameter
- *
- */
-
- public String[] getParameterValues(String name);
-
- /**
- * Returns the name and version of the protocol the request uses
- * in the form <i>protocol/majorVersion.minorVersion</i>, for
- * example, HTTP/1.1. For HTTP servlets, the value
- * returned is the same as the value of the CGI variable
- * <code>SERVER_PROTOCOL</code>.
- *
- * @return a <code>String</code> containing the protocol
- * name and version number
- *
- */
-
- public String getProtocol();
-
-
-
-
- /**
- * Returns the name of the scheme used to make this request,
- * for example,
- * <code>http</code>, <code>https</code>, or <code>ftp</code>.
- * Different schemes have different rules for constructing URLs,
- * as noted in RFC 1738.
- *
- * @return a <code>String</code> containing the name
- * of the scheme used to make this request
- *
- */
-
- public String getScheme();
-
-
-
-
- /**
- * Returns the host name of the server that received the request.
- * For HTTP servlets, same as the value of the CGI variable
- * <code>SERVER_NAME</code>.
- *
- * @return a <code>String</code> containing the name
- * of the server to which the request was sent
- */
-
- public String getServerName();
-
-
-
-
- /**
- * Returns the port number on which this request was received.
- * For HTTP servlets, same as the value of the CGI variable
- * <code>SERVER_PORT</code>.
- *
- * @return an integer specifying the port number
- *
- */
-
- public int getServerPort();
-
-
-
- /**
- * Retrieves the body of the request as character data using
- * a <code>BufferedReader</code>. The reader translates the character
- * data according to the character encoding used on the body.
- * Either this method or {@link #getInputStream} may be called to read the
- * body, not both.
- *
- *
- * @return a <code>BufferedReader</code>
- * containing the body of the request
- *
- * @exception IllegalStateException if {@link #getInputStream} method
- * has been called on this request
- *
- * @exception IOException if an input or output exception occurred
- *
- * @see #getInputStream
- *
- */
-
- public BufferedReader getReader() throws IOException;
-
-
-
-
- /**
- * Returns the Internet Protocol (IP) address of the client
- * that sent the request. For HTTP servlets, same as the value of the
- * CGI variable <code>REMOTE_ADDR</code>.
- *
- * @return a <code>String</code> containing the
- * IP address of the client that sent the request
- *
- */
-
- public String getRemoteAddr();
-
-
-
-
- /**
- * Returns the fully qualified name of the client that sent the
- * request. If the engine cannot or chooses not to resolve the hostname
- * (to improve performance), this method returns the dotted-string form of
- * the IP address. For HTTP servlets, same as the value of the CGI variable
- * <code>REMOTE_HOST</code>.
- *
- * @return a <code>String</code> containing the fully
- * qualified name of the client
- *
- */
-
- public String getRemoteHost();
-
-
-
-
- /**
- *
- * Stores an attribute in this request.
- * Attributes are reset between requests. This method is most
- * often used in conjunction with {@link RequestDispatcher}.
- *
- * <p>Attribute names should follow the same conventions as
- * package names. Names beginning with <code>java.*</code>,
- * <code>javax.*</code>, and <code>com.sun.*</code>, are
- * reserved for use by Sun Microsystems.
- *
- *
- * @param name a <code>String</code> specifying
- * the name of the attribute
- *
- * @param o the <code>Object</code> to be stored
- *
- */
-
- public void setAttribute(String name, Object o);
-
-
-
-
- /**
- *
- * @deprecated As of Version 2.1 of the Java Servlet API,
- * use {@link ServletContext#getRealPath} instead.
- *
- */
-
- public String getRealPath(String path);
-
-
-}
-
diff --git a/javax.servlet/src/main/java/javax/servlet/ServletResponse.java b/javax.servlet/src/main/java/javax/servlet/ServletResponse.java
deleted file mode 100644
index e658b45..0000000
--- a/javax.servlet/src/main/java/javax/servlet/ServletResponse.java
+++ /dev/null
@@ -1,186 +0,0 @@
-/*
- * Copyright 1999,2005 The Apache Software Foundation.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package javax.servlet;
-
-import java.io.*;
-
-
-/**
- * Defines an object to assist a servlet in sending a response to the client.
- * The servlet container creates a <code>ServletResponse</code> object and
- * passes it as an argument to the servlet's <code>service</code> method.
- *
- * <p>To send binary data in a MIME body response, use
- * the {@link ServletOutputStream} returned by {@link #getOutputStream}.
- * To send character data, use the <code>PrintWriter</code> object
- * returned by {@link #getWriter}. To mix binary and text data,
- * for example, to create a multipart response, use a
- * <code>ServletOutputStream</code> and manage the character sections
- * manually.
- *
- * <p>The charset for the MIME body response can be specified with
- * {@link #setContentType}. For example, "text/html; charset=Shift_JIS".
- * If no charset is specified, ISO-8859-1 will be used.
- * The <code>setContentType</code> or <code>setLocale</code> method
- * must be called before <code>getWriter</code> for the charset to
- * affect the construction of the writer.
- *
- * <p>See the Internet RFCs such as
- * <a href="http://info.internet.isi.edu/in-notes/rfc/files/rfc2045.txt">
- * RFC 2045</a> for more information on MIME. Protocols such as SMTP
- * and HTTP define profiles of MIME, and those standards
- * are still evolving.
- *
- * @author Various
- * @version $Version$
- *
- * @see ServletOutputStream
- *
- */
-
-public interface ServletResponse {
-
-
-
- /**
- * Returns the name of the charset used for
- * the MIME body sent in this response.
- *
- * <p>If no charset has been assigned, it is implicitly
- * set to <code>ISO-8859-1</code> (<code>Latin-1</code>).
- *
- * <p>See RFC 2047 (http://ds.internic.net/rfc/rfc2045.txt)
- * for more information about character encoding and MIME.
- *
- * @return a <code>String</code> specifying the
- * name of the charset, for
- * example, <code>ISO-8859-1</code>
- *
- */
-
- public String getCharacterEncoding();
-
-
-
- /**
- * Returns a {@link ServletOutputStream} suitable for writing binary
- * data in the response. The servlet container does not encode the
- * binary data.
-
- * <p> Calling flush() on the ServletOutputStream commits the response.
-
- * Either this method or {@link #getWriter} may
- * be called to write the body, not both.
- *
- * @return a {@link ServletOutputStream} for writing binary data
- *
- * @exception IllegalStateException if the <code>getWriter</code> method
- * has been called on this response
- *
- * @exception IOException if an input or output exception occurred
- *
- * @see #getWriter
- *
- */
-
- public ServletOutputStream getOutputStream() throws IOException;
-
-
-
- /**
- * Returns a <code>PrintWriter</code> object that
- * can send character text to the client.
- * The character encoding used is the one specified
- * in the <code>charset=</code> property of the
- * {@link #setContentType} method, which must be called
- * <i>before</i> calling this method for the charset to take effect.
- *
- * <p>If necessary, the MIME type of the response is
- * modified to reflect the character encoding used.
- *
- * <p> Calling flush() on the PrintWriter commits the response.
- *
- * <p>Either this method or {@link #getOutputStream} may be called
- * to write the body, not both.
- *
- *
- * @return a <code>PrintWriter</code> object that
- * can return character data to the client
- *
- * @exception UnsupportedEncodingException if the charset specified in
- * <code>setContentType</code> cannot be
- * used
- *
- * @exception IllegalStateException if the <code>getOutputStream</code>
- * method has already been called for this
- * response object
- *
- * @exception IOException if an input or output exception occurred
- *
- * @see #getOutputStream
- * @see #setContentType
- *
- */
-
- public PrintWriter getWriter() throws IOException;
-
-
-
-
-
- /**
- * Sets the length of the content body in the response
- * In HTTP servlets, this method sets the HTTP Content-Length header.
- *
- *
- * @param len an integer specifying the length of the
- * content being returned to the client; sets
- * the Content-Length header
- *
- */
-
- public void setContentLength(int len);
-
-
-
- /**
- * Sets the content type of the response being sent to
- * the client. The content type may include the type of character
- * encoding used, for example, <code>text/html; charset=ISO-8859-4</code>.
- *
- * <p>If obtaining a <code>PrintWriter</code>, this method should be
- * called first.
- *
- *
- * @param type a <code>String</code> specifying the MIME
- * type of the content
- *
- * @see #getOutputStream
- * @see #getWriter
- *
- */
-
- public void setContentType(String type);
-
-
-
-}
-
-
-
-
-
diff --git a/javax.servlet/src/main/java/javax/servlet/SingleThreadModel.java b/javax.servlet/src/main/java/javax/servlet/SingleThreadModel.java
deleted file mode 100644
index 14b54fd..0000000
--- a/javax.servlet/src/main/java/javax/servlet/SingleThreadModel.java
+++ /dev/null
@@ -1,42 +0,0 @@
-/*
- * Copyright 1999,2005 The Apache Software Foundation.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package javax.servlet;
-
-/**
- * Ensures that servlets handle
- * only one request at a time. This interface has no methods.
- *
- * <p>If a servlet implements this interface, you are <i>guaranteed</i>
- * that no two threads will execute concurrently in the
- * servlet's <code>service</code> method. The servlet container
- * can make this guarantee by synchronizing access to a single
- * instance of the servlet, or by maintaining a pool of servlet
- * instances and dispatching each new request to a free servlet.
- *
- * <p>This interface does not prevent
- * synchronization problems that result from servlets accessing shared
- * resources such as static class variables or classes outside
- * the scope of the servlet.
- *
- *
- * @author Various
- * @version $Version$
- *
- */
-
-public interface SingleThreadModel {
-}
diff --git a/javax.servlet/src/main/java/javax/servlet/UnavailableException.java b/javax.servlet/src/main/java/javax/servlet/UnavailableException.java
deleted file mode 100644
index 3ea2d57..0000000
--- a/javax.servlet/src/main/java/javax/servlet/UnavailableException.java
+++ /dev/null
@@ -1,149 +0,0 @@
-/*
- * Copyright 1999,2005 The Apache Software Foundation.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package javax.servlet;
-
-
-/**
- * Defines an exception that a servlet throws to indicate
- * that it is permanently or temporarily unavailable.
- *
- * <p>When a servlet is permanently unavailable, something is wrong
- * with the servlet, and it cannot handle
- * requests until some action is taken. For example, the servlet
- * might be configured incorrectly, or its state may be corrupted.
- * A servlet should log both the error and the corrective action
- * that is needed.
- *
- * <p>A servlet is temporarily unavailable if it cannot handle
- * requests momentarily due to some system-wide problem. For example,
- * a third-tier server might not be accessible, or there may be
- * insufficient memory or disk storage to handle requests. A system
- * administrator may need to take corrective action.
- *
- * <p>Servlet containers can safely treat both types of unavailable
- * exceptions in the same way. However, treating temporary unavailability
- * effectively makes the servlet container more robust. Specifically,
- * the servlet container might block requests to the servlet for a period
- * of time suggested by the exception, rather than rejecting them until
- * the servlet container restarts.
- *
- *
- * @author Various
- * @version $Version$
- *
- */
-
-public class UnavailableException
-extends ServletException {
-
- private Servlet servlet; // what's unavailable
- private boolean permanent; // needs admin action?
- private int seconds; // unavailability estimate
-
- /**
- *
- * @param servlet the <code>Servlet</code> instance that is
- * unavailable
- *
- * @param msg a <code>String</code> specifying the
- * descriptive message
- *
- */
-
- public UnavailableException(Servlet servlet, String msg) {
- super(msg);
- this.servlet = servlet;
- permanent = true;
- }
-
- /**
- *
- * @param seconds an integer specifying the number of seconds
- * the servlet expects to be unavailable; if
- * zero or negative, indicates that the servlet
- * can't make an estimate
- *
- * @param servlet the <code>Servlet</code> that is unavailable
- *
- * @param msg a <code>String</code> specifying the descriptive
- * message, which can be written to a log file or
- * displayed for the user.
- *
- */
-
- public UnavailableException(int seconds, Servlet servlet, String msg) {
- super(msg);
- this.servlet = servlet;
- if (seconds <= 0)
- this.seconds = -1;
- else
- this.seconds = seconds;
- permanent = false;
- }
-
- /**
- *
- * Returns a <code>boolean</code> indicating
- * whether the servlet is permanently unavailable.
- * If so, something is wrong with the servlet, and the
- * system administrator must take some corrective action.
- *
- * @return <code>true</code> if the servlet is
- * permanently unavailable; <code>false</code>
- * if the servlet is available or temporarily
- * unavailable
- *
- */
-
- public boolean isPermanent() {
- return permanent;
- }
-
- /**
- *
- * Returns the servlet that is reporting its unavailability.
- *
- * @return the <code>Servlet</code> object that is
- * throwing the <code>UnavailableException</code>
- *
- */
-
- public Servlet getServlet() {
- return servlet;
- }
-
- /**
- * Returns the number of seconds the servlet expects to
- * be temporarily unavailable.
- *
- * <p>If this method returns a negative number, the servlet
- * is permanently unavailable or cannot provide an estimate of
- * how long it will be unavailable. No effort is
- * made to correct for the time elapsed since the exception was
- * first reported.
- *
- * @return an integer specifying the number of seconds
- * the servlet will be temporarily unavailable,
- * or a negative number if the servlet is permanently
- * unavailable or cannot make an estimate
- *
- */
-
- public int getUnavailableSeconds() {
- return permanent ? -1 : seconds;
- }
-}
diff --git a/javax.servlet/src/main/java/javax/servlet/http/Cookie.java b/javax.servlet/src/main/java/javax/servlet/http/Cookie.java
deleted file mode 100644
index baeac67..0000000
--- a/javax.servlet/src/main/java/javax/servlet/http/Cookie.java
+++ /dev/null
@@ -1,536 +0,0 @@
-/*
- * Copyright 1999,2005 The Apache Software Foundation.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package javax.servlet.http;
-
-import java.text.MessageFormat;
-import java.util.ResourceBundle;
-
-/**
- *
- * Creates a cookie, a small amount of information sent by a servlet to
- * a Web browser, saved by the browser, and later sent back to the server.
- * A cookie's value can uniquely
- * identify a client, so cookies are commonly used for session management.
- *
- * <p>A cookie has a name, a single value, and optional attributes
- * such as a comment, path and domain qualifiers, a maximum age, and a
- * version number. Some Web browsers have bugs in how they handle the
- * optional attributes, so use them sparingly to improve the interoperability
- * of your servlets.
- *
- * <p>The servlet sends cookies to the browser by using the
- * {@link HttpServletResponse#addCookie} method, which adds
- * fields to HTTP response headers to send cookies to the
- * browser, one at a time. The browser is expected to
- * support 20 cookies for each Web server, 300 cookies total, and
- * may limit cookie size to 4 KB each.
- *
- * <p>The browser returns cookies to the servlet by adding
- * fields to HTTP request headers. Cookies can be retrieved
- * from a request by using the {@link HttpServletRequest#getCookies} method.
- * Several cookies might have the same name but different path attributes.
- *
- * <p>Cookies affect the caching of the Web pages that use them.
- * HTTP 1.0 does not cache pages that use cookies created with
- * this class. This class does not support the cache control
- * defined with HTTP 1.1.
- *
- * <p>This class supports both the Version 0 (by Netscape) and Version 1
- * (by RFC 2109) cookie specifications. By default, cookies are
- * created using Version 0 to ensure the best interoperability.
- *
- *
- * @author Various
- * @version $Version$
- *
- */
-
-// XXX would implement java.io.Serializable too, but can't do that
-// so long as sun.servlet.* must run on older JDK 1.02 JVMs which
-// don't include that support.
-
-public class Cookie implements Cloneable {
-
- private static final String LSTRING_FILE =
- "javax.servlet.http.LocalStrings";
- private static ResourceBundle lStrings =
- ResourceBundle.getBundle(LSTRING_FILE);
-
- //
- // The value of the cookie itself.
- //
-
- private String name; // NAME= ... "$Name" style is reserved
- private String value; // value of NAME
-
- //
- // Attributes encoded in the header's cookie fields.
- //
-
- private String comment; // ;Comment=VALUE ... describes cookie's use
- // ;Discard ... implied by maxAge < 0
- private String domain; // ;Domain=VALUE ... domain that sees cookie
- private int maxAge = -1; // ;Max-Age=VALUE ... cookies auto-expire
- private String path; // ;Path=VALUE ... URLs that see the cookie
- private boolean secure; // ;Secure ... e.g. use SSL
- private int version = 0; // ;Version=1 ... means RFC 2109++ style
-
-
-
- /**
- * Constructs a cookie with a specified name and value.
- *
- * <p>The name must conform to RFC 2109. That means it can contain
- * only ASCII alphanumeric characters and cannot contain commas,
- * semicolons, or white space or begin with a $ character. The cookie's
- * name cannot be changed after creation.
- *
- * <p>The value can be anything the server chooses to send. Its
- * value is probably of interest only to the server. The cookie's
- * value can be changed after creation with the
- * <code>setValue</code> method.
- *
- * <p>By default, cookies are created according to the Netscape
- * cookie specification. The version can be changed with the
- * <code>setVersion</code> method.
- *
- *
- * @param name a <code>String</code> specifying the name of the cookie
- *
- * @param value a <code>String</code> specifying the value of the cookie
- *
- * @throws IllegalArgumentException if the cookie name contains illegal characters
- * (for example, a comma, space, or semicolon)
- * or it is one of the tokens reserved for use
- * by the cookie protocol
- * @see #setValue
- * @see #setVersion
- *
- */
-
- public Cookie(String name, String value) {
- if (!isToken(name)
- || name.equalsIgnoreCase("Comment") // rfc2019
- || name.equalsIgnoreCase("Discard") // 2019++
- || name.equalsIgnoreCase("Domain")
- || name.equalsIgnoreCase("Expires") // (old cookies)
- || name.equalsIgnoreCase("Max-Age") // rfc2019
- || name.equalsIgnoreCase("Path")
- || name.equalsIgnoreCase("Secure")
- || name.equalsIgnoreCase("Version")
- ) {
- String errMsg = lStrings.getString("err.cookie_name_is_token");
- Object[] errArgs = new Object[1];
- errArgs[0] = name;
- errMsg = MessageFormat.format(errMsg, errArgs);
- throw new IllegalArgumentException(errMsg);
- }
-
- this.name = name;
- this.value = value;
- }
-
-
-
-
-
- /**
- *
- * Specifies a comment that describes a cookie's purpose.
- * The comment is useful if the browser presents the cookie
- * to the user. Comments
- * are not supported by Netscape Version 0 cookies.
- *
- * @param purpose a <code>String</code> specifying the comment
- * to display to the user
- *
- * @see #getComment
- *
- */
-
- public void setComment(String purpose) {
- comment = purpose;
- }
-
-
-
-
- /**
- * Returns the comment describing the purpose of this cookie, or
- * <code>null</code> if the cookie has no comment.
- *
- * @return a <code>String</code> containing the comment,
- * or <code>null</code> if none
- *
- * @see #setComment
- *
- */
-
- public String getComment() {
- return comment;
- }
-
-
-
-
-
- /**
- *
- * Specifies the domain within which this cookie should be presented.
- *
- * <p>The form of the domain name is specified by RFC 2109. A domain
- * name begins with a dot (<code>.foo.com</code>) and means that
- * the cookie is visible to servers in a specified Domain Name System
- * (DNS) zone (for example, <code>www.foo.com</code>, but not
- * <code>a.b.foo.com</code>). By default, cookies are only returned
- * to the server that sent them.
- *
- *
- * @param pattern a <code>String</code> containing the domain name
- * within which this cookie is visible;
- * form is according to RFC 2109
- *
- * @see #getDomain
- *
- */
-
- public void setDomain(String pattern) {
- domain = pattern.toLowerCase(); // IE allegedly needs this
- }
-
-
-
-
-
- /**
- * Returns the domain name set for this cookie. The form of
- * the domain name is set by RFC 2109.
- *
- * @return a <code>String</code> containing the domain name
- *
- * @see #setDomain
- *
- */
-
- public String getDomain() {
- return domain;
- }
-
-
-
-
- /**
- * Sets the maximum age of the cookie in seconds.
- *
- * <p>A positive value indicates that the cookie will expire
- * after that many seconds have passed. Note that the value is
- * the <i>maximum</i> age when the cookie will expire, not the cookie's
- * current age.
- *
- * <p>A negative value means
- * that the cookie is not stored persistently and will be deleted
- * when the Web browser exits. A zero value causes the cookie
- * to be deleted.
- *
- * @param expiry an integer specifying the maximum age of the
- * cookie in seconds; if negative, means
- * the cookie is not stored; if zero, deletes
- * the cookie
- *
- *
- * @see #getMaxAge
- *
- */
-
- public void setMaxAge(int expiry) {
- maxAge = expiry;
- }
-
-
-
-
- /**
- * Returns the maximum age of the cookie, specified in seconds,
- * By default, <code>-1</code> indicating the cookie will persist
- * until browser shutdown.
- *
- *
- * @return an integer specifying the maximum age of the
- * cookie in seconds; if negative, means
- * the cookie persists until browser shutdown
- *
- *
- * @see #setMaxAge
- *
- */
-
- public int getMaxAge() {
- return maxAge;
- }
-
-
-
-
- /**
- * Specifies a path for the cookie
- * to which the client should return the cookie.
- *
- * <p>The cookie is visible to all the pages in the directory
- * you specify, and all the pages in that directory's subdirectories.
- * A cookie's path must include the servlet that set the cookie,
- * for example, <i>/catalog</i>, which makes the cookie
- * visible to all directories on the server under <i>/catalog</i>.
- *
- * <p>Consult RFC 2109 (available on the Internet) for more
- * information on setting path names for cookies.
- *
- *
- * @param uri a <code>String</code> specifying a path
- *
- *
- * @see #getPath
- *
- */
-
- public void setPath(String uri) {
- path = uri;
- }
-
-
-
-
- /**
- * Returns the path on the server
- * to which the browser returns this cookie. The
- * cookie is visible to all subpaths on the server.
- *
- *
- * @return a <code>String</code> specifying a path that contains
- * a servlet name, for example, <i>/catalog</i>
- *
- * @see #setPath
- *
- */
-
- public String getPath() {
- return path;
- }
-
-
-
-
-
- /**
- * Indicates to the browser whether the cookie should only be sent
- * using a secure protocol, such as HTTPS or SSL.
- *
- * <p>The default value is <code>false</code>.
- *
- * @param flag if <code>true</code>, sends the cookie from the browser
- * to the server using only when using a secure protocol;
- * if <code>false</code>, sent on any protocol
- *
- * @see #getSecure
- *
- */
-
- public void setSecure(boolean flag) {
- secure = flag;
- }
-
-
-
-
- /**
- * Returns <code>true</code> if the browser is sending cookies
- * only over a secure protocol, or <code>false</code> if the
- * browser can send cookies using any protocol.
- *
- * @return <code>true</code> if the browser uses a secure protocol;
- * otherwise, <code>true</code>
- *
- * @see #setSecure
- *
- */
-
- public boolean getSecure() {
- return secure;
- }
-
-
-
-
-
- /**
- * Returns the name of the cookie. The name cannot be changed after
- * creation.
- *
- * @return a <code>String</code> specifying the cookie's name
- *
- */
-
- public String getName() {
- return name;
- }
-
-
-
-
-
- /**
- *
- * Assigns a new value to a cookie after the cookie is created.
- * If you use a binary value, you may want to use BASE64 encoding.
- *
- * <p>With Version 0 cookies, values should not contain white
- * space, brackets, parentheses, equals signs, commas,
- * double quotes, slashes, question marks, at signs, colons,
- * and semicolons. Empty values may not behave the same way
- * on all browsers.
- *
- * @param newValue a <code>String</code> specifying the new value
- *
- *
- * @see #getValue
- * @see Cookie
- *
- */
-
- public void setValue(String newValue) {
- value = newValue;
- }
-
-
-
-
- /**
- * Returns the value of the cookie.
- *
- * @return a <code>String</code> containing the cookie's
- * present value
- *
- * @see #setValue
- * @see Cookie
- *
- */
-
- public String getValue() {
- return value;
- }
-
-
-
-
- /**
- * Returns the version of the protocol this cookie complies
- * with. Version 1 complies with RFC 2109,
- * and version 0 complies with the original
- * cookie specification drafted by Netscape. Cookies provided
- * by a browser use and identify the browser's cookie version.
- *
- *
- * @return 0 if the cookie complies with the
- * original Netscape specification; 1
- * if the cookie complies with RFC 2109
- *
- * @see #setVersion
- *
- */
-
- public int getVersion() {
- return version;
- }
-
-
-
-
- /**
- * Sets the version of the cookie protocol this cookie complies
- * with. Version 0 complies with the original Netscape cookie
- * specification. Version 1 complies with RFC 2109.
- *
- * <p>Since RFC 2109 is still somewhat new, consider
- * version 1 as experimental; do not use it yet on production sites.
- *
- *
- * @param v 0 if the cookie should comply with
- * the original Netscape specification;
- * 1 if the cookie should comply with RFC 2109
- *
- * @see #getVersion
- *
- */
-
- public void setVersion(int v) {
- version = v;
- }
-
- // Note -- disabled for now to allow full Netscape compatibility
- // from RFC 2068, token special case characters
- //
- // private static final String tspecials = "()<>@,;:\\\"/[]?={} \t";
-
- private static final String tspecials = ",;";
-
-
-
-
- /*
- * Tests a string and returns true if the string counts as a
- * reserved token in the Java language.
- *
- * @param value the <code>String</code> to be tested
- *
- * @return <code>true</code> if the <code>String</code> is
- * a reserved token; <code>false</code>
- * if it is not
- */
-
- private boolean isToken(String value) {
- int len = value.length();
-
- for (int i = 0; i < len; i++) {
- char c = value.charAt(i);
-
- if (c < 0x20 || c >= 0x7f || tspecials.indexOf(c) != -1)
- return false;
- }
- return true;
- }
-
-
-
-
-
-
- /**
- *
- * Overrides the standard <code>java.lang.Object.clone</code>
- * method to return a copy of this cookie.
- *
- *
- */
-
- public Object clone() {
- try {
- return super.clone();
- } catch (CloneNotSupportedException e) {
- throw new RuntimeException(e.getMessage());
- }
- }
-}
-
diff --git a/javax.servlet/src/main/java/javax/servlet/http/HttpServlet.java b/javax.servlet/src/main/java/javax/servlet/http/HttpServlet.java
deleted file mode 100644
index ff7681b..0000000
--- a/javax.servlet/src/main/java/javax/servlet/http/HttpServlet.java
+++ /dev/null
@@ -1,979 +0,0 @@
-/*
- * Copyright 1999,2005 The Apache Software Foundation.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-
-package javax.servlet.http;
-
-import java.io.IOException;
-import java.io.PrintWriter;
-import java.io.OutputStreamWriter;
-import java.io.UnsupportedEncodingException;
-import java.lang.reflect.Method;
-import java.text.MessageFormat;
-import java.util.Enumeration;
-import java.util.ResourceBundle;
-
-import javax.servlet.GenericServlet;
-import javax.servlet.ServletException;
-import javax.servlet.ServletOutputStream;
-import javax.servlet.ServletRequest;
-import javax.servlet.ServletResponse;
-
-
-/**
- *
- * Provides an abstract class to be subclassed to create
- * an HTTP servlet suitable for a Web site. A subclass of
- * <code>HttpServlet</code> must override at least
- * one method, usually one of these:
- *
- * <ul>
- * <li> <code>doGet</code>, if the servlet supports HTTP GET requests
- * <li> <code>doPost</code>, for HTTP POST requests
- * <li> <code>doPut</code>, for HTTP PUT requests
- * <li> <code>doDelete</code>, for HTTP DELETE requests
- * <li> <code>init</code> and <code>destroy</code>,
- * to manage resources that are held for the life of the servlet
- * <li> <code>getServletInfo</code>, which the servlet uses to
- * provide information about itself
- * </ul>
- *
- * <p>There's almost no reason to override the <code>service</code>
- * method. <code>service</code> handles standard HTTP
- * requests by dispatching them to the handler methods
- * for each HTTP request type (the <code>do</code><i>XXX</i>
- * methods listed above).
- *
- * <p>Likewise, there's almost no reason to override the
- * <code>doOptions</code> and <code>doTrace</code> methods.
- *
- * <p>Servlets typically run on multithreaded servers,
- * so be aware that a servlet must handle concurrent
- * requests and be careful to synchronize access to shared resources.
- * Shared resources include in-memory data such as
- * instance or class variables and external objects
- * such as files, database connections, and network
- * connections.
- * See the
- * <a href="http://java.sun.com/Series/Tutorial/java/threads/multithreaded.html">
- * Java Tutorial on Multithreaded Programming</a> for more
- * information on handling multiple threads in a Java program.
- *
- * @author Various
- * @version $Version$
- *
- */
-
-
-
-public abstract class HttpServlet extends GenericServlet
- implements java.io.Serializable
-{
- private static final String METHOD_DELETE = "DELETE";
- private static final String METHOD_HEAD = "HEAD";
- private static final String METHOD_GET = "GET";
- private static final String METHOD_OPTIONS = "OPTIONS";
- private static final String METHOD_POST = "POST";
- private static final String METHOD_PUT = "PUT";
- private static final String METHOD_TRACE = "TRACE";
-
- private static final String HEADER_IFMODSINCE = "If-Modified-Since";
- private static final String HEADER_LASTMOD = "Last-Modified";
-
- private static final String LSTRING_FILE =
- "javax.servlet.http.LocalStrings";
- private static ResourceBundle lStrings =
- ResourceBundle.getBundle(LSTRING_FILE);
-
-
-
-
- /**
- * Does nothing, because this is an abstract class.
- *
- */
-
- public HttpServlet() { }
-
-
-
- /**
- *
- * Called by the server (via the <code>service</code> method) to
- * allow a servlet to handle a GET request.
- *
- * <p>Overriding this method to support a GET request also
- * automatically supports an HTTP HEAD request. A HEAD
- * request is a GET request that returns no body in the
- * response, only the request header fields.
- *
- * <p>When overriding this method, read the request data,
- * write the response headers, get the response's writer or
- * output stream object, and finally, write the response data.
- * It's best to include content type and encoding. When using
- * a <code>PrintWriter</code> object to return the response,
- * set the content type before accessing the
- * <code>PrintWriter</code> object.
- *
- * <p>The servlet container must write the headers before
- * committing the response, because in HTTP the headers must be sent
- * before the response body.
- *
- * <p>Where possible, set the Content-Length header (with the
- * {@link javax.servlet.ServletResponse#setContentLength} method),
- * to allow the servlet container to use a persistent connection
- * to return its response to the client, improving performance.
- * The content length is automatically set if the entire response fits
- * inside the response buffer.
- *
- * <p>The GET method should be safe, that is, without
- * any side effects for which users are held responsible.
- * For example, most form queries have no side effects.
- * If a client request is intended to change stored data,
- * the request should use some other HTTP method.
- *
- * <p>The GET method should also be idempotent, meaning
- * that it can be safely repeated. Sometimes making a
- * method safe also makes it idempotent. For example,
- * repeating queries is both safe and idempotent, but
- * buying a product online or modifying data is neither
- * safe nor idempotent.
- *
- * <p>If the request is incorrectly formatted, <code>doGet</code>
- * returns an HTTP "Bad Request" message.
- *
- *
- * @param req an {@link HttpServletRequest} object that
- * contains the request the client has made
- * of the servlet
- *
- * @param resp an {@link HttpServletResponse} object that
- * contains the response the servlet sends
- * to the client
- *
- * @exception IOException if an input or output error is
- * detected when the servlet handles
- * the GET request
- *
- * @exception ServletException if the request for the GET
- * could not be handled
- *
- *
- * @see javax.servlet.ServletResponse#setContentType
- *
- */
-
- protected void doGet(HttpServletRequest req, HttpServletResponse resp)
- throws ServletException, IOException
- {
- String protocol = req.getProtocol();
- String msg = lStrings.getString("http.method_get_not_supported");
- if (protocol.endsWith("1.1")) {
- resp.sendError(HttpServletResponse.SC_METHOD_NOT_ALLOWED, msg);
- } else {
- resp.sendError(HttpServletResponse.SC_BAD_REQUEST, msg);
- }
- }
-
-
-
-
-
- /**
- *
- * Returns the time the <code>HttpServletRequest</code>
- * object was last modified,
- * in milliseconds since midnight January 1, 1970 GMT.
- * If the time is unknown, this method returns a negative
- * number (the default).
- *
- * <p>Servlets that support HTTP GET requests and can quickly determine
- * their last modification time should override this method.
- * This makes browser and proxy caches work more effectively,
- * reducing the load on server and network resources.
- *
- *
- * @param req the <code>HttpServletRequest</code>
- * object that is sent to the servlet
- *
- * @return a <code>long</code> integer specifying
- * the time the <code>HttpServletRequest</code>
- * object was last modified, in milliseconds
- * since midnight, January 1, 1970 GMT, or
- * -1 if the time is not known
- *
- */
-
- protected long getLastModified(HttpServletRequest req) {
- return -1;
- }
-
-
-
-
- /**
- *
- *
- * <p>Receives an HTTP HEAD request from the protected
- * <code>service</code> method and handles the
- * request.
- * The client sends a HEAD request when it wants
- * to see only the headers of a response, such as
- * Content-Type or Content-Length. The HTTP HEAD
- * method counts the output bytes in the response
- * to set the Content-Length header accurately.
- *
- * <p>If you override this method, you can avoid computing
- * the response body and just set the response headers
- * directly to improve performance. Make sure that the
- * <code>doHead</code> method you write is both safe
- * and idempotent (that is, protects itself from being
- * called multiple times for one HTTP HEAD request).
- *
- * <p>If the HTTP HEAD request is incorrectly formatted,
- * <code>doHead</code> returns an HTTP "Bad Request"
- * message.
- *
- *
- * @param req the request object that is passed
- * to the servlet
- *
- * @param resp the response object that the servlet
- * uses to return the headers to the clien
- *
- * @exception IOException if an input or output error occurs
- *
- * @exception ServletException if the request for the HEAD
- * could not be handled
- */
-
- protected void doHead(HttpServletRequest req, HttpServletResponse resp)
- throws ServletException, IOException
- {
- NoBodyResponse response = new NoBodyResponse(resp);
-
- doGet(req, response);
- response.setContentLength();
- }
-
-
-
-
-
- /**
- *
- * Called by the server (via the <code>service</code> method)
- * to allow a servlet to handle a POST request.
- *
- * The HTTP POST method allows the client to send
- * data of unlimited length to the Web server a single time
- * and is useful when posting information such as
- * credit card numbers.
- *
- * <p>When overriding this method, read the request data,
- * write the response headers, get the response's writer or output
- * stream object, and finally, write the response data. It's best
- * to include content type and encoding. When using a
- * <code>PrintWriter</code> object to return the response, set the
- * content type before accessing the <code>PrintWriter</code> object.
- *
- * <p>The servlet container must write the headers before committing the
- * response, because in HTTP the headers must be sent before the
- * response body.
- *
- * <p>Where possible, set the Content-Length header (with the
- * {@link javax.servlet.ServletResponse#setContentLength} method),
- * to allow the servlet container to use a persistent connection
- * to return its response to the client, improving performance.
- * The content length is automatically set if the entire response fits
- * inside the response buffer.
- *
- * <p>When using HTTP 1.1 chunked encoding (which means that the response
- * has a Transfer-Encoding header), do not set the Content-Length header.
- *
- * <p>This method does not need to be either safe or idempotent.
- * Operations requested through POST can have side effects for
- * which the user can be held accountable, for example,
- * updating stored data or buying items online.
- *
- * <p>If the HTTP POST request is incorrectly formatted,
- * <code>doPost</code> returns an HTTP "Bad Request" message.
- *
- *
- * @param req an {@link HttpServletRequest} object that
- * contains the request the client has made
- * of the servlet
- *
- * @param resp an {@link HttpServletResponse} object that
- * contains the response the servlet sends
- * to the client
- *
- * @exception IOException if an input or output error is
- * detected when the servlet handles
- * the request
- *
- * @exception ServletException if the request for the POST
- * could not be handled
- *
- *
- * @see javax.servlet.ServletOutputStream
- * @see javax.servlet.ServletResponse#setContentType
- *
- *
- */
-
- protected void doPost(HttpServletRequest req, HttpServletResponse resp)
- throws ServletException, IOException
- {
- String protocol = req.getProtocol();
- String msg = lStrings.getString("http.method_post_not_supported");
- if (protocol.endsWith("1.1")) {
- resp.sendError(HttpServletResponse.SC_METHOD_NOT_ALLOWED, msg);
- } else {
- resp.sendError(HttpServletResponse.SC_BAD_REQUEST, msg);
- }
- }
-
-
-
-
- /**
- * Called by the server (via the <code>service</code> method)
- * to allow a servlet to handle a PUT request.
- *
- * The PUT operation allows a client to
- * place a file on the server and is similar to
- * sending a file by FTP.
- *
- * <p>When overriding this method, leave intact
- * any content headers sent with the request (including
- * Content-Length, Content-Type, Content-Transfer-Encoding,
- * Content-Encoding, Content-Base, Content-Language, Content-Location,
- * Content-MD5, and Content-Range). If your method cannot
- * handle a content header, it must issue an error message
- * (HTTP 501 - Not Implemented) and discard the request.
- * For more information on HTTP 1.1, see RFC 2068
- * <a href="http://info.internet.isi.edu:80/in-notes/rfc/files/rfc2068.txt"></a>.
- *
- * <p>This method does not need to be either safe or idempotent.
- * Operations that <code>doPut</code> performs can have side
- * effects for which the user can be held accountable. When using
- * this method, it may be useful to save a copy of the
- * affected URL in temporary storage.
- *
- * <p>If the HTTP PUT request is incorrectly formatted,
- * <code>doPut</code> returns an HTTP "Bad Request" message.
- *
- *
- * @param req the {@link HttpServletRequest} object that
- * contains the request the client made of
- * the servlet
- *
- * @param resp the {@link HttpServletResponse} object that
- * contains the response the servlet returns
- * to the client
- *
- * @exception IOException if an input or output error occurs
- * while the servlet is handling the
- * PUT request
- *
- * @exception ServletException if the request for the PUT
- * cannot be handled
- *
- */
-
- protected void doPut(HttpServletRequest req, HttpServletResponse resp)
- throws ServletException, IOException
- {
- String protocol = req.getProtocol();
- String msg = lStrings.getString("http.method_put_not_supported");
- if (protocol.endsWith("1.1")) {
- resp.sendError(HttpServletResponse.SC_METHOD_NOT_ALLOWED, msg);
- } else {
- resp.sendError(HttpServletResponse.SC_BAD_REQUEST, msg);
- }
- }
-
-
-
-
- /**
- *
- * Called by the server (via the <code>service</code> method)
- * to allow a servlet to handle a DELETE request.
- *
- * The DELETE operation allows a client to remove a document
- * or Web page from the server.
- *
- * <p>This method does not need to be either safe
- * or idempotent. Operations requested through
- * DELETE can have side effects for which users
- * can be held accountable. When using
- * this method, it may be useful to save a copy of the
- * affected URL in temporary storage.
- *
- * <p>If the HTTP DELETE request is incorrectly formatted,
- * <code>doDelete</code> returns an HTTP "Bad Request"
- * message.
- *
- *
- * @param req the {@link HttpServletRequest} object that
- * contains the request the client made of
- * the servlet
- *
- *
- * @param resp the {@link HttpServletResponse} object that
- * contains the response the servlet returns
- * to the client
- *
- *
- * @exception IOException if an input or output error occurs
- * while the servlet is handling the
- * DELETE request
- *
- * @exception ServletException if the request for the
- * DELETE cannot be handled
- *
- */
-
- protected void doDelete(HttpServletRequest req,
- HttpServletResponse resp)
- throws ServletException, IOException
- {
- String protocol = req.getProtocol();
- String msg = lStrings.getString("http.method_delete_not_supported");
- if (protocol.endsWith("1.1")) {
- resp.sendError(HttpServletResponse.SC_METHOD_NOT_ALLOWED, msg);
- } else {
- resp.sendError(HttpServletResponse.SC_BAD_REQUEST, msg);
- }
- }
-
-
-
-
-
- private Method[] getAllDeclaredMethods(Class c) {
- if (c.getName().equals("javax.servlet.http.HttpServlet"))
- return null;
-
- int j=0;
- Method[] parentMethods = getAllDeclaredMethods(c.getSuperclass());
- Method[] thisMethods = c.getDeclaredMethods();
-
- if (parentMethods!=null) {
- Method[] allMethods =
- new Method[parentMethods.length + thisMethods.length];
- for (int i=0; i<parentMethods.length; i++) {
- allMethods[i]=parentMethods[i];
- j=i;
- }
- j++;
- for (int i=j; i<thisMethods.length+j; i++) {
- allMethods[i] = thisMethods[i-j];
- }
- return allMethods;
- }
- return thisMethods;
- }
-
-
-
-
-
-
- /**
- * Called by the server (via the <code>service</code> method)
- * to allow a servlet to handle a OPTIONS request.
- *
- * The OPTIONS request determines which HTTP methods
- * the server supports and
- * returns an appropriate header. For example, if a servlet
- * overrides <code>doGet</code>, this method returns the
- * following header:
- *
- * <p><code>Allow: GET, HEAD, TRACE, OPTIONS</code>
- *
- * <p>There's no need to override this method unless the
- * servlet implements new HTTP methods, beyond those
- * implemented by HTTP 1.1.
- *
- * @param req the {@link HttpServletRequest} object that
- * contains the request the client made of
- * the servlet
- *
- *
- * @param resp the {@link HttpServletResponse} object that
- * contains the response the servlet returns
- * to the client
- *
- *
- * @exception IOException if an input or output error occurs
- * while the servlet is handling the
- * OPTIONS request
- *
- * @exception ServletException if the request for the
- * OPTIONS cannot be handled
- *
- */
-
- protected void doOptions(HttpServletRequest req, HttpServletResponse resp)
- throws ServletException, IOException
- {
- Method[] methods = getAllDeclaredMethods(this.getClass());
-
- boolean ALLOW_GET = false;
- boolean ALLOW_HEAD = false;
- boolean ALLOW_POST = false;
- boolean ALLOW_PUT = false;
- boolean ALLOW_DELETE = false;
- boolean ALLOW_TRACE = true;
- boolean ALLOW_OPTIONS = true;
-
- for (int i=0; i<methods.length; i++) {
- Method m = methods[i];
-
- if (m.getName().equals("doGet")) {
- ALLOW_GET = true;
- ALLOW_HEAD = true;
- }
- if (m.getName().equals("doPost"))
- ALLOW_POST = true;
- if (m.getName().equals("doPut"))
- ALLOW_PUT = true;
- if (m.getName().equals("doDelete"))
- ALLOW_DELETE = true;
-
- }
-
- String allow = null;
- if (ALLOW_GET)
- if (allow==null) allow=METHOD_GET;
- if (ALLOW_HEAD)
- if (allow==null) allow=METHOD_HEAD;
- else allow += ", " + METHOD_HEAD;
- if (ALLOW_POST)
- if (allow==null) allow=METHOD_POST;
- else allow += ", " + METHOD_POST;
- if (ALLOW_PUT)
- if (allow==null) allow=METHOD_PUT;
- else allow += ", " + METHOD_PUT;
- if (ALLOW_DELETE)
- if (allow==null) allow=METHOD_DELETE;
- else allow += ", " + METHOD_DELETE;
- if (ALLOW_TRACE)
- if (allow==null) allow=METHOD_TRACE;
- else allow += ", " + METHOD_TRACE;
- if (ALLOW_OPTIONS)
- if (allow==null) allow=METHOD_OPTIONS;
- else allow += ", " + METHOD_OPTIONS;
-
- resp.setHeader("Allow", allow);
- }
-
-
-
-
- /**
- * Called by the server (via the <code>service</code> method)
- * to allow a servlet to handle a TRACE request.
- *
- * A TRACE returns the headers sent with the TRACE
- * request to the client, so that they can be used in
- * debugging. There's no need to override this method.
- *
- *
- *
- * @param req the {@link HttpServletRequest} object that
- * contains the request the client made of
- * the servlet
- *
- *
- * @param resp the {@link HttpServletResponse} object that
- * contains the response the servlet returns
- * to the client
- *
- *
- * @exception IOException if an input or output error occurs
- * while the servlet is handling the
- * TRACE request
- *
- * @exception ServletException if the request for the
- * TRACE cannot be handled
- *
- */
-
- protected void doTrace(HttpServletRequest req, HttpServletResponse resp)
- throws ServletException, IOException
- {
-
- int responseLength;
-
- String CRLF = "\r\n";
- String responseString = "TRACE "+ req.getRequestURI()+
- " " + req.getProtocol();
-
- Enumeration reqHeaderEnum = req.getHeaderNames();
-
- while( reqHeaderEnum.hasMoreElements() ) {
- String headerName = (String)reqHeaderEnum.nextElement();
- responseString += CRLF + headerName + ": " +
- req.getHeader(headerName);
- }
-
- responseString += CRLF;
-
- responseLength = responseString.length();
-
- resp.setContentType("message/http");
- resp.setContentLength(responseLength);
- ServletOutputStream out = resp.getOutputStream();
- out.print(responseString);
- out.close();
- return;
- }
-
-
-
-
-
- /**
- *
- * Receives standard HTTP requests from the public
- * <code>service</code> method and dispatches
- * them to the <code>do</code><i>XXX</i> methods defined in
- * this class. This method is an HTTP-specific version of the
- * {@link javax.servlet.Servlet#service} method. There's no
- * need to override this method.
- *
- *
- *
- * @param req the {@link HttpServletRequest} object that
- * contains the request the client made of
- * the servlet
- *
- *
- * @param resp the {@link HttpServletResponse} object that
- * contains the response the servlet returns
- * to the client
- *
- *
- * @exception IOException if an input or output error occurs
- * while the servlet is handling the
- * TRACE request
- *
- * @exception ServletException if the request for the
- * TRACE cannot be handled
- *
- * @see javax.servlet.Servlet#service
- *
- */
-
- protected void service(HttpServletRequest req, HttpServletResponse resp)
- throws ServletException, IOException
- {
- String method = req.getMethod();
-
- if (method.equals(METHOD_GET)) {
- long lastModified = getLastModified(req);
- if (lastModified == -1) {
- // servlet doesn't support if-modified-since, no reason
- // to go through further expensive logic
- doGet(req, resp);
- } else {
- long ifModifiedSince = req.getDateHeader(HEADER_IFMODSINCE);
- if (ifModifiedSince < (lastModified / 1000 * 1000)) {
- // If the servlet mod time is later, call doGet()
- // Round down to the nearest second for a proper compare
- // A ifModifiedSince of -1 will always be less
- maybeSetLastModified(resp, lastModified);
- doGet(req, resp);
- } else {
- resp.setStatus(HttpServletResponse.SC_NOT_MODIFIED);
- }
- }
-
- } else if (method.equals(METHOD_HEAD)) {
- long lastModified = getLastModified(req);
- maybeSetLastModified(resp, lastModified);
- doHead(req, resp);
-
- } else if (method.equals(METHOD_POST)) {
- doPost(req, resp);
-
- } else if (method.equals(METHOD_PUT)) {
- doPut(req, resp);
-
- } else if (method.equals(METHOD_DELETE)) {
- doDelete(req, resp);
-
- } else if (method.equals(METHOD_OPTIONS)) {
- doOptions(req,resp);
-
- } else if (method.equals(METHOD_TRACE)) {
- doTrace(req,resp);
-
- } else {
- //
- // Note that this means NO servlet supports whatever
- // method was requested, anywhere on this server.
- //
-
- String errMsg = lStrings.getString("http.method_not_implemented");
- Object[] errArgs = new Object[1];
- errArgs[0] = method;
- errMsg = MessageFormat.format(errMsg, errArgs);
-
- resp.sendError(HttpServletResponse.SC_NOT_IMPLEMENTED, errMsg);
- }
- }
-
-
-
-
-
- /*
- * Sets the Last-Modified entity header field, if it has not
- * already been set and if the value is meaningful. Called before
- * doGet, to ensure that headers are set before response data is
- * written. A subclass might have set this header already, so we
- * check.
- */
-
- private void maybeSetLastModified(HttpServletResponse resp,
- long lastModified) {
- if (resp.containsHeader(HEADER_LASTMOD))
- return;
- if (lastModified >= 0)
- resp.setDateHeader(HEADER_LASTMOD, lastModified);
- }
-
-
-
-
- /**
- *
- * Dispatches client requests to the protected
- * <code>service</code> method. There's no need to
- * override this method.
- *
- *
- * @param req the {@link HttpServletRequest} object that
- * contains the request the client made of
- * the servlet
- *
- *
- * @param res the {@link HttpServletResponse} object that
- * contains the response the servlet returns
- * to the client
- *
- *
- * @exception IOException if an input or output error occurs
- * while the servlet is handling the
- * TRACE request
- *
- * @exception ServletException if the request for the
- * TRACE cannot be handled
- *
- *
- * @see javax.servlet.Servlet#service
- *
- */
-
- public void service(ServletRequest req, ServletResponse res)
- throws ServletException, IOException
- {
- HttpServletRequest request;
- HttpServletResponse response;
-
- try {
- request = (HttpServletRequest) req;
- response = (HttpServletResponse) res;
- } catch (ClassCastException e) {
- throw new ServletException("non-HTTP request or response");
- }
- service(request, response);
- }
-}
-
-
-
-
-/*
- * A response that includes no body, for use in (dumb) "HEAD" support.
- * This just swallows that body, counting the bytes in order to set
- * the content length appropriately. All other methods delegate directly
- * to the HTTP Servlet Response object used to construct this one.
- */
-// file private
-class NoBodyResponse implements HttpServletResponse {
- private HttpServletResponse resp;
- private NoBodyOutputStream noBody;
- private PrintWriter writer;
- private boolean didSetContentLength;
-
- // file private
- NoBodyResponse(HttpServletResponse r) {
- resp = r;
- noBody = new NoBodyOutputStream();
- }
-
- // file private
- void setContentLength() {
- if (!didSetContentLength)
- resp.setContentLength(noBody.getContentLength());
- }
-
-
- // SERVLET RESPONSE interface methods
-
- public void setContentLength(int len) {
- resp.setContentLength(len);
- didSetContentLength = true;
- }
-
- public void setContentType(String type)
- { resp.setContentType(type); }
-
- public ServletOutputStream getOutputStream() throws IOException
- { return noBody; }
-
- public String getCharacterEncoding()
- { return resp.getCharacterEncoding(); }
-
- public PrintWriter getWriter() throws UnsupportedEncodingException
- {
- if (writer == null) {
- OutputStreamWriter w;
-
- w = new OutputStreamWriter(noBody, getCharacterEncoding());
- writer = new PrintWriter(w);
- }
- return writer;
- }
-
- public void addCookie(Cookie cookie)
- { resp.addCookie(cookie); }
-
- public boolean containsHeader(String name)
- { return resp.containsHeader(name); }
-
- /** @deprecated */
- public void setStatus(int sc, String sm)
- { resp.setStatus(sc, sm); }
-
- public void setStatus(int sc)
- { resp.setStatus(sc); }
-
- public void setHeader(String name, String value)
- { resp.setHeader(name, value); }
-
- public void setIntHeader(String name, int value)
- { resp.setIntHeader(name, value); }
-
- public void setDateHeader(String name, long date)
- { resp.setDateHeader(name, date); }
-
- public void sendError(int sc, String msg) throws IOException
- { resp.sendError(sc, msg); }
-
- public void sendError(int sc) throws IOException
- { resp.sendError(sc); }
-
- public void sendRedirect(String location) throws IOException
- { resp.sendRedirect(location); }
-
- public String encodeURL(String url)
- { return resp.encodeURL(url); }
-
- public String encodeRedirectURL(String url)
- { return resp.encodeRedirectURL(url); }
-
- /**
- * @deprecated As of Version 2.1, replaced by
- * {@link HttpServletResponse#encodeURL}.
- *
- */
-
-
- public String encodeUrl(String url)
- { return this.encodeURL(url); }
-
-
-
-
-
-
-
-
- /**
- * @deprecated As of Version 2.1, replaced by
- * {@link HttpServletResponse#encodeRedirectURL}.
- *
- */
-
-
- public String encodeRedirectUrl(String url)
- { return this.encodeRedirectURL(url); }
-
-}
-
-
-
-
-
-
-
-/*
- * Servlet output stream that gobbles up all its data.
- */
-
-// file private
-class NoBodyOutputStream extends ServletOutputStream {
-
- private static final String LSTRING_FILE =
- "javax.servlet.http.LocalStrings";
- private static ResourceBundle lStrings =
- ResourceBundle.getBundle(LSTRING_FILE);
-
- private int contentLength = 0;
-
- // file private
- NoBodyOutputStream() {}
-
- // file private
- int getContentLength() {
- return contentLength;
- }
-
- public void write(int b) {
- contentLength++;
- }
-
- public void write(byte buf[], int offset, int len)
- throws IOException
- {
- if (len >= 0) {
- contentLength += len;
- } else {
- // XXX
- // isn't this really an IllegalArgumentException?
-
- String msg = lStrings.getString("err.io.negativelength");
- throw new IOException(msg);
- }
- }
-}
diff --git a/javax.servlet/src/main/java/javax/servlet/http/HttpServletRequest.java b/javax.servlet/src/main/java/javax/servlet/http/HttpServletRequest.java
deleted file mode 100644
index 68c77cc..0000000
--- a/javax.servlet/src/main/java/javax/servlet/http/HttpServletRequest.java
+++ /dev/null
@@ -1,514 +0,0 @@
-/*
- * Copyright 1999,2005 The Apache Software Foundation.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-
-package javax.servlet.http;
-
-import javax.servlet.ServletRequest;
-import java.util.Enumeration;
-
-/**
- *
- * Extends the {@link javax.servlet.ServletRequest} interface
- * to provide request information for HTTP servlets.
- *
- * <p>The servlet container creates an <code>HttpServletRequest</code>
- * object and passes it as an argument to the servlet's service
- * methods (<code>doGet</code>, <code>doPost</code>, etc).
- *
- *
- * @author Various
- * @version $Version$
- *
- *
- */
-
-public interface HttpServletRequest extends ServletRequest {
-
- /**
- * Returns the name of the authentication scheme used to protect
- * the servlet, for example, "BASIC" or "SSL".
- * If the servlet is not authenticated <code>null</code> is returned.
- *
- * <p>Same as the value of the CGI variable AUTH_TYPE.
- *
- *
- * @return a <code>String</code> specifying the name of
- * the authentication scheme, or
- * <code>null</code> if the request was not
- * authenticated
- *
- */
-
- public String getAuthType();
-
-
-
-
- /**
- *
- * Returns an array containing all of the <code>Cookie</code>
- * objects the client sent with this request.
- * This method returns <code>null</code> if no cookies were sent.
- *
- * @return an array of all the <code>Cookies</code>
- * included with this request, or <code>null</code>
- * if the request has no cookies
- *
- *
- */
-
- public Cookie[] getCookies();
-
-
-
-
- /**
- *
- * Returns the value of the specified request header
- * as a <code>long</code> value that represents a
- * <code>Date</code> object. Use this method with
- * headers that contain dates, such as
- * <code>If-Modified-Since</code>.
- *
- * <p>The date is returned as
- * the number of milliseconds since January 1, 1970 GMT.
- * The header name is case insensitive.
- *
- * <p>If the request did not have a header of the
- * specified name, this method returns -1. If the header
- * can't be converted to a date, the method throws
- * an <code>IllegalArgumentException</code>.
- *
- * @param name a <code>String</code> specifying the
- * name of the header
- *
- * @return a <code>long</code> value
- * representing the date specified
- * in the header expressed as
- * the number of milliseconds
- * since January 1, 1970 GMT,
- * or -1 if the named header
- * was not included with the
- * reqest
- *
- * @exception IllegalArgumentException If the header value
- * can't be converted
- * to a date
- *
- */
-
- public long getDateHeader(String name);
-
-
-
-
- /**
- *
- * Returns the value of the specified request header
- * as a <code>String</code>. If the request did not include a header
- * of the specified name, this method returns <code>null</code>.
- * The header name is case insensitive. You can use
- * this method with any request header.
- *
- * @param name a <code>String</code> specifying the
- * header name
- *
- * @return a <code>String</code> containing the
- * value of the requested
- * header, or <code>null</code>
- * if the request does not
- * have a header of that name
- *
- */
-
- public String getHeader(String name);
-
-
-
-
- /**
- *
- * Returns an enumeration of all the header names
- * this request contains. If the request has no
- * headers, this method returns an empty enumeration.
- *
- * <p>Some servlet containers do not allow do not allow
- * servlets to access headers using this method, in
- * which case this method returns <code>null</code>
- *
- * @return an enumeration of all the
- * header names sent with this
- * request; if the request has
- * no headers, an empty enumeration;
- * if the servlet container does not
- * allow servlets to use this method,
- * <code>null</code>
- *
- *
- */
-
- public Enumeration getHeaderNames();
-
-
-
-
- /**
- *
- * Returns the value of the specified request header
- * as an <code>int</code>. If the request does not have a header
- * of the specified name, this method returns -1. If the
- * header cannot be converted to an integer, this method
- * throws a <code>NumberFormatException</code>.
- *
- * <p>The header name is case insensitive.
- *
- * @param name a <code>String</code> specifying the name
- * of a request header
- *
- * @return an integer expressing the value
- * of the request header or -1
- * if the request doesn't have a
- * header of this name
- *
- * @exception NumberFormatException If the header value
- * can't be converted
- * to an <code>int</code>
- */
-
- public int getIntHeader(String name);
-
-
-
-
- /**
- *
- * Returns the name of the HTTP method with which this
- * request was made, for example, GET, POST, or PUT.
- * Same as the value of the CGI variable REQUEST_METHOD.
- *
- * @return a <code>String</code>
- * specifying the name
- * of the method with which
- * this request was made
- *
- */
-
- public String getMethod();
-
-
-
-
- /**
- *
- * Returns any extra path information associated with
- * the URL the client sent when it made this request.
- * The extra path information follows the servlet path
- * but precedes the query string.
- * This method returns <code>null</code> if there
- * was no extra path information.
- *
- * <p>Same as the value of the CGI variable PATH_INFO.
- *
- *
- * @return a <code>String</code>, decoded by the
- * web container, specifying
- * extra path information that comes
- * after the servlet path but before
- * the query string in the request URL;
- * or <code>null</code> if the URL does not have
- * any extra path information
- *
- */
-
- public String getPathInfo();
-
-
-
-
- /**
- *
- * Returns any extra path information after the servlet name
- * but before the query string, and translates it to a real
- * path. Same as the value of the CGI variable PATH_TRANSLATED.
- *
- * <p>If the URL does not have any extra path information,
- * this method returns <code>null</code>.
- *
- * The web container does not decode this string.
- *
- *
- * @return a <code>String</code> specifying the
- * real path, or <code>null</code> if
- * the URL does not have any extra path
- * information
- *
- *
- */
-
- public String getPathTranslated();
-
-
-
-
- /**
- *
- * Returns the query string that is contained in the request
- * URL after the path. This method returns <code>null</code>
- * if the URL does not have a query string. Same as the value
- * of the CGI variable QUERY_STRING.
- *
- * @return a <code>String</code> containing the query
- * string or <code>null</code> if the URL
- * contains no query string. The value is not
- * decoded by the container.
- *
- */
-
- public String getQueryString();
-
-
-
-
- /**
- *
- * Returns the login of the user making this request, if the
- * user has been authenticated, or <code>null</code> if the user
- * has not been authenticated.
- * Whether the user name is sent with each subsequent request
- * depends on the browser and type of authentication. Same as the
- * value of the CGI variable REMOTE_USER.
- *
- * @return a <code>String</code> specifying the login
- * of the user making this request, or <code>null</code
- * if the user login is not known
- *
- */
-
- public String getRemoteUser();
-
-
-
-
- /**
- *
- * Returns the session ID specified by the client. This may
- * not be the same as the ID of the actual session in use.
- * For example, if the request specified an old (expired)
- * session ID and the server has started a new session, this
- * method gets a new session with a new ID. If the request
- * did not specify a session ID, this method returns
- * <code>null</code>.
- *
- *
- * @return a <code>String</code> specifying the session
- * ID, or <code>null</code> if the request did
- * not specify a session ID
- *
- * @see #isRequestedSessionIdValid
- *
- */
-
- public String getRequestedSessionId();
-
-
-
-
- /**
- *
- * Returns the part of this request's URL from the protocol
- * name up to the query string in the first line of the HTTP request.
- * The web container does not decode this String.
- * For example:
- *
- *
-
- * <table>
- * <tr align=left><th>First line of HTTP request </th>
- * <th> Returned Value</th>
- * <tr><td>POST /some/path.html HTTP/1.1<td><td>/some/path.html
- * <tr><td>GET http://foo.bar/a.html HTTP/1.0
- * <td><td>/a.html
- * <tr><td>HEAD /xyz?a=b HTTP/1.1<td><td>/xyz
- * </table>
- *
- * <p>To reconstruct an URL with a scheme and host, use
- * {@link HttpUtils#getRequestURL}.
- *
- * @return a <code>String</code> containing
- * the part of the URL from the
- * protocol name up to the query string
- *
- * @see HttpUtils#getRequestURL
- *
- */
-
- public String getRequestURI();
-
- /**
- *
- * Returns the part of this request's URL that calls
- * the servlet. This includes either the servlet name or
- * a path to the servlet, but does not include any extra
- * path information or a query string. Same as the value
- * of the CGI variable SCRIPT_NAME.
- *
- *
- * @return a <code>String</code> containing
- * the name or path of the servlet being
- * called, as specified in the request URL,
- * decoded.
- *
- *
- */
-
- public String getServletPath();
-
-
-
-
- /**
- *
- * Returns the current <code>HttpSession</code>
- * associated with this request or, if if there is no
- * current session and <code>create</code> is true, returns
- * a new session.
- *
- * <p>If <code>create</code> is <code>false</code>
- * and the request has no valid <code>HttpSession</code>,
- * this method returns <code>null</code>.
- *
- * <p>To make sure the session is properly maintained,
- * you must call this method before
- * the response is committed. If the container is using cookies
- * to maintain session integrity and is asked to create a new session
- * when the response is committed, an IllegalStateException is thrown.
- *
- *
- *
- *
- * @param create <code>true</code> to create
- * a new session for this request if necessary;
- * <code>false</code> to return <code>null</code>
- * if there's no current session
- *
- *
- * @return the <code>HttpSession</code> associated
- * with this request or <code>null</code> if
- * <code>create</code> is <code>false</code>
- * and the request has no valid session
- *
- * @see #getSession()
- *
- *
- */
-
- public HttpSession getSession(boolean create);
-
-
-
-
-
- /**
- *
- * Returns the current session associated with this request,
- * or if the request does not have a session, creates one.
- *
- * @return the <code>HttpSession</code> associated
- * with this request
- *
- * @see #getSession(boolean)
- *
- */
-
- public HttpSession getSession();
-
-
-
-
-
-
- /**
- *
- * Checks whether the requested session ID is still valid.
- *
- * @return <code>true</code> if this
- * request has an id for a valid session
- * in the current session context;
- * <code>false</code> otherwise
- *
- * @see #getRequestedSessionId
- * @see #getSession(boolean)
- * @see HttpSessionContext
- *
- */
-
- public boolean isRequestedSessionIdValid();
-
-
-
-
- /**
- *
- * Checks whether the requested session ID came in as a cookie.
- *
- * @return <code>true</code> if the session ID
- * came in as a
- * cookie; otherwise, <code>false</code>
- *
- *
- * @see #getSession(boolean)
- *
- */
-
- public boolean isRequestedSessionIdFromCookie();
-
-
-
-
- /**
- *
- * Checks whether the requested session ID came in as part of the
- * request URL.
- *
- * @return <code>true</code> if the session ID
- * came in as part of a URL; otherwise,
- * <code>false</code>
- *
- *
- * @see #getSession(boolean)
- *
- */
-
- public boolean isRequestedSessionIdFromURL();
-
-
-
-
-
- /**
- *
- * @deprecated As of Version 2.1 of the Java Servlet
- * API, use {@link #isRequestedSessionIdFromURL}
- * instead.
- *
- */
-
- public boolean isRequestedSessionIdFromUrl();
-
-
-
-}
diff --git a/javax.servlet/src/main/java/javax/servlet/http/HttpServletResponse.java b/javax.servlet/src/main/java/javax/servlet/http/HttpServletResponse.java
deleted file mode 100644
index 0335f6b..0000000
--- a/javax.servlet/src/main/java/javax/servlet/http/HttpServletResponse.java
+++ /dev/null
@@ -1,547 +0,0 @@
-/*
- * Copyright 1999,2005 The Apache Software Foundation.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package javax.servlet.http;
-
-import javax.servlet.ServletResponse;
-import java.io.IOException;
-
-/**
- *
- * Extends the {@link ServletResponse} interface to provide HTTP-specific
- * functionality in sending a response. For example, it has methods
- * to access HTTP headers and cookies.
- *
- * <p>The servlet container creates an <code>HttpServletRequest</code> object
- * and passes it as an argument to the servlet's service methods
- * (<code>doGet</code>, <code>doPost</code>, etc).
- *
- *
- * @author Various
- * @version $Version$
- *
- * @see javax.servlet.ServletResponse
- *
- */
-
-
-
-public interface HttpServletResponse extends ServletResponse {
-
- /**
- * Adds the specified cookie to the response. This method can be called
- * multiple times to set more than one cookie.
- *
- * @param cookie the Cookie to return to the client
- *
- */
-
- public void addCookie(Cookie cookie);
-
- /**
- * Returns a boolean indicating whether the named response header
- * has already been set.
- *
- * @param name the header name
- * @return <code>true</code> if the named response header
- * has already been set;
- * <code>false</code> otherwise
- */
-
- public boolean containsHeader(String name);
-
- /**
- * Encodes the specified URL by including the session ID in it,
- * or, if encoding is not needed, returns the URL unchanged.
- * The implementation of this method includes the logic to
- * determine whether the session ID needs to be encoded in the URL.
- * For example, if the browser supports cookies, or session
- * tracking is turned off, URL encoding is unnecessary.
- *
- * <p>For robust session tracking, all URLs emitted by a servlet
- * should be run through this
- * method. Otherwise, URL rewriting cannot be used with browsers
- * which do not support cookies.
- *
- * @param url the url to be encoded.
- * @return the encoded URL if encoding is needed;
- * the unchanged URL otherwise.
- */
-
- public String encodeURL(String url);
-
- /**
- * Encodes the specified URL for use in the
- * <code>sendRedirect</code> method or, if encoding is not needed,
- * returns the URL unchanged. The implementation of this method
- * includes the logic to determine whether the session ID
- * needs to be encoded in the URL. Because the rules for making
- * this determination can differ from those used to decide whether to
- * encode a normal link, this method is seperate from the
- * <code>encodeURL</code> method.
- *
- * <p>All URLs sent to the <code>HttpServletResponse.sendRedirect</code>
- * method should be run through this method. Otherwise, URL
- * rewriting cannot be used with browsers which do not support
- * cookies.
- *
- * @param url the url to be encoded.
- * @return the encoded URL if encoding is needed;
- * the unchanged URL otherwise.
- *
- * @see #sendRedirect
- * @see #encodeUrl
- */
-
- public String encodeRedirectURL(String url);
-
- /**
- * @deprecated As of version 2.1, use encodeURL(String url) instead
- *
- * @param url the url to be encoded.
- * @return the encoded URL if encoding is needed;
- * the unchanged URL otherwise.
- */
-
- public String encodeUrl(String url);
-
- /**
- * @deprecated As of version 2.1, use
- * encodeRedirectURL(String url) instead
- *
- * @param url the url to be encoded.
- * @return the encoded URL if encoding is needed;
- * the unchanged URL otherwise.
- */
-
- public String encodeRedirectUrl(String url);
-
- /**
- * Sends an error response to the client using the specified
- * status clearing the buffer. The server defaults to creating the
- * response to look like an HTML-formatted server error page containing the specified message, setting the content type
- * to "text/html", leaving cookies and other headers unmodified.
- *
- * If an error-page declaration has been made for the web application
- * corresponding to the status code passed in, it will be served back in
- * preference to the suggested msg parameter.
- *
- * <p>If the response has already been committed, this method throws
- * an IllegalStateException.
- * After using this method, the response should be considered
- * to be committed and should not be written to.
- *
- * @param sc the error status code
- * @param msg the descriptive message
- * @exception IOException If an input or output exception occurs
- * @exception IllegalStateException If the response was committed
- */
-
- public void sendError(int sc, String msg) throws IOException;
-
- /**
- * Sends an error response to the client using the specified status
- * code and clearing the buffer.
- * <p>If the response has already been committed, this method throws
- * an IllegalStateException.
- * After using this method, the response should be considered
- * to be committed and should not be written to.
- *
- * @param sc the error status code
- * @exception IOException If an input or output exception occurs
- * @exception IllegalStateException If the response was committed
- * before this method call
- */
-
- public void sendError(int sc) throws IOException;
-
- /**
- * Sends a temporary redirect response to the client using the
- * specified redirect location URL. This method can accept relative URLs;
- * the servlet container must convert the relative URL to an absolute URL
- * before sending the response to the client. If the location is relative
- * without a leading '/' the container interprets it as relative to
- * the current request URI. If the location is relative with a leading
- * '/' the container interprets it as relative to the servlet container root.
- *
- * <p>If the response has already been committed, this method throws
- * an IllegalStateException.
- * After using this method, the response should be considered
- * to be committed and should not be written to.
- *
- * @param location the redirect location URL
- * @exception IOException If an input or output exception occurs
- * @exception IllegalStateException If the response was committed
- */
-
- public void sendRedirect(String location) throws IOException;
-
- /**
- *
- * Sets a response header with the given name and
- * date-value. The date is specified in terms of
- * milliseconds since the epoch. If the header had already
- * been set, the new value overwrites the previous one. The
- * <code>containsHeader</code> method can be used to test for the
- * presence of a header before setting its value.
- *
- * @param name the name of the header to set
- * @param date the assigned date value
- *
- * @see #containsHeader
- */
-
- public void setDateHeader(String name, long date);
-
- /**
- *
- * Sets a response header with the given name and value.
- * If the header had already been set, the new value overwrites the
- * previous one. The <code>containsHeader</code> method can be
- * used to test for the presence of a header before setting its
- * value.
- *
- * @param name the name of the header
- * @param value the header value
- *
- * @see #containsHeader
- */
-
- public void setHeader(String name, String value);
-
- /**
- * Sets a response header with the given name and
- * integer value. If the header had already been set, the new value
- * overwrites the previous one. The <code>containsHeader</code>
- * method can be used to test for the presence of a header before
- * setting its value.
- *
- * @param name the name of the header
- * @param value the assigned integer value
- *
- * @see #containsHeader
- */
-
- public void setIntHeader(String name, int value);
-
- /**
- * Sets the status code for this response. This method is used to
- * set the return status code when there is no error (for example,
- * for the status codes SC_OK or SC_MOVED_TEMPORARILY). If there
- * is an error, the <code>sendError</code> method should be used
- * instead.
- * <p> The container clears the buffer and sets the Location header, preserving
- * cookies and other headers.
- *
- * @param sc the status code
- *
- * @see #sendError(int, String)
- */
-
- public void setStatus(int sc);
-
- /**
- * @deprecated As of version 2.1, due to ambiguous meaning of the
- * message parameter. To set a status code
- * use <code>setStatus(int)</code>, to send an error with a description
- * use <code>sendError(int, String)</code>.
- *
- * Sets the status code and message for this response.
- *
- * @param sc the status code
- * @param sm the status message
- */
-
- public void setStatus(int sc, String sm);
-
-
- /*
- * Server status codes; see RFC 2068.
- */
-
- /**
- * Status code (100) indicating the client can continue.
- */
-
- public static final int SC_CONTINUE = 100;
-
-
- /**
- * Status code (101) indicating the server is switching protocols
- * according to Upgrade header.
- */
-
- public static final int SC_SWITCHING_PROTOCOLS = 101;
-
- /**
- * Status code (200) indicating the request succeeded normally.
- */
-
- public static final int SC_OK = 200;
-
- /**
- * Status code (201) indicating the request succeeded and created
- * a new resource on the server.
- */
-
- public static final int SC_CREATED = 201;
-
- /**
- * Status code (202) indicating that a request was accepted for
- * processing, but was not completed.
- */
-
- public static final int SC_ACCEPTED = 202;
-
- /**
- * Status code (203) indicating that the meta information presented
- * by the client did not originate from the server.
- */
-
- public static final int SC_NON_AUTHORITATIVE_INFORMATION = 203;
-
- /**
- * Status code (204) indicating that the request succeeded but that
- * there was no new information to return.
- */
-
- public static final int SC_NO_CONTENT = 204;
-
- /**
- * Status code (205) indicating that the agent <em>SHOULD</em> reset
- * the document view which caused the request to be sent.
- */
-
- public static final int SC_RESET_CONTENT = 205;
-
- /**
- * Status code (206) indicating that the server has fulfilled
- * the partial GET request for the resource.
- */
-
- public static final int SC_PARTIAL_CONTENT = 206;
-
- /**
- * Status code (300) indicating that the requested resource
- * corresponds to any one of a set of representations, each with
- * its own specific location.
- */
-
- public static final int SC_MULTIPLE_CHOICES = 300;
-
- /**
- * Status code (301) indicating that the resource has permanently
- * moved to a new location, and that future references should use a
- * new URI with their requests.
- */
-
- public static final int SC_MOVED_PERMANENTLY = 301;
-
- /**
- * Status code (302) indicating that the resource has temporarily
- * moved to another location, but that future references should
- * still use the original URI to access the resource.
- */
-
- public static final int SC_MOVED_TEMPORARILY = 302;
-
- /**
- * Status code (303) indicating that the response to the request
- * can be found under a different URI.
- */
-
- public static final int SC_SEE_OTHER = 303;
-
- /**
- * Status code (304) indicating that a conditional GET operation
- * found that the resource was available and not modified.
- */
-
- public static final int SC_NOT_MODIFIED = 304;
-
- /**
- * Status code (305) indicating that the requested resource
- * <em>MUST</em> be accessed through the proxy given by the
- * <code><em>Location</em></code> field.
- */
-
- public static final int SC_USE_PROXY = 305;
-
- /**
- * Status code (400) indicating the request sent by the client was
- * syntactically incorrect.
- */
-
- public static final int SC_BAD_REQUEST = 400;
-
- /**
- * Status code (401) indicating that the request requires HTTP
- * authentication.
- */
-
- public static final int SC_UNAUTHORIZED = 401;
-
- /**
- * Status code (402) reserved for future use.
- */
-
- public static final int SC_PAYMENT_REQUIRED = 402;
-
- /**
- * Status code (403) indicating the server understood the request
- * but refused to fulfill it.
- */
-
- public static final int SC_FORBIDDEN = 403;
-
- /**
- * Status code (404) indicating that the requested resource is not
- * available.
- */
-
- public static final int SC_NOT_FOUND = 404;
-
- /**
- * Status code (405) indicating that the method specified in the
- * <code><em>Request-Line</em></code> is not allowed for the resource
- * identified by the <code><em>Request-URI</em></code>.
- */
-
- public static final int SC_METHOD_NOT_ALLOWED = 405;
-
- /**
- * Status code (406) indicating that the resource identified by the
- * request is only capable of generating response entities which have
- * content characteristics not acceptable according to the accept
- * headerssent in the request.
- */
-
- public static final int SC_NOT_ACCEPTABLE = 406;
-
- /**
- * Status code (407) indicating that the client <em>MUST</em> first
- * authenticate itself with the proxy.
- */
-
- public static final int SC_PROXY_AUTHENTICATION_REQUIRED = 407;
-
- /**
- * Status code (408) indicating that the client did not produce a
- * requestwithin the time that the server was prepared to wait.
- */
-
- public static final int SC_REQUEST_TIMEOUT = 408;
-
- /**
- * Status code (409) indicating that the request could not be
- * completed due to a conflict with the current state of the
- * resource.
- */
-
- public static final int SC_CONFLICT = 409;
-
- /**
- * Status code (410) indicating that the resource is no longer
- * available at the server and no forwarding address is known.
- * This condition <em>SHOULD</em> be considered permanent.
- */
-
- public static final int SC_GONE = 410;
-
- /**
- * Status code (411) indicating that the request cannot be handled
- * without a defined <code><em>Content-Length</em></code>.
- */
-
- public static final int SC_LENGTH_REQUIRED = 411;
-
- /**
- * Status code (412) indicating that the precondition given in one
- * or more of the request-header fields evaluated to false when it
- * was tested on the server.
- */
-
- public static final int SC_PRECONDITION_FAILED = 412;
-
- /**
- * Status code (413) indicating that the server is refusing to process
- * the request because the request entity is larger than the server is
- * willing or able to process.
- */
-
- public static final int SC_REQUEST_ENTITY_TOO_LARGE = 413;
-
- /**
- * Status code (414) indicating that the server is refusing to service
- * the request because the <code><em>Request-URI</em></code> is longer
- * than the server is willing to interpret.
- */
-
- public static final int SC_REQUEST_URI_TOO_LONG = 414;
-
- /**
- * Status code (415) indicating that the server is refusing to service
- * the request because the entity of the request is in a format not
- * supported by the requested resource for the requested method.
- */
-
- public static final int SC_UNSUPPORTED_MEDIA_TYPE = 415;
-
- /**
- * Status code (500) indicating an error inside the HTTP server
- * which prevented it from fulfilling the request.
- */
-
- public static final int SC_INTERNAL_SERVER_ERROR = 500;
-
- /**
- * Status code (501) indicating the HTTP server does not support
- * the functionality needed to fulfill the request.
- */
-
- public static final int SC_NOT_IMPLEMENTED = 501;
-
- /**
- * Status code (502) indicating that the HTTP server received an
- * invalid response from a server it consulted when acting as a
- * proxy or gateway.
- */
-
- public static final int SC_BAD_GATEWAY = 502;
-
- /**
- * Status code (503) indicating that the HTTP server is
- * temporarily overloaded, and unable to handle the request.
- */
-
- public static final int SC_SERVICE_UNAVAILABLE = 503;
-
- /**
- * Status code (504) indicating that the server did not receive
- * a timely response from the upstream server while acting as
- * a gateway or proxy.
- */
-
- public static final int SC_GATEWAY_TIMEOUT = 504;
-
- /**
- * Status code (505) indicating that the server does not support
- * or refuses to support the HTTP protocol version that was used
- * in the request message.
- */
-
- public static final int SC_HTTP_VERSION_NOT_SUPPORTED = 505;
-}
diff --git a/javax.servlet/src/main/java/javax/servlet/http/HttpSession.java b/javax.servlet/src/main/java/javax/servlet/http/HttpSession.java
deleted file mode 100644
index 94872a1..0000000
--- a/javax.servlet/src/main/java/javax/servlet/http/HttpSession.java
+++ /dev/null
@@ -1,294 +0,0 @@
-/*
- * Copyright 1999,2005 The Apache Software Foundation.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package javax.servlet.http;
-
-
-/**
- *
- * Provides a way to identify a user across more than one page
- * request or visit to a Web site and to store information about that user.
- *
- * <p>The servlet container uses this interface to create a session
- * between an HTTP client and an HTTP server. The session persists
- * for a specified time period, across more than one connection or
- * page request from the user. A session usually corresponds to one
- * user, who may visit a site many times. The server can maintain a
- * session in many ways such as using cookies or rewriting URLs.
- *
- * <p>This interface allows servlets to
- * <ul>
- * <li>View and manipulate information about a session, such as
- * the session identifier, creation time, and last accessed time
- * <li>Bind objects to sessions, allowing user information to persist
- * across multiple user connections
- * </ul>
- *
- * <p>When an application stores an object in or removes an object from a
- * session, the session checks whether the object implements
- * {@link HttpSessionBindingListener}. If it does,
- * the servlet notifies the object that it has been bound to or unbound
- * from the session. Notifications are sent after the binding methods complete.
- * For session that are invalidated or expire, notifications are sent after
- * the session has been invalidatd or expired.
- *
- * <p>A servlet should be able to handle cases in which
- * the client does not choose to join a session, such as when cookies are
- * intentionally turned off. Until the client joins the session,
- * <code>isNew</code> returns <code>true</code>. If the client chooses
- * not to join
- * the session, <code>getSession</code> will return a different session
- * on each request, and <code>isNew</code> will always return
- * <code>true</code>.
- *
- * <p>Session information is scoped only to the current web application
- * (<code>ServletContext</code>), so information stored in one context
- * will not be directly visible in another.
- *
- * @author Various
- * @version $Version$
- *
- *
- * @see HttpSessionBindingListener
- * @see HttpSessionContext
- *
- */
-
-public interface HttpSession {
-
-
-
-
- /**
- *
- * Returns the time when this session was created, measured
- * in milliseconds since midnight January 1, 1970 GMT.
- *
- * @return a <code>long</code> specifying
- * when this session was created,
- * expressed in
- * milliseconds since 1/1/1970 GMT
- *
- * @exception IllegalStateException if this method is called on an
- * invalidated session
- *
- */
-
- public long getCreationTime();
-
-
-
-
- /**
- *
- * Returns a string containing the unique identifier assigned
- * to this session. The identifier is assigned
- * by the servlet container and is implementation dependent.
- *
- * @return a string specifying the identifier
- * assigned to this session
- *
- * @exeption IllegalStateException if this method is called on an
- * invalidated session
- *
- */
-
- public String getId();
-
-
-
-
- /**
- *
- * Returns the last time the client sent a request associated with
- * this session, as the number of milliseconds since midnight
- * January 1, 1970 GMT, and marked by the time the container recieved the request.
- *
- * <p>Actions that your application takes, such as getting or setting
- * a value associated with the session, do not affect the access
- * time.
- *
- * @return a <code>long</code>
- * representing the last time
- * the client sent a request associated
- * with this session, expressed in
- * milliseconds since 1/1/1970 GMT
- *
- * @exeption IllegalStateException if this method is called on an
- * invalidated session
- *
- */
-
- public long getLastAccessedTime();
-
-
- /**
- *
- * Specifies the time, in seconds, between client requests before the
- * servlet container will invalidate this session. A negative time
- * indicates the session should never timeout.
- *
- * @param interval An integer specifying the number
- * of seconds
- *
- */
-
- public void setMaxInactiveInterval(int interval);
-
-
-
-
- /**
- * Returns the maximum time interval, in seconds, that
- * the servlet container will keep this session open between
- * client accesses. After this interval, the servlet container
- * will invalidate the session. The maximum time interval can be set
- * with the <code>setMaxInactiveInterval</code> method.
- * A negative time indicates the session should never timeout.
- *
- *
- * @return an integer specifying the number of
- * seconds this session remains open
- * between client requests
- *
- * @see #setMaxInactiveInterval
- *
- *
- */
-
- public int getMaxInactiveInterval();
-
-
-
-
- /**
- *
- * @deprecated As of Version 2.1, this method is
- * deprecated and has no replacement.
- * It will be removed in a future
- * version of the Java Servlet API.
- *
- */
-
- public HttpSessionContext getSessionContext();
-
-
-
-
- /**
- *
- *
- * @param name a string specifying the name of the object
- *
- * @return the object with the specified name
- *
- * @exception IllegalStateException if this method is called on an
- * invalidated session
- *
- */
-
- public Object getValue(String name);
-
-
-
-
- /**
- *
- *
- * @return an array of <code>String</code>
- * objects specifying the
- * names of all the objects bound to
- * this session
- *
- * @exception IllegalStateException if this method is called on an
- * invalidated session
- *
- */
-
- public String[] getValueNames();
-
-
-
-
- /**
- *
- *
- * @param name the name to which the object is bound;
- * cannot be null
- *
- * @param value the object to be bound; cannot be null
- *
- * @exception IllegalStateException if this method is called on an
- * invalidated session
- *
- */
-
- public void putValue(String name, Object value);
-
-
-
-
-
- /**
- *
- *
- * @param name the name of the object to
- * remove from this session
- *
- * @exception IllegalStateException if this method is called on an
- * invalidated session
- */
-
- public void removeValue(String name);
-
-
-
-
- /**
- *
- * Invalidates this session then unbinds any objects bound
- * to it.
- *
- * @exception IllegalStateException if this method is called on an
- * already invalidated session
- *
- */
-
- public void invalidate();
-
-
-
-
- /**
- *
- * Returns <code>true</code> if the client does not yet know about the
- * session or if the client chooses not to join the session. For
- * example, if the server used only cookie-based sessions, and
- * the client had disabled the use of cookies, then a session would
- * be new on each request.
- *
- * @return <code>true</code> if the
- * server has created a session,
- * but the client has not yet joined
- *
- * @exception IllegalStateException if this method is called on an
- * already invalidated session
- *
- */
-
- public boolean isNew();
-}
-
diff --git a/javax.servlet/src/main/java/javax/servlet/http/HttpSessionBindingEvent.java b/javax.servlet/src/main/java/javax/servlet/http/HttpSessionBindingEvent.java
deleted file mode 100644
index f967ad9..0000000
--- a/javax.servlet/src/main/java/javax/servlet/http/HttpSessionBindingEvent.java
+++ /dev/null
@@ -1,127 +0,0 @@
-/*
- * Copyright 1999,2005 The Apache Software Foundation.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-
-package javax.servlet.http;
-
-import java.util.EventObject;
-
-
-/**
- *
- * Sent to an object that implements
- * {@link HttpSessionBindingListener} when the object is
- * bound to or unbound from the session.
- *
- * <p>The session binds the object by a call to
- * <code>HttpSession.putValue</code> and unbinds the object
- * by a call to <code>HttpSession.removeValue</code>.
- *
- *
- *
- * @author Various
- * @version $Version$
- *
- * @see HttpSession
- * @see HttpSessionBindingListener
- *
- */
-
-public class HttpSessionBindingEvent extends EventObject {
-
-
-
-
- /* The name to which the object is being bound or unbound */
-
- private String name;
-
-
-
- /**
- *
- * Constructs an event that notifies an object that it
- * has been bound to or unbound from a session.
- * To receive the event, the object must implement
- * {@link HttpSessionBindingListener}.
- *
- *
- *
- * @param session the session to which the object is bound or unbound
- *
- * @param name the name with which the object is bound or unbound
- *
- * @see #getName
- * @see #getSession
- *
- */
-
- public HttpSessionBindingEvent(HttpSession session, String name) {
- super(session);
- this.name = name;
- }
-
-
-
-
-
-
- /**
- *
- * Returns the name with which the object is bound to or
- * unbound from the session.
- *
- *
- * @return a string specifying the name with which
- * the object is bound to or unbound from
- * the session
- *
- *
- */
-
- public String getName() {
- return name;
- }
-
-
-
-
-
-
- /**
- *
- * Returns the session to or from which the object is
- * bound or unbound.
- *
- * @return the session to which the object is
- * bound or from which the object is
- * unbound
- *
- *
- *
- */
-
- public HttpSession getSession() {
- return (HttpSession) getSource();
- }
-}
-
-
-
-
-
-
-
diff --git a/javax.servlet/src/main/java/javax/servlet/http/HttpSessionBindingListener.java b/javax.servlet/src/main/java/javax/servlet/http/HttpSessionBindingListener.java
deleted file mode 100644
index f78e1fe..0000000
--- a/javax.servlet/src/main/java/javax/servlet/http/HttpSessionBindingListener.java
+++ /dev/null
@@ -1,76 +0,0 @@
-/*
- * Copyright 1999,2005 The Apache Software Foundation.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-
-package javax.servlet.http;
-
-import java.util.EventListener;
-
-
-
-
-
-/**
- * Causes an object to be notified when it is bound to
- * or unbound from a session. The object is notified
- * by an {@link HttpSessionBindingEvent} object.
- *
- *
- * @author Various
- * @version $Version$
- *
- * @see HttpSession
- * @see HttpSessionBindingEvent
- *
- */
-
-public interface HttpSessionBindingListener extends EventListener {
-
-
-
- /**
- *
- * Notifies the object that it is being bound to
- * a session and identifies the session.
- *
- * @param event the event that identifies the
- * session
- *
- * @see #valueUnbound
- *
- */
-
- public void valueBound(HttpSessionBindingEvent event);
-
-
-
- /**
- *
- * Notifies the object that it is being unbound
- * from a session and identifies the session.
- *
- * @param event the event that identifies
- * the session
- *
- * @see #valueBound
- *
- */
-
- public void valueUnbound(HttpSessionBindingEvent event);
-
-
-}
-
diff --git a/javax.servlet/src/main/java/javax/servlet/http/HttpSessionContext.java b/javax.servlet/src/main/java/javax/servlet/http/HttpSessionContext.java
deleted file mode 100644
index 85b776a..0000000
--- a/javax.servlet/src/main/java/javax/servlet/http/HttpSessionContext.java
+++ /dev/null
@@ -1,70 +0,0 @@
-/*
- * Copyright 1999,2005 The Apache Software Foundation.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-
-package javax.servlet.http;
-
-import java.util.Enumeration;
-
-/**
- *
- * @author Various
- * @version $Version$
- *
- * @deprecated As of Java(tm) Servlet API 2.1
- * for security reasons, with no replacement.
- * This interface will be removed in a future
- * version of this API.
- *
- * @see HttpSession
- * @see HttpSessionBindingEvent
- * @see HttpSessionBindingListener
- *
- */
-
-
-public interface HttpSessionContext {
-
- /**
- *
- * @deprecated As of Java Servlet API 2.1 with
- * no replacement. This method must
- * return null and will be removed in
- * a future version of this API.
- *
- */
-
- public HttpSession getSession(String sessionId);
-
-
-
-
- /**
- *
- * @deprecated As of Java Servlet API 2.1 with
- * no replacement. This method must return
- * an empty <code>Enumeration</code> and will be removed
- * in a future version of this API.
- *
- */
-
- public Enumeration getIds();
-}
-
-
-
-
-
diff --git a/javax.servlet/src/main/java/javax/servlet/http/HttpUtils.java b/javax.servlet/src/main/java/javax/servlet/http/HttpUtils.java
deleted file mode 100644
index 99e4ed6..0000000
--- a/javax.servlet/src/main/java/javax/servlet/http/HttpUtils.java
+++ /dev/null
@@ -1,308 +0,0 @@
-/*
- * Copyright 1999,2005 The Apache Software Foundation.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-
-package javax.servlet.http;
-
-import javax.servlet.ServletInputStream;
-import java.util.Hashtable;
-import java.util.ResourceBundle;
-import java.util.StringTokenizer;
-import java.io.IOException;
-
-
-/**
- * Provides a collection of methods that are useful
- * in writing HTTP servlets.
- *
- */
-
-
-public class HttpUtils {
-
- private static final String LSTRING_FILE =
- "javax.servlet.http.LocalStrings";
- private static ResourceBundle lStrings =
- ResourceBundle.getBundle(LSTRING_FILE);
-
- static Hashtable nullHashtable = new Hashtable();
-
-
-
- /**
- * Constructs an empty <code>HttpUtils</code> object.
- *
- */
-
- public HttpUtils() {}
-
-
-
-
-
- /**
- *
- * Parses a query string passed from the client to the
- * server and builds a <code>HashTable</code> object
- * with key-value pairs.
- * The query string should be in the form of a string
- * packaged by the GET or POST method, that is, it
- * should have key-value pairs in the form <i>key=value</i>,
- * with each pair separated from the next by a & character.
- *
- * <p>A key can appear more than once in the query string
- * with different values. However, the key appears only once in
- * the hashtable, with its value being
- * an array of strings containing the multiple values sent
- * by the query string.
- *
- * <p>The keys and values in the hashtable are stored in their
- * decoded form, so
- * any + characters are converted to spaces, and characters
- * sent in hexadecimal notation (like <i>%xx</i>) are
- * converted to ASCII characters.
- *
- * @param s a string containing the query to be parsed
- *
- * @return a <code>HashTable</code> object built
- * from the parsed key-value pairs
- *
- * @exception IllegalArgumentException if the query string
- * is invalid
- *
- */
-
- static public Hashtable parseQueryString(String s) {
-
- String valArray[] = null;
-
- if (s == null) {
- throw new IllegalArgumentException();
- }
- Hashtable ht = new Hashtable();
- StringBuffer sb = new StringBuffer();
- StringTokenizer st = new StringTokenizer(s, "&");
- while (st.hasMoreTokens()) {
- String pair = (String)st.nextToken();
- int pos = pair.indexOf('=');
- if (pos == -1) {
- // XXX
- // should give more detail about the illegal argument
- throw new IllegalArgumentException();
- }
- String key = parseName(pair.substring(0, pos), sb);
- String val = parseName(pair.substring(pos+1, pair.length()), sb);
- if (ht.containsKey(key)) {
- String oldVals[] = (String []) ht.get(key);
- valArray = new String[oldVals.length + 1];
- for (int i = 0; i < oldVals.length; i++)
- valArray[i] = oldVals[i];
- valArray[oldVals.length] = val;
- } else {
- valArray = new String[1];
- valArray[0] = val;
- }
- ht.put(key, valArray);
- }
- return ht;
- }
-
-
-
-
- /**
- *
- * Parses data from an HTML form that the client sends to
- * the server using the HTTP POST method and the
- * <i>application/x-www-form-urlencoded</i> MIME type.
- *
- * <p>The data sent by the POST method contains key-value
- * pairs. A key can appear more than once in the POST data
- * with different values. However, the key appears only once in
- * the hashtable, with its value being
- * an array of strings containing the multiple values sent
- * by the POST method.
- *
- * <p>The keys and values in the hashtable are stored in their
- * decoded form, so
- * any + characters are converted to spaces, and characters
- * sent in hexadecimal notation (like <i>%xx</i>) are
- * converted to ASCII characters.
- *
- *
- *
- * @param len an integer specifying the length,
- * in characters, of the
- * <code>ServletInputStream</code>
- * object that is also passed to this
- * method
- *
- * @param in the <code>ServletInputStream</code>
- * object that contains the data sent
- * from the client
- *
- * @return a <code>HashTable</code> object built
- * from the parsed key-value pairs
- *
- *
- * @exception IllegalArgumentException if the data
- * sent by the POST method is invalid
- *
- */
-
-
- static public Hashtable parsePostData(int len,
- ServletInputStream in)
- {
- // XXX
- // should a length of 0 be an IllegalArgumentException
-
- if (len <=0)
- return new Hashtable(); // cheap hack to return an empty hash
-
- if (in == null) {
- throw new IllegalArgumentException();
- }
-
- //
- // Make sure we read the entire POSTed body.
- //
- byte[] postedBytes = new byte [len];
- try {
- int offset = 0;
-
- do {
- int inputLen = in.read (postedBytes, offset, len - offset);
- if (inputLen <= 0) {
- String msg = lStrings.getString("err.io.short_read");
- throw new IllegalArgumentException (msg);
- }
- offset += inputLen;
- } while ((len - offset) > 0);
-
- } catch (IOException e) {
- throw new IllegalArgumentException(e.getMessage());
- }
-
- // XXX we shouldn't assume that the only kind of POST body
- // is FORM data encoded using ASCII or ISO Latin/1 ... or
- // that the body should always be treated as FORM data.
- //
-
- try {
- String postedBody = new String(postedBytes, 0, len, "8859_1");
- return parseQueryString(postedBody);
- } catch (java.io.UnsupportedEncodingException e) {
- // XXX function should accept an encoding parameter & throw this
- // exception. Otherwise throw something expected.
- throw new IllegalArgumentException(e.getMessage());
- }
- }
-
-
-
-
- /*
- * Parse a name in the query string.
- */
-
- static private String parseName(String s, StringBuffer sb) {
- sb.setLength(0);
- for (int i = 0; i < s.length(); i++) {
- char c = s.charAt(i);
- switch (c) {
- case '+':
- sb.append(' ');
- break;
- case '%':
- try {
- sb.append((char) Integer.parseInt(s.substring(i+1, i+3),
- 16));
- i += 2;
- } catch (NumberFormatException e) {
- // XXX
- // need to be more specific about illegal arg
- throw new IllegalArgumentException();
- } catch (StringIndexOutOfBoundsException e) {
- String rest = s.substring(i);
- sb.append(rest);
- if (rest.length()==2)
- i++;
- }
-
- break;
- default:
- sb.append(c);
- break;
- }
- }
- return sb.toString();
- }
-
-
-
-
- /**
- *
- * Reconstructs the URL the client used to make the request,
- * using information in the <code>HttpServletRequest</code> object.
- * The returned URL contains a protocol, server name, port
- * number, and server path, but it does not include query
- * string parameters.
- *
- * <p>Because this method returns a <code>StringBuffer</code>,
- * not a string, you can modify the URL easily, for example,
- * to append query parameters.
- *
- * <p>This method is useful for creating redirect messages
- * and for reporting errors.
- *
- * @param req a <code>HttpServletRequest</code> object
- * containing the client's request
- *
- * @return a <code>StringBuffer</code> object containing
- * the reconstructed URL
- *
- */
-
- public static StringBuffer getRequestURL (HttpServletRequest req) {
- StringBuffer url = new StringBuffer ();
- String scheme = req.getScheme ();
- int port = req.getServerPort ();
- String urlPath = req.getRequestURI();
-
- //String servletPath = req.getServletPath ();
- //String pathInfo = req.getPathInfo ();
-
- url.append (scheme); // http, https
- url.append ("://");
- url.append (req.getServerName ());
- if ((scheme.equals ("http") && port != 80)
- || (scheme.equals ("https") && port != 443)) {
- url.append (':');
- url.append (req.getServerPort ());
- }
- //if (servletPath != null)
- // url.append (servletPath);
- //if (pathInfo != null)
- // url.append (pathInfo);
- url.append(urlPath);
- return url;
- }
-}
-
-
-
diff --git a/javax.servlet/src/main/resources/META-INF/LICENSE b/javax.servlet/src/main/resources/META-INF/LICENSE
deleted file mode 100644
index d645695..0000000
--- a/javax.servlet/src/main/resources/META-INF/LICENSE
+++ /dev/null
@@ -1,202 +0,0 @@
-
- Apache License
- Version 2.0, January 2004
- http://www.apache.org/licenses/
-
- TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
-
- 1. Definitions.
-
- "License" shall mean the terms and conditions for use, reproduction,
- and distribution as defined by Sections 1 through 9 of this document.
-
- "Licensor" shall mean the copyright owner or entity authorized by
- the copyright owner that is granting the License.
-
- "Legal Entity" shall mean the union of the acting entity and all
- other entities that control, are controlled by, or are under common
- control with that entity. For the purposes of this definition,
- "control" means (i) the power, direct or indirect, to cause the
- direction or management of such entity, whether by contract or
- otherwise, or (ii) ownership of fifty percent (50%) or more of the
- outstanding shares, or (iii) beneficial ownership of such entity.
-
- "You" (or "Your") shall mean an individual or Legal Entity
- exercising permissions granted by this License.
-
- "Source" form shall mean the preferred form for making modifications,
- including but not limited to software source code, documentation
- source, and configuration files.
-
- "Object" form shall mean any form resulting from mechanical
- transformation or translation of a Source form, including but
- not limited to compiled object code, generated documentation,
- and conversions to other media types.
-
- "Work" shall mean the work of authorship, whether in Source or
- Object form, made available under the License, as indicated by a
- copyright notice that is included in or attached to the work
- (an example is provided in the Appendix below).
-
- "Derivative Works" shall mean any work, whether in Source or Object
- form, that is based on (or derived from) the Work and for which the
- editorial revisions, annotations, elaborations, or other modifications
- represent, as a whole, an original work of authorship. For the purposes
- of this License, Derivative Works shall not include works that remain
- separable from, or merely link (or bind by name) to the interfaces of,
- the Work and Derivative Works thereof.
-
- "Contribution" shall mean any work of authorship, including
- the original version of the Work and any modifications or additions
- to that Work or Derivative Works thereof, that is intentionally
- submitted to Licensor for inclusion in the Work by the copyright owner
- or by an individual or Legal Entity authorized to submit on behalf of
- the copyright owner. For the purposes of this definition, "submitted"
- means any form of electronic, verbal, or written communication sent
- to the Licensor or its representatives, including but not limited to
- communication on electronic mailing lists, source code control systems,
- and issue tracking systems that are managed by, or on behalf of, the
- Licensor for the purpose of discussing and improving the Work, but
- excluding communication that is conspicuously marked or otherwise
- designated in writing by the copyright owner as "Not a Contribution."
-
- "Contributor" shall mean Licensor and any individual or Legal Entity
- on behalf of whom a Contribution has been received by Licensor and
- subsequently incorporated within the Work.
-
- 2. Grant of Copyright License. Subject to the terms and conditions of
- this License, each Contributor hereby grants to You a perpetual,
- worldwide, non-exclusive, no-charge, royalty-free, irrevocable
- copyright license to reproduce, prepare Derivative Works of,
- publicly display, publicly perform, sublicense, and distribute the
- Work and such Derivative Works in Source or Object form.
-
- 3. Grant of Patent License. Subject to the terms and conditions of
- this License, each Contributor hereby grants to You a perpetual,
- worldwide, non-exclusive, no-charge, royalty-free, irrevocable
- (except as stated in this section) patent license to make, have made,
- use, offer to sell, sell, import, and otherwise transfer the Work,
- where such license applies only to those patent claims licensable
- by such Contributor that are necessarily infringed by their
- Contribution(s) alone or by combination of their Contribution(s)
- with the Work to which such Contribution(s) was submitted. If You
- institute patent litigation against any entity (including a
- cross-claim or counterclaim in a lawsuit) alleging that the Work
- or a Contribution incorporated within the Work constitutes direct
- or contributory patent infringement, then any patent licenses
- granted to You under this License for that Work shall terminate
- as of the date such litigation is filed.
-
- 4. Redistribution. You may reproduce and distribute copies of the
- Work or Derivative Works thereof in any medium, with or without
- modifications, and in Source or Object form, provided that You
- meet the following conditions:
-
- (a) You must give any other recipients of the Work or
- Derivative Works a copy of this License; and
-
- (b) You must cause any modified files to carry prominent notices
- stating that You changed the files; and
-
- (c) You must retain, in the Source form of any Derivative Works
- that You distribute, all copyright, patent, trademark, and
- attribution notices from the Source form of the Work,
- excluding those notices that do not pertain to any part of
- the Derivative Works; and
-
- (d) If the Work includes a "NOTICE" text file as part of its
- distribution, then any Derivative Works that You distribute must
- include a readable copy of the attribution notices contained
- within such NOTICE file, excluding those notices that do not
- pertain to any part of the Derivative Works, in at least one
- of the following places: within a NOTICE text file distributed
- as part of the Derivative Works; within the Source form or
- documentation, if provided along with the Derivative Works; or,
- within a display generated by the Derivative Works, if and
- wherever such third-party notices normally appear. The contents
- of the NOTICE file are for informational purposes only and
- do not modify the License. You may add Your own attribution
- notices within Derivative Works that You distribute, alongside
- or as an addendum to the NOTICE text from the Work, provided
- that such additional attribution notices cannot be construed
- as modifying the License.
-
- You may add Your own copyright statement to Your modifications and
- may provide additional or different license terms and conditions
- for use, reproduction, or distribution of Your modifications, or
- for any such Derivative Works as a whole, provided Your use,
- reproduction, and distribution of the Work otherwise complies with
- the conditions stated in this License.
-
- 5. Submission of Contributions. Unless You explicitly state otherwise,
- any Contribution intentionally submitted for inclusion in the Work
- by You to the Licensor shall be under the terms and conditions of
- this License, without any additional terms or conditions.
- Notwithstanding the above, nothing herein shall supersede or modify
- the terms of any separate license agreement you may have executed
- with Licensor regarding such Contributions.
-
- 6. Trademarks. This License does not grant permission to use the trade
- names, trademarks, service marks, or product names of the Licensor,
- except as required for reasonable and customary use in describing the
- origin of the Work and reproducing the content of the NOTICE file.
-
- 7. Disclaimer of Warranty. Unless required by applicable law or
- agreed to in writing, Licensor provides the Work (and each
- Contributor provides its Contributions) on an "AS IS" BASIS,
- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
- implied, including, without limitation, any warranties or conditions
- of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
- PARTICULAR PURPOSE. You are solely responsible for determining the
- appropriateness of using or redistributing the Work and assume any
- risks associated with Your exercise of permissions under this License.
-
- 8. Limitation of Liability. In no event and under no legal theory,
- whether in tort (including negligence), contract, or otherwise,
- unless required by applicable law (such as deliberate and grossly
- negligent acts) or agreed to in writing, shall any Contributor be
- liable to You for damages, including any direct, indirect, special,
- incidental, or consequential damages of any character arising as a
- result of this License or out of the use or inability to use the
- Work (including but not limited to damages for loss of goodwill,
- work stoppage, computer failure or malfunction, or any and all
- other commercial damages or losses), even if such Contributor
- has been advised of the possibility of such damages.
-
- 9. Accepting Warranty or Additional Liability. While redistributing
- the Work or Derivative Works thereof, You may choose to offer,
- and charge a fee for, acceptance of support, warranty, indemnity,
- or other liability obligations and/or rights consistent with this
- License. However, in accepting such obligations, You may act only
- on Your own behalf and on Your sole responsibility, not on behalf
- of any other Contributor, and only if You agree to indemnify,
- defend, and hold each Contributor harmless for any liability
- incurred by, or claims asserted against, such Contributor by reason
- of your accepting any such warranty or additional liability.
-
- END OF TERMS AND CONDITIONS
-
- APPENDIX: How to apply the Apache License to your work.
-
- To apply the Apache License to your work, attach the following
- boilerplate notice, with the fields enclosed by brackets "[]"
- replaced with your own identifying information. (Don't include
- the brackets!) The text should be enclosed in the appropriate
- comment syntax for the file format. We also recommend that a
- file or class name and description of purpose be included on the
- same "printed page" as the copyright notice for easier
- identification within third-party archives.
-
- Copyright [yyyy] [name of copyright owner]
-
- Licensed under the Apache License, Version 2.0 (the "License");
- you may not use this file except in compliance with the License.
- You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
- Unless required by applicable law or agreed to in writing, software
- distributed under the License is distributed on an "AS IS" BASIS,
- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- See the License for the specific language governing permissions and
- limitations under the License.
diff --git a/javax.servlet/src/main/resources/META-INF/NOTICE b/javax.servlet/src/main/resources/META-INF/NOTICE
deleted file mode 100644
index 4f02a58..0000000
--- a/javax.servlet/src/main/resources/META-INF/NOTICE
+++ /dev/null
@@ -1,5 +0,0 @@
-Apache Felix Servlet API
-Copyright 2006 The Apache Software Foundation
-
-This product includes software developed at
-The Apache Software Foundation (http://www.apache.org/).
diff --git a/javax.servlet/src/main/resources/javax/servlet/LocalStrings.properties b/javax.servlet/src/main/resources/javax/servlet/LocalStrings.properties
deleted file mode 100644
index 7ac4863..0000000
--- a/javax.servlet/src/main/resources/javax/servlet/LocalStrings.properties
+++ /dev/null
@@ -1,6 +0,0 @@
-# Default localized string information
-# Localized for Locale en_US
-
-err.not_iso8859_1=Not an ISO 8859-1 character: {0}
-value.true=true
-value.false=false
diff --git a/javax.servlet/src/main/resources/javax/servlet/http/LocalStrings.properties b/javax.servlet/src/main/resources/javax/servlet/http/LocalStrings.properties
deleted file mode 100644
index 5908d24..0000000
--- a/javax.servlet/src/main/resources/javax/servlet/http/LocalStrings.properties
+++ /dev/null
@@ -1,13 +0,0 @@
-# Default localized string information
-# Localized for Locale en_US
-
-err.cookie_name_is_token=Cookie name {0} is a reserved token
-err.io.negativelength=Negative Length given in write method
-err.io.short_read=Short Read
-
-http.method_not_implemented=Method {0} is not defined in RFC 2068 and is not supported by the Servlet API
-
-http.method_get_not_supported=HTTP method GET is not supported by this URL
-http.method_post_not_supported=HTTP method POST is not supported by this URL
-http.method_put_not_supported=HTTP method PUT is not supported by this URL
-http.method_delete_not_supported=Http method DELETE is not supported by this URL
diff --git a/org.osgi.compendium/LICENSE b/org.osgi.compendium/LICENSE
deleted file mode 100644
index d645695..0000000
--- a/org.osgi.compendium/LICENSE
+++ /dev/null
@@ -1,202 +0,0 @@
-
- Apache License
- Version 2.0, January 2004
- http://www.apache.org/licenses/
-
- TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
-
- 1. Definitions.
-
- "License" shall mean the terms and conditions for use, reproduction,
- and distribution as defined by Sections 1 through 9 of this document.
-
- "Licensor" shall mean the copyright owner or entity authorized by
- the copyright owner that is granting the License.
-
- "Legal Entity" shall mean the union of the acting entity and all
- other entities that control, are controlled by, or are under common
- control with that entity. For the purposes of this definition,
- "control" means (i) the power, direct or indirect, to cause the
- direction or management of such entity, whether by contract or
- otherwise, or (ii) ownership of fifty percent (50%) or more of the
- outstanding shares, or (iii) beneficial ownership of such entity.
-
- "You" (or "Your") shall mean an individual or Legal Entity
- exercising permissions granted by this License.
-
- "Source" form shall mean the preferred form for making modifications,
- including but not limited to software source code, documentation
- source, and configuration files.
-
- "Object" form shall mean any form resulting from mechanical
- transformation or translation of a Source form, including but
- not limited to compiled object code, generated documentation,
- and conversions to other media types.
-
- "Work" shall mean the work of authorship, whether in Source or
- Object form, made available under the License, as indicated by a
- copyright notice that is included in or attached to the work
- (an example is provided in the Appendix below).
-
- "Derivative Works" shall mean any work, whether in Source or Object
- form, that is based on (or derived from) the Work and for which the
- editorial revisions, annotations, elaborations, or other modifications
- represent, as a whole, an original work of authorship. For the purposes
- of this License, Derivative Works shall not include works that remain
- separable from, or merely link (or bind by name) to the interfaces of,
- the Work and Derivative Works thereof.
-
- "Contribution" shall mean any work of authorship, including
- the original version of the Work and any modifications or additions
- to that Work or Derivative Works thereof, that is intentionally
- submitted to Licensor for inclusion in the Work by the copyright owner
- or by an individual or Legal Entity authorized to submit on behalf of
- the copyright owner. For the purposes of this definition, "submitted"
- means any form of electronic, verbal, or written communication sent
- to the Licensor or its representatives, including but not limited to
- communication on electronic mailing lists, source code control systems,
- and issue tracking systems that are managed by, or on behalf of, the
- Licensor for the purpose of discussing and improving the Work, but
- excluding communication that is conspicuously marked or otherwise
- designated in writing by the copyright owner as "Not a Contribution."
-
- "Contributor" shall mean Licensor and any individual or Legal Entity
- on behalf of whom a Contribution has been received by Licensor and
- subsequently incorporated within the Work.
-
- 2. Grant of Copyright License. Subject to the terms and conditions of
- this License, each Contributor hereby grants to You a perpetual,
- worldwide, non-exclusive, no-charge, royalty-free, irrevocable
- copyright license to reproduce, prepare Derivative Works of,
- publicly display, publicly perform, sublicense, and distribute the
- Work and such Derivative Works in Source or Object form.
-
- 3. Grant of Patent License. Subject to the terms and conditions of
- this License, each Contributor hereby grants to You a perpetual,
- worldwide, non-exclusive, no-charge, royalty-free, irrevocable
- (except as stated in this section) patent license to make, have made,
- use, offer to sell, sell, import, and otherwise transfer the Work,
- where such license applies only to those patent claims licensable
- by such Contributor that are necessarily infringed by their
- Contribution(s) alone or by combination of their Contribution(s)
- with the Work to which such Contribution(s) was submitted. If You
- institute patent litigation against any entity (including a
- cross-claim or counterclaim in a lawsuit) alleging that the Work
- or a Contribution incorporated within the Work constitutes direct
- or contributory patent infringement, then any patent licenses
- granted to You under this License for that Work shall terminate
- as of the date such litigation is filed.
-
- 4. Redistribution. You may reproduce and distribute copies of the
- Work or Derivative Works thereof in any medium, with or without
- modifications, and in Source or Object form, provided that You
- meet the following conditions:
-
- (a) You must give any other recipients of the Work or
- Derivative Works a copy of this License; and
-
- (b) You must cause any modified files to carry prominent notices
- stating that You changed the files; and
-
- (c) You must retain, in the Source form of any Derivative Works
- that You distribute, all copyright, patent, trademark, and
- attribution notices from the Source form of the Work,
- excluding those notices that do not pertain to any part of
- the Derivative Works; and
-
- (d) If the Work includes a "NOTICE" text file as part of its
- distribution, then any Derivative Works that You distribute must
- include a readable copy of the attribution notices contained
- within such NOTICE file, excluding those notices that do not
- pertain to any part of the Derivative Works, in at least one
- of the following places: within a NOTICE text file distributed
- as part of the Derivative Works; within the Source form or
- documentation, if provided along with the Derivative Works; or,
- within a display generated by the Derivative Works, if and
- wherever such third-party notices normally appear. The contents
- of the NOTICE file are for informational purposes only and
- do not modify the License. You may add Your own attribution
- notices within Derivative Works that You distribute, alongside
- or as an addendum to the NOTICE text from the Work, provided
- that such additional attribution notices cannot be construed
- as modifying the License.
-
- You may add Your own copyright statement to Your modifications and
- may provide additional or different license terms and conditions
- for use, reproduction, or distribution of Your modifications, or
- for any such Derivative Works as a whole, provided Your use,
- reproduction, and distribution of the Work otherwise complies with
- the conditions stated in this License.
-
- 5. Submission of Contributions. Unless You explicitly state otherwise,
- any Contribution intentionally submitted for inclusion in the Work
- by You to the Licensor shall be under the terms and conditions of
- this License, without any additional terms or conditions.
- Notwithstanding the above, nothing herein shall supersede or modify
- the terms of any separate license agreement you may have executed
- with Licensor regarding such Contributions.
-
- 6. Trademarks. This License does not grant permission to use the trade
- names, trademarks, service marks, or product names of the Licensor,
- except as required for reasonable and customary use in describing the
- origin of the Work and reproducing the content of the NOTICE file.
-
- 7. Disclaimer of Warranty. Unless required by applicable law or
- agreed to in writing, Licensor provides the Work (and each
- Contributor provides its Contributions) on an "AS IS" BASIS,
- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
- implied, including, without limitation, any warranties or conditions
- of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
- PARTICULAR PURPOSE. You are solely responsible for determining the
- appropriateness of using or redistributing the Work and assume any
- risks associated with Your exercise of permissions under this License.
-
- 8. Limitation of Liability. In no event and under no legal theory,
- whether in tort (including negligence), contract, or otherwise,
- unless required by applicable law (such as deliberate and grossly
- negligent acts) or agreed to in writing, shall any Contributor be
- liable to You for damages, including any direct, indirect, special,
- incidental, or consequential damages of any character arising as a
- result of this License or out of the use or inability to use the
- Work (including but not limited to damages for loss of goodwill,
- work stoppage, computer failure or malfunction, or any and all
- other commercial damages or losses), even if such Contributor
- has been advised of the possibility of such damages.
-
- 9. Accepting Warranty or Additional Liability. While redistributing
- the Work or Derivative Works thereof, You may choose to offer,
- and charge a fee for, acceptance of support, warranty, indemnity,
- or other liability obligations and/or rights consistent with this
- License. However, in accepting such obligations, You may act only
- on Your own behalf and on Your sole responsibility, not on behalf
- of any other Contributor, and only if You agree to indemnify,
- defend, and hold each Contributor harmless for any liability
- incurred by, or claims asserted against, such Contributor by reason
- of your accepting any such warranty or additional liability.
-
- END OF TERMS AND CONDITIONS
-
- APPENDIX: How to apply the Apache License to your work.
-
- To apply the Apache License to your work, attach the following
- boilerplate notice, with the fields enclosed by brackets "[]"
- replaced with your own identifying information. (Don't include
- the brackets!) The text should be enclosed in the appropriate
- comment syntax for the file format. We also recommend that a
- file or class name and description of purpose be included on the
- same "printed page" as the copyright notice for easier
- identification within third-party archives.
-
- Copyright [yyyy] [name of copyright owner]
-
- Licensed under the Apache License, Version 2.0 (the "License");
- you may not use this file except in compliance with the License.
- You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
- Unless required by applicable law or agreed to in writing, software
- distributed under the License is distributed on an "AS IS" BASIS,
- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- See the License for the specific language governing permissions and
- limitations under the License.
diff --git a/org.osgi.compendium/NOTICE b/org.osgi.compendium/NOTICE
deleted file mode 100644
index 3c9ffa5..0000000
--- a/org.osgi.compendium/NOTICE
+++ /dev/null
@@ -1,5 +0,0 @@
-OSGi Compendium Classes
-Copyright (c) OSGi Alliance (2000, 2009).
-
-This product includes software developed at
-the OSGi Alliance (http://www.osgi.org/).
diff --git a/org.osgi.compendium/doc/changelog.txt b/org.osgi.compendium/doc/changelog.txt
deleted file mode 100644
index 98616f0..0000000
--- a/org.osgi.compendium/doc/changelog.txt
+++ /dev/null
@@ -1,17 +0,0 @@
-Changes from 1.2.0 to 1.4.0
-----------------------------
-
-*[2009-09-01] Update to latest R4.2 API
-
-Changes from 1.0.1 to 1.2.0
-----------------------------
-
-* [2008-08-02] Updated from Compendium 4.0 to 4.1 (FELIX-514)
-
-Changes from 1.0.0 to 1.0.1
--------------------------------------
-
-* [2008-04-21] Re-release to make bytecode executable on jre 1.3.
-* [2008-02-16] Updated import-package in order to match the bundle released by OSGi Alliance
- (FELIX-488)
-
diff --git a/org.osgi.compendium/pom.xml b/org.osgi.compendium/pom.xml
deleted file mode 100644
index aa4b24a..0000000
--- a/org.osgi.compendium/pom.xml
+++ /dev/null
@@ -1,72 +0,0 @@
-<!--
- Licensed to the Apache Software Foundation (ASF) under one
- or more contributor license agreements. See the NOTICE file
- distributed with this work for additional information
- regarding copyright ownership. The ASF licenses this file
- to you under the Apache License, Version 2.0 (the
- "License"); you may not use this file except in compliance
- with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
- Unless required by applicable law or agreed to in writing,
- software distributed under the License is distributed on an
- "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- KIND, either express or implied. See the License for the
- specific language governing permissions and limitations
- under the License. -->
-<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
- <parent>
- <groupId>org.apache.felix</groupId>
- <artifactId>felix-parent</artifactId>
- <version>1.2.0</version>
- <relativePath>../pom/pom.xml</relativePath> </parent>
- <organization>
- <name>OSGi Alliance</name>
- <url>http://www.osgi.org/</url>
- </organization>
- <modelVersion>4.0.0</modelVersion>
- <description>OSGi Service Platform Release 4 Compendium Interfaces and Classes.</description>
- <artifactId>org.osgi.compendium</artifactId>
- <version>1.5.0-SNAPSHOT</version>
- <name>OSGi R4 Compendium Bundle</name>
- <packaging>bundle</packaging>
- <dependencies>
- <dependency>
- <groupId>${pom.groupId}</groupId>
- <artifactId>org.osgi.core</artifactId>
- <version>1.5.0-SNAPSHOT</version>
- </dependency>
- <dependency>
- <groupId>${pom.groupId}</groupId>
- <artifactId>javax.servlet</artifactId>
- <version>1.0.0</version>
- </dependency>
- <dependency>
- <groupId>org.apache.felix</groupId>
- <artifactId>org.osgi.foundation</artifactId>
- <version>1.3.0-SNAPSHOT</version>
- </dependency>
- </dependencies>
- <build>
- <plugins>
- <plugin>
- <groupId>org.apache.felix</groupId>
- <artifactId>maven-bundle-plugin</artifactId>
- <version>1.4.0</version>
- <extensions>true</extensions>
- <configuration>
- <instructions>
- <Bundle-Version>4.1.0</Bundle-Version>
- <Bundle-SymbolicName>org.osgi.compendium</Bundle-SymbolicName>
- <Bundle-Copyright>Copyright (c) OSGi Alliance (2000, 2009). All Rights Reserved.</Bundle-Copyright>
- <Bundle-Category>osgi</Bundle-Category>
- <Export-Package>info.dmtree.notification,info.dmtree.notification.spi,info.dmtree.registry,info.dmtree.security,info.dmtree.spi,org.osgi.service.application,org.osgi.service.cm,org.osgi.service.component,org.osgi.service.deploymentadmin,org.osgi.service.deploymentadmin.spi,org.osgi.service.device,org.osgi.service.event,org.osgi.service.http,org.osgi.service.io,org.osgi.service.log,org.osgi.service.metatype,org.osgi.service.monitor,org.osgi.service.prefs,org.osgi.service.provisioning,org.osgi.service.upnp,org.osgi.service.useradmin,org.osgi.service.wireadmin,org.osgi.util.gsm,org.osgi.util.measurement,org.osgi.util.mobile,org.osgi.util.position,org.osgi.util.tracker,org.osgi.util.xml</Export-Package>
- <Import-Package />
- <DynamicImport-Package>*</DynamicImport-Package>
- </instructions>
- </configuration>
- </plugin>
- </plugins>
- </build>
-</project>
diff --git a/org.osgi.compendium/src/main/java/info/dmtree/Acl.java b/org.osgi.compendium/src/main/java/info/dmtree/Acl.java
deleted file mode 100644
index b502c26..0000000
--- a/org.osgi.compendium/src/main/java/info/dmtree/Acl.java
+++ /dev/null
@@ -1,579 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2004, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package info.dmtree;
-
-import java.util.Arrays;
-import java.util.Iterator;
-import java.util.Map;
-import java.util.TreeMap;
-import java.util.Vector;
-
-/**
- * <code>Acl</code> is an immutable class representing structured access to DMT
- * ACLs. Under OMA DM the ACLs are defined as strings with an internal syntax.
- * <p>
- * The methods of this class taking a principal as parameter accept remote
- * server IDs (as passed to {@link DmtAdmin#getSession(String, String, int)
- * DmtAdmin.getSession}), as well as " <code>*</code> " indicating any
- * principal.
- * <p>
- * The syntax for valid remote server IDs:<br>
- * <<i>server-identifier</i>> ::= All printable characters except
- * <code>'='</code>, <code>'&'</code>, <code>'*'</code>, <code>'+'</code> or white-space
- * characters.
- *
- * @version $Revision: 5673 $
- */
-public final class Acl {
-
- // ----- Public constants -----//
-
- /**
- * Principals holding this permission can issue GET command on the node
- * having this ACL.
- */
- public static final int GET = 1;
-
- /**
- * Principals holding this permission can issue ADD commands on the node
- * having this ACL.
- */
- public static final int ADD = 2;
-
- /**
- * Principals holding this permission can issue REPLACE commands on the node
- * having this ACL.
- */
- public static final int REPLACE = 4;
-
- /**
- * Principals holding this permission can issue DELETE commands on the node
- * having this ACL.
- */
- public static final int DELETE = 8;
-
- /**
- * Principals holding this permission can issue EXEC commands on the node
- * having this ACL.
- */
- public static final int EXEC = 16;
-
- /**
- * Principals holding this permission can issue any command on the node
- * having this ACL. This permission is the logical OR of {@link #ADD},
- * {@link #DELETE}, {@link #EXEC}, {@link #GET} and {@link #REPLACE}
- * permissions.
- */
- public static final int ALL_PERMISSION = ADD | DELETE | EXEC | GET
- | REPLACE;
-
- // ----- Private constants -----//
-
- private static final int[] PERMISSION_CODES = new int[] { ADD, DELETE,
- EXEC, GET, REPLACE };
-
- private static final String[] PERMISSION_NAMES = new String[] { "Add",
- "Delete", "Exec", "Get", "Replace" };
-
- private static final String ALL_PRINCIPALS = "*";
-
- // ----- Private fields -----//
-
- // the implementation takes advantage of this being a sorted map
- private final TreeMap principalPermissions;
-
- private final int globalPermissions;
-
- // ----- Public constructors -----//
-
- /**
- * Create an instance of the ACL from its canonic string representation.
- *
- * @param acl The string representation of the ACL as defined in OMA DM. If
- * <code>null</code> or empty then it represents an empty list of
- * principals with no permissions.
- * @throws IllegalArgumentException if acl is not a valid OMA DM ACL string
- */
- public Acl(String acl) {
- if (acl == null || acl.equals("")) { // empty permission set
- principalPermissions = new TreeMap();
- globalPermissions = 0;
- return;
- }
-
- TreeMap tempPrincipalPermissions = new TreeMap();
- int tempGlobalPermissions = 0;
-
- String[] aclEntries = split(acl, '&', -1);
- for (int i = 0; i < aclEntries.length; i++) {
- if (aclEntries[i].length() == 0)
- throw new IllegalArgumentException(
- "Invalid ACL string: empty ACL entry.");
-
- String[] entryParts = split(aclEntries[i], '=', 2);
- if (entryParts.length == 1)
- throw new IllegalArgumentException(
- "Invalid ACL string: no '=' in ACL entry.");
- if (entryParts[1].length() == 0)
- throw new IllegalArgumentException(
- "Invalid ACL string: no server identifiers in ACL entry.");
-
- int command = parseCommand(entryParts[0]);
- String[] serverIds = split(entryParts[1], '+', -1);
- for (int j = 0; j < serverIds.length; j++) {
- if (serverIds[j].length() == 0)
- throw new IllegalArgumentException(
- "Invalid ACL string: empty server identifier.");
-
- if (serverIds[j].equals(ALL_PRINCIPALS))
- tempGlobalPermissions |= command;
- else {
- checkServerId(serverIds[j], "Invalid ACL string: "
- + "server ID contains illegal character");
- Integer n = (Integer) tempPrincipalPermissions
- .get(serverIds[j]);
- int oldPermission = (n != null) ? n.intValue() : 0;
- tempPrincipalPermissions.put(serverIds[j], new Integer(
- oldPermission | command));
- }
- }
- }
-
- principalPermissions = tempPrincipalPermissions;
- globalPermissions = tempGlobalPermissions;
- }
-
- /**
- * Creates an instance with a specified list of principals and the
- * permissions they hold. The two arrays run in parallel, that is
- * <code>principals[i]</code> will hold <code>permissions[i]</code> in
- * the ACL.
- * <p>
- * A principal name may not appear multiple times in the 'principals'
- * argument. If the "*" principal appears in the array, the
- * corresponding permissions will be granted to all principals (regardless
- * of whether they appear in the array or not).
- *
- * @param principals The array of principals
- * @param permissions The array of permissions
- * @throws IllegalArgumentException if the length of the two arrays are not
- * the same, if any array element is invalid, or if a principal
- * appears multiple times in the <code>principals</code> array
- */
- public Acl(String[] principals, int[] permissions) {
- if (principals.length != permissions.length)
- throw new IllegalArgumentException(
- "The lengths of the principal and permission arrays are not the same.");
-
- TreeMap tempPrincipalPermissions = new TreeMap();
- int tempGlobalPermissions = 0;
-
- for (int i = 0; i < principals.length; i++) {
- // allow one * in 'principals' array, remove after loop
- if (!ALL_PRINCIPALS.equals(principals[i]))
- checkPrincipal(principals[i]);
- checkPermissions(permissions[i]);
-
- Integer permInt = new Integer(permissions[i]);
- Object old = tempPrincipalPermissions.put(principals[i], permInt);
- if (old != null)
- throw new IllegalArgumentException("Principal '"
- + principals[i]
- + "' appears multiple times in the principal array.");
- }
-
- // set the global permissions if there was a * in the array
- Object globalPermObj = tempPrincipalPermissions.remove(ALL_PRINCIPALS);
- if (globalPermObj != null)
- tempGlobalPermissions = ((Integer) globalPermObj).intValue();
-
- principalPermissions = tempPrincipalPermissions;
- globalPermissions = tempGlobalPermissions;
- }
-
- // ----- Private constructors -----//
-
- /**
- * Creates an instance identical to the <code>base</code> ACL except for
- * the permissions of the given <code>principal</code>, which are
- * overwritten with the given <code>permissions</code>.
- * <p>
- * Assumes that the permissions parameter has been checked. All
- * modifications of an <code>Acl</code> (add, delete, set) are done
- * through this method.
- *
- * @param base The ACL that provides all permissions except for permissions
- * of the given principal.
- * @param principal The entity to which permission should be granted.
- * @param permissions The set of permissions to be given. The parameter can
- * be a logical <code>or</code> of the permission constants defined
- * in this class.
- */
- private Acl(Acl base, String principal, int permissions) {
- // make a shallow copy of the permission table, the keys (String) and
- // values (Integer) are immutable anyway
- TreeMap tempPrincipalPermissions = (TreeMap) base.principalPermissions
- .clone();
- int tempGlobalPermissions = base.globalPermissions;
-
- int deletedGlobalPerm = tempGlobalPermissions & ~permissions;
- if (ALL_PRINCIPALS.equals(principal)) {
- deleteFromAll(tempPrincipalPermissions, deletedGlobalPerm);
- tempGlobalPermissions = permissions;
- } else {
- checkPrincipal(principal);
-
- if (deletedGlobalPerm != 0)
- throw new IllegalArgumentException(
- "Cannot revoke globally set permissions ("
- + writeCommands(deletedGlobalPerm)
- + ") from a specific principal (" + principal
- + ").");
-
- setPrincipalPermission(tempPrincipalPermissions, principal,
- permissions);
- }
-
- principalPermissions = tempPrincipalPermissions;
- globalPermissions = tempGlobalPermissions;
- }
-
- // ----- Public methods -----//
-
- /**
- * Checks whether the given object is equal to this <code>Acl</code>
- * instance. Two <code>Acl</code> instances are equal if they allow the
- * same set of permissions for the same set of principals.
- *
- * @param obj the object to compare with this <code>Acl</code> instance
- * @return <code>true</code> if the parameter represents the same ACL as
- * this instance
- */
- public boolean equals(Object obj) {
- if (obj == this)
- return true;
-
- if (!(obj instanceof Acl))
- return false;
-
- Acl other = (Acl) obj;
-
- if (globalPermissions != other.globalPermissions
- || principalPermissions.size() != other.principalPermissions
- .size())
- return false;
-
- // principalPermissions sets cannot be easily compared, because they are
- // not canonical: the global permissions may or may not be present for
- // each principal, without changing the meaning of the Acl object.
-
- // Compare canonical string representations, inefficient but simple.
- return toString().equals(other.toString());
- }
-
- /**
- * Returns the hash code for this ACL instance. If two <code>Acl</code>
- * instances are equal according to the {@link #equals} method, then calling
- * this method on each of them must produce the same integer result.
- *
- * @return hash code for this ACL
- */
- public int hashcode() {
- // Using the hash code of the canonical string representation, because
- // the principalPermissions set is not canonical (see above).
- return toString().hashCode();
- }
-
- /**
- * Create a new <code>Acl</code> instance from this <code>Acl</code> with
- * the given permission added for the given principal. The already existing
- * permissions of the principal are not affected.
- *
- * @param principal The entity to which permissions should be granted, or
- * "*" to grant permissions to all principals.
- * @param permissions The permissions to be given. The parameter can be a
- * logical <code>or</code> of more permission constants defined in
- * this class.
- * @return a new <code>Acl</code> instance
- * @throws IllegalArgumentException if <code>principal</code> is not a
- * valid principal name or if <code>permissions</code> is not a
- * valid combination of the permission constants defined in this
- * class
- */
- public synchronized Acl addPermission(String principal, int permissions) {
- checkPermissions(permissions);
-
- int oldPermissions = getPermissions(principal);
- return setPermission(principal, oldPermissions | permissions);
- }
-
- /**
- * Create a new <code>Acl</code> instance from this <code>Acl</code> with
- * the given permission revoked from the given principal. Other permissions
- * of the principal are not affected.
- * <p>
- * Note, that it is not valid to revoke a permission from a specific
- * principal if that permission is granted globally to all principals.
- *
- * @param principal The entity from which permissions should be revoked, or
- * "*" to revoke permissions from all principals.
- * @param permissions The permissions to be revoked. The parameter can be a
- * logical <code>or</code> of more permission constants defined in
- * this class.
- * @return a new <code>Acl</code> instance
- * @throws IllegalArgumentException if <code>principal</code> is not a
- * valid principal name, if <code>permissions</code> is not a
- * valid combination of the permission constants defined in this
- * class, or if a globally granted permission would have been
- * revoked from a specific principal
- */
- public synchronized Acl deletePermission(String principal, int permissions) {
- checkPermissions(permissions);
-
- int oldPermissions = getPermissions(principal);
- return setPermission(principal, oldPermissions & ~permissions);
- }
-
- /**
- * Get the permissions associated to a given principal.
- *
- * @param principal The entity whose permissions to query, or "*"
- * to query the permissions that are granted globally, to all
- * principals
- * @return The permissions of the given principal. The returned
- * <code>int</code> is a bitmask of the permission constants defined
- * in this class
- * @throws IllegalArgumentException if <code>principal</code> is not a
- * valid principal name
- */
- public synchronized int getPermissions(String principal) {
- int permissions = 0;
-
- if (!(ALL_PRINCIPALS.equals(principal))) {
- checkPrincipal(principal);
- Object po = principalPermissions.get(principal);
- if (po != null)
- permissions = ((Integer) po).intValue();
- }
-
- return permissions | globalPermissions;
- }
-
- /**
- * Check whether the given permissions are granted to a certain principal.
- * The requested permissions are specified as a bitfield, for example
- * <code>(Acl.ADD | Acl.DELETE | Acl.GET)</code>.
- *
- * @param principal The entity to check, or "*" to check whether
- * the given permissions are granted to all principals globally
- * @param permissions The permissions to check
- * @return <code>true</code> if the principal holds all the given permissions
- * @throws IllegalArgumentException if <code>principal</code> is not a
- * valid principal name or if <code>permissions</code> is not a
- * valid combination of the permission constants defined in this
- * class
- */
- public synchronized boolean isPermitted(String principal, int permissions) {
- checkPermissions(permissions);
-
- int hasPermissions = getPermissions(principal);
- return (permissions & hasPermissions) == permissions;
- }
-
- /**
- * Create a new <code>Acl</code> instance from this <code>Acl</code> where
- * all permissions for the given principal are overwritten with the given
- * permissions.
- * <p>
- * Note, that when changing the permissions of a specific principal, it is
- * not allowed to specify a set of permissions stricter than the global set
- * of permissions (that apply to all principals).
- *
- * @param principal The entity to which permissions should be granted, or
- * "*" to globally grant permissions to all principals.
- * @param permissions The set of permissions to be given. The parameter is
- * a bitmask of the permission constants defined in this class.
- * @return a new <code>Acl</code> instance
- * @throws IllegalArgumentException if <code>principal</code> is not a
- * valid principal name, if <code>permissions</code> is not a
- * valid combination of the permission constants defined in this
- * class, or if a globally granted permission would have been
- * revoked from a specific principal
- */
- public synchronized Acl setPermission(String principal, int permissions) {
- checkPermissions(permissions);
-
- Acl newPermission = new Acl(this, principal, permissions);
- return newPermission;
- }
-
- /**
- * Get the list of principals who have any kind of permissions on this node.
- * The list only includes those principals that have been explicitly
- * assigned permissions (so "*" is never returned), globally set
- * permissions naturally apply to all other principals as well.
- *
- * @return The array of principals having permissions on this node.
- */
- public String[] getPrincipals() {
- return (String[]) (principalPermissions.keySet().toArray(new String[0]));
- }
-
- /**
- * Give the canonic string representation of this ACL. The operations are in
- * the following order: {Add, Delete, Exec, Get, Replace}, principal names
- * are sorted alphabetically.
- *
- * @return The string representation as defined in OMA DM.
- */
- public synchronized String toString() {
- String acl = null;
- for (int i = 0; i < PERMISSION_CODES.length; i++)
- acl = writeEntry(PERMISSION_CODES[i], acl);
-
- return (acl != null) ? acl : "";
- }
-
- // ----- Private utility methods -----//
-
- private String writeEntry(int command, String acl) {
- String aclEntry = null;
-
- if ((command & globalPermissions) > 0)
- aclEntry = ALL_PRINCIPALS;
- else {
- // TreeMap guarantees alphabetical ordering of keys during traversal
- Iterator i = principalPermissions.entrySet().iterator();
- while (i.hasNext()) {
- Map.Entry entry = (Map.Entry) i.next();
- if ((command & ((Integer) entry.getValue()).intValue()) > 0)
- aclEntry = appendEntry(aclEntry, '+', (String) entry
- .getKey());
- }
- }
-
- if (aclEntry == null)
- return acl;
-
- return appendEntry(acl, '&', writeCommands(command) + '=' + aclEntry);
- }
-
- private static void deleteFromAll(TreeMap principalPermissions, int perm) {
- Iterator i = principalPermissions.entrySet().iterator();
- while (i.hasNext()) {
- Map.Entry entry = (Map.Entry) i.next();
- setPrincipalPermission(principalPermissions, (String) entry
- .getKey(), ((Integer) entry.getValue()).intValue() & ~perm);
- }
- }
-
- private static void setPrincipalPermission(TreeMap principalPermissions,
- String principal, int perm) {
- if (perm == 0)
- principalPermissions.remove(principal);
- else
- principalPermissions.put(principal, new Integer(perm));
- }
-
- private static String writeCommands(int command) {
- String commandStr = null;
- for (int i = 0; i < PERMISSION_CODES.length; i++)
- if ((command & PERMISSION_CODES[i]) != 0)
- commandStr = appendEntry(commandStr, ',', PERMISSION_NAMES[i]);
-
- return (commandStr != null) ? commandStr : "";
- }
-
- private static String appendEntry(String base, char separator, String entry) {
- return (base != null) ? base + separator + entry : entry;
- }
-
- private static int parseCommand(String command) {
- int i = Arrays.asList(PERMISSION_NAMES).indexOf(command);
- if (i == -1)
- throw new IllegalArgumentException(
- "Invalid ACL string: unknown command '" + command + "'.");
-
- return PERMISSION_CODES[i];
- }
-
- private static void checkPermissions(int perm) {
- if ((perm & ~ALL_PERMISSION) != 0)
- throw new IllegalArgumentException("Invalid ACL permission value: "
- + perm);
- }
-
- private static void checkPrincipal(String principal) {
- if (principal == null)
- throw new IllegalArgumentException("Principal is null.");
-
- checkServerId(principal, "Principal name contains illegal character");
- }
-
- private static void checkServerId(String serverId, String errorText) {
- char[] chars = serverId.toCharArray();
- for (int i = 0; i < chars.length; i++)
- if ("*=+&".indexOf(chars[i]) != -1
- || Character.isWhitespace(chars[i]))
- throw new IllegalArgumentException(errorText + " '" + chars[i]
- + "'.");
- }
-
- private static String[] split(String input, char sep, int limit) {
- Vector v = new Vector();
- boolean limited = (limit > 0);
- int applied = 0;
- int index = 0;
- StringBuffer part = new StringBuffer();
-
- while (index < input.length()) {
- char ch = input.charAt(index);
- if (ch != sep)
- part.append(ch);
- else {
- ++applied;
- v.add(part.toString());
- part = new StringBuffer();
- }
- ++index;
- if (limited && applied == limit - 1)
- break;
- }
- while (index < input.length()) {
- char ch = input.charAt(index);
- part.append(ch);
- ++index;
- }
- v.add(part.toString());
-
- int last = v.size();
- if (0 == limit) {
- for (int j = v.size() - 1; j >= 0; --j) {
- String s = (String) v.elementAt(j);
- if ("".equals(s))
- --last;
- else
- break;
- }
- }
-
- String[] ret = new String[last];
- for (int i = 0; i < last; ++i)
- ret[i] = (String) v.elementAt(i);
-
- return ret;
- }
-}
diff --git a/org.osgi.compendium/src/main/java/info/dmtree/DmtAdmin.java b/org.osgi.compendium/src/main/java/info/dmtree/DmtAdmin.java
deleted file mode 100644
index eea6e99..0000000
--- a/org.osgi.compendium/src/main/java/info/dmtree/DmtAdmin.java
+++ /dev/null
@@ -1,282 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2004, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package info.dmtree;
-
-/**
- * An interface providing methods to open sessions and register listeners. The
- * implementation of <code>DmtAdmin</code> should register itself in the OSGi
- * service registry as a service. <code>DmtAdmin</code> is the entry point for
- * applications to use the DMT API.
- * <p>
- * The <code>getSession</code> methods are used to open a session on a specified
- * subtree of the DMT. A typical way of usage:
- *
- * <pre>
- * serviceRef = context.getServiceReference(DmtAdmin.class.getName());
- * DmtAdmin admin = (DmtAdmin) context.getService(serviceRef);
- * DmtSession session = admin.getSession("./OSGi/Configuration");
- * session.createInteriorNode("./OSGi/Configuration/my.table");
- * </pre>
- * <p>
- * The methods for opening a session take a node URI (the session root) as a
- * parameter. All segments of the given URI must be within the segment length
- * limit of the implementation, and the special characters '/' and '\' must be
- * escaped (preceded by a '\'). Any string can be converted to a valid URI
- * segment using the {@link Uri#mangle(String)} method.
- * <p>
- * It is possible to specify a lock mode when opening the session (see lock type
- * constants in {@link DmtSession}). This determines whether the session can run
- * in parallel with other sessions, and the kinds of operations that can be
- * performed in the session. All Management Objects constituting the device
- * management tree must support read operations on their nodes, while support
- * for write operations depends on the Management Object. Management Objects
- * supporting write access may support transactional write, non-transactional
- * write or both. Users of <code>DmtAdmin</code> should consult the Management
- * Object specification and implementation for the supported update modes. If
- * Management Object definition permits, implementations are encouraged to
- * support both update modes.
- * <p>
- * This interface also contains methods for manipulating the set of
- * <code>DmtEventListener</code> objects that are called when the structure or
- * content of the tree is changed. These methods are not needed in an OSGi
- * environment, clients should register listeners through the Event Admin
- * service.
- *
- * @version $Revision: 5673 $
- */
-public interface DmtAdmin {
- /**
- * Opens a <code>DmtSession</code> for local usage on a given subtree of
- * the DMT with non transactional write lock. This call is equivalent to the
- * following:
- * <code>getSession(null, subtreeUri, DmtSession.LOCK_TYPE_EXCLUSIVE)</code>
- * <p>
- * The <code>subtreeUri</code> parameter must contain an absolute URI. It
- * can also be <code>null</code>, in this case the session is opened with
- * the default session root, ".", that gives access to the whole
- * tree.
- * <p>
- * To perform this operation the caller must have <code>DmtPermission</code>
- * for the <code>subtreeUri</code> node with the Get action present.
- *
- * @param subtreeUri the subtree on which DMT manipulations can be performed
- * within the returned session
- * @return a <code>DmtSession</code> object for the requested subtree
- * @throws DmtException with the following possible error codes:
- * <ul>
- * <li><code>URI_TOO_LONG</code> if <code>subtreeUri</code> or
- * a segment of it is too long, or if it has too many segments
- * <li><code>INVALID_URI</code> if <code>subtreeUri</code> is
- * syntactically invalid
- * <li><code>NODE_NOT_FOUND</code> if <code>subtreeUri</code>
- * specifies a non-existing node
- * <li><code>SESSION_CREATION_TIMEOUT</code> if the operation
- * timed out because of another ongoing session
- * <li><code>COMMAND_FAILED</code> if <code>subtreeUri</code>
- * specifies a relative URI, or some unspecified error is
- * encountered while attempting to complete the command
- * </ul>
- * @throws SecurityException if the caller does not have
- * <code>DmtPermission</code> for the given root node with the Get
- * action present
- */
- DmtSession getSession(String subtreeUri) throws DmtException;
-
- /**
- * Opens a <code>DmtSession</code> for local usage on a specific DMT
- * subtree with a given lock mode. This call is equivalent to the
- * following: <code>getSession(null, subtreeUri, lockMode)</code>
- * <p>
- * The <code>subtreeUri</code> parameter must contain an absolute URI. It
- * can also be <code>null</code>, in this case the session is opened with
- * the default session root, ".", that gives access to the whole
- * tree.
- * <p>
- * To perform this operation the caller must have <code>DmtPermission</code>
- * for the <code>subtreeUri</code> node with the Get action present.
- *
- * @param subtreeUri the subtree on which DMT manipulations can be performed
- * within the returned session
- * @param lockMode one of the lock modes specified in
- * <code>DmtSession</code>
- * @return a <code>DmtSession</code> object for the requested subtree
- * @throws DmtException with the following possible error codes:
- * <ul>
- * <li><code>URI_TOO_LONG</code> if <code>subtreeUri</code> or
- * a segment of it is too long, or if it has too many segments
- * <li><code>INVALID_URI</code> if <code>subtreeUri</code> is
- * syntactically invalid
- * <li><code>NODE_NOT_FOUND</code> if <code>subtreeUri</code>
- * specifies a non-existing node
- * <li><code>FEATURE_NOT_SUPPORTED</code> if atomic sessions are
- * not supported by the implementation and <code>lockMode</code>
- * requests an atomic session
- * <li><code>SESSION_CREATION_TIMEOUT</code> if the operation
- * timed out because of another ongoing session
- * <li><code>COMMAND_FAILED</code> if <code>subtreeUri</code>
- * specifies a relative URI, if <code>lockMode</code> is unknown,
- * or some unspecified error is encountered while attempting to
- * complete the command
- * </ul>
- * @throws SecurityException if the caller does not have
- * <code>DmtPermission</code> for the given root node with the Get
- * action present
- */
- DmtSession getSession(String subtreeUri, int lockMode) throws DmtException;
-
- /**
- * Opens a <code>DmtSession</code> on a specific DMT subtree using a
- * specific lock mode on behalf of a remote principal. If local management
- * applications are using this method then they should provide
- * <code>null</code> as the first parameter. Alternatively they can use
- * other forms of this method without providing a principal string.
- * <p>
- * The <code>subtreeUri</code> parameter must contain an absolute URI. It
- * can also be <code>null</code>, in this case the session is opened with
- * the default session root, ".", that gives access to the whole
- * tree.
- * <p>
- * This method is guarded by <code>DmtPrincipalPermission</code> in case of
- * remote sessions. In addition, the caller must have Get access rights
- * (ACL in case of remote sessions, <code>DmtPermission</code> in case of
- * local sessions) on the <code>subtreeUri</code> node to perform this
- * operation.
- *
- * @param principal the identifier of the remote server on whose behalf the
- * data manipulation is performed, or <code>null</code> for local
- * sessions
- * @param subtreeUri the subtree on which DMT manipulations can be performed
- * within the returned session
- * @param lockMode one of the lock modes specified in
- * <code>DmtSession</code>
- * @return a <code>DmtSession</code> object for the requested subtree
- * @throws DmtException with the following possible error codes:
- * <ul>
- * <li><code>URI_TOO_LONG</code> if <code>subtreeUri</code> or
- * a segment of it is too long, or if it has too many segments
- * <li><code>INVALID_URI</code> if <code>subtreeUri</code> is
- * syntactically invalid
- * <li><code>NODE_NOT_FOUND</code> if <code>subtreeUri</code>
- * specifies a non-existing node
- * <li><code>PERMISSION_DENIED</code> if <code>principal</code> is
- * not <code>null</code> and the ACL of the node does not allow the
- * <code>Get</code> operation for the principal on the given root
- * node
- * <li><code>FEATURE_NOT_SUPPORTED</code> if atomic sessions are
- * not supported by the implementation and <code>lockMode</code>
- * requests an atomic session
- * <li><code>SESSION_CREATION_TIMEOUT</code> if the operation
- * timed out because of another ongoing session
- * <li><code>COMMAND_FAILED</code> if <code>subtreeUri</code>
- * specifies a relative URI, if <code>lockMode</code> is unknown,
- * or some unspecified error is encountered while attempting to
- * complete the command
- * </ul>
- * @throws SecurityException in case of remote sessions, if the caller does
- * not have the required <code>DmtPrincipalPermission</code> with a
- * target matching the <code>principal</code> parameter, or in case
- * of local sessions, if the caller does not have
- * <code>DmtPermission</code> for the given root node with the Get
- * action present
- */
- DmtSession getSession(String principal, String subtreeUri, int lockMode)
- throws DmtException;
-
- /**
- * Registers an event listener on behalf of a local application. The given
- * listener will receive notification on all changes affecting the specified
- * subtree. The subtree is specified by its root node URI. An event is
- * delivered to the registered listener if at least one affected node is
- * within this subtree. The events can also be filtered by specifying a
- * bitmask of relevant event types (e.g.
- * <code>DmtEvent.ADDED | DmtEvent.REPLACED | DmtEvent.SESSION_CLOSED</code>).
- * Only event types included in the bitmask will be delivered to the
- * listener.
- * <p>
- * The listener will only receive the change notifications of nodes for
- * which the registering application has the appropriate GET
- * {@link info.dmtree.security.DmtPermission}.
- * <p>
- * If the specified <code>listener</code> was already registered, calling
- * this method will update the registration.
- *
- * @param type a bitmask of event types the caller is interested in
- * @param uri the URI of the root node of a subtree, must not be
- * <code>null</code>
- * @param listener the listener to be registered, must not be
- * <code>null</code>
- * @throws SecurityException if the caller doesn't have the necessary GET
- * <code>DmtPermission</code> for the given URI
- * @throws NullPointerException if the <code>uri</code> or
- * <code>listener</code> parameter is <code>null</code>
- * @throws IllegalArgumentException if the <code>type</code> parameter
- * contains invalid bits (not corresponding to any event type
- * defined in <code>DmtEvent</code>), or if the <code>uri</code>
- * parameter is invalid (is not an absolute URI or is syntactically
- * incorrect)
- */
- void addEventListener(int type, String uri, DmtEventListener listener);
-
- /**
- * Registers an event listener on behalf of a remote principal. The given
- * listener will receive notification on all changes affecting the specified
- * subtree. The subtree is specified by its root node URI. An event is
- * delivered to the registered listener if at least one affected node is
- * within this subtree. The events can also be filtered by specifying a
- * bitmask of relevant event types (e.g.
- * <code>DmtEvent.ADDED | DmtEvent.REPLACED | DmtEvent.SESSION_CLOSED</code>).
- * Only event types included in the bitmask will be delivered to the
- * listener.
- * <p>
- * The listener will only receive the change notifications of nodes for
- * which the node ACL grants GET access to the specified principal.
- * <p>
- * If the specified <code>listener</code> was already registered, calling
- * this method will update the registration.
- *
- * @param principal the management server identity the caller is acting on
- * behalf of, must not be <code>null</code>
- * @param type a bitmask of event types the caller is interested in
- * @param uri the URI of the root node of a subtree, must not be
- * <code>null</code>
- * @param listener the listener to be registered, must not be
- * <code>null</code>
- * @throws SecurityException if the caller doesn't have the necessary
- * <code>DmtPrincipalPermission</code> to use the specified
- * principal
- * @throws NullPointerException if the <code>principal</code>,
- * <code>uri</code> or <code>listener</code> parameter is
- * <code>null</code>
- * @throws IllegalArgumentException if the <code>type</code> parameter
- * contains invalid bits (not corresponding to any event type
- * defined in <code>DmtEvent</code>), or if the <code>uri</code>
- * parameter is invalid (is not an absolute URI or is syntactically
- * incorrect)
- */
- void addEventListener(String principal, int type, String uri,
- DmtEventListener listener);
-
- /**
- * Remove a previously registered listener. After this call, the listener
- * will not receive change notifications.
- *
- * @param listener the listener to be unregistered, must not be
- * <code>null</code>
- * @throws NullPointerException if the <code>listener</code> parameter is
- * <code>null</code>
- */
- void removeEventListener(DmtEventListener listener);
-}
diff --git a/org.osgi.compendium/src/main/java/info/dmtree/DmtData.java b/org.osgi.compendium/src/main/java/info/dmtree/DmtData.java
deleted file mode 100644
index 264ecf9..0000000
--- a/org.osgi.compendium/src/main/java/info/dmtree/DmtData.java
+++ /dev/null
@@ -1,907 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2004, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package info.dmtree;
-
-import java.util.Arrays;
-import java.util.Hashtable;
-
-// Possible enhancements to this class:
-// * new constructors and get/set methods for b64, to access the encoded value
-// * new constructors and get/set methods for date/time, for more convenient
-// Java access
-/**
- * An immutable data structure representing the contents of a leaf or interior
- * node. This structure represents only the value and the format property of the
- * node, all other properties (like MIME type) can be set and read using the
- * <code>DmtSession</code> interface.
- * <p>
- * Different constructors are available to create nodes with different formats.
- * Nodes of <code>null</code> format can be created using the static
- * {@link #NULL_VALUE} constant instance of this class.
- * <p>
- * {@link #FORMAT_RAW_BINARY} and {@link #FORMAT_RAW_STRING} enable the support
- * of future data formats. When using these formats, the actual format name is
- * specified as a <code>String</code>. The application is responsible for the
- * proper encoding of the data according to the specified format.
- *
- * @version $Revision: 5673 $
- */
-public final class DmtData {
-
- /**
- * The node holds an OMA DM <code>int</code> value.
- */
- public static final int FORMAT_INTEGER = 0x0001;
-
- /**
- * The node holds an OMA DM <code>float</code> value.
- */
- public static final int FORMAT_FLOAT = 0x0002;
-
- /**
- * The node holds an OMA DM <code>chr</code> value.
- */
- public static final int FORMAT_STRING = 0x0004;
-
- /**
- * The node holds an OMA DM <code>bool</code> value.
- */
- public static final int FORMAT_BOOLEAN = 0x0008;
-
- /**
- * The node holds an OMA DM <code>date</code> value.
- */
- public static final int FORMAT_DATE = 0x0010;
-
- /**
- * The node holds an OMA DM <code>time</code> value.
- */
- public static final int FORMAT_TIME = 0x0020;
-
- /**
- * The node holds an OMA DM <code>bin</code> value. The value of the node
- * corresponds to the Java <code>byte[]</code> type.
- */
- public static final int FORMAT_BINARY = 0x0040;
-
- /**
- * The node holds an OMA DM <code>b64</code> value. Like
- * {@link #FORMAT_BINARY}, this format is also represented by the Java
- * <code>byte[]</code> type, the difference is only in the corresponding
- * OMA DM format.
- */
- public static final int FORMAT_BASE64 = 0x0080;
-
- /**
- * The node holds an OMA DM <code>xml</code> value.
- */
- public static final int FORMAT_XML = 0x0100;
-
- /**
- * The node holds an OMA DM <code>null</code> value. This corresponds to
- * the Java <code>null</code> type.
- */
- public static final int FORMAT_NULL = 0x0200;
-
- /**
- * Format specifier of an internal node. An interior node can hold a Java
- * object as value (see {@link DmtData#DmtData(Object)} and
- * {@link DmtData#getNode()}). This value can be used by Java programs that
- * know a specific URI understands the associated Java type. This type is
- * further used as a return value of the {@link MetaNode#getFormat} method
- * for interior nodes.
- */
- public static final int FORMAT_NODE = 0x0400;
-
- /**
- * The node holds raw protocol data encoded as <code>String</code>. The
- * {@link #getFormatName()} method can be used to get the actual format
- * name.
- */
- public static final int FORMAT_RAW_STRING = 0x0800;
-
- /**
- * The node holds raw protocol data encoded in binary format. The
- * {@link #getFormatName()} method can be used to get the actual format
- * name.
- */
- public static final int FORMAT_RAW_BINARY = 0x1000;
-
-
- private static final Hashtable FORMAT_NAMES = new Hashtable();
-
- static {
- FORMAT_NAMES.put(new Integer(FORMAT_BASE64), "b64");
- FORMAT_NAMES.put(new Integer(FORMAT_BINARY), "bin");
- FORMAT_NAMES.put(new Integer(FORMAT_BOOLEAN), "bool");
- FORMAT_NAMES.put(new Integer(FORMAT_DATE), "date");
- FORMAT_NAMES.put(new Integer(FORMAT_FLOAT), "float");
- FORMAT_NAMES.put(new Integer(FORMAT_INTEGER), "int");
- FORMAT_NAMES.put(new Integer(FORMAT_NODE), "node");
- FORMAT_NAMES.put(new Integer(FORMAT_NULL), "null");
- FORMAT_NAMES.put(new Integer(FORMAT_STRING), "chr");
- FORMAT_NAMES.put(new Integer(FORMAT_TIME), "time");
- FORMAT_NAMES.put(new Integer(FORMAT_XML), "xml");
- }
-
- /**
- * Constant instance representing a leaf node of <code>null</code> format.
- */
- public static final DmtData NULL_VALUE = new DmtData();
- // FORMAT_NAMES must be initialized by the time the constr. is called
-
- private final String str;
-
- private final int integer;
-
- private final float flt;
-
- private final boolean bool;
-
- private final byte[] bytes;
-
- private final int format;
-
- private final String formatName;
-
- private final Object complex;
-
- /**
- * Create a <code>DmtData</code> instance of <code>null</code> format.
- * This constructor is private and used only to create the public
- * {@link #NULL_VALUE} constant.
- */
- private DmtData() {
- format = FORMAT_NULL;
- formatName = getFormatName(format);
-
- this.str = null;
- this.integer = 0;
- this.flt = 0;
- this.bool = false;
- this.bytes = null;
- this.complex = null;
- }
-
- /**
- * Create a <code>DmtData</code> instance of <code>chr</code> format
- * with the given string value. The <code>null</code> string argument is
- * valid.
- *
- * @param str the string value to set
- */
- public DmtData(String str) {
- format = FORMAT_STRING;
- formatName = getFormatName(format);
- this.str = str;
-
- this.integer = 0;
- this.flt = 0;
- this.bool = false;
- this.bytes = null;
- this.complex = null;
- }
-
- /**
- * Create a <code>DmtData</code> instance of <code>node</code> format
- * with the given object value. The value represents complex data associated
- * with an interior node.
- * <p>
- * Certain interior nodes can support access to their subtrees through such
- * complex values, making it simpler to retrieve or update all leaf nodes in
- * a subtree.
- * <p>
- * The given value must be a non-<code>null</code> immutable object.
- *
- * @param complex the complex data object to set
- */
- public DmtData(Object complex) {
- if(complex == null)
- throw new NullPointerException("Complex data argument is null.");
-
- format = FORMAT_NODE;
- formatName = getFormatName(format);
- this.complex = complex;
-
- this.str = null;
- this.integer = 0;
- this.flt = 0;
- this.bool = false;
- this.bytes = null;
- }
-
- /**
- * Create a <code>DmtData</code> instance of the specified format and set
- * its value based on the given string. Only the following string-based
- * formats can be created using this constructor:
- * <ul>
- * <li>{@link #FORMAT_STRING} - value can be any string
- * <li>{@link #FORMAT_XML} - value must contain an XML fragment (the
- * validity is not checked by this constructor)
- * <li>{@link #FORMAT_DATE} - value must be parseable to an ISO 8601
- * calendar date in complete representation, basic format (pattern
- * <tt>CCYYMMDD</tt>)
- * <li>{@link #FORMAT_TIME} - value must be parseable to an ISO 8601 time
- * of day in either local time, complete representation, basic format
- * (pattern <tt>hhmmss</tt>) or Coordinated Universal Time, basic format
- * (pattern <tt>hhmmssZ</tt>)
- * </ul>
- * The <code>null</code> string argument is only valid if the format is
- * string or XML.
- *
- * @param value the string, XML, date or time value to set
- * @param format the format of the <code>DmtData</code> instance to be
- * created, must be one of the formats specified above
- * @throws IllegalArgumentException if <code>format</code> is not one of
- * the allowed formats, or <code>value</code> is not a valid
- * string for the given format
- * @throws NullPointerException if a date or time is constructed and
- * <code>value</code> is <code>null</code>
- */
- public DmtData(String value, int format) {
- switch (format) {
- case FORMAT_DATE:
- checkDateFormat(value);
- break;
- case FORMAT_TIME:
- checkTimeFormat(value);
- break;
- case FORMAT_STRING:
- case FORMAT_XML:
- break; // nothing to do, all string values are accepted
- default:
- throw new IllegalArgumentException(
- "Invalid format in string constructor: " + format);
- }
- this.format = format;
- this.formatName = getFormatName(format);
- this.str = value;
-
- this.integer = 0;
- this.flt = 0;
- this.bool = false;
- this.bytes = null;
- this.complex = null;
- }
-
- /**
- * Create a <code>DmtData</code> instance of <code>int</code> format and
- * set its value.
- *
- * @param integer the integer value to set
- */
- public DmtData(int integer) {
- format = FORMAT_INTEGER;
- formatName = getFormatName(format);
- this.integer = integer;
-
- this.str = null;
- this.flt = 0;
- this.bool = false;
- this.bytes = null;
- this.complex = null;
- }
-
- /**
- * Create a <code>DmtData</code> instance of <code>float</code> format
- * and set its value.
- *
- * @param flt the float value to set
- */
- public DmtData(float flt) {
- format = FORMAT_FLOAT;
- formatName = getFormatName(format);
- this.flt = flt;
-
- this.str = null;
- this.integer = 0;
- this.bool = false;
- this.bytes = null;
- this.complex = null;
- }
-
- /**
- * Create a <code>DmtData</code> instance of <code>bool</code> format
- * and set its value.
- *
- * @param bool the boolean value to set
- */
- public DmtData(boolean bool) {
- format = FORMAT_BOOLEAN;
- formatName = getFormatName(format);
- this.bool = bool;
-
- this.str = null;
- this.integer = 0;
- this.flt = 0;
- this.bytes = null;
- this.complex = null;
- }
-
- /**
- * Create a <code>DmtData</code> instance of <code>bin</code> format and
- * set its value.
- *
- * @param bytes the byte array to set, must not be <code>null</code>
- * @throws NullPointerException if <code>bytes</code> is <code>null</code>
- */
- public DmtData(byte[] bytes) {
- if (bytes == null)
- throw new NullPointerException("Binary data argument is null.");
-
- format = FORMAT_BINARY;
- formatName = getFormatName(format);
- this.bytes = bytes;
-
- this.str = null;
- this.integer = 0;
- this.flt = 0;
- this.bool = false;
- this.complex = null;
- }
-
- /**
- * Create a <code>DmtData</code> instance of <code>bin</code> or
- * <code>b64</code> format and set its value. The chosen format is
- * specified by the <code>base64</code> parameter.
- *
- * @param bytes the byte array to set, must not be <code>null</code>
- * @param base64 if <code>true</code>, the new instance will have
- * <code>b64</code> format, if <code>false</code>, it will have
- * <code>bin</code> format
- * @throws NullPointerException if <code>bytes</code> is <code>null</code>
- */
- public DmtData(byte[] bytes, boolean base64) {
- if (bytes == null)
- throw new NullPointerException("Binary data argument is null.");
-
- format = base64 ? FORMAT_BASE64 : FORMAT_BINARY;
- formatName = getFormatName(format);
- this.bytes = bytes;
-
- this.str = null;
- this.integer = 0;
- this.flt = 0;
- this.bool = false;
- this.complex = null;
- }
-
- /**
- * Create a <code>DmtData</code> instance in {@link #FORMAT_RAW_STRING}
- * format. The data is provided encoded as a <code>String</code>. The
- * actual data format is specified in <code>formatName</code>. The
- * encoding used in <code>data</code> must conform to this format.
- *
- * @param formatName the name of the format, must not be <code>null</code>
- * @param data the data encoded according to the specified format, must not
- * be <code>null</code>
- * @throws NullPointerException if <code>formatName</code> or
- * <code>data</code> is <code>null</code>
- */
- public DmtData(String formatName, String data) {
- if(formatName == null)
- throw new NullPointerException("Format name argument is null.");
- if(data == null)
- throw new NullPointerException("Data argument is null.");
-
- format = FORMAT_RAW_STRING;
- this.formatName = formatName;
- this.str = data;
-
- this.bytes = null;
- this.integer = 0;
- this.flt = 0;
- this.bool = false;
- this.complex = null;
- }
-
- /**
- * Create a <code>DmtData</code> instance in {@link #FORMAT_RAW_BINARY}
- * format. The data is provided encoded as binary. The actual data format is
- * specified in <code>formatName</code>. The encoding used in
- * <code>data</code> must conform to this format.
- *
- * @param formatName the name of the format, must not be <code>null</code>
- * @param data the data encoded according to the specified format, must not
- * be <code>null</code>
- * @throws NullPointerException if <code>formatName</code> or
- * <code>data</code> is <code>null</code>
- */
- public DmtData(String formatName, byte[] data) {
- if(formatName == null)
- throw new NullPointerException("Format name argument is null.");
- if(data == null)
- throw new NullPointerException("Data argument is null.");
-
- format = FORMAT_RAW_BINARY;
- this.formatName = formatName;
- this.bytes = (byte[]) data.clone();
-
- this.str = null;
- this.integer = 0;
- this.flt = 0;
- this.bool = false;
- this.complex = null;
- }
-
- /**
- * Gets the value of a node with string (<code>chr</code>) format.
- *
- * @return the string value
- * @throws DmtIllegalStateException if the format of the node is not string
- */
- public String getString() {
- if (format == FORMAT_STRING)
- return str;
-
- throw new DmtIllegalStateException("DmtData value is not string.");
- }
-
- /**
- * Gets the value of a node with date format. The returned date string is
- * formatted according to the ISO 8601 definition of a calendar date in
- * complete representation, basic format (pattern <tt>CCYYMMDD</tt>).
- *
- * @return the date value
- * @throws DmtIllegalStateException if the format of the node is not date
- */
- public String getDate() {
- if (format == FORMAT_DATE)
- return str;
-
- throw new DmtIllegalStateException("DmtData value is not date.");
- }
-
- /**
- * Gets the value of a node with time format. The returned time string is
- * formatted according to the ISO 8601 definition of the time of day. The
- * exact format depends on the value the object was initialized with: either
- * local time, complete representation, basic format (pattern
- * <tt>hhmmss</tt>) or Coordinated Universal Time, basic format (pattern
- * <tt>hhmmssZ</tt>).
- *
- * @return the time value
- * @throws DmtIllegalStateException if the format of the node is not time
- */
- public String getTime() {
- if (format == FORMAT_TIME)
- return str;
-
- throw new DmtIllegalStateException("DmtData value is not time.");
- }
-
- /**
- * Gets the value of a node with <code>xml</code> format.
- *
- * @return the XML value
- * @throws DmtIllegalStateException if the format of the node is not
- * <code>xml</code>
- */
- public String getXml() {
- if (format == FORMAT_XML)
- return str;
-
- throw new DmtIllegalStateException("DmtData value is not XML.");
- }
-
- /**
- * Gets the value of a node with integer (<code>int</code>) format.
- *
- * @return the integer value
- * @throws DmtIllegalStateException if the format of the node is not integer
- */
- public int getInt() {
- if (format == FORMAT_INTEGER)
- return integer;
-
- throw new DmtIllegalStateException("DmtData value is not integer.");
- }
-
- /**
- * Gets the value of a node with <code>float</code> format.
- *
- * @return the float value
- * @throws DmtIllegalStateException if the format of the node is not
- * <code>float</code>
- */
- public float getFloat() {
- if (format == FORMAT_FLOAT)
- return flt;
-
- throw new DmtIllegalStateException("DmtData value is not float.");
- }
-
- /**
- * Gets the value of a node with boolean (<code>bool</code>) format.
- *
- * @return the boolean value
- * @throws DmtIllegalStateException if the format of the node is not boolean
- */
- public boolean getBoolean() {
- if (format == FORMAT_BOOLEAN)
- return bool;
-
- throw new DmtIllegalStateException("DmtData value is not boolean.");
- }
-
- /**
- * Gets the value of a node with binary (<code>bin</code>) format.
- *
- * @return the binary value
- * @throws DmtIllegalStateException if the format of the node is not binary
- */
- public byte[] getBinary() {
- if (format == FORMAT_BINARY) {
- byte[] bytesCopy = new byte[bytes.length];
- for (int i = 0; i < bytes.length; i++)
- bytesCopy[i] = bytes[i];
-
- return bytesCopy;
- }
-
- throw new DmtIllegalStateException("DmtData value is not a byte array.");
- }
-
- /**
- * Gets the value of a node in raw binary ({@link #FORMAT_RAW_BINARY})
- * format.
- *
- * @return the data value in raw binary format
- * @throws DmtIllegalStateException if the format of the node is not raw binary
- */
- public byte[] getRawBinary() {
- if (format == FORMAT_RAW_BINARY)
- return (byte[]) bytes.clone();
-
- throw new DmtIllegalStateException(
- "DmtData value is not in raw binary format.");
- }
-
- /**
- * Gets the value of a node in raw <code>String</code>
- * ({@link #FORMAT_RAW_STRING}) format.
- *
- * @return the data value in raw <code>String</code> format
- * @throws DmtIllegalStateException if the format of the node is not raw
- * <code>String</code>
- */
- public String getRawString() {
- if (format == FORMAT_RAW_STRING)
- return str;
-
- throw new DmtIllegalStateException(
- "DmtData value is not in raw string format.");
- }
-
- /**
- * Gets the value of a node with base 64 (<code>b64</code>) format.
- *
- * @return the binary value
- * @throws DmtIllegalStateException if the format of the node is not base 64.
- */
- public byte[] getBase64() {
- if (format == FORMAT_BASE64) {
- byte[] bytesCopy = new byte[bytes.length];
- for (int i = 0; i < bytes.length; i++)
- bytesCopy[i] = bytes[i];
-
- return bytesCopy;
- }
-
- throw new DmtIllegalStateException(
- "DmtData value is not in base 64 format.");
- }
-
- /**
- * Gets the complex data associated with an interior node (<code>node</code>
- * format).
- * <p>
- * Certain interior nodes can support access to their subtrees through
- * complex values, making it simpler to retrieve or update all leaf nodes in
- * the subtree.
- *
- * @return the data object associated with an interior node
- * @throws DmtIllegalStateException if the format of the data is not
- * <code>node</code>
- */
- public Object getNode() {
- if(format == FORMAT_NODE)
- return complex;
-
- throw new DmtIllegalStateException(
- "DmtData does not contain interior node data.");
- }
-
- /**
- * Get the node's format, expressed in terms of type constants defined in
- * this class. Note that the 'format' term is a legacy from OMA DM, it is
- * more customary to think of this as 'type'.
- *
- * @return the format of the node
- */
- public int getFormat() {
- return format;
- }
-
- /**
- * Returns the format of this <code>DmtData</code> as <code>String</code>.
- * For the predefined data formats this is the OMA DM defined name of the
- * format. For {@link #FORMAT_RAW_STRING} and {@link #FORMAT_RAW_BINARY}
- * this is the format specified when the object was created.
- *
- * @return the format name as <code>String</code>
- */
- public String getFormatName() {
- return formatName;
- }
-
- /**
- * Get the size of the data. The returned value depends on the format of
- * data in the node:
- * <ul>
- * <li>{@link #FORMAT_STRING}, {@link #FORMAT_XML}, {@link #FORMAT_BINARY},
- * {@link #FORMAT_BASE64}, {@link #FORMAT_RAW_STRING}, and
- * {@link #FORMAT_RAW_BINARY}: the length of the stored data, or 0 if
- * the data is <code>null</code>
- * <li>{@link #FORMAT_INTEGER} and {@link #FORMAT_FLOAT}: 4
- * <li>{@link #FORMAT_DATE} and {@link #FORMAT_TIME}: the length of the
- * date or time in its string representation
- * <li>{@link #FORMAT_BOOLEAN}: 1
- * <li>{@link #FORMAT_NODE}: -1 (unknown)
- * <li>{@link #FORMAT_NULL}: 0
- * </ul>
- *
- * @return the size of the data stored by this object
- */
- public int getSize() {
- switch (format) {
- case FORMAT_STRING:
- case FORMAT_XML:
- case FORMAT_DATE:
- case FORMAT_TIME:
- case FORMAT_RAW_STRING:
- return str == null ? 0 : str.length();
- case FORMAT_BINARY:
- case FORMAT_BASE64:
- case FORMAT_RAW_BINARY:
- return bytes.length;
- case FORMAT_INTEGER:
- case FORMAT_FLOAT:
- return 4;
- case FORMAT_BOOLEAN:
- return 1;
- case FORMAT_NODE:
- return -1;
- case FORMAT_NULL:
- return 0;
- }
-
- return 0; // never reached
- }
-
- /**
- * Gets the string representation of the <code>DmtData</code>. This
- * method works for all formats.
- * <p>
- * For string format data - including {@link #FORMAT_RAW_STRING} - the
- * string value itself is returned, while for XML, date, time, integer,
- * float, boolean and node formats the string form of the value is returned.
- * Binary - including {@link #FORMAT_RAW_BINARY} - and base64 data is
- * represented by two-digit hexadecimal numbers for each byte separated by
- * spaces. The {@link #NULL_VALUE} data has the string form of
- * "<code>null</code>". Data of string or XML format containing the Java
- * <code>null</code> value is represented by an empty string.
- *
- * @return the string representation of this <code>DmtData</code> instance
- */
- public String toString() {
- switch (format) {
- case FORMAT_STRING:
- case FORMAT_XML:
- case FORMAT_DATE:
- case FORMAT_TIME:
- case FORMAT_RAW_STRING:
- return str == null ? "" : str;
- case FORMAT_INTEGER:
- return String.valueOf(integer);
- case FORMAT_FLOAT:
- return String.valueOf(flt);
- case FORMAT_BOOLEAN:
- return String.valueOf(bool);
- case FORMAT_BINARY:
- case FORMAT_BASE64:
- case FORMAT_RAW_BINARY:
- return getHexDump(bytes);
- case FORMAT_NODE:
- return complex.toString();
- case FORMAT_NULL:
- return "null";
- }
-
- return null; // never reached
- }
-
- /**
- * Compares the specified object with this <code>DmtData</code> instance.
- * Two <code>DmtData</code> objects are considered equal if their format
- * is the same, and their data (selected by the format) is equal.
- * <p>
- * In case of {@link #FORMAT_RAW_BINARY} and {@link #FORMAT_RAW_STRING}
- * the textual name of the data format - as returned by
- * {@link #getFormatName()} - must be equal as well.
- *
- * @param obj the object to compare with this <code>DmtData</code>
- * @return true if the argument represents the same <code>DmtData</code>
- * as this object
- */
- public boolean equals(Object obj) {
- if (!(obj instanceof DmtData))
- return false;
-
- DmtData other = (DmtData) obj;
-
- if (format != other.format)
- return false;
-
- switch (format) {
- case FORMAT_STRING:
- case FORMAT_XML:
- case FORMAT_DATE:
- case FORMAT_TIME:
- return str == null ? other.str == null : str.equals(other.str);
- case FORMAT_INTEGER:
- return integer == other.integer;
- case FORMAT_FLOAT:
- return flt == other.flt;
- case FORMAT_BOOLEAN:
- return bool == other.bool;
- case FORMAT_BINARY:
- case FORMAT_BASE64:
- return Arrays.equals(bytes, other.bytes);
- case FORMAT_NODE:
- return complex.equals(other.complex);
- case FORMAT_NULL:
- return true;
- case FORMAT_RAW_BINARY:
- return formatName.equals(other.formatName)
- && Arrays.equals(bytes, other.bytes);
- case FORMAT_RAW_STRING:
- // in this case str cannot be null
- return formatName.equals(other.formatName) && str.equals(other.str);
- }
-
- return false; // never reached
- }
-
- /**
- * Returns the hash code value for this <code>DmtData</code> instance. The
- * hash code is calculated based on the data (selected by the format) of
- * this object.
- *
- * @return the hash code value for this object
- */
- public int hashCode() {
- switch (format) {
- case FORMAT_STRING:
- case FORMAT_XML:
- case FORMAT_DATE:
- case FORMAT_TIME:
- case FORMAT_RAW_STRING:
- return str == null ? 0 : str.hashCode();
- case FORMAT_INTEGER:
- return new Integer(integer).hashCode();
- case FORMAT_FLOAT:
- return new Float(flt).hashCode();
- case FORMAT_BOOLEAN:
- return new Boolean(bool).hashCode();
- case FORMAT_BINARY:
- case FORMAT_BASE64:
- case FORMAT_RAW_BINARY:
- return new String(bytes).hashCode();
- case FORMAT_NODE:
- return complex.hashCode();
- case FORMAT_NULL:
- return 0;
- }
-
- return 0; // never reached
- }
-
- private static void checkDateFormat(String value) {
- if(value.length() != 8)
- throw new IllegalArgumentException("Date string '" + value +
- "' does not follow the format 'CCYYMMDD'.");
-
- int year = checkNumber(value, "Date", 0, 4, 0, 9999);
- int month = checkNumber(value, "Date", 4, 2, 1, 12);
- int day = checkNumber(value, "Date", 6, 2, 1, 31);
-
- // Date checking is not prepared for all special rules (for example
- // historical leap years), production code could contain a full check.
-
- // Day 31 is invalid for April, June, September and November
- if((month == 4 || month == 6 || month == 9 || month == 11) && day == 31)
- throw new IllegalArgumentException("Date string '" + value +
- "' contains an invalid date.");
-
- // February 29 is invalid except for leap years, Feb. 30-31 are invalid
- if(month == 2 && day > 28 &&
- !(day == 29 && year%4 == 0 && (year%100 != 0 || year%400 == 0)))
- throw new IllegalArgumentException("Date string '" + value +
- "' contains an invalid date.");
- }
-
- private static void checkTimeFormat(String value) {
- if(value.length() > 0 && value.charAt(value.length()-1) == 'Z')
- value = value.substring(0, value.length()-1);
-
- if(value.length() != 6)
- throw new IllegalArgumentException("Time string '" + value +
- "' does not follow the format 'hhmmss' or 'hhmmssZ'.");
-
- // Time checking is not prepared for all special rules (for example
- // leap seconds), production code could contain a full check.
-
- // if hour is 24, only 240000 should be allowed
- checkNumber(value, "Time", 0, 2, 0, 24);
- checkNumber(value, "Time", 2, 2, 0, 59);
- checkNumber(value, "Time", 4, 2, 0, 59);
-
- if(value.startsWith("24") && !value.startsWith("240000"))
- throw new IllegalArgumentException("Time string is out of range.");
- }
-
- private static int checkNumber(String value, String name, int from,
- int length, int min, int max) {
- String part = value.substring(from, from+length);
- int number;
- try {
- number = Integer.parseInt(part);
- } catch(NumberFormatException e) {
- throw new IllegalArgumentException(name + " string '" + value +
- "' contains a non-numeric part.");
- }
- if(number < min || number > max)
- throw new IllegalArgumentException("A segment of the " + name +
- " string '" + value + "' is out of range.");
-
- return number;
- }
-
- // character array of hexadecimal digits, used for printing binary data
- private static char[] hex = "0123456789ABCDEF".toCharArray();
-
- // generates a hexadecimal dump of the given binary data
- private static String getHexDump(byte[] bytes) {
- if (bytes.length == 0)
- return "";
-
- StringBuffer buf = new StringBuffer();
- appendHexByte(buf, bytes[0]);
- for (int i = 1; i < bytes.length; i++)
- appendHexByte(buf.append(' '), bytes[i]);
-
- return buf.toString();
- }
-
- private static void appendHexByte(StringBuffer buf, byte b) {
- buf.append(hex[(b & 0xF0) >> 4]).append(hex[b & 0x0F]);
- }
-
- private static String getFormatName(int format) {
- return (String) FORMAT_NAMES.get(new Integer(format));
- }
-}
diff --git a/org.osgi.compendium/src/main/java/info/dmtree/DmtEvent.java b/org.osgi.compendium/src/main/java/info/dmtree/DmtEvent.java
deleted file mode 100644
index 1b24fdc..0000000
--- a/org.osgi.compendium/src/main/java/info/dmtree/DmtEvent.java
+++ /dev/null
@@ -1,140 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2004, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package info.dmtree;
-
-/**
- * Event class storing the details of a change in the tree.
- * <code>DmtEvent</code> is used by <code>DmtAdmin</code> to notify registered
- * {@link DmtEventListener EventListeners} about important changes. Events are
- * generated after every successful DMT change, and also when sessions are
- * opened or closed. If a {@link DmtSession} is opened in atomic mode, DMT
- * events are only sent when the session is committed, when the changes are
- * actually performed.
- * <p>
- * An event is generated for each group of nodes added, deleted, replaced,
- * renamed or copied, in this order. Events are also generated when sessions are
- * opened and closed.
- * <p>
- * The <code>type</code> of the event describes the change that triggered the
- * event delivery. Each event carries the unique identifier of the session in
- * which the described change happened. The events describing changes in the DMT
- * carry the list of affected nodes. In case of {@link #COPIED} or
- * {@link #RENAMED} events, the event carries the list of new nodes as well.
- * <p>
- * When a <code>DmtEvent</code> is delivered to a listener, the event contains
- * only those node URIs that the listener has access to. This access control
- * decision is based on the principal specified when the listener was
- * registered:
- * <ul>
- * <li>If the listener was registered specifying an explicit principal, using
- * the {@link DmtAdmin#addEventListener(String, int, String, DmtEventListener)}
- * method, then the target node ACLs should be checked for providing GET access
- * to the specified principal;
- * <li>When the listener was registered without an explicit principal then the
- * listener needs GET {@link info.dmtree.security.DmtPermission} for the
- * corresponding node.
- * </ul>
- *
- * @version $Revision: 5673 $
- */
-public interface DmtEvent {
-
- /**
- * Event type indicating nodes that were added.
- */
- int ADDED = 0x01;
-
- /**
- * Event type indicating nodes that were copied.
- */
- int COPIED = 0x02;
-
- /**
- * Event type indicating nodes that were deleted.
- */
- int DELETED = 0x04;
-
- /**
- * Event type indicating nodes that were renamed.
- */
- int RENAMED = 0x08;
-
- /**
- * Event type indicating nodes that were replaced.
- */
- int REPLACED = 0x10;
-
- /**
- * Event type indicating that a new session was opened.
- */
- int SESSION_OPENED = 0x20;
-
- /**
- * Event type indicating that a session was closed. This type of event is
- * sent when the session is closed by the client or becomes inactive for any
- * other reason (session timeout, fatal errors in business methods, etc.).
- */
- int SESSION_CLOSED = 0x40;
-
- /**
- * This method returns the type of this event.
- *
- * @return the type of this event.
- */
- int getType();
-
- /**
- * This method returns the identifier of the session in which this event
- * took place. The ID is guaranteed to be unique on a machine.
- *
- * @return the unique indetifier of the session that triggered the event
- */
- int getSessionId();
-
- /**
- * This method can be used to query the subject nodes of this event. The
- * method returns <code>null</code> for {@link #SESSION_OPENED} and
- * {@link #SESSION_CLOSED}.
- * <p>
- * The method returns only those affected nodes that the caller has the GET
- * permission for (or in case of {@link #COPIED} or {@link #RENAMED} events,
- * where the caller has GET permissions for either the source or the
- * destination nodes). Therefore, it is possible that the method returns an
- * empty array. All returned URIs are absolute.
- *
- * @return the array of affected nodes
- * @see #getNewNodes
- */
- String[] getNodes();
-
- /**
- * This method can be used to query the new nodes, when the type of the
- * event is {@link #COPIED} or {@link #RENAMED}. For all other event types
- * this method returns <code>null</code>.
- * <p>
- * The array returned by this method runs parallel to the array returned by
- * {@link #getNodes}, the elements in the two arrays contain the source and
- * destination URIs for the renamed or copied nodes in the same order. All
- * returned URIs are absolute.
- * <p>
- * This method returns only those nodes where the caller has the GET
- * permission for the source or destination node of the operation.
- * Therefore, it is possible that the method returns an empty array.
- *
- * @return the array of newly created nodes
- */
- String[] getNewNodes();
-}
diff --git a/org.osgi.compendium/src/main/java/info/dmtree/DmtEventListener.java b/org.osgi.compendium/src/main/java/info/dmtree/DmtEventListener.java
deleted file mode 100644
index a0cf664..0000000
--- a/org.osgi.compendium/src/main/java/info/dmtree/DmtEventListener.java
+++ /dev/null
@@ -1,37 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2004, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package info.dmtree;
-
-/**
- * Registered implementations of this class are notified via {@link DmtEvent}
- * objects about important changes in the tree. Events are generated after every
- * successful DMT change, and also when sessions are opened or closed. If a
- * {@link DmtSession} is opened in atomic mode, DMT events are only sent when
- * the session is committed, when the changes are actually performed.
- *
- * @version $Revision: 5673 $
- */
-public interface DmtEventListener {
-
- /**
- * <code>DmtAdmin</code> uses this method to notify the registered
- * listeners about the change. This method is called asynchronously from the
- * actual event occurrence.
- *
- * @param event the <code>DmtEvent</code> describing the change in detail
- */
- void changeOccurred(DmtEvent event);
-}
diff --git a/org.osgi.compendium/src/main/java/info/dmtree/DmtException.java b/org.osgi.compendium/src/main/java/info/dmtree/DmtException.java
deleted file mode 100644
index 0325e03..0000000
--- a/org.osgi.compendium/src/main/java/info/dmtree/DmtException.java
+++ /dev/null
@@ -1,640 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2004, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package info.dmtree;
-
-import java.io.PrintStream;
-import java.util.Vector;
-
-/**
- * Checked exception received when a DMT operation fails. Beside the exception
- * message, a <code>DmtException</code> always contains an error code (one of
- * the constants specified in this class), and may optionally contain the URI of
- * the related node, and information about the cause of the exception.
- * <p>
- * Some of the error codes defined in this class have a corresponding error code
- * defined in OMA DM, in these cases the name and numerical value from OMA DM is
- * used. Error codes without counterparts in OMA DM were given numbers from a
- * different range, starting from 1.
- * <p>
- * The cause of the exception (if specified) can either be a single
- * <code>Throwable</code> instance, or a list of such instances if several
- * problems occurred during the execution of a method. An example for the latter
- * is the <code>close</code> method of <code>DmtSession</code> that tries to
- * close multiple plugins, and has to report the exceptions of all failures.
- * <p>
- * Each constructor has two variants, one accepts a <code>String</code> node
- * URI, the other accepts a <code>String[]</code> node path. The former is used
- * by the DmtAdmin implementation, the latter by the plugins, who receive the
- * node URI as an array of segment names. The constructors are otherwise
- * identical.
- * <p>
- * Getter methods are provided to retrieve the values of the additional
- * parameters, and the <code>printStackTrace(PrintWriter)</code> method is
- * extended to print the stack trace of all causing throwables as well.
- *
- * @version $Revision: 5837 $
- */
-public class DmtException extends Exception {
- private static final long serialVersionUID = -63006267148118655L;
-
- // ----- Public constants -----//
-
- /**
- * The originator's authentication credentials specify a principal with
- * insufficient rights to complete the command.
- * <p>
- * This status code is used as response to device originated sessions if the
- * remote management server cannot authorize the device to perform the
- * requested operation.
- * <p>
- * This error code corresponds to the OMA DM response status code 401
- * "Unauthorized".
- */
- public static final int UNAUTHORIZED = 401;
-
- /**
- * The requested target node was not found. No indication is given as to
- * whether this is a temporary or permanent condition, unless otherwise
- * noted.
- * <p>
- * This is only used when the requested node name is valid, otherwise the
- * more specific error codes {@link #URI_TOO_LONG} or {@link #INVALID_URI}
- * are used. This error code corresponds to the OMA DM response status code
- * 404 "Not Found".
- */
- public static final int NODE_NOT_FOUND = 404;
-
- /**
- * The requested command is not allowed on the target node. This includes
- * the following situations:
- * <ul>
- * <li>an interior node operation is requested for a leaf node, or vice
- * versa (e.g. trying to retrieve the children of a leaf node)
- * <li>an attempt is made to create a node where the parent is a leaf node
- * <li>an attempt is made to rename or delete the root node of the tree
- * <li>an attempt is made to rename or delete the root node of the session
- * <li>a write operation (other than setting the ACL) is performed in a
- * non-atomic write session on a node provided by a plugin that is read-only
- * or does not support non-atomic writing
- * <li>a node is copied to its descendant
- * <li>the ACL of the root node is changed not to include Add rights for
- * all principals
- * </ul>
- * <p>
- * This error code corresponds to the OMA DM response status code 405
- * "Command not allowed".
- */
- public static final int COMMAND_NOT_ALLOWED = 405;
-
- /**
- * The requested command failed because an optional feature required by the
- * command is not supported. For example, opening an atomic session might
- * return this error code if the DmtAdmin implementation does not support
- * transactions. Similarly, accessing the optional node properties (Title,
- * Timestamp, Version, Size) might not succeed if either the DmtAdmin
- * implementation or the underlying plugin does not support the property.
- * <p>
- * When getting or setting values for interior nodes (an optional
- * optimization feature), a plugin can use this error code to indicate that
- * the given interior node does not support values.
- * <p>
- * This error code corresponds to the OMA DM response status code 406
- * "Optional feature not supported".
- */
- public static final int FEATURE_NOT_SUPPORTED = 406;
-
- /**
- * The requested command failed because the target URI or one of its
- * segments is too long for what the recipient is able or willing to
- * process, or the target URI contains too many segments. The length and
- * segment number limits are implementation dependent, their minimum values
- * can be found in the Non Functional Requirements section of the OSGi
- * specification.
- * <p>
- * The {@link Uri#mangle(String)} method provides support for ensuring that
- * a URI segment conforms to the length limits set by the implementation.
- * <p>
- * This error code corresponds to the OMA DM response status code 414
- * "URI too long".
- *
- * @see "OSGi Service Platform, Mobile Specification Release 4"
- */
- public static final int URI_TOO_LONG = 414;
-
- /**
- * The requested node creation operation failed because the target already
- * exists. This can occur if the node is created directly (with one of the
- * <code>create...</code> methods), or indirectly (during a
- * <code>copy</code> operation).
- * <p>
- * This error code corresponds to the OMA DM response status code 418
- * "Already exists".
- */
- public static final int NODE_ALREADY_EXISTS = 418;
-
- /**
- * The requested command failed because the principal associated with the
- * session does not have adequate access control permissions (ACL) on the
- * target. This can only appear in case of remote sessions, i.e. if the
- * session is associated with an authenticated principal.
- * <p>
- * This error code corresponds to the OMA DM response status code 425
- * "Permission denied".
- */
- public static final int PERMISSION_DENIED = 425;
-
- /**
- * The recipient encountered an error which prevented it from fulfilling the
- * request.
- * <p>
- * This error code is only used in situations not covered by any of the
- * other error codes that a method may use. Some methods specify more
- * specific error situations for this code, but it can generally be used for
- * any unexpected condition that causes the command to fail.
- * <p>
- * This error code corresponds to the OMA DM response status code 500
- * "Command Failed".
- */
- public static final int COMMAND_FAILED = 500;
-
- /**
- * An error related to the recipient data store occurred while processing
- * the request. This error code may be thrown by any of the methods
- * accessing the tree, but whether it is really used depends on the
- * implementation, and the data store it uses.
- * <p>
- * This error code corresponds to the OMA DM response status code 510
- * "Data store failure".
- */
- public static final int DATA_STORE_FAILURE = 510;
-
- /**
- * The rollback command was not completed successfully. The tree might be in
- * an inconsistent state after this error.
- * <p>
- * This error code corresponds to the OMA DM response status code 516
- * "Atomic roll back failed".
- */
- public static final int ROLLBACK_FAILED = 516;
-
-
- /**
- * A device initiated remote operation failed. This is used when the
- * protocol adapter fails to send an alert for any reason.
- * <p>
- * Alert routing errors (that occur while looking for the proper protocol
- * adapter to use) are indicated by {@link #ALERT_NOT_ROUTED}, this code is
- * only for errors encountered while sending the routed alert. This error
- * code does not correspond to any OMA DM response status code. It should be
- * translated to the code 500 "Command Failed" when transferring
- * over OMA DM.
- */
- public static final int REMOTE_ERROR = 1;
-
- /**
- * Operation failed because of meta data restrictions. This covers any
- * attempted deviation from the parameters defined by the
- * <code>MetaNode</code> objects of the affected nodes, for example in the
- * following situations:
- * <ul>
- * <li>creating, deleting or renaming a permanent node, or modifying its
- * type or value
- * <li>creating an interior node where the meta-node defines it as a leaf,
- * or vice versa
- * <li>any operation on a node which does not have the required access type
- * (e.g. executing a node that lacks the <code>MetaNode.CMD_EXECUTE</code>
- * access type)
- * <li>any node creation or deletion that would violate the cardinality
- * constraints
- * <li>any leaf node value setting that would violate the allowed formats,
- * values, mime types, etc.
- * <li>any node creation that would violate the allowed node names
- * </ul>
- * <p>
- * This error code can also be used to indicate any other meta data
- * violation, even if it cannot be described by the <code>MetaNode</code>
- * class. For example, detecting a multi-node constraint violation while
- * committing an atomic session should result in this error.
- * <p>
- * This error code does not correspond to any OMA DM response status code.
- * It should be translated to the code 405 "Command not allowed"
- * when transferring over OMA DM.
- */
- public static final int METADATA_MISMATCH = 2;
-
- /**
- * The requested command failed because the target URI or node name is
- * <code>null</code> or syntactically invalid. This covers the following
- * cases:
- * <ul>
- * <li>the URI or node name ends with the '\' or '/' character
- * <li>the URI is an empty string (only invalid if the method does not
- * accept relative URIs)
- * <li>the URI contains the segment "<code>.</code>" at a position
- * other than the beginning of the URI
- * <li>the node name is "<code>..</code>" or the URI contains such
- * a segment
- * <li>the node name is an empty string or the URI contains an empty segment
- * <li>the node name contains an unescaped '/' character
- * </ul>
- * <p>
- * See the {@link Uri#mangle(String)} method for support on escaping invalid
- * characters in a URI.
- * <p>
- * This code is only used if the URI or node name does not match any of the
- * criteria for {@link #URI_TOO_LONG}. This error code does not correspond
- * to any OMA DM response status code. It should be translated to the code
- * 404 "Not Found" when transferring over OMA DM.
- */
- public static final int INVALID_URI = 3;
-
- /**
- * An error occurred related to concurrent access of nodes. This can happen
- * for example if a configuration node was deleted directly through the
- * Configuration Admin service, while the node was manipulated via the tree.
- * <p>
- * This error code does not correspond to any OMA DM response status code.
- * It should be translated to the code 500 "Command Failed" when
- * transferring over OMA DM.
- */
- public static final int CONCURRENT_ACCESS = 4;
-
- /**
- * An alert can not be sent from the device to the given principal. This can
- * happen if there is no Remote Alert Sender willing to forward the alert to
- * the given principal, or if no principal was given and the DmtAdmin did
- * not find an appropriate default destination.
- * <p>
- * This error code does not correspond to any OMA DM response status code.
- * It should be translated to the code 500 "Command Failed" when
- * transferring over OMA DM.
- */
- public static final int ALERT_NOT_ROUTED = 5;
-
- /**
- * A transaction-related error occurred in an atomic session. This error is
- * caused by one of the following situations:
- * <ul>
- * <li>an updating method within an atomic session can not be executed
- * because the underlying plugin is read-only or does not support atomic
- * writing</li>
- * <li>a commit operation at the end of an atomic session failed because
- * one of the underlying plugins failed to close</li>
- * </ul>
- * The latter case may leave the tree in an inconsistent state due to the
- * lack of a two-phase commit system, see {@link DmtSession#commit} for
- * details.
- * <p>
- * This error code does not correspond to any OMA DM response status code.
- * It should be translated to the code 500 "Command Failed" when
- * transferring over OMA DM.
- */
- public static final int TRANSACTION_ERROR = 6;
-
- /**
- * Creation of a session timed out because of another ongoing session. The
- * length of time while the DmtAdmin waits for the blocking session(s) to
- * finish is implementation dependant.
- * <p>
- * This error code does not correspond to any OMA DM response status code.
- * OMA has several status codes related to timeout, but these are meant to
- * be used when a request times out, not if a session can not be
- * established. This error code should be translated to the code 500
- * "Command Failed" when transferring over OMA DM.
- */
- public static final int SESSION_CREATION_TIMEOUT = 7;
-
- // ----- Content fields -----//
-
- /**
- * The URI of the node on which the failed DMT operation was issued, or
- * <code>null</code> if the operation was not associated with a node.
- */
- private final String uri;
-
- /**
- * The error code of the failure, one of the constants defined in this
- * class.
- */
- private final int code;
-
- /**
- * The message associated with the exception, or <code>null</code> if there
- * is no error message.
- */
- private final String message;
-
- /**
- * The list of originating exceptions, or empty list or <code>null</code> if
- * there are no originating exceptions.
- */
- private final Throwable[] causes;
-
- /**
- * Determines whether the exception is fatal or not. This is basically a
- * two-state severity indicator, with the 'fatal' severity being the more
- * serious one.
- */
- private final boolean fatal;
-
- // ----- Constructors -----//
-
- /**
- * Create an instance of the exception. The <code>uri</code> and
- * <code>message</code> parameters are optional. No originating exception
- * is specified.
- *
- * @param uri the node on which the failed DMT operation was issued, or
- * <code>null</code> if the operation is not associated with a node
- * @param code the error code of the failure
- * @param message the message associated with the exception, or
- * <code>null</code> if there is no error message
- */
- public DmtException(String uri, int code, String message) {
- this(uri, code, message, new Throwable[0], false);
- }
-
- /**
- * Create an instance of the exception, specifying the cause exception. The
- * <code>uri</code>, <code>message</code> and <code>cause</code>
- * parameters are optional.
- *
- * @param uri the node on which the failed DMT operation was issued, or
- * <code>null</code> if the operation is not associated with a node
- * @param code the error code of the failure
- * @param message the message associated with the exception, or
- * <code>null</code> if there is no error message
- * @param cause the originating exception, or <code>null</code> if there
- * is no originating exception
- */
- public DmtException(String uri, int code, String message, Throwable cause) {
- this(uri, code, message, (cause == null) ? new Throwable[0]
- : new Throwable[] { cause }, false);
- }
-
- /**
- * Create an instance of the exception, specifying the list of cause
- * exceptions and whether the exception is a fatal one. This constructor is
- * meant to be used by plugins wishing to indicate that a serious error
- * occurred which should invalidate the ongoing atomic session. The
- * <code>uri</code>, <code>message</code> and <code>causes</code>
- * parameters are optional.
- * <p>
- * If a fatal exception is thrown, no further business methods will be
- * called on the originator plugin. In case of atomic sessions, all other
- * open plugins will be rolled back automatically, except if the fatal
- * exception was thrown during commit.
- *
- * @param uri the node on which the failed DMT operation was issued, or
- * <code>null</code> if the operation is not associated with a node
- * @param code the error code of the failure
- * @param message the message associated with the exception, or
- * <code>null</code> if there is no error message
- * @param causes the list of originating exceptions, or empty list or
- * <code>null</code> if there are no originating exceptions
- * @param fatal whether the exception is fatal
- */
- public DmtException(String uri, int code, String message, Vector causes,
- boolean fatal) {
- this(uri, code, message, (causes == null) ? new Throwable[0]
- : (Throwable[]) causes.toArray(new Throwable[causes.size()]),
- fatal);
- }
-
- private DmtException(String uri, int code, String message,
- Throwable[] causes, boolean fatal) {
- super((Throwable) null);
- this.uri = uri;
- this.code = code;
- this.message = message;
- this.causes = causes;
- this.fatal = fatal;
- }
-
- /**
- * Create an instance of the exception, specifying the target node as an
- * array of path segments. This method behaves in exactly the same way as if
- * the path was given as a URI string.
- *
- * @param path the path of the node on which the failed DMT operation was
- * issued, or <code>null</code> if the operation is not associated
- * with a node
- * @param code the error code of the failure
- * @param message the message associated with the exception, or
- * <code>null</code> if there is no error message
- * @see #DmtException(String, int, String)
- */
- public DmtException(String[] path, int code, String message) {
- this(pathToUri(path), code, message);
- }
-
- /**
- * Create an instance of the exception, specifying the target node as an
- * array of path segments, and specifying the cause exception. This method
- * behaves in exactly the same way as if the path was given as a URI string.
- *
- * @param path the path of the node on which the failed DMT operation was
- * issued, or <code>null</code> if the operation is not associated
- * with a node
- * @param code the error code of the failure
- * @param message the message associated with the exception, or
- * <code>null</code> if there is no error message
- * @param cause the originating exception, or <code>null</code> if there
- * is no originating exception
- * @see #DmtException(String, int, String, Throwable)
- */
- public DmtException(String[] path, int code, String message, Throwable cause) {
- this(pathToUri(path), code, message, cause);
- }
-
- /**
- * Create an instance of the exception, specifying the target node as an
- * array of path segments, the list of cause exceptions, and whether the
- * exception is a fatal one. This method behaves in exactly the same way as
- * if the path was given as a URI string.
- *
- * @param path the path of the node on which the failed DMT operation was
- * issued, or <code>null</code> if the operation is not associated
- * with a node
- * @param code the error code of the failure
- * @param message the message associated with the exception, or
- * <code>null</code> if there is no error message
- * @param causes the list of originating exceptions, or empty list or
- * <code>null</code> if there are no originating exceptions
- * @param fatal whether the exception is fatal
- * @see #DmtException(String, int, String, Vector, boolean)
- */
- public DmtException(String[] path, int code, String message, Vector causes,
- boolean fatal) {
- this(pathToUri(path), code, message, causes, fatal);
- }
-
- // ----- Public methods -----//
-
- /**
- * Get the node on which the failed DMT operation was issued. Some
- * operations like <code>DmtSession.close()</code> don't require an URI,
- * in this case this method returns <code>null</code>.
- *
- * @return the URI of the node, or <code>null</code>
- */
- public String getURI() {
- return uri;
- }
-
- /**
- * Get the error code associated with this exception. Most of the error
- * codes within this exception correspond to OMA DM error codes.
- *
- * @return the error code
- */
- public int getCode() {
- return code;
- }
-
- /**
- * Get the message associated with this exception. The returned string also
- * contains the associated URI (if any) and the exception code. The
- * resulting message has the following format (parts in square brackets are
- * only included if the field inside them is not <code>null</code>):
- *
- * <pre>
- * <exception_code>[: '<uri>'][: <error_message>]
- * </pre>
- *
- * @return the error message in the format described above
- */
- public String getMessage() {
- StringBuffer sb = new StringBuffer(getCodeText(code));
- if (uri != null)
- sb.append(": '").append(uri).append('\'');
- if (message != null)
- sb.append(": ").append(message);
-
- return sb.toString();
- }
-
- /**
- * Get the cause of this exception. Returns non-<code>null</code>, if
- * this exception is caused by one or more other exceptions (like a
- * <code>NullPointerException</code> in a DmtPlugin). If there are more
- * than one cause exceptions, the first one is returned.
- *
- * @return the cause of this exception, or <code>null</code> if no cause
- * was given
- */
- public Throwable getCause() {
- return causes.length == 0 ? null : causes[0];
- }
-
- /**
- * Get all causes of this exception. Returns the causing exceptions in an
- * array. If no cause was specified, an empty array is returned.
- *
- * @return the list of causes of this exception
- */
- public Throwable[] getCauses() {
- return (Throwable[]) causes.clone();
- }
-
- /**
- * Check whether this exception is marked as fatal in the session. Fatal
- * exceptions trigger an automatic rollback of atomic sessions.
- *
- * @return whether the exception is marked as fatal
- */
- public boolean isFatal() {
- return fatal;
- }
-
- /**
- * Prints the exception and its backtrace to the specified print stream. Any
- * causes that were specified for this exception are also printed, together
- * with their backtraces.
- *
- * @param s <code>PrintStream</code> to use for output
- */
- public void printStackTrace(PrintStream s) {
- super.printStackTrace(s);
- for (int i = 0; i<causes.length; i++) {
- s.print("Caused by" + (i > 0 ? " (" + (i+1) + ")" : "") + ": ");
- causes[i].printStackTrace(s);
- }
- }
-
- // ----- Utility methods -----//
-
- /**
- * Converts the given path, given as an array of path segments, to a single
- * URI string.
- *
- * @param path the path to convert
- * @return the URI string representing the same node as the given path
- */
- static String pathToUri(String[] path) {
- if (path == null)
- return null;
-
- return Uri.toUri(path);
- }
-
- /**
- * Returns the name of the given error code.
- *
- * @param code the error code
- * @return a string containing the error code name
- */
- private static String getCodeText(int code) {
- // todo sync codes
- switch (code) {
- case NODE_NOT_FOUND:
- return "NODE_NOT_FOUND";
- case COMMAND_NOT_ALLOWED:
- return "COMMAND_NOT_ALLOWED";
- case FEATURE_NOT_SUPPORTED:
- return "FEATURE_NOT_SUPPORTED";
- case URI_TOO_LONG:
- return "URI_TOO_LONG";
- case NODE_ALREADY_EXISTS:
- return "NODE_ALREADY_EXISTS";
- case PERMISSION_DENIED:
- return "PERMISSION_DENIED";
- case COMMAND_FAILED:
- return "COMMAND_FAILED";
- case DATA_STORE_FAILURE:
- return "DATA_STORE_FAILURE";
- case ROLLBACK_FAILED:
- return "ROLLBACK_FAILED";
-
- case REMOTE_ERROR:
- return "REMOTE_ERROR";
- case METADATA_MISMATCH:
- return "METADATA_MISMATCH";
- case INVALID_URI:
- return "INVALID_URI";
- case CONCURRENT_ACCESS:
- return "CONCURRENT_ACCESS";
- case ALERT_NOT_ROUTED:
- return "ALERT_NOT_ROUTED";
- case TRANSACTION_ERROR:
- return "TRANSACTION_ERROR";
- case SESSION_CREATION_TIMEOUT:
- return "SESSION_CREATION_TIMEOUT";
- default:
- return "<unknown code>";
- }
- }
-}
diff --git a/org.osgi.compendium/src/main/java/info/dmtree/DmtIllegalStateException.java b/org.osgi.compendium/src/main/java/info/dmtree/DmtIllegalStateException.java
deleted file mode 100644
index 127c754..0000000
--- a/org.osgi.compendium/src/main/java/info/dmtree/DmtIllegalStateException.java
+++ /dev/null
@@ -1,90 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2006, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package info.dmtree;
-
-/**
- * Unchecked illegal state exception. This class is used in DMT because
- * java.lang.IllegalStateException does not exist in CLDC.
- *
- * @version $Revision: 6083 $
- */
-public class DmtIllegalStateException extends RuntimeException {
- private static final long serialVersionUID = 2015244852018469700L;
-
- /**
- * Create an instance of the exception with no message.
- */
- public DmtIllegalStateException() {
- super();
- }
-
- /**
- * Create an instance of the exception with the specified message.
- *
- * @param message the reason for the exception
- */
- public DmtIllegalStateException(String message) {
- super(message);
- }
-
- /**
- * Create an instance of the exception with the specified cause exception
- * and no message.
- *
- * @param cause the cause of the exception
- */
- public DmtIllegalStateException(Throwable cause) {
- super(cause);
- }
-
- /**
- * Create an instance of the exception with the specified message and cause
- * exception.
- *
- * @param message the reason for the exception
- * @param cause the cause of the exception
- */
- public DmtIllegalStateException(String message, Throwable cause) {
- super(message, cause);
- }
-
- /**
- * Returns the cause of this exception or <code>null</code> if no cause was
- * set.
- *
- * @return The cause of this exception or <code>null</code> if no cause was
- * set.
- */
- public Throwable getCause() {
- return super.getCause();
- }
-
- /**
- * Initializes the cause of this exception to the specified value.
- *
- * @param cause The cause of this exception.
- * @return This exception.
- * @throws IllegalArgumentException If the specified cause is this
- * exception.
- * @throws IllegalStateException If the cause of this exception has already
- * been set.
- * @since 1.0.1
- */
- public Throwable initCause(Throwable cause) {
- return super.initCause(cause);
- }
-}
diff --git a/org.osgi.compendium/src/main/java/info/dmtree/DmtSession.java b/org.osgi.compendium/src/main/java/info/dmtree/DmtSession.java
deleted file mode 100644
index fd8d692..0000000
--- a/org.osgi.compendium/src/main/java/info/dmtree/DmtSession.java
+++ /dev/null
@@ -1,1599 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2004, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package info.dmtree;
-
-import java.util.Date;
-
-/**
- * DmtSession provides concurrent access to the DMT. All DMT manipulation
- * commands for management applications are available on the
- * <code>DmtSession</code> interface. The session is associated with a root node
- * which limits the subtree in which the operations can be executed within this
- * session.
- * <p>
- * Most of the operations take a node URI as parameter, which can be either an
- * absolute URI (starting with "./") or a URI relative to the root
- * node of the session. The empty string as relative URI means the root URI the
- * session was opened with. All segments of a URI must be within the segment
- * length limit of the implementation, and the special characters '/' and '\'
- * must be escaped (preceded by a '\'). Any string can be converted to a valid
- * URI segment using the {@link Uri#mangle(String)} method.
- * <p>
- * If the URI specified does not correspond to a legitimate node in the tree an
- * exception is thrown. The only exception is the {@link #isNodeUri(String)}
- * method which returns <code>false</code> in case of an invalid URI.
- * <p>
- * Each method of <code>DmtSession</code> that accesses the tree in any way can
- * throw <code>DmtIllegalStateException</code> if the session has been closed or
- * invalidated (due to timeout, fatal exceptions, or unexpectedly unregistered
- * plugins).
- *
- * @version $Revision: 5673 $
- */
-public interface DmtSession {
- /**
- * Sessions created with <code>LOCK_TYPE_SHARED</code> lock allows
- * read-only access to the tree, but can be shared between multiple readers.
- */
- int LOCK_TYPE_SHARED = 0;
-
- /**
- * <code>LOCK_TYPE_EXCLUSIVE</code> lock guarantees full access to the
- * tree, but can not be shared with any other locks.
- */
- int LOCK_TYPE_EXCLUSIVE = 1;
-
- /**
- * <code>LOCK_TYPE_ATOMIC</code> is an exclusive lock with transactional
- * functionality. Commands of an atomic session will either fail or succeed
- * together, if a single command fails then the whole session will be rolled
- * back.
- */
- int LOCK_TYPE_ATOMIC = 2;
-
- /**
- * The session is open, all session operations are available.
- */
- int STATE_OPEN = 0;
-
- /**
- * The session is closed, DMT manipulation operations are not available,
- * they throw <code>DmtIllegalStateException</code> if tried.
- */
- int STATE_CLOSED = 1;
-
- /**
- * The session is invalid because a fatal error happened. Fatal errors
- * include the timeout of the session, any DmtException with the 'fatal'
- * flag set, or the case when a plugin service is unregistered while in use
- * by the session. DMT manipulation operations are not available, they throw
- * <code>DmtIllegalStateException</code> if tried.
- */
- int STATE_INVALID = 2;
-
- /**
- * Get the current state of this session.
- *
- * @return the state of the session, one of {@link #STATE_OPEN},
- * {@link #STATE_CLOSED} and {@link #STATE_INVALID}
- */
- int getState();
-
- /**
- * Gives the type of lock the session has.
- *
- * @return the lock type of the session, one of {@link #LOCK_TYPE_SHARED},
- * {@link #LOCK_TYPE_EXCLUSIVE} and {@link #LOCK_TYPE_ATOMIC}
- */
- int getLockType();
-
- /**
- * Gives the name of the principal on whose behalf the session was created.
- * Local sessions do not have an associated principal, in this case
- * <code>null</code> is returned.
- *
- * @return the identifier of the remote server that initiated the session,
- * or <code>null</code> for local sessions
- */
- String getPrincipal();
-
- /**
- * The unique identifier of the session. The ID is generated automatically,
- * and it is guaranteed to be unique on a machine.
- *
- * @return the session identification number
- */
- int getSessionId();
-
- /**
- * Get the root URI associated with this session. Gives "<code>.</code>"
- * if the session was created without specifying a root, which means that
- * the target of this session is the whole DMT.
- *
- * @return the root URI
- */
- String getRootUri();
-
- /**
- * Commits a series of DMT operations issued in the current atomic session
- * since the last transaction boundary. Transaction boundaries are the
- * creation of this object that starts the session, and all subsequent
- * {@link #commit} and {@link #rollback} calls.
- * <p>
- * This method can fail even if all operations were successful. This can
- * happen due to some multi-node semantic constraints defined by a specific
- * implementation. For example, node A can be required to always have
- * children A/B, A/C and A/D. If this condition is broken when
- * <code>commit()</code> is executed, the method will fail, and throw a
- * <code>METADATA_MISMATCH</code> exception.
- * <p>
- * An error situation can arise due to the lack of a two phase commit
- * mechanism in the underlying plugins. As an example, if plugin A has
- * committed successfully but plugin B failed, the whole session must fail,
- * but there is no way to undo the commit performed by A. To provide
- * predictable behaviour, the commit operation should continue with the
- * remaining plugins even after detecting a failure. All exceptions received
- * from failed commits are aggregated into one
- * <code>TRANSACTION_ERROR</code> exception thrown by this method.
- * <p>
- * In many cases the tree is not the only way to manage a given part of the
- * system. It may happen that while modifying some nodes in an atomic
- * session, the underlying settings are modified in parallel outside the
- * scope of the DMT. If this is detected during commit, an exception with
- * the code <code>CONCURRENT_ACCESS</code> is thrown.
- *
- * @throws DmtException with the following possible error codes:
- * <ul>
- * <li><code>METADATA_MISMATCH</code> if the operation failed
- * because of meta-data restrictions
- * <li><code>CONCURRENT_ACCESS</code> if it is detected that some
- * modification has been made outside the scope of the DMT to the
- * nodes affected in the session's operations
- * <li><code>TRANSACTION_ERROR</code> if an error occurred during
- * the commit of any of the underlying plugins
- * <li><code>DATA_STORE_FAILURE</code> if an error occurred while
- * accessing the data store
- * <li><code>COMMAND_FAILED</code> if some unspecified error is
- * encountered while attempting to complete the command
- * </ul>
- * @throws DmtIllegalStateException if the session was not opened using the
- * <code>LOCK_TYPE_ATOMIC</code> lock type, or if the session is
- * already closed or invalidated
- * @throws SecurityException if the caller does not have the necessary
- * permissions to execute the underlying management operation
- */
- void commit() throws DmtException;
-
- /**
- * Rolls back a series of DMT operations issued in the current atomic
- * session since the last transaction boundary. Transaction boundaries are
- * the creation of this object that starts the session, and all subsequent
- * {@link #commit} and {@link #rollback} calls.
- *
- * @throws DmtException with the error code <code>ROLLBACK_FAILED</code>
- * in case the rollback did not succeed
- * @throws DmtIllegalStateException if the session was not opened using the
- * <code>LOCK_TYPE_ATOMIC</code> lock type, or if the session is
- * already closed or invalidated
- * @throws SecurityException if the caller does not have the necessary
- * permissions to execute the underlying management operation
- */
- void rollback() throws DmtException;
-
- /**
- * Closes a session. If the session was opened with atomic lock mode, the
- * <code>DmtSession</code> must first persist the changes made to the DMT
- * by calling <code>commit()</code> on all (transactional) plugins
- * participating in the session. See the documentation of the
- * {@link #commit} method for details and possible errors during this
- * operation.
- * <p>
- * The state of the session changes to <code>DmtSession.STATE_CLOSED</code>
- * if the close operation completed successfully, otherwise it becomes
- * <code>DmtSession.STATE_INVALID</code>.
- *
- * @throws DmtException with the following possible error codes:
- * <ul>
- * <li><code>METADATA_MISMATCH</code> in case of atomic sessions,
- * if the commit operation failed because of meta-data restrictions
- * <li><code>CONCURRENT_ACCESS</code> in case of atomic sessions,
- * if the commit operation failed because of some modification
- * outside the scope of the DMT to the nodes affected in the session
- * <li><code>TRANSACTION_ERROR</code> in case of atomic sessions,
- * if an underlying plugin failed to commit
- * <li><code>DATA_STORE_FAILURE</code> if an error occurred while
- * accessing the data store
- * <li><code>COMMAND_FAILED</code> if an underlying plugin failed
- * to close, or if some unspecified error is encountered while
- * attempting to complete the command
- * </ul>
- * @throws DmtIllegalStateException if the session is already closed or
- * invalidated
- * @throws SecurityException if the caller does not have the necessary
- * permissions to execute the underlying management operation
- */
- void close() throws DmtException;
-
- /**
- * Executes a node. This corresponds to the EXEC operation in OMA DM. This
- * method cannot be called in a read-only session.
- * <p>
- * The semantics of an execute operation and the data parameter it takes
- * depends on the definition of the managed object on which the command is
- * issued.
- *
- * @param nodeUri the node on which the execute operation is issued
- * @param data the parameter of the execute operation, can be
- * <code>null</code>
- * @throws DmtException with the following possible error codes:
- * <ul>
- * <li><code>URI_TOO_LONG</code> if <code>nodeUri</code> or a
- * segment of it is too long, or if it has too many segments
- * <li><code>INVALID_URI</code> if <code>nodeUri</code> is
- * <code>null</code> or syntactically invalid
- * <li><code>NODE_NOT_FOUND</code> if the node does not exist and
- * the plugin does not allow executing unexisting nodes
- * <li><code>PERMISSION_DENIED</code> if the session is
- * associated with a principal and the ACL of the node does not
- * allow the <code>Execute</code> operation for the associated
- * principal
- * <li><code>METADATA_MISMATCH</code> if the node cannot be
- * executed according to the meta-data (does not have
- * <code>MetaNode.CMD_EXECUTE</code> access type)
- * <li><code>DATA_STORE_FAILURE</code> if an error occurred while
- * accessing the data store
- * <li><code>COMMAND_FAILED</code> if the URI is not within the
- * current session's subtree, if no DmtExecPlugin is associated with
- * the node and the DmtAdmin can not execute the node, or if some
- * unspecified error is encountered while attempting to complete the
- * command
- * </ul>
- * @throws DmtIllegalStateException if the session was opened using the
- * <code>LOCK_TYPE_SHARED</code> lock type, or if the session is
- * already closed or invalidated
- * @throws SecurityException if the caller does not have the necessary
- * permissions to execute the underlying management operation, or,
- * in case of local sessions, if the caller does not have
- * <code>DmtPermission</code> for the node with the Exec action
- * present
- *
- * @see #execute(String, String, String)
- */
- void execute(String nodeUri, String data) throws DmtException;
-
- /**
- * Executes a node, also specifying a correlation ID for use in response
- * notifications. This operation corresponds to the EXEC command in OMA DM.
- * This method cannot be called in a read-only session.
- * <p>
- * The semantics of an execute operation and the data parameter it takes
- * depends on the definition of the managed object on which the command is
- * issued. If a correlation ID is specified, it should be used as the
- * <code>correlator</code> parameter for notifications sent in response to this
- * execute operation.
- *
- * @param nodeUri the node on which the execute operation is issued
- * @param correlator an identifier to associate this operation with any
- * notifications sent in response to it, can be <code>null</code> if not
- * needed
- * @param data the parameter of the execute operation, can be
- * <code>null</code>
- * @throws DmtException with the following possible error codes:
- * <ul>
- * <li><code>URI_TOO_LONG</code> if <code>nodeUri</code> or a
- * segment of it is too long, or if it has too many segments
- * <li><code>INVALID_URI</code> if <code>nodeUri</code> is
- * <code>null</code> or syntactically invalid
- * <li><code>NODE_NOT_FOUND</code> if the node does not exist and
- * the plugin does not allow executing unexisting nodes
- * <li><code>PERMISSION_DENIED</code> if the session is
- * associated with a principal and the ACL of the node does not
- * allow the <code>Execute</code> operation for the associated
- * principal
- * <li><code>METADATA_MISMATCH</code> if the node cannot be
- * executed according to the meta-data (does not have
- * <code>MetaNode.CMD_EXECUTE</code> access type)
- * <li><code>DATA_STORE_FAILURE</code> if an error occurred while
- * accessing the data store
- * <li><code>COMMAND_FAILED</code> if the URI is not within the
- * current session's subtree, if no DmtExecPlugin is associated with
- * the node, or if some unspecified error is encountered while
- * attempting to complete the command
- * </ul>
- * @throws DmtIllegalStateException if the session was opened using the
- * <code>LOCK_TYPE_SHARED</code> lock type, or if the session is
- * already closed or invalidated
- * @throws SecurityException if the caller does not have the necessary
- * permissions to execute the underlying management operation, or,
- * in case of local sessions, if the caller does not have
- * <code>DmtPermission</code> for the node with the Exec action
- * present
- * @see #execute(String, String)
- */
- void execute(String nodeUri, String correlator, String data)
- throws DmtException;
-
- /**
- * Get the Access Control List associated with a given node. The returned
- * <code>Acl</code> object does not take inheritance into account, it
- * gives the ACL specifically given to the node.
- *
- * @param nodeUri the URI of the node
- * @return the Access Control List belonging to the node or
- * <code>null</code> if none defined
- * @throws DmtException with the following possible error codes:
- * <ul>
- * <li><code>URI_TOO_LONG</code> if <code>nodeUri</code> or a
- * segment of it is too long, or if it has too many segments
- * <li><code>INVALID_URI</code> if <code>nodeUri</code> is
- * <code>null</code> or syntactically invalid
- * <li><code>NODE_NOT_FOUND</code> if <code>nodeUri</code>
- * points to a non-existing node
- * <li><code>PERMISSION_DENIED</code> if the session is
- * associated with a principal and the ACL of the node does not
- * allow the <code>Get</code> operation for the associated
- * principal
- * <li><code>METADATA_MISMATCH</code> if node information cannot
- * be retrieved according to the meta-data (the node does not have
- * <code>MetaNode.CMD_GET</code> access type)
- * <li><code>DATA_STORE_FAILURE</code> if an error occurred while
- * accessing the data store
- * <li><code>COMMAND_FAILED</code> if the URI is not within the
- * current session's subtree, or if some unspecified error is
- * encountered while attempting to complete the command
- * </ul>
- * @throws DmtIllegalStateException if the session is already closed or
- * invalidated
- * @throws SecurityException in case of local sessions, if the caller does
- * not have <code>DmtPermission</code> for the node with the Get
- * action present
- * @see #getEffectiveNodeAcl
- */
- Acl getNodeAcl(String nodeUri) throws DmtException;
-
- /**
- * Gives the Access Control List in effect for a given node. The returned
- * <code>Acl</code> takes inheritance into account, that is if there is no
- * ACL defined for the node, it will be derived from the closest ancestor
- * having an ACL defined.
- *
- * @param nodeUri the URI of the node
- * @return the Access Control List belonging to the node
- * @throws DmtException with the following possible error codes:
- * <ul>
- * <li><code>URI_TOO_LONG</code> if <code>nodeUri</code> or a
- * segment of it is too long, or if it has too many segments
- * <li><code>INVALID_URI</code> if <code>nodeUri</code> is
- * <code>null</code> or syntactically invalid
- * <li><code>NODE_NOT_FOUND</code> if <code>nodeUri</code>
- * points to a non-existing node
- * <li><code>PERMISSION_DENIED</code> if the session is
- * associated with a principal and the ACL of the node does not
- * allow the <code>Get</code> operation for the associated
- * principal
- * <li><code>METADATA_MISMATCH</code> if node information cannot
- * be retrieved according to the meta-data (the node does not have
- * <code>MetaNode.CMD_GET</code> access type)
- * <li><code>DATA_STORE_FAILURE</code> if an error occurred while
- * accessing the data store
- * <li><code>COMMAND_FAILED</code> if the URI is not within the
- * current session's subtree, or if some unspecified error is
- * encountered while attempting to complete the command
- * </ul>
- * @throws DmtIllegalStateException if the session is already closed or
- * invalidated
- * @throws SecurityException in case of local sessions, if the caller does
- * not have <code>DmtPermission</code> for the node with the Get
- * action present
- * @see #getNodeAcl
- */
- Acl getEffectiveNodeAcl(String nodeUri) throws DmtException;
-
- /**
- * Set the Access Control List associated with a given node. To perform this
- * operation, the caller needs to have replace rights (<code>Acl.REPLACE</code>
- * or the corresponding Java permission depending on the session type) as
- * described below:
- * <ul>
- * <li>if <code>nodeUri</code> specifies a leaf node, replace rights are
- * needed on the parent of the node
- * <li>if <code>nodeUri</code> specifies an interior node, replace rights
- * on either the node or its parent are sufficient
- * </ul>
- * <p>
- * If the given <code>acl</code> is <code>null</code> or an empty ACL
- * (not specifying any permissions for any principals), then the ACL of the
- * node is deleted, and the node will inherit the ACL from its parent node.
- *
- * @param nodeUri the URI of the node
- * @param acl the Access Control List to be set on the node, can be
- * <code>null</code>
- * @throws DmtException with the following possible error codes:
- * <ul>
- * <li><code>URI_TOO_LONG</code> if <code>nodeUri</code> or a
- * segment of it is too long, or if it has too many segments
- * <li><code>INVALID_URI</code> if <code>nodeUri</code> is
- * <code>null</code> or syntactically invalid
- * <li><code>NODE_NOT_FOUND</code> if <code>nodeUri</code>
- * points to a non-existing node
- * <li><code>PERMISSION_DENIED</code> if the session is
- * associated with a principal and the ACL of the node or its parent
- * (see above) does not allow the <code>Replace</code> operation
- * for the associated principal
- * <li><code>COMMAND_NOT_ALLOWED</code> if the command attempts
- * to set the ACL of the root node not to include Add rights for all
- * principals
- * <li><code>DATA_STORE_FAILURE</code> if an error occurred while
- * accessing the data store
- * <li><code>COMMAND_FAILED</code> if the URI is not within the
- * current session's subtree, or if some unspecified error is
- * encountered while attempting to complete the command
- * </ul>
- * @throws DmtIllegalStateException if the session was opened using the
- * <code>LOCK_TYPE_SHARED</code> lock type, or if the session is
- * already closed or invalidated
- * @throws SecurityException in case of local sessions, if the caller does
- * not have <code>DmtPermission</code> for the node or its parent
- * (see above) with the Replace action present
- */
- void setNodeAcl(String nodeUri, Acl acl) throws DmtException;
-
- /**
- * Create a copy of a node or a whole subtree. Beside the structure and
- * values of the nodes, most properties are also copied, with the exception
- * of the ACL (Access Control List), Timestamp and Version properties.
- * <p>
- * The copy method is essentially a convenience method that could be
- * substituted with a sequence of retrieval and update operations. This
- * determines the permissions required for copying. However, some
- * optimization can be possible if the source and target nodes are all
- * handled by DmtAdmin or by the same plugin. In this case, the handler
- * might be able to perform the underlying management operation more
- * efficiently: for example, a configuration table can be copied at once
- * instead of reading each node for each entry and creating it in the new
- * tree.
- * <p>
- * This method may result in any of the errors possible for the contributing
- * operations. Most of these are collected in the exception descriptions
- * below, but for the full list also consult the documentation of
- * {@link #getChildNodeNames(String)}, {@link #isLeafNode(String)},
- * {@link #getNodeValue(String)}, {@link #getNodeType(String)},
- * {@link #getNodeTitle(String)}, {@link #setNodeTitle(String, String)},
- * {@link #createLeafNode(String, DmtData, String)} and
- * {@link #createInteriorNode(String, String)}.
- *
- * @param nodeUri the node or root of a subtree to be copied
- * @param newNodeUri the URI of the new node or root of a subtree
- * @param recursive <code>false</code> if only a single node is copied,
- * <code>true</code> if the whole subtree is copied
- * @throws DmtException with the following possible error codes:
- * <ul>
- * <li><code>URI_TOO_LONG</code> if <code>nodeUri</code> or
- * <code>newNodeUri</code> or any segment of them is too long, or
- * if they have too many segments
- * <li><code>INVALID_URI</code> if <code>nodeUri</code> or
- * <code>newNodeUri</code> is <code>null</code> or syntactically
- * invalid
- * <li><code>NODE_NOT_FOUND</code> if <code>nodeUri</code>
- * points to a non-existing node, or if <code>newNodeUri</code>
- * points to a node that cannot exist in the tree according to the
- * meta-data (see {@link #getMetaNode(String)})
- * <li><code>NODE_ALREADY_EXISTS</code> if
- * <code>newNodeUri</code> points to a node that already exists
- * <li><code>PERMISSION_DENIED</code> if the session is
- * associated with a principal and the ACL of the copied node(s)
- * does not allow the <code>Get</code> operation, or the ACL of
- * the parent of the target node does not allow the <code>Add</code>
- * operation for the associated principal
- * <li><code>COMMAND_NOT_ALLOWED</code> if <code>nodeUri</code>
- * is an ancestor of <code>newNodeUri</code>, or if any of the
- * implied retrieval or update operations are not allowed
- * <li><code>METADATA_MISMATCH</code> if any of the meta-data
- * constraints of the implied retrieval or update operations are
- * violated
- * <li><code>TRANSACTION_ERROR</code> in an atomic session if the
- * underlying plugin is read-only or does not support atomic writing
- * <li><code>DATA_STORE_FAILURE</code> if an error occurred while
- * accessing the data store
- * <li><code>COMMAND_FAILED</code> if either URI is not within
- * the current session's subtree, or if some unspecified error is
- * encountered while attempting to complete the command
- * </ul>
- * @throws DmtIllegalStateException if the session was opened using the
- * <code>LOCK_TYPE_SHARED</code> lock type, or if the session is
- * already closed or invalidated
- * @throws SecurityException if the caller does not have the necessary
- * permissions to execute the underlying management operation, or,
- * in case of local sessions, if the caller does not have
- * <code>DmtPermission</code> for the copied node(s) with the Get
- * action present, or for the parent of the target node with the Add
- * action
- */
- void copy(String nodeUri, String newNodeUri, boolean recursive)
- throws DmtException;
-
- /**
- * Create an interior node. If the parent node does not exist, it is created
- * automatically, as if this method were called for the parent URI. This way
- * all missing ancestor nodes leading to the specified node are created. Any
- * exceptions encountered while creating the ancestors are propagated to the
- * caller of this method, these are not explicitly listed in the error
- * descriptions below.
- * <p>
- * If meta-data is available for the node, several checks are made before
- * creating it. The node must have <code>MetaNode.CMD_ADD</code> access
- * type, it must be defined as a non-permanent interior node, the node name
- * must conform to the valid names, and the creation of the new node must
- * not cause the maximum occurrence number to be exceeded.
- * <p>
- * If the meta-data cannot be retrieved because the given node cannot
- * possibly exist in the tree (it is not defined in the specification), the
- * <code>NODE_NOT_FOUND</code> error code is returned (see
- * {@link #getMetaNode(String)}).
- *
- * @param nodeUri the URI of the node to create
- * @throws DmtException with the following possible error codes:
- * <ul>
- * <li><code>URI_TOO_LONG</code> if <code>nodeUri</code> or a
- * segment of it is too long, or if it has too many segments
- * <li><code>INVALID_URI</code> if <code>nodeUri</code> is
- * <code>null</code> or syntactically invalid
- * <li><code>NODE_NOT_FOUND</code> if <code>nodeUri</code>
- * points to a node that cannot exist in the tree (see above)
- * <li><code>NODE_ALREADY_EXISTS</code> if <code>nodeUri</code>
- * points to a node that already exists
- * <li><code>PERMISSION_DENIED</code> if the session is
- * associated with a principal and the ACL of the parent node does
- * not allow the <code>Add</code> operation for the associated
- * principal
- * <li><code>COMMAND_NOT_ALLOWED</code> if the parent node is not
- * an interior node, or in non-atomic sessions if the underlying
- * plugin is read-only or does not support non-atomic writing
- * <li><code>METADATA_MISMATCH</code> if the node could not be
- * created because of meta-data restrictions (see above)
- * <li><code>TRANSACTION_ERROR</code> in an atomic session if the
- * underlying plugin is read-only or does not support atomic writing
- * <li><code>DATA_STORE_FAILURE</code> if an error occurred while
- * accessing the data store
- * <li><code>COMMAND_FAILED</code> if the URI is not within the
- * current session's subtree, or if some unspecified error is
- * encountered while attempting to complete the command
- * </ul>
- * @throws DmtIllegalStateException if the session was opened using the
- * <code>LOCK_TYPE_SHARED</code> lock type, or if the session is
- * already closed or invalidated
- * @throws SecurityException if the caller does not have the necessary
- * permissions to execute the underlying management operation, or,
- * in case of local sessions, if the caller does not have
- * <code>DmtPermission</code> for the parent node with the Add
- * action present
- */
- void createInteriorNode(String nodeUri) throws DmtException;
-
- /**
- * Create an interior node with a given type. The type of interior node, if
- * specified, is a URI identifying a DDF document. If the parent node does
- * not exist, it is created automatically, as if
- * {@link #createInteriorNode(String)} were called for the parent URI. This
- * way all missing ancestor nodes leading to the specified node are created.
- * Any exceptions encountered while creating the ancestors are propagated to
- * the caller of this method, these are not explicitly listed in the error
- * descriptions below.
- * <p>
- * If meta-data is available for the node, several checks are made before
- * creating it. The node must have <code>MetaNode.CMD_ADD</code> access
- * type, it must be defined as a non-permanent interior node, the node name
- * must conform to the valid names, and the creation of the new node must
- * not cause the maximum occurrence number to be exceeded.
- * <p>
- * If the meta-data cannot be retrieved because the given node cannot
- * possibly exist in the tree (it is not defined in the specification), the
- * <code>NODE_NOT_FOUND</code> error code is returned (see
- * {@link #getMetaNode(String)}).
- * <p>
- * Interior node type identifiers must follow the format defined in section
- * 7.7.7.2 of the OMA Device Management Tree and Description document.
- * Checking the validity of the type string does not have to be done by the
- * DmtAdmin, this can be left to the plugin handling the node (if any), to
- * avoid unnecessary double-checks.
- *
- * @param nodeUri the URI of the node to create
- * @param type the type URI of the interior node, can be <code>null</code>
- * if no node type is defined
- * @throws DmtException with the following possible error codes:
- * <ul>
- * <li><code>URI_TOO_LONG</code> if <code>nodeUri</code> or a
- * segment of it is too long, or if it has too many segments
- * <li><code>INVALID_URI</code> if <code>nodeUri</code> is
- * <code>null</code> or syntactically invalid
- * <li><code>NODE_NOT_FOUND</code> if <code>nodeUri</code>
- * points to a node that cannot exist in the tree (see above)
- * <li><code>NODE_ALREADY_EXISTS</code> if <code>nodeUri</code>
- * points to a node that already exists
- * <li><code>PERMISSION_DENIED</code> if the session is
- * associated with a principal and the ACL of the parent node does
- * not allow the <code>Add</code> operation for the associated
- * principal
- * <li><code>COMMAND_NOT_ALLOWED</code> if the parent node is not
- * an interior node, or in non-atomic sessions if the underlying
- * plugin is read-only or does not support non-atomic writing
- * <li><code>METADATA_MISMATCH</code> if the node could not be
- * created because of meta-data restrictions (see above)
- * <li><code>TRANSACTION_ERROR</code> in an atomic session if the
- * underlying plugin is read-only or does not support atomic writing
- * <li><code>DATA_STORE_FAILURE</code> if an error occurred while
- * accessing the data store
- * <li><code>COMMAND_FAILED</code> if the URI is not within the
- * current session's subtree, if the type string is invalid (see
- * above), or if some unspecified error is encountered while
- * attempting to complete the command
- * </ul>
- * @throws DmtIllegalStateException if the session was opened using the
- * <code>LOCK_TYPE_SHARED</code> lock type, or if the session is
- * already closed or invalidated
- * @throws SecurityException if the caller does not have the necessary
- * permissions to execute the underlying management operation, or,
- * in case of local sessions, if the caller does not have
- * <code>DmtPermission</code> for the parent node with the Add
- * action present
- * @see #createInteriorNode(String)
- * @see <a
- * href="http://member.openmobilealliance.org/ftp/public_documents/dm/Permanent_documents/OMA-TS-DM-TND-V1_2-20050615-C.zip">
- * OMA Device Management Tree and Description v1.2 draft</a>
- */
- void createInteriorNode(String nodeUri, String type) throws DmtException;
-
- /**
- * Create a leaf node with default value and MIME type. If a node does not
- * have a default value or MIME type, this method will throw a
- * <code>DmtException</code> with error code
- * <code>METADATA_MISMATCH</code>. Note that a node might have a default
- * value or MIME type even if there is no meta-data for the node or its
- * meta-data does not specify the default.
- * <p>
- * If the parent node does not exist, it is created automatically, as if
- * {@link #createInteriorNode(String)} were called for the parent URI. This
- * way all missing ancestor nodes leading to the specified node are created.
- * Any exceptions encountered while creating the ancestors are propagated to
- * the caller of this method, these are not explicitly listed in the error
- * descriptions below.
- * <p>
- * If meta-data is available for a node, several checks are made before
- * creating it. The node must have <code>MetaNode.CMD_ADD</code> access
- * type, it must be defined as a non-permanent leaf node, the node name must
- * conform to the valid names, and the creation of the new node must not
- * cause the maximum occurrence number to be exceeded.
- * <p>
- * If the meta-data cannot be retrieved because the given node cannot
- * possibly exist in the tree (it is not defined in the specification), the
- * <code>NODE_NOT_FOUND</code> error code is returned (see
- * {@link #getMetaNode(String)}).
- *
- * @param nodeUri the URI of the node to create
- * @throws DmtException with the following possible error codes:
- * <ul>
- * <li><code>URI_TOO_LONG</code> if <code>nodeUri</code> or a
- * segment of it is too long, or if it has too many segments
- * <li><code>INVALID_URI</code> if <code>nodeUri</code> is
- * <code>null</code> or syntactically invalid
- * <li><code>NODE_NOT_FOUND</code> if <code>nodeUri</code>
- * points to a node that cannot exist in the tree (see above)
- * <li><code>NODE_ALREADY_EXISTS</code> if <code>nodeUri</code>
- * points to a node that already exists
- * <li><code>PERMISSION_DENIED</code> if the session is
- * associated with a principal and the ACL of the parent node does
- * not allow the <code>Add</code> operation for the associated
- * principal
- * <li><code>COMMAND_NOT_ALLOWED</code> if the parent node is not
- * an interior node, or in non-atomic sessions if the underlying
- * plugin is read-only or does not support non-atomic writing
- * <li><code>METADATA_MISMATCH</code> if the node could not be
- * created because of meta-data restrictions (see above)
- * <li><code>TRANSACTION_ERROR</code> in an atomic session if the
- * underlying plugin is read-only or does not support atomic writing
- * <li><code>DATA_STORE_FAILURE</code> if an error occurred while
- * accessing the data store
- * <li><code>COMMAND_FAILED</code> if the URI is not within the
- * current session's subtree, or if some unspecified error is
- * encountered while attempting to complete the command
- * </ul>
- * @throws DmtIllegalStateException if the session was opened using the
- * <code>LOCK_TYPE_SHARED</code> lock type, or if the session is
- * already closed or invalidated
- * @throws SecurityException if the caller does not have the necessary
- * permissions to execute the underlying management operation, or,
- * in case of local sessions, if the caller does not have
- * <code>DmtPermission</code> for the parent node with the Add
- * action present
- * @see #createLeafNode(String, DmtData)
- */
- void createLeafNode(String nodeUri) throws DmtException;
-
- /**
- * Create a leaf node with a given value and the default MIME type. If the
- * specified value is <code>null</code>, the default value is taken. If
- * the node does not have a default MIME type or value (if needed), this
- * method will throw a <code>DmtException</code> with error code
- * <code>METADATA_MISMATCH</code>. Note that a node might have a default
- * value or MIME type even if there is no meta-data for the node or its
- * meta-data does not specify the default.
- * <p>
- * If the parent node does not exist, it is created automatically, as if
- * {@link #createInteriorNode(String)} were called for the parent URI. This
- * way all missing ancestor nodes leading to the specified node are created.
- * Any exceptions encountered while creating the ancestors are propagated to
- * the caller of this method, these are not explicitly listed in the error
- * descriptions below.
- * <p>
- * If meta-data is available for a node, several checks are made before
- * creating it. The node must have <code>MetaNode.CMD_ADD</code> access
- * type, it must be defined as a non-permanent leaf node, the node name must
- * conform to the valid names, the node value must conform to the value
- * constraints, and the creation of the new node must not cause the maximum
- * occurrence number to be exceeded.
- * <p>
- * If the meta-data cannot be retrieved because the given node cannot
- * possibly exist in the tree (it is not defined in the specification), the
- * <code>NODE_NOT_FOUND</code> error code is returned (see
- * {@link #getMetaNode(String)}).
- * <p>
- * Nodes of <code>null</code> format can be created by using
- * {@link DmtData#NULL_VALUE} as second argument.
- *
- * @param nodeUri the URI of the node to create
- * @param value the value to be given to the new node, can be
- * <code>null</code>
- * @throws DmtException with the following possible error codes:
- * <ul>
- * <li><code>URI_TOO_LONG</code> if <code>nodeUri</code> or a
- * segment of it is too long, or if it has too many segments
- * <li><code>INVALID_URI</code> if <code>nodeUri</code> is
- * <code>null</code> or syntactically invalid
- * <li><code>NODE_NOT_FOUND</code> if <code>nodeUri</code>
- * points to a node that cannot exist in the tree (see above)
- * <li><code>NODE_ALREADY_EXISTS</code> if <code>nodeUri</code>
- * points to a node that already exists
- * <li><code>PERMISSION_DENIED</code> if the session is
- * associated with a principal and the ACL of the parent node does
- * not allow the <code>Add</code> operation for the associated
- * principal
- * <li><code>COMMAND_NOT_ALLOWED</code> if the parent node is not
- * an interior node, or in non-atomic sessions if the underlying
- * plugin is read-only or does not support non-atomic writing
- * <li><code>METADATA_MISMATCH</code> if the node could not be
- * created because of meta-data restrictions (see above)
- * <li><code>TRANSACTION_ERROR</code> in an atomic session if the
- * underlying plugin is read-only or does not support atomic writing
- * <li><code>DATA_STORE_FAILURE</code> if an error occurred while
- * accessing the data store
- * <li><code>COMMAND_FAILED</code> if the URI is not within the
- * current session's subtree, or if some unspecified error is
- * encountered while attempting to complete the command
- * </ul>
- * @throws DmtIllegalStateException if the session was opened using the
- * <code>LOCK_TYPE_SHARED</code> lock type, or if the session is
- * already closed or invalidated
- * @throws SecurityException if the caller does not have the necessary
- * permissions to execute the underlying management operation, or,
- * in case of local sessions, if the caller does not have
- * <code>DmtPermission</code> for the parent node with the Add
- * action present
- */
- void createLeafNode(String nodeUri, DmtData value) throws DmtException;
-
- /**
- * Create a leaf node with a given value and MIME type. If the specified
- * value or MIME type is <code>null</code>, their default values are
- * taken. If the node does not have the necessary defaults, this method will
- * throw a <code>DmtException</code> with error code
- * <code>METADATA_MISMATCH</code>. Note that a node might have a default
- * value or MIME type even if there is no meta-data for the node or its
- * meta-data does not specify the default.
- * <p>
- * If the parent node does not exist, it is created automatically, as if
- * {@link #createInteriorNode(String)} were called for the parent URI. This
- * way all missing ancestor nodes leading to the specified node are created.
- * Any exceptions encountered while creating the ancestors are propagated to
- * the caller of this method, these are not explicitly listed in the error
- * descriptions below.
- * <p>
- * If meta-data is available for a node, several checks are made before
- * creating it. The node must have <code>MetaNode.CMD_ADD</code> access
- * type, it must be defined as a non-permanent leaf node, the node name must
- * conform to the valid names, the node value must conform to the value
- * constraints, the MIME type must be among the listed types, and the
- * creation of the new node must not cause the maximum occurrence number to
- * be exceeded.
- * <p>
- * If the meta-data cannot be retrieved because the given node cannot
- * possibly exist in the tree (it is not defined in the specification), the
- * <code>NODE_NOT_FOUND</code> error code is returned (see
- * {@link #getMetaNode(String)}).
- * <p>
- * Nodes of <code>null</code> format can be created by using
- * {@link DmtData#NULL_VALUE} as second argument.
- * <p>
- * The MIME type string must conform to the definition in RFC 2045. Checking
- * its validity does not have to be done by the DmtAdmin, this can be left
- * to the plugin handling the node (if any), to avoid unnecessary
- * double-checks.
- *
- * @param nodeUri the URI of the node to create
- * @param value the value to be given to the new node, can be
- * <code>null</code>
- * @param mimeType the MIME type to be given to the new node, can be
- * <code>null</code>
- * @throws DmtException with the following possible error codes:
- * <ul>
- * <li><code>URI_TOO_LONG</code> if <code>nodeUri</code> or a
- * segment of it is too long, or if it has too many segments
- * <li><code>INVALID_URI</code> if <code>nodeUri</code> is
- * <code>null</code> or syntactically invalid
- * <li><code>NODE_NOT_FOUND</code> if <code>nodeUri</code>
- * points to a node that cannot exist in the tree (see above)
- * <li><code>NODE_ALREADY_EXISTS</code> if <code>nodeUri</code>
- * points to a node that already exists
- * <li><code>PERMISSION_DENIED</code> if the session is
- * associated with a principal and the ACL of the parent node does
- * not allow the <code>Add</code> operation for the associated
- * principal
- * <li><code>COMMAND_NOT_ALLOWED</code> if the parent node is not
- * an interior node, or in non-atomic sessions if the underlying
- * plugin is read-only or does not support non-atomic writing
- * <li><code>METADATA_MISMATCH</code> if the node could not be
- * created because of meta-data restrictions (see above)
- * <li><code>TRANSACTION_ERROR</code> in an atomic session if the
- * underlying plugin is read-only or does not support atomic writing
- * <li><code>DATA_STORE_FAILURE</code> if an error occurred while
- * accessing the data store
- * <li><code>COMMAND_FAILED</code> if the URI is not within the
- * current session's subtree, if <code>mimeType</code> is not a
- * proper MIME type string (see above), or if some unspecified error
- * is encountered while attempting to complete the command
- * </ul>
- * @throws DmtIllegalStateException if the session was opened using the
- * <code>LOCK_TYPE_SHARED</code> lock type, or if the session is
- * already closed or invalidated
- * @throws SecurityException if the caller does not have the necessary
- * permissions to execute the underlying management operation, or,
- * in case of local sessions, if the caller does not have
- * <code>DmtPermission</code> for the parent node with the Add
- * action present
- * @see #createLeafNode(String, DmtData)
- * @see <a href="http://www.ietf.org/rfc/rfc2045.txt">RFC 2045</a>
- */
- void createLeafNode(String nodeUri, DmtData value, String mimeType)
- throws DmtException;
-
- /**
- * Delete the given node. Deleting interior nodes is recursive, the whole
- * subtree under the given node is deleted. It is not allowed to delete
- * the root node of the session.
- * <p>
- * If meta-data is available for a node, several checks are made before
- * deleting it. The node must be non-permanent, it must have the
- * <code>MetaNode.CMD_DELETE</code> access type, and if zero occurrences
- * of the node are not allowed, it must not be the last one.
- *
- * @param nodeUri the URI of the node
- * @throws DmtException with the following possible error codes:
- * <ul>
- * <li><code>URI_TOO_LONG</code> if <code>nodeUri</code> or a
- * segment of it is too long, or if it has too many segments
- * <li><code>INVALID_URI</code> if <code>nodeUri</code> is
- * <code>null</code> or syntactically invalid
- * <li><code>NODE_NOT_FOUND</code> if <code>nodeUri</code>
- * points to a non-existing node
- * <li><code>PERMISSION_DENIED</code> if the session is
- * associated with a principal and the ACL of the node does not
- * allow the <code>Delete</code> operation for the associated
- * principal
- * <li><code>COMMAND_NOT_ALLOWED</code> if the target node is the
- * root of the session, or in non-atomic sessions if the underlying
- * plugin is read-only or does not support non-atomic writing
- * <li><code>METADATA_MISMATCH</code> if the node could not be
- * deleted because of meta-data restrictions (see above)
- * <li><code>TRANSACTION_ERROR</code> in an atomic session if the
- * underlying plugin is read-only or does not support atomic writing
- * <li><code>DATA_STORE_FAILURE</code> if an error occurred while
- * accessing the data store
- * <li><code>COMMAND_FAILED</code> if the URI is not within the
- * current session's subtree, or if some unspecified error is
- * encountered while attempting to complete the command
- * </ul>
- * @throws DmtIllegalStateException if the session was opened using the
- * <code>LOCK_TYPE_SHARED</code> lock type, or if the session is
- * already closed or invalidated
- * @throws SecurityException if the caller does not have the necessary
- * permissions to execute the underlying management operation, or,
- * in case of local sessions, if the caller does not have
- * <code>DmtPermission</code> for the node with the Delete action
- * present
- */
- void deleteNode(String nodeUri) throws DmtException;
-
- /**
- * Rename a node. This operation only changes the name of the node (updating
- * the timestamp and version properties if they are supported), the value
- * and the other properties are not changed. The new name of the node must
- * be provided, the new URI is constructed from the base of the old URI and
- * the given name. It is not allowed to rename the root node of the session.
- * <p>
- * If available, the meta-data of the original and the new nodes are checked
- * before performing the rename operation. Neither node can be permanent,
- * their leaf/interior property must match, and the name change must not
- * violate any of the cardinality constraints. The original node must have
- * the <code>MetaNode.CMD_REPLACE</code> access type, and the name of the
- * new node must conform to the valid names.
- *
- * @param nodeUri the URI of the node to rename
- * @param newName the new name property of the node
- * @throws DmtException with the following possible error codes:
- * <ul>
- * <li><code>URI_TOO_LONG</code> if <code>nodeUri</code> or a
- * segment of it is too long, if <code>nodeUri</code> has too many
- * segments, or if <code>newName</code> is too long
- * <li><code>INVALID_URI</code> if <code>nodeUri</code> or
- * <code>newName</code> is <code>null</code> or syntactically
- * invalid
- * <li><code>NODE_NOT_FOUND</code> if <code>nodeUri</code>
- * points to a non-existing node, or if the new node is not defined
- * in the tree according to the meta-data (see
- * {@link #getMetaNode(String)})
- * <li><code>NODE_ALREADY_EXISTS</code> if there already exists a
- * sibling of <code>nodeUri</code> with the name
- * <code>newName</code>
- * <li><code>PERMISSION_DENIED</code> if the session is
- * associated with a principal and the ACL of the node does not
- * allow the <code>Replace</code> operation for the associated
- * principal
- * <li><code>COMMAND_NOT_ALLOWED</code> if the target node is the
- * root of the session, or in non-atomic sessions if the underlying
- * plugin is read-only or does not support non-atomic writing
- * <li><code>METADATA_MISMATCH</code> if the node could not be
- * renamed because of meta-data restrictions (see above)
- * <li><code>TRANSACTION_ERROR</code> in an atomic session if the
- * underlying plugin is read-only or does not support atomic writing
- * <li><code>DATA_STORE_FAILURE</code> if an error occurred while
- * accessing the data store
- * <li><code>COMMAND_FAILED</code> if the URI is not within the
- * current session's subtree, or if some unspecified error is
- * encountered while attempting to complete the command
- * </ul>
- * @throws DmtIllegalStateException if the session was opened using the
- * <code>LOCK_TYPE_SHARED</code> lock type, or if the session is
- * already closed or invalidated
- * @throws SecurityException if the caller does not have the necessary
- * permissions to execute the underlying management operation, or,
- * in case of local sessions, if the caller does not have
- * <code>DmtPermission</code> for the node with the Replace action
- * present
- */
- void renameNode(String nodeUri, String newName) throws DmtException;
-
- /**
- * Set the value of a leaf or interior node to its default. The default
- * can be defined by the node's <code>MetaNode</code>. The method throws a
- * <code>METADATA_MISMATCH</code> exception if the node does not have a
- * default value.
- *
- * @param nodeUri the URI of the node
- * @throws DmtException with the following possible error codes:
- * <ul>
- * <li><code>URI_TOO_LONG</code> if <code>nodeUri</code> or a
- * segment of it is too long, or if it has too many segments
- * <li><code>INVALID_URI</code> if <code>nodeUri</code> is
- * <code>null</code> or syntactically invalid
- * <li><code>NODE_NOT_FOUND</code> if <code>nodeUri</code>
- * points to a non-existing node
- * <li><code>PERMISSION_DENIED</code> if the session is
- * associated with a principal and the ACL of the node does not
- * allow the <code>Replace</code> operation for the associated
- * principal
- * <li><code>COMMAND_NOT_ALLOWED</code> in non-atomic sessions if
- * the underlying plugin is read-only or does not support non-atomic
- * writing
- * <li><code>METADATA_MISMATCH</code> if the node is permanent or
- * cannot be modified according to the meta-data (does not have the
- * <code>MetaNode.CMD_REPLACE</code> access type), or if there is
- * no default value defined for this node
- * <li><code>FEATURE_NOT_SUPPORTED</code> if the specified node is
- * an interior node and does not support Java object values
- * <li><code>TRANSACTION_ERROR</code> in an atomic session if the
- * underlying plugin is read-only or does not support atomic writing
- * <li><code>DATA_STORE_FAILURE</code> if an error occurred while
- * accessing the data store
- * <li><code>COMMAND_FAILED</code> if the URI is not within the
- * current session's subtree, or if some unspecified error is
- * encountered while attempting to complete the command
- * </ul>
- * @throws DmtIllegalStateException if the session was opened using the
- * <code>LOCK_TYPE_SHARED</code> lock type, or if the session is
- * already closed or invalidated
- * @throws SecurityException if the caller does not have the necessary
- * permissions to execute the underlying management operation, or,
- * in case of local sessions, if the caller does not have
- * <code>DmtPermission</code> for the node with the Replace action
- * present
- * @see #setNodeValue
- */
- void setDefaultNodeValue(String nodeUri) throws DmtException;
-
- /**
- * Set the value of a leaf or interior node. The format of the node is
- * contained in the <code>DmtData</code> object. For interior nodes, the
- * format must be <code>FORMAT_NODE</code>, while for leaf nodes this
- * format must not be used.
- * <p>
- * If the specified value is <code>null</code>, the default value is taken.
- * In this case, if the node does not have a default value, this method will
- * throw a <code>DmtException</code> with error code
- * <code>METADATA_MISMATCH</code>. Nodes of <code>null</code> format can be
- * set by using {@link DmtData#NULL_VALUE} as second argument.
- * <p>
- * An Event of type REPLACE is sent out for a leaf node. A replaced interior
- * node sends out events for each of its children in depth first order
- * and node names sorted with Arrays.sort(String[]). When setting a value
- * on an interior node, the values of the leaf nodes under it can change,
- * but the structure of the subtree is not modified by the operation.
- *
- * @param nodeUri the URI of the node
- * @param data the data to be set, can be <code>null</code>
- * @throws DmtException with the following possible error codes:
- * <ul>
- * <li><code>URI_TOO_LONG</code> if <code>nodeUri</code> or a
- * segment of it is too long, or if it has too many segments
- * <li><code>INVALID_URI</code> if <code>nodeUri</code> is
- * <code>null</code> or syntactically invalid
- * <li><code>NODE_NOT_FOUND</code> if <code>nodeUri</code>
- * points to a non-existing node
- * <li><code>PERMISSION_DENIED</code> if the session is
- * associated with a principal and the ACL of the node does not
- * allow the <code>Replace</code> operation for the associated
- * principal
- * <li><code>COMMAND_NOT_ALLOWED</code> if the given data has
- * <code>FORMAT_NODE</code> format but the node is a leaf node (or
- * vice versa), or in non-atomic sessions if the underlying plugin
- * is read-only or does not support non-atomic writing
- * <li><code>METADATA_MISMATCH</code> if the node is permanent or
- * cannot be modified according to the meta-data (does not have the
- * <code>MetaNode.CMD_REPLACE</code> access type), or if the given
- * value does not conform to the meta-data value constraints
- * <li><code>FEATURE_NOT_SUPPORTED</code> if the specified node is
- * an interior node and does not support Java object values
- * <li><code>TRANSACTION_ERROR</code> in an atomic session if the
- * underlying plugin is read-only or does not support atomic writing
- * <li><code>DATA_STORE_FAILURE</code> if an error occurred while
- * accessing the data store
- * <li><code>COMMAND_FAILED</code> if the URI is not within the
- * current session's subtree, or if some unspecified error is
- * encountered while attempting to complete the command
- * </ul>
- * @throws DmtIllegalStateException if the session was opened using the
- * <code>LOCK_TYPE_SHARED</code> lock type, or if the session is
- * already closed or invalidated
- * @throws SecurityException if the caller does not have the necessary
- * permissions to execute the underlying management operation, or,
- * in case of local sessions, if the caller does not have
- * <code>DmtPermission</code> for the node with the Replace action
- * present
- */
- void setNodeValue(String nodeUri, DmtData data) throws DmtException;
-
- /**
- * Set the title property of a node. The length of the title string in UTF-8
- * encoding must not exceed 255 bytes.
- *
- * @param nodeUri the URI of the node
- * @param title the title text of the node, can be <code>null</code>
- * @throws DmtException with the following possible error codes:
- * <ul>
- * <li><code>URI_TOO_LONG</code> if <code>nodeUri</code> or a
- * segment of it is too long, or if it has too many segments
- * <li><code>INVALID_URI</code> if <code>nodeUri</code> is
- * <code>null</code> or syntactically invalid
- * <li><code>NODE_NOT_FOUND</code> if <code>nodeUri</code>
- * points to a non-existing node
- * <li><code>PERMISSION_DENIED</code> if the session is
- * associated with a principal and the ACL of the node does not
- * allow the <code>Replace</code> operation for the associated
- * principal
- * <li><code>COMMAND_NOT_ALLOWED</code> in non-atomic sessions if
- * the underlying plugin is read-only or does not support non-atomic
- * writing
- * <li><code>METADATA_MISMATCH</code> if the node cannot be
- * modified according to the meta-data (does not have the
- * <code>MetaNode.CMD_REPLACE</code> access type)
- * <li><code>FEATURE_NOT_SUPPORTED</code> if the Title property
- * is not supported by the DmtAdmin implementation or the
- * underlying plugin
- * <li><code>TRANSACTION_ERROR</code> in an atomic session if the
- * underlying plugin is read-only or does not support atomic writing
- * <li><code>DATA_STORE_FAILURE</code> if an error occurred while
- * accessing the data store
- * <li><code>COMMAND_FAILED</code> if the title string is too
- * long, if the URI is not within the current session's subtree, or
- * if some unspecified error is encountered while attempting to
- * complete the command
- * </ul>
- * @throws DmtIllegalStateException if the session was opened using the
- * <code>LOCK_TYPE_SHARED</code> lock type, or if the session is
- * already closed or invalidated
- * @throws SecurityException if the caller does not have the necessary
- * permissions to execute the underlying management operation, or,
- * in case of local sessions, if the caller does not have
- * <code>DmtPermission</code> for the node with the Replace action
- * present
- */
- void setNodeTitle(String nodeUri, String title) throws DmtException;
-
- /**
- * Set the type of a node. The type of leaf node is the MIME type of the
- * data it contains. The type of an interior node is a URI identifying a DDF
- * document.
- * <p>
- * For interior nodes, a <code>null</code> type string means that there is
- * no DDF document overriding the tree structure defined by the ancestors.
- * For leaf nodes, it requests that the default MIME type is used for the
- * given node. If the node does not have a default MIME type this method
- * will throw a <code>DmtException</code> with error code
- * <code>METADATA_MISMATCH</code>. Note that a node might have a default
- * MIME type even if there is no meta-data for the node or its meta-data
- * does not specify the default.
- * <p>
- * MIME types must conform to the definition in RFC 2045. Interior node type
- * identifiers must follow the format defined in section 7.7.7.2 of the OMA
- * Device Management Tree and Description document. Checking the validity of
- * the type string does not have to be done by the DmtAdmin, this can be
- * left to the plugin handling the node (if any), to avoid unnecessary
- * double-checks.
- *
- * @param nodeUri the URI of the node
- * @param type the type of the node, can be <code>null</code>
- * @throws DmtException with the following possible error codes:
- * <ul>
- * <li><code>URI_TOO_LONG</code> if <code>nodeUri</code> or a
- * segment of it is too long, or if it has too many segments
- * <li><code>INVALID_URI</code> if <code>nodeUri</code> is
- * <code>null</code> or syntactically invalid
- * <li><code>NODE_NOT_FOUND</code> if <code>nodeUri</code>
- * points to a non-existing node
- * <li><code>PERMISSION_DENIED</code> if the session is
- * associated with a principal and the ACL of the node does not
- * allow the <code>Replace</code> operation for the associated
- * principal
- * <li><code>COMMAND_NOT_ALLOWED</code> in non-atomic sessions if
- * the underlying plugin is read-only or does not support non-atomic
- * writing
- * <li><code>METADATA_MISMATCH</code> if the node is permanent or
- * cannot be modified according to the meta-data (does not have the
- * <code>MetaNode.CMD_REPLACE</code> access type), and in case of
- * leaf nodes, if <code>null</code> is given and there is no
- * default MIME type, or the given MIME type is not allowed
- * <li><code>TRANSACTION_ERROR</code> in an atomic session if the
- * underlying plugin is read-only or does not support atomic writing
- * <li><code>DATA_STORE_FAILURE</code> if an error occurred while
- * accessing the data store
- * <li><code>COMMAND_FAILED</code> if the URI is not within the
- * current session's subtree, if the type string is invalid (see
- * above), or if some unspecified error is encountered while
- * attempting to complete the command
- * </ul>
- * @throws DmtIllegalStateException if the session was opened using the
- * <code>LOCK_TYPE_SHARED</code> lock type, or if the session is
- * already closed or invalidated
- * @throws SecurityException if the caller does not have the necessary
- * permissions to execute the underlying management operation, or,
- * in case of local sessions, if the caller does not have
- * <code>DmtPermission</code> for the node with the Replace action
- * present
- * @see <a href="http://www.ietf.org/rfc/rfc2045.txt">RFC 2045</a>
- * @see <a
- * href="http://member.openmobilealliance.org/ftp/public_documents/dm/Permanent_documents/OMA-TS-DM-TND-V1_2-20050615-C.zip">
- * OMA Device Management Tree and Description v1.2 draft</a>
- */
- void setNodeType(String nodeUri, String type) throws DmtException;
-
- /**
- * Get the list of children names of a node. The returned array contains the
- * names - not the URIs - of the immediate children nodes of the given node.
- * The returned child names are mangled ({@link Uri#mangle(String)}). The elements
- * are in no particular order. The returned array must not contain
- * <code>null</code> entries.
- *
- * @param nodeUri the URI of the node
- * @return the list of child node names as a string array or an empty string
- * array if the node has no children
- * @throws DmtException with the following possible error codes:
- * <ul>
- * <li><code>URI_TOO_LONG</code> if <code>nodeUri</code> or a
- * segment of it is too long, or if it has too many segments
- * <li><code>INVALID_URI</code> if <code>nodeUri</code> is
- * <code>null</code> or syntactically invalid
- * <li><code>NODE_NOT_FOUND</code> if <code>nodeUri</code>
- * points to a non-existing node
- * <li><code>PERMISSION_DENIED</code> if the session is
- * associated with a principal and the ACL of the node does not
- * allow the <code>Get</code> operation for the associated
- * principal
- * <li><code>COMMAND_NOT_ALLOWED</code> if the specified node is
- * not an interior node
- * <li><code>METADATA_MISMATCH</code> if node information cannot
- * be retrieved according to the meta-data (it does not have
- * <code>MetaNode.CMD_GET</code> access type)
- * <li><code>DATA_STORE_FAILURE</code> if an error occurred while
- * accessing the data store
- * <li><code>COMMAND_FAILED</code> if the URI is not within the
- * current session's subtree, or if some unspecified error is
- * encountered while attempting to complete the command
- * </ul>
- * @throws DmtIllegalStateException if the session is already closed or
- * invalidated
- * @throws SecurityException if the caller does not have the necessary
- * permissions to execute the underlying management operation, or,
- * in case of local sessions, if the caller does not have
- * <code>DmtPermission</code> for the node with the Get action
- * present
- */
- String[] getChildNodeNames(String nodeUri) throws DmtException;
-
- /**
- * Get the meta data which describes a given node. Meta data can only be
- * inspected, it can not be changed.
- * <p>
- * The <code>MetaNode</code> object returned to the client is the
- * combination of the meta data returned by the data plugin (if any) plus
- * the meta data returned by the DmtAdmin. If there are differences in the
- * meta data elements known by the plugin and the DmtAdmin then the plugin
- * specific elements take precedence.
- * <p>
- * Note, that a node does not have to exist for having meta-data associated
- * with it. This method may provide meta-data for any node that can possibly
- * exist in the tree (any node defined in the specification). For nodes that
- * are not defined, it may throw <code>DmtException</code> with the error
- * code <code>NODE_NOT_FOUND</code>. To allow easier implementation of
- * plugins that do not provide meta-data, it is allowed to return
- * <code>null</code> for any node, regardless of whether it is defined or
- * not.
- *
- * @param nodeUri the URI of the node
- * @return a MetaNode which describes meta data information, can be
- * <code>null</code> if there is no meta data available for the
- * given node
- * @throws DmtException with the following possible error codes:
- * <ul>
- * <li><code>URI_TOO_LONG</code> if <code>nodeUri</code> or a
- * segment of it is too long, or if it has too many segments
- * <li><code>INVALID_URI</code> if <code>nodeUri</code> is
- * <code>null</code> or syntactically invalid
- * <li><code>NODE_NOT_FOUND</code> if <code>nodeUri</code>
- * points to a node that is not defined in the tree (see above)
- * <li><code>PERMISSION_DENIED</code> if the session is
- * associated with a principal and the ACL of the node does not
- * allow the <code>Get</code> operation for the associated
- * principal
- * <li><code>DATA_STORE_FAILURE</code> if an error occurred while
- * accessing the data store
- * <li><code>COMMAND_FAILED</code> if the URI is not within the
- * current session's subtree, or if some unspecified error is
- * encountered while attempting to complete the command
- * </ul>
- * @throws DmtIllegalStateException if the session is already closed or
- * invalidated
- * @throws SecurityException if the caller does not have the necessary
- * permissions to execute the underlying management operation, or,
- * in case of local sessions, if the caller does not have
- * <code>DmtPermission</code> for the node with the Get action
- * present
- */
- MetaNode getMetaNode(String nodeUri) throws DmtException;
-
- /**
- * Get the size of the data in a leaf node. The returned value depends on
- * the format of the data in the node, see the description of the
- * {@link DmtData#getSize()} method for the definition of node size for each
- * format.
- *
- * @param nodeUri the URI of the leaf node
- * @return the size of the data in the node
- * @throws DmtException with the following possible error codes:
- * <ul>
- * <li><code>URI_TOO_LONG</code> if <code>nodeUri</code> or a
- * segment of it is too long, or if it has too many segments
- * <li><code>INVALID_URI</code> if <code>nodeUri</code> is
- * <code>null</code> or syntactically invalid
- * <li><code>NODE_NOT_FOUND</code> if <code>nodeUri</code>
- * points to a non-existing node
- * <li><code>PERMISSION_DENIED</code> if the session is
- * associated with a principal and the ACL of the node does not
- * allow the <code>Get</code> operation for the associated
- * principal
- * <li><code>COMMAND_NOT_ALLOWED</code> if the specified node is
- * not a leaf node
- * <li><code>METADATA_MISMATCH</code> if node information cannot
- * be retrieved according to the meta-data (it does not have
- * <code>MetaNode.CMD_GET</code> access type)
- * <li><code>FEATURE_NOT_SUPPORTED</code> if the Size property is
- * not supported by the DmtAdmin implementation or the underlying
- * plugin
- * <li><code>DATA_STORE_FAILURE</code> if an error occurred while
- * accessing the data store
- * <li><code>COMMAND_FAILED</code> if the URI is not within the
- * current session's subtree, or if some unspecified error is
- * encountered while attempting to complete the command
- * </ul>
- * @throws DmtIllegalStateException if the session is already closed or
- * invalidated
- * @throws SecurityException if the caller does not have the necessary
- * permissions to execute the underlying management operation, or,
- * in case of local sessions, if the caller does not have
- * <code>DmtPermission</code> for the node with the Get action
- * present
- * @see DmtData#getSize
- */
- int getNodeSize(String nodeUri) throws DmtException;
-
- /**
- * Get the timestamp when the node was created or last modified.
- *
- * @param nodeUri the URI of the node
- * @return the timestamp of the last modification
- * @throws DmtException with the following possible error codes:
- * <ul>
- * <li><code>URI_TOO_LONG</code> if <code>nodeUri</code> or a
- * segment of it is too long, or if it has too many segments
- * <li><code>INVALID_URI</code> if <code>nodeUri</code> is
- * <code>null</code> or syntactically invalid
- * <li><code>NODE_NOT_FOUND</code> if <code>nodeUri</code>
- * points to a non-existing node
- * <li><code>PERMISSION_DENIED</code> if the session is
- * associated with a principal and the ACL of the node does not
- * allow the <code>Get</code> operation for the associated
- * principal
- * <li><code>METADATA_MISMATCH</code> if node information cannot
- * be retrieved according to the meta-data (it does not have
- * <code>MetaNode.CMD_GET</code> access type)
- * <li><code>FEATURE_NOT_SUPPORTED</code> if the Timestamp
- * property is not supported by the DmtAdmin implementation or the
- * underlying plugin
- * <li><code>DATA_STORE_FAILURE</code> if an error occurred while
- * accessing the data store
- * <li><code>COMMAND_FAILED</code> if the URI is not within the
- * current session's subtree, or if some unspecified error is
- * encountered while attempting to complete the command
- * </ul>
- * @throws DmtIllegalStateException if the session is already closed or
- * invalidated
- * @throws SecurityException if the caller does not have the necessary
- * permissions to execute the underlying management operation, or,
- * in case of local sessions, if the caller does not have
- * <code>DmtPermission</code> for the node with the Get action
- * present
- */
- Date getNodeTimestamp(String nodeUri) throws DmtException;
-
- /**
- * Get the title of a node. There might be no title property set for a node.
- *
- * @param nodeUri the URI of the node
- * @return the title of the node, or <code>null</code> if the node has no
- * title
- * @throws DmtException with the following possible error codes:
- * <ul>
- * <li><code>URI_TOO_LONG</code> if <code>nodeUri</code> or a
- * segment of it is too long, or if it has too many segments
- * <li><code>INVALID_URI</code> if <code>nodeUri</code> is
- * <code>null</code> or syntactically invalid
- * <li><code>NODE_NOT_FOUND</code> if <code>nodeUri</code>
- * points to a non-existing node
- * <li><code>PERMISSION_DENIED</code> if the session is
- * associated with a principal and the ACL of the node does not
- * allow the <code>Get</code> operation for the associated
- * principal
- * <li><code>METADATA_MISMATCH</code> if node information cannot
- * be retrieved according to the meta-data (it does not have
- * <code>MetaNode.CMD_GET</code> access type)
- * <li><code>FEATURE_NOT_SUPPORTED</code> if the Title property
- * is not supported by the DmtAdmin implementation or the
- * underlying plugin
- * <li><code>DATA_STORE_FAILURE</code> if an error occurred while
- * accessing the data store
- * <li><code>COMMAND_FAILED</code> if the URI is not within the
- * current session's subtree, or if some unspecified error is
- * encountered while attempting to complete the command
- * </ul>
- * @throws DmtIllegalStateException if the session is already closed or
- * invalidated
- * @throws SecurityException if the caller does not have the necessary
- * permissions to execute the underlying management operation, or,
- * in case of local sessions, if the caller does not have
- * <code>DmtPermission</code> for the node with the Get action
- * present
- */
- String getNodeTitle(String nodeUri) throws DmtException;
-
- /**
- * Get the type of a node. The type of leaf node is the MIME type of the
- * data it contains. The type of an interior node is a URI identifying a DDF
- * document; a <code>null</code> type means that there is no DDF document
- * overriding the tree structure defined by the ancestors.
- *
- * @param nodeUri the URI of the node
- * @return the type of the node, can be <code>null</code>
- * @throws DmtException with the following possible error codes:
- * <ul>
- * <li><code>URI_TOO_LONG</code> if <code>nodeUri</code> or a
- * segment of it is too long, or if it has too many segments
- * <li><code>INVALID_URI</code> if <code>nodeUri</code> is
- * <code>null</code> or syntactically invalid
- * <li><code>NODE_NOT_FOUND</code> if <code>nodeUri</code>
- * points to a non-existing node
- * <li><code>PERMISSION_DENIED</code> if the session is
- * associated with a principal and the ACL of the node does not
- * allow the <code>Get</code> operation for the associated
- * principal
- * <li><code>METADATA_MISMATCH</code> if node information cannot
- * be retrieved according to the meta-data (it does not have
- * <code>MetaNode.CMD_GET</code> access type)
- * <li><code>DATA_STORE_FAILURE</code> if an error occurred while
- * accessing the data store
- * <li><code>COMMAND_FAILED</code> if the URI is not within the
- * current session's subtree, or if some unspecified error is
- * encountered while attempting to complete the command
- * </ul>
- * @throws DmtIllegalStateException if the session is already closed or
- * invalidated
- * @throws SecurityException if the caller does not have the necessary
- * permissions to execute the underlying management operation, or,
- * in case of local sessions, if the caller does not have
- * <code>DmtPermission</code> for the node with the Get action
- * present
- */
- String getNodeType(String nodeUri) throws DmtException;
-
- /**
- * Get the data contained in a leaf or interior node. When retrieving the
- * value associated with an interior node, the caller must have rights to
- * read all nodes in the subtree under the given node.
- *
- * @param nodeUri the URI of the node to retrieve
- * @return the data of the node, can not be <code>null</code>
- * @throws DmtException with the following possible error codes:
- * <ul>
- * <li><code>URI_TOO_LONG</code> if <code>nodeUri</code> or a
- * segment of it is too long, or if it has too many segments
- * <li><code>INVALID_URI</code> if <code>nodeUri</code> is
- * <code>null</code> or syntactically invalid
- * <li><code>NODE_NOT_FOUND</code> if <code>nodeUri</code>
- * points to a non-existing node
- * <li><code>PERMISSION_DENIED</code> if the session is
- * associated with a principal and the ACL of the node (and the ACLs
- * of all its descendants in case of interior nodes) do not allow
- * the <code>Get</code> operation for the associated principal
- * <li><code>METADATA_MISMATCH</code> if the node value cannot be
- * retrieved according to the meta-data (it does not have
- * <code>MetaNode.CMD_GET</code> access type)
- * <li><code>FEATURE_NOT_SUPPORTED</code> if the specified node is
- * an interior node and does not support Java object values
- * <li><code>DATA_STORE_FAILURE</code> if an error occurred while
- * accessing the data store
- * <li><code>COMMAND_FAILED</code> if the URI is not within the
- * current session's subtree, or if some unspecified error is
- * encountered while attempting to complete the command
- * </ul>
- * @throws DmtIllegalStateException if the session is already closed or
- * invalidated
- * @throws SecurityException if the caller does not have the necessary
- * permissions to execute the underlying management operation, or,
- * in case of local sessions, if the caller does not have
- * <code>DmtPermission</code> for the node (and all its descendants
- * in case of interior nodes) with the Get action present
- */
- DmtData getNodeValue(String nodeUri) throws DmtException;
-
- /**
- * Get the version of a node. The version can not be set, it is calculated
- * automatically by the device. It is incremented modulo 0x10000 at every
- * modification of the value or any other property of the node, for both
- * leaf and interior nodes. When a node is created the initial value is 0.
- *
- * @param nodeUri the URI of the node
- * @return the version of the node
- * @throws DmtException with the following possible error codes:
- * <ul>
- * <li><code>URI_TOO_LONG</code> if <code>nodeUri</code> or a
- * segment of it is too long, or if it has too many segments
- * <li><code>INVALID_URI</code> if <code>nodeUri</code> is
- * <code>null</code> or syntactically invalid
- * <li><code>NODE_NOT_FOUND</code> if <code>nodeUri</code>
- * points to a non-existing node
- * <li><code>PERMISSION_DENIED</code> if the session is
- * associated with a principal and the ACL of the node does not
- * allow the <code>Get</code> operation for the associated
- * principal
- * <li><code>METADATA_MISMATCH</code> if node information cannot
- * be retrieved according to the meta-data (it does not have
- * <code>MetaNode.CMD_GET</code> access type)
- * <li><code>FEATURE_NOT_SUPPORTED</code> if the Version property
- * is not supported by the DmtAdmin implementation or the
- * underlying plugin
- * <li><code>DATA_STORE_FAILURE</code> if an error occurred while
- * accessing the data store
- * <li><code>COMMAND_FAILED</code> if the URI is not within the
- * current session's subtree, or if some unspecified error is
- * encountered while attempting to complete the command
- * </ul>
- * @throws DmtIllegalStateException if the session is already closed or
- * invalidated
- * @throws SecurityException if the caller does not have the necessary
- * permissions to execute the underlying management operation, or,
- * in case of local sessions, if the caller does not have
- * <code>DmtPermission</code> for the node with the Get action
- * present
- */
- int getNodeVersion(String nodeUri) throws DmtException;
-
- /**
- * Tells whether a node is a leaf or an interior node of the DMT.
- *
- * @param nodeUri the URI of the node
- * @return true if the given node is a leaf node
- * @throws DmtException with the following possible error codes:
- * <ul>
- * <li><code>URI_TOO_LONG</code> if <code>nodeUri</code> or a
- * segment of it is too long, or if it has too many segments
- * <li><code>INVALID_URI</code> if <code>nodeUri</code> is
- * <code>null</code> or syntactically invalid
- * <li><code>NODE_NOT_FOUND</code> if <code>nodeUri</code>
- * points to a non-existing node
- * <li><code>PERMISSION_DENIED</code> if the session is
- * associated with a principal and the ACL of the node does not
- * allow the <code>Get</code> operation for the associated
- * principal
- * <li><code>METADATA_MISMATCH</code> if node information cannot
- * be retrieved according to the meta-data (it does not have
- * <code>MetaNode.CMD_GET</code> access type)
- * <li><code>DATA_STORE_FAILURE</code> if an error occurred while
- * accessing the data store
- * <li><code>COMMAND_FAILED</code> if the URI is not within the
- * current session's subtree, or if some unspecified error is
- * encountered while attempting to complete the command
- * </ul>
- * @throws DmtIllegalStateException if the session is already closed or
- * invalidated
- * @throws SecurityException if the caller does not have the necessary
- * permissions to execute the underlying management operation, or,
- * in case of local sessions, if the caller does not have
- * <code>DmtPermission</code> for the node with the Get action
- * present
- */
- boolean isLeafNode(String nodeUri) throws DmtException;
-
- /**
- * Check whether the specified URI corresponds to a valid node in the DMT.
- *
- * @param nodeUri the URI to check
- * @return true if the given node exists in the DMT
- * @throws DmtIllegalStateException if the session is already closed or
- * invalidated
- * @throws SecurityException if the caller does not have the necessary
- * permissions to execute the underlying management operation, or,
- * in case of local sessions, if the caller does not have
- * <code>DmtPermission</code> for the node with the Get action
- * present
- */
- boolean isNodeUri(String nodeUri);
-}
diff --git a/org.osgi.compendium/src/main/java/info/dmtree/MetaNode.java b/org.osgi.compendium/src/main/java/info/dmtree/MetaNode.java
deleted file mode 100644
index 91b442f..0000000
--- a/org.osgi.compendium/src/main/java/info/dmtree/MetaNode.java
+++ /dev/null
@@ -1,383 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2004, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package info.dmtree;
-
-/**
- * The MetaNode contains meta data as standardized by OMA DM but extends it
- * (without breaking the compatibility) to provide for better DMT data quality
- * in an environment where many software components manipulate this data.
- * <p>
- * The interface has several types of functions to describe the nodes in the
- * DMT. Some methods can be used to retrieve standard OMA DM metadata such as
- * access type, cardinality, default, etc., others are for data extensions such
- * as valid names and values. In some cases the standard behaviour has been
- * extended, for example it is possible to provide several valid MIME types, or
- * to differentiate between normal and automatic dynamic nodes.
- * <p>
- * Most methods in this interface receive no input, just return information
- * about some aspect of the node. However, there are two methods that behave
- * differently, {@link #isValidName} and {@link #isValidValue}. These validation
- * methods are given a potential node name or value (respectively), and can
- * decide whether it is valid for the given node. Passing the validation methods
- * is a necessary condition for a name or value to be used, but it is not
- * necessarily sufficient: the plugin may carry out more thorough (more
- * expensive) checks when the node is actually created or set.
- * <p>
- * If a <code>MetaNode</code> is available for a node, the DmtAdmin must use the
- * information provided by it to filter out invalid requests on that node.
- * However, not all methods on this interface are actually used for this
- * purpose, as many of them (e.g. {@link #getFormat} or {@link #getValidNames})
- * can be substituted with the validating methods. For example,
- * {@link #isValidValue} can be expected to check the format, minimum, maximum,
- * etc. of a given value, making it unnecessary for the DmtAdmin to call
- * {@link #getFormat()}, {@link #getMin()}, {@link #getMax()} etc. separately.
- * It is indicated in the description of each method if the DmtAdmin does not
- * enforce the constraints defined by it - such methods are only for external
- * use, for example in user interfaces.
- * <p>
- * Most of the methods of this class return <code>null</code> if a certain piece
- * of meta information is not defined for the node or providing this information
- * is not supported. Methods of this class do not throw exceptions.
- *
- * @version $Revision: 5673 $
- */
-public interface MetaNode {
-
- /**
- * Constant for the ADD access type. If {@link #can(int)} returns
- * <code>true</code> for this operation, this node can potentially be
- * added to its parent. Nodes with {@link #PERMANENT} or {@link #AUTOMATIC}
- * scope typically do not have this access type.
- */
- int CMD_ADD = 0;
-
- /**
- * Constant for the DELETE access type. If {@link #can(int)} returns
- * <code>true</code> for this operation, the node can potentially be
- * deleted.
- */
- int CMD_DELETE = 1;
-
- /**
- * Constant for the EXECUTE access type. If {@link #can(int)} returns
- * <code>true</code> for this operation, the node can potentially be
- * executed.
- */
- int CMD_EXECUTE = 2;
-
- /**
- * Constant for the REPLACE access type. If {@link #can(int)} returns
- * <code>true</code> for this operation, the value and other properties of
- * the node can potentially be modified.
- */
- int CMD_REPLACE = 3;
-
- /**
- * Constant for the GET access type. If {@link #can(int)} returns
- * <code>true</code> for this operation, the value, the list of child nodes
- * (in case of interior nodes) and the properties of the node can
- * potentially be retrieved.
- */
- int CMD_GET = 4;
-
- /**
- * Constant for representing a permanent node in the tree. This must be
- * returned by {@link #getScope} if the node cannot be added, deleted or
- * modified in any way through tree operations. Permanent nodes cannot have
- * non-permanent nodes as parents.
- */
- int PERMANENT = 0;
-
- /**
- * Constant for representing a dynamic node in the tree. This must be
- * returned by {@link #getScope} for all nodes that are not permanent and
- * are not created automatically by the management object.
- */
- int DYNAMIC = 1;
-
- /**
- * Constant for representing an automatic node in the tree. This must be
- * returned by {@link #getScope()} for all nodes that are created
- * automatically by the management object. Automatic nodes represent a
- * special case of dynamic nodes, so this scope should be mapped to
- * {@link #DYNAMIC} when used in an OMA DM context.
- * <p>
- * An automatic node is usually created instantly when its parent is
- * created, but it is also valid if it only appears later, triggered by some
- * other condition. The exact behaviour must be defined by the Management
- * Object.
- */
- int AUTOMATIC = 2;
-
- /**
- * Check whether the given operation is valid for this node. If no meta-data
- * is provided for a node, all operations are valid.
- *
- * @param operation One of the <code>MetaNode.CMD_...</code> constants.
- * @return <code>false</code> if the operation is not valid for this node
- * or the operation code is not one of the allowed constants
- */
- boolean can(int operation);
-
- /**
- * Check whether the node is a leaf node or an internal one.
- *
- * @return <code>true</code> if the node is a leaf node
- */
- boolean isLeaf();
-
- /**
- * Return the scope of the node. Valid values are
- * {@link #PERMANENT MetaNode.PERMANENT}, {@link #DYNAMIC MetaNode.DYNAMIC}
- * and {@link #AUTOMATIC MetaNode.AUTOMATIC}. Note that a permanent node is
- * not the same as a node where the DELETE operation is not allowed.
- * Permanent nodes never can be deleted, whereas a non-deletable node can
- * disappear in a recursive DELETE operation issued on one of its parents.
- * If no meta-data is provided for a node, it can be assumed to be a dynamic
- * node.
- *
- * @return {@link #PERMANENT} for permanent nodes, {@link #AUTOMATIC} for
- * nodes that are automatically created, and {@link #DYNAMIC}
- * otherwise
- */
- int getScope();
-
- /**
- * Get the explanation string associated with this node. Can be
- * <code>null</code> if no description is provided for this node.
- *
- * @return node description string or <code>null</code> for no description
- */
- String getDescription();
-
- /**
- * Get the number of maximum occurrences of this type of nodes on the same
- * level in the DMT. Returns <code>Integer.MAX_VALUE</code> if there is no
- * upper limit. Note that if the occurrence is greater than 1 then this node
- * can not have siblings with different metadata. In other words, if
- * different types of nodes coexist on the same level, their occurrence can
- * not be greater than 1. If no meta-data is provided for a node, there is
- * no upper limit on the number of occurrences.
- *
- * @return The maximum allowed occurrence of this node type
- */
- int getMaxOccurrence();
-
- /**
- * Check whether zero occurrence of this node is valid. If no meta-data is
- * returned for a node, zero occurrences are allowed.
- *
- * @return <code>true</code> if zero occurrence of this node is valid
- */
- boolean isZeroOccurrenceAllowed();
-
- /**
- * Get the default value of this node if any.
- *
- * @return The default value or <code>null</code> if not defined
- */
- DmtData getDefault();
-
- /**
- * Get the list of MIME types this node can hold. The first element of the
- * returned list must be the default MIME type.
- * <p>
- * All MIME types are considered valid if no meta-data is provided for a
- * node or if <code>null</code> is returned by this method. In this case
- * the default MIME type cannot be retrieved from the meta-data, but the
- * node may still have a default. This hidden default (if it exists) can be
- * utilized by passing <code>null</code> as the type parameter of
- * {@link DmtSession#setNodeType(String, String)} or
- * {@link DmtSession#createLeafNode(String, DmtData, String)}.
- *
- * @return the list of allowed MIME types for this node, starting with the
- * default MIME type, or <code>null</code> if all types are
- * allowed
- */
- String[] getMimeTypes();
-
- /**
- * Get the maximum allowed value associated with a node of numeric format.
- * If no meta-data is provided for a node, there is no upper limit to its
- * value. This method is only meaningful if the node has integer or float
- * format. The returned limit has <code>double</code> type, as this can be
- * used to denote both integer and float limits with full precision. The
- * actual maximum should be the largest integer or float number that does
- * not exceed the returned value.
- * <p>
- * The information returned by this method is not checked by DmtAdmin, it
- * is only for external use, for example in user interfaces. DmtAdmin only
- * calls {@link #isValidValue} for checking the value, its behaviour should
- * be consistent with this method.
- *
- * @return the allowed maximum, or <code>Double.MAX_VALUE</code> if there
- * is no upper limit defined or the node's format is not integer or
- * float
- */
- double getMax();
-
- /**
- * Get the minimum allowed value associated with a node of numeric format.
- * If no meta-data is provided for a node, there is no lower limit to its
- * value. This method is only meaningful if the node has integer or float
- * format. The returned limit has <code>double</code> type, as this can be
- * used to denote both integer and float limits with full precision. The
- * actual minimum should be the smallest integer or float number that is
- * larger than the returned value.
- * <p>
- * The information returned by this method is not checked by DmtAdmin, it
- * is only for external use, for example in user interfaces. DmtAdmin only
- * calls {@link #isValidValue} for checking the value, its behaviour should
- * be consistent with this method.
- *
- * @return the allowed minimum, or <code>Double.MIN_VALUE</code> if there
- * is no lower limit defined or the node's format is not integer or
- * float
- */
- double getMin();
-
- /**
- * Return an array of DmtData objects if valid values are defined for the
- * node, or <code>null</code> otherwise. If no meta-data is provided for a
- * node, all values are considered valid.
- * <p>
- * The information returned by this method is not checked by DmtAdmin, it
- * is only for external use, for example in user interfaces. DmtAdmin only
- * calls {@link #isValidValue} for checking the value, its behaviour should
- * be consistent with this method.
- *
- * @return the valid values for this node, or <code>null</code> if not
- * defined
- */
- DmtData[] getValidValues();
-
- /**
- * Get the node's format, expressed in terms of type constants defined in
- * {@link DmtData}. If there are multiple formats allowed for the node then
- * the format constants are OR-ed. Interior nodes must have
- * {@link DmtData#FORMAT_NODE} format, and this code must not be returned
- * for leaf nodes. If no meta-data is provided for a node, all applicable
- * formats are considered valid (with the above constraints regarding
- * interior and leaf nodes).
- * <p>
- * Note that the 'format' term is a legacy from OMA DM, it is more customary
- * to think of this as 'type'.
- * <p>
- * The formats returned by this method are not checked by DmtAdmin, they
- * are only for external use, for example in user interfaces. DmtAdmin only
- * calls {@link #isValidValue} for checking the value, its behaviour should
- * be consistent with this method.
- *
- * @return the allowed format(s) of the node
- */
- int getFormat();
-
- /**
- * Get the format names for any raw formats supported by the node. This
- * method is only meaningful if the list of supported formats returned by
- * {@link #getFormat()} contains {@link DmtData#FORMAT_RAW_STRING} or
- * {@link DmtData#FORMAT_RAW_BINARY}: it specifies precisely which raw
- * format(s) are actually supported. If the node cannot contain data in one
- * of the raw types, this method must return <code>null</code>.
- * <p>
- * The format names returned by this method are not checked by DmtAdmin,
- * they are only for external use, for example in user interfaces. DmtAdmin
- * only calls {@link #isValidValue} for checking the value, its behaviour
- * should be consistent with this method.
- *
- * @return the allowed format name(s) of raw data stored by the node, or
- * <code>null</code> if raw formats are not supported
- */
- String[] getRawFormatNames();
-
- /**
- * Checks whether the given value is valid for this node. This method can be
- * used to ensure that the value has the correct format and range, that it
- * is well formed, etc. This method should be consistent with the
- * constraints defined by the {@link #getFormat}, {@link #getValidValues},
- * {@link #getMin} and {@link #getMax} methods (if applicable), as the Dmt
- * Admin only calls this method for value validation.
- * <p>
- * This method may return <code>true</code> even if not all aspects of the
- * value have been checked, expensive operations (for example those that
- * require external resources) need not be performed here. The actual value
- * setting method may still indicate that the value is invalid.
- *
- * @param value the value to check for validity
- * @return <code>false</code> if the specified value is found to be
- * invalid for the node described by this meta-node,
- * <code>true</code> otherwise
- */
- boolean isValidValue(DmtData value);
-
- /**
- * Return an array of Strings if valid names are defined for the node, or
- * <code>null</code> if no valid name list is defined or if this piece of
- * meta info is not supported. If no meta-data is provided for a node, all
- * names are considered valid.
- * <p>
- * The information returned by this method is not checked by DmtAdmin, it
- * is only for external use, for example in user interfaces. DmtAdmin only
- * calls {@link #isValidName} for checking the name, its behaviour should be
- * consistent with this method.
- *
- * @return the valid values for this node name, or <code>null</code> if
- * not defined
- */
- String[] getValidNames();
-
- /**
- * Checks whether the given name is a valid name for this node. This method
- * can be used for example to ensure that the node name is always one of a
- * predefined set of valid names, or that it matches a specific pattern.
- * This method should be consistent with the values returned by
- * {@link #getValidNames} (if any), the DmtAdmin only calls this method for
- * name validation.
- * <p>
- * This method may return <code>true</code> even if not all aspects of the
- * name have been checked, expensive operations (for example those that
- * require external resources) need not be performed here. The actual node
- * creation may still indicate that the node name is invalid.
- *
- * @param name the node name to check for validity
- * @return <code>false</code> if the specified name is found to be invalid
- * for the node described by this meta-node, <code>true</code>
- * otherwise
- */
- boolean isValidName(String name);
-
- /**
- * Returns the list of extension property keys, if the provider of this
- * <code>MetaNode</code> provides proprietary extensions to node meta
- * data. The method returns <code>null</code> if the node doesn't provide
- * such extensions.
- *
- * @return the array of supported extension property keys
- */
- String[] getExtensionPropertyKeys();
-
- /**
- * Returns the value for the specified extension property key. This method
- * only works if the provider of this <code>MetaNode</code> provides
- * proprietary extensions to node meta data.
- *
- * @param key the key for the extension property
- * @return the value of the requested property, cannot be <code>null</code>
- * @throws IllegalArgumentException if the specified key is not supported by
- * this <code>MetaNode</code>
- */
- Object getExtensionProperty(String key);
-}
diff --git a/org.osgi.compendium/src/main/java/info/dmtree/Uri.java b/org.osgi.compendium/src/main/java/info/dmtree/Uri.java
deleted file mode 100644
index ab5b8a8..0000000
--- a/org.osgi.compendium/src/main/java/info/dmtree/Uri.java
+++ /dev/null
@@ -1,564 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2004, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package info.dmtree;
-
-import java.io.UnsupportedEncodingException;
-import java.lang.reflect.InvocationTargetException;
-import java.lang.reflect.Method;
-import java.lang.reflect.Modifier;
-import java.security.AccessController;
-import java.security.PrivilegedAction;
-import java.util.ArrayList;
-import java.util.List;
-
-/**
- * This class contains static utility methods to manipulate DMT URIs.
- * <p>
- * Syntax of valid DMT URIs:
- * <ul>
- * <li>A slash (<code>'/'</code> \u002F) is the separator of the node names.
- * Slashes used in node name must therefore be escaped using a backslash slash (
- * <code>"\/"</code>). The backslash must be escaped with a double backslash sequence. A
- * backslash found must be ignored when it is not followed by a slash or
- * backslash.
- * <li>The node name can be constructed using full Unicode character set (except
- * the Supplementary code, not being supported by CLDC/CDC). However, using the
- * full Unicode character set for node names is discouraged because the encoding
- * in the underlying storage as well as the encoding needed in communications
- * can create significant performance and memory usage overhead. Names that are
- * restricted to the URI set <code>[-a-zA-Z0-9_.!~*'()]</code> are most efficient.
- * <li>URIs used in the DMT must be treated and interpreted as case sensitive.
- * <li>No End Slash: URI must not end with the delimiter slash (<code>'/'</code>
- * \u002F). This implies that the root node must be denoted as
- * <code>"."</code> and not <code>"./"</code>.
- * <li>No parent denotation: URI must not be constructed using the character
- * sequence <code>"../"</code> to traverse the tree upwards.
- * <li>Single Root: The character sequence <code>"./"</code> must not be used
- * anywhere else but in the beginning of a URI.
- * </ul>
- *
- * @version $Revision: 5673 $
- */
-public final class Uri {
- /*
- * NOTE: An implementor may also choose to replace this class in
- * their distribution with a class that directly interfaces with the
- * info.dmtree implementation. This replacement class MUST NOT alter the
- * public/protected signature of this class.
- */
-
- /*
- * This class will load the class named
- * by the org.osgi.vendor.dmtree.DigestDelegate property. This class will call
- * the public static byte[] digest(byte[]) method on that class.
- */
-
- private static class ImplHolder implements PrivilegedAction {
- // the name of the system property containing the digest delegate class name
- private static final String DIGEST_DELEGATE_PROPERTY =
- "org.osgi.vendor.dmtree.DigestDelegate";
-
- // the Method where message digest requests can be delegated
- static final Method digestMethod;
-
- static {
- digestMethod = (Method) AccessController.doPrivileged(new ImplHolder());
- }
-
- private ImplHolder() {
- }
-
- public Object run() {
- String className = System
- .getProperty(DIGEST_DELEGATE_PROPERTY);
- if (className == null) {
- throw new NoClassDefFoundError("Digest " +
- "delegate class property '" +
- DIGEST_DELEGATE_PROPERTY +
- "' must be set to a " +
- "class which implements a " +
- "public static byte[] digest(byte[]) method.");
- }
-
- Class delegateClass;
- try {
- delegateClass = Class.forName(className);
- }
- catch (ClassNotFoundException e) {
- throw new NoClassDefFoundError(e.toString());
- }
-
- Method result;
- try {
- result = delegateClass.getMethod("digest",
- new Class[] {byte[].class});
- }
- catch (NoSuchMethodException e) {
- throw new NoSuchMethodError(e.toString());
- }
-
- if (!Modifier.isStatic(result.getModifiers())) {
- throw new NoSuchMethodError(
- "digest method must be static");
- }
-
- return result;
- }
- }
-
-
- // the name of the system property containing the URI segment length limit
- private static final String SEGMENT_LENGTH_LIMIT_PROPERTY =
- "org.osgi.impl.service.dmt.uri.limits.segmentlength";
-
- // the smallest valid value for the URI segment length limit
- private static final int MINIMAL_SEGMENT_LENGTH_LIMIT = 32;
-
- // contains the maximum length of node names
- private static final int segmentLengthLimit;
-
- static {
- segmentLengthLimit = ((Integer) AccessController
- .doPrivileged(new PrivilegedAction() {
- public Object run() {
- String limitString = System.getProperty(SEGMENT_LENGTH_LIMIT_PROPERTY);
- int limit = MINIMAL_SEGMENT_LENGTH_LIMIT; // min. used as default
-
- try {
- int limitInt = Integer.parseInt(limitString);
- if(limitInt >= MINIMAL_SEGMENT_LENGTH_LIMIT)
- limit = limitInt;
- } catch(NumberFormatException e) {}
-
- return new Integer(limit);
- }
- })).intValue();
- }
-
- // base64 encoding table, modified for use in node name mangling
- private static final char BASE_64_TABLE[] = {
- 'A','B','C','D','E','F','G','H',
- 'I','J','K','L','M','N','O','P',
- 'Q','R','S','T','U','V','W','X',
- 'Y','Z','a','b','c','d','e','f',
- 'g','h','i','j','k','l','m','n',
- 'o','p','q','r','s','t','u','v',
- 'w','x','y','z','0','1','2','3',
- '4','5','6','7','8','9','+','_', // !!! this differs from base64
- };
-
-
- /**
- * A private constructor to suppress the default public constructor.
- */
- private Uri() {}
-
- /**
- * Returns a node name that is valid for the tree operation methods, based
- * on the given node name. This transformation is not idempotent, so it must
- * not be called with a parameter that is the result of a previous
- * <code>mangle</code> method call.
- * <p>
- * Node name mangling is needed in the following cases:
- * <ul>
- * <li>if the name contains '/' or '\' characters
- * <li>if the length of the name exceeds the limit defined by the
- * implementation
- * </ul>
- * <p>
- * A node name that does not suffer from either of these problems is
- * guaranteed to remain unchanged by this method. Therefore the client may
- * skip the mangling if the node name is known to be valid (though it is
- * always safe to call this method).
- * <p>
- * The method returns the normalized <code>nodeName</code> as described
- * below. Invalid node names are normalized in different ways, depending on
- * the cause. If the length of the name does not exceed the limit, but the
- * name contains '/' or '\' characters, then these are simply escaped by
- * inserting an additional '\' before each occurrence. If the length of the
- * name does exceed the limit, the following mechanism is used to normalize
- * it:
- * <ul>
- * <li>the SHA 1 digest of the name is calculated
- * <li>the digest is encoded with the base 64 algorithm
- * <li>all '/' characters in the encoded digest are replaced with '_'
- * <li>trailing '=' signs are removed
- * </ul>
- *
- * @param nodeName the node name to be mangled (if necessary), must not be
- * <code>null</code> or empty
- * @return the normalized node name that is valid for tree operations
- * @throws NullPointerException if <code>nodeName</code> is
- * <code>null</code>
- * @throws IllegalArgumentException if <code>nodeName</code> is empty
- */
- public static String mangle(String nodeName) {
- return mangle(nodeName, getMaxSegmentNameLength());
- }
-
- /**
- * Construct a URI from the specified URI segments. The segments must
- * already be mangled.
- * <p>
- * If the specified path is an empty array then an empty URI
- * (<code>""</code>) is returned.
- *
- * @param path a possibly empty array of URI segments, must not be
- * <code>null</code>
- * @return the URI created from the specified segments
- * @throws NullPointerException if the specified path or any of its
- * segments are <code>null</code>
- * @throws IllegalArgumentException if the specified path contains too many
- * or malformed segments or the resulting URI is too long
- */
- public static String toUri(String[] path) {
- if (0 == path.length) {
- return "";
- }
-
- if (path.length > getMaxUriSegments()) {
- throw new IllegalArgumentException(
- "Path contains too many segments.");
- }
-
- StringBuffer uri = new StringBuffer();
- int uriLength = 0;
- for (int i = 0; i < path.length; ++i) {
- // getSegmentLength throws exceptions on malformed segments.
- int segmentLength = getSegmentLength(path[i]);
- if (segmentLength > getMaxSegmentNameLength()) {
- throw new IllegalArgumentException("URI segment too long.");
- }
- if (i > 0) {
- uri.append('/');
- uriLength++;
- }
- uriLength += segmentLength;
- uri.append(path[i]);
- }
- if (uriLength > getMaxUriLength()) {
- throw new IllegalArgumentException("URI too long.");
- }
- return uri.toString();
- }
-
- /**
- * This method returns the length of a URI segment. The length of the URI
- * segment is defined as the number of bytes in the unescaped, UTF-8 encoded
- * represenation of the segment.
- * <p>
- * The method verifies that the URI segment is well-formed.
- *
- * @param segment the URI segment
- * @return URI segment length
- * @throws NullPointerException if the specified segment is
- * <code>null</code>
- * @throws IllegalArgumentException if the specified URI segment is
- * malformed
- */
- private static int getSegmentLength(String segment) {
- if (segment.length() == 0)
- throw new IllegalArgumentException("URI segment is empty.");
-
- StringBuffer newsegment = new StringBuffer(segment);
- int i = 0;
- while (i < newsegment.length()) { // length can decrease during the loop!
- if (newsegment.charAt(i) == '\\') {
- if (i == newsegment.length() - 1) // last character cannot be a '\'
- throw new IllegalArgumentException(
- "URI segment ends with the escape character.");
-
- newsegment.deleteCharAt(i); // remove the extra '\'
- } else if (newsegment.charAt(i) == '/')
- throw new IllegalArgumentException(
- "URI segment contains an unescaped '/' character.");
-
- i++;
- }
-
- if (newsegment.toString().equals(".."))
- throw new IllegalArgumentException(
- "URI segment must not be \"..\".");
-
- try {
- return newsegment.toString().getBytes("UTF-8").length;
- } catch (UnsupportedEncodingException e) {
- // This should never happen. All implementations must support
- // UTF-8 encoding;
- throw new RuntimeException(e.toString());
- }
- }
-
- /**
- * Split the specified URI along the path separator '/' charaters and return
- * an array of URI segments. Special characters in the returned segments are
- * escaped. The returned array may be empty if the specifed URI was empty.
- *
- * @param uri the URI to be split, must not be <code>null</code>
- * @return an array of URI segments created by splitting the specified URI
- * @throws NullPointerException if the specified URI is <code>null</code>
- * @throws IllegalArgumentException if the specified URI is malformed
- */
- public static String[] toPath(String uri) {
- if (uri == null)
- throw new NullPointerException("'uri' parameter is null.");
-
- if (!isValidUri(uri))
- throw new IllegalArgumentException("Malformed URI: " + uri);
-
- if (uri.length() == 0)
- return new String[] {};
-
- List segments = new ArrayList();
- StringBuffer segment = new StringBuffer();
-
- boolean escape = false;
- for (int i = 0; i < uri.length(); i++) {
- char ch = uri.charAt(i);
-
- if (escape) {
- if(ch == '/' || ch == '\\')
- segment.append('\\');
- segment.append(ch);
- escape = false;
- } else if (ch == '/') {
- segments.add(segment.toString());
- segment = new StringBuffer();
- } else if (ch == '\\') {
- escape = true;
- } else
- segment.append(ch);
- }
- if (segment.length() > 0) {
- segments.add(segment.toString());
- }
-
- return (String[]) segments.toArray(new String[segments.size()]);
- }
-
- /**
- * Returns the maximum allowed number of URI segments. The returned value is
- * implementation specific.
- * <p>
- * The return value of <code>Integer.MAX_VALUE</code> indicates that there
- * is no upper limit on the number of URI segments.
- *
- * @return maximum number of URI segments supported by the implementation
- */
- public static int getMaxUriSegments() {
- return Integer.MAX_VALUE;
- }
-
- /**
- * Returns the maximum allowed length of a URI. The value is implementation
- * specific. The length of the URI is defined as the number of bytes in the
- * unescaped, UTF-8 encoded represenation of the URI.
- * <p>
- * The return value of <code>Integer.MAX_VALUE</code> indicates that there
- * is no upper limit on the length of URIs.
- *
- * @return maximum URI length supported by the implementation
- */
- public static int getMaxUriLength() {
- return Integer.MAX_VALUE;
- }
-
- /**
- * Returns the maximum allowed length of a URI segment. The value is
- * implementation specific. The length of the URI segment is defined as the
- * number of bytes in the unescaped, UTF-8 encoded represenation of the
- * segment.
- * <p>
- * The return value of <code>Integer.MAX_VALUE</code> indicates that there
- * is no upper limit on the length of segment names.
- *
- * @return maximum URI segment length supported by the implementation
- */
- public static int getMaxSegmentNameLength() {
- return segmentLengthLimit;
- }
-
- /**
- * Checks whether the specified URI is an absolute URI. An absolute URI
- * contains the complete path to a node in the DMT starting from the DMT
- * root (".").
- *
- * @param uri the URI to be checked, must not be <code>null</code> and must
- * contain a valid URI
- * @return whether the specified URI is absolute
- * @throws NullPointerException if the specified URI is <code>null</code>
- * @throws IllegalArgumentException if the specified URI is malformed
- */
- public static boolean isAbsoluteUri(String uri) {
- if( null == uri ) {
- throw new NullPointerException("'uri' parameter is null.");
- }
- if( !isValidUri(uri) )
- throw new IllegalArgumentException("Malformed URI: " + uri);
- return uri.equals(".") || uri.equals("\\.") || uri.startsWith("./")
- || uri.startsWith("\\./");
- }
-
- /**
- * Checks whether the specified URI is valid. A URI is considered valid if
- * it meets the following constraints:
- * <ul>
- * <li>the URI is not <code>null</code>;
- * <li>the URI follows the syntax defined for valid DMT URIs;
- * <li>the length of the URI is not more than {@link #getMaxUriLength()};
- * <li>the URI doesn't contain more than {@link #getMaxUriSegments()}
- * segments;
- * <li>the length of each segment of the URI is less than or equal to
- * {@link #getMaxSegmentNameLength()}.
- * </ul>
- * The exact definition of the length of a URI and its segments is
- * given in the descriptions of the <code>getMaxUriLength()</code> and
- * <code>getMaxSegmentNameLength()</code> methods.
- *
- * @param uri the URI to be validated
- * @return whether the specified URI is valid
- */
- public static boolean isValidUri(String uri) {
- if (null == uri)
- return false;
-
- int paramLen = uri.length();
- if( paramLen == 0 )
- return true;
- if( uri.charAt(0) == '/' || uri.charAt(paramLen-1) == '\\' )
- return false;
-
- int processedUriLength = 0;
- int segmentNumber = 0;
-
- // append a '/' to indicate the end of the last segment (the URI in the
- // parameter must not end with a '/')
- uri += '/';
- paramLen++;
-
- int start = 0;
- for(int i = 1; i < paramLen; i++) { // first character is not a '/'
- if(uri.charAt(i) == '/' && uri.charAt(i-1) != '\\') {
- segmentNumber++;
-
- String segment = uri.substring(start, i);
- if(segmentNumber > 1 && segment.equals("."))
- return false; // the URI contains the "." node name at a
- // position other than the beginning of the URI
-
- int segmentLength;
- try {
- // also checks that the segment is valid
- segmentLength = getSegmentLength(segment);
- } catch(IllegalArgumentException e) {
- return false;
- }
-
- if(segmentLength > getMaxSegmentNameLength())
- return false;
-
- // the extra byte is for the separator '/' (will be deducted
- // again for the last segment of the URI)
- processedUriLength += segmentLength + 1;
- start = i+1;
- }
- }
-
- processedUriLength--; // remove the '/' added to the end of the URI
-
- return segmentNumber <= getMaxUriSegments() &&
- processedUriLength <= getMaxUriLength();
- }
-
- // Non-public fields and methods
-
- // package private method for testing purposes
- static String mangle(String nodeName, int limit) {
- if(nodeName == null)
- throw new NullPointerException(
- "The 'nodeName' parameter must not be null.");
-
- if(nodeName.equals(""))
- throw new IllegalArgumentException(
- "The 'nodeName' parameter must not be empty.");
-
- if(nodeName.length() > limit)
- // create node name hash
- return getHash(nodeName);
-
- // escape any '/' and '\' characters in the node name
- StringBuffer nameBuffer = new StringBuffer(nodeName);
- for(int i = 0; i < nameBuffer.length(); i++) // 'i' can increase in loop
- if(nameBuffer.charAt(i) == '\\' || nameBuffer.charAt(i) == '/')
- nameBuffer.insert(i++, '\\');
-
- return nameBuffer.toString();
- }
-
- private static String getHash(String from) {
- byte[] byteStream;
- try {
- byteStream = from.getBytes("UTF-8");
- }
- catch (UnsupportedEncodingException e) {
- // There's no way UTF-8 encoding is not implemented...
- throw new IllegalStateException("there's no UTF-8 encoder here!");
- }
- byte[] digest = digestMessage(byteStream);
-
- // very dumb base64 encoder code. There is no need for multiple lines
- // or trailing '='-s....
- // also, we hardcoded the fact that sha-1 digests are 20 bytes long
- StringBuffer sb = new StringBuffer(digest.length*2);
- for(int i=0;i<6;i++) {
- int d0 = digest[i*3]&0xff;
- int d1 = digest[i*3+1]&0xff;
- int d2 = digest[i*3+2]&0xff;
- sb.append(BASE_64_TABLE[d0>>2]);
- sb.append(BASE_64_TABLE[(d0<<4|d1>>4)&63]);
- sb.append(BASE_64_TABLE[(d1<<2|d2>>6)&63]);
- sb.append(BASE_64_TABLE[d2&63]);
- }
- int d0 = digest[18]&0xff;
- int d1 = digest[19]&0xff;
- sb.append(BASE_64_TABLE[d0>>2]);
- sb.append(BASE_64_TABLE[(d0<<4|d1>>4)&63]);
- sb.append(BASE_64_TABLE[(d1<<2)&63]);
-
- return sb.toString();
- }
-
- private static byte[] digestMessage(byte[] byteStream) {
- try {
- try {
- return (byte[]) ImplHolder.digestMethod.invoke(null, new Object[] {
- byteStream});
- }
- catch (InvocationTargetException e) {
- throw e.getTargetException();
- }
- }
- catch (Error e) {
- throw e;
- }
- catch (RuntimeException e) {
- throw e;
- }
- catch (Throwable e) {
- throw new RuntimeException(e.toString());
- }
- }
-}
diff --git a/org.osgi.compendium/src/main/java/info/dmtree/notification/AlertItem.java b/org.osgi.compendium/src/main/java/info/dmtree/notification/AlertItem.java
deleted file mode 100644
index cacf44f..0000000
--- a/org.osgi.compendium/src/main/java/info/dmtree/notification/AlertItem.java
+++ /dev/null
@@ -1,170 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2004, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package info.dmtree.notification;
-
-import info.dmtree.DmtData;
-import info.dmtree.Uri;
-
-/**
- * Immutable data structure carried in an alert (client initiated notification).
- * The <code>AlertItem</code> describes details of various notifications that
- * can be sent by the client, for example as alerts in the OMA DM protocol. The
- * use cases include the client sending a session request to the server (alert
- * 1201), the client notifying the server of completion of a software update
- * operation (alert 1226) or sending back results in response to an asynchronous
- * EXEC command.
- * <p>
- * The data syntax and semantics varies widely between various alerts, so does
- * the optionality of particular parameters of an alert item. If an item, such
- * as source or type, is not defined, the corresponding getter method returns
- * <code>null</code>. For example, for alert 1201 (client-initiated session) all
- * elements will be <code>null</code>.
- * <P>
- * The syntax used in <code>AlertItem</code> class corresponds to the OMA DM
- * alert format. {@link NotificationService} implementations on other management
- * protocols should map these constructs to the underlying protocol.
- *
- * @version $Revision: 5673 $
- */
-public class AlertItem {
-
- private final String source;
-
- private final String type;
-
- private final String mark;
-
- private final DmtData data;
-
- /**
- * Create an instance of the alert item. The constructor takes all possible
- * data entries as parameters. Any of these parameters can be
- * <code>null</code>. The semantics of the parameters may be refined by
- * the definition of a specific alert, identified by its alert code (see
- * {@link NotificationService#sendNotification}). In case of Generic Alerts
- * for example (code 1226), the <code>mark</code> parameter contains a
- * severity string.
- *
- * @param source the URI of the node which is the source of the alert item
- * @param type a MIME type or a URN that identifies the type of the data in
- * the alert item
- * @param data a <code>DmtData</code> object that contains the format and
- * value of the data in the alert item
- * @param mark the mark parameter of the alert item
- */
- public AlertItem(String source, String type, String mark, DmtData data) {
- this.source = source;
- this.type = type;
- this.mark = mark;
- this.data = data;
- }
-
- /**
- * Create an instance of the alert item, specifying the source node URI as
- * an array of path segments. The constructor takes all possible data
- * entries as parameters. Any of these parameters can be <code>null</code>.
- * The semantics of the parameters may be refined by the definition of a
- * specific alert, identified by its alert code (see
- * {@link NotificationService#sendNotification}). In case of Generic Alerts
- * for example (code 1226), the <code>mark</code> parameter contains a
- * severity string.
- *
- * @param source the path of the node which is the source of the alert item
- * @param type a MIME type or a URN that identifies the type of the data in
- * the alert item
- * @param data a <code>DmtData</code> object that contains the format and
- * value of the data in the alert item
- * @param mark the mark parameter of the alert item
- */
- public AlertItem(String[] source, String type, String mark, DmtData data) {
- if ((null == source)) {
- this.source = null;
- } else {
- this.source = Uri.toUri(source);
- }
- this.type = type;
- this.mark = mark;
- this.data = data;
- }
-
- /**
- * Get the node which is the source of the alert. There might be no source
- * associated with the alert item.
- *
- * @return the URI of the node which is the source of this alert, or
- * <code>null</code> if there is no source
- */
- public String getSource() {
- return source;
- }
-
- /**
- * Get the type associated with the alert item. The type string is a MIME
- * type or a URN that identifies the type of the data in the alert item
- * (returned by {@link #getData}). There might be no type associated with
- * the alert item.
- *
- * @return the type type associated with the alert item, or
- * <code>null</code> if there is no type
- */
- public String getType() {
- return type;
- }
-
- /**
- * Get the mark parameter associated with the alert item. The interpretation
- * of the mark parameter depends on the alert being sent, as identified by
- * the alert code in {@link NotificationService#sendNotification}. There
- * might be no mark associated with the alert item.
- *
- * @return the mark associated with the alert item, or <code>null</code>
- * if there is no mark
- */
- public String getMark() {
- return mark;
- }
-
- /**
- * Get the data associated with the alert item. The returned
- * <code>DmtData</code> object contains the format and the value of the
- * data in the alert item. There might be no data associated with the alert
- * item.
- *
- * @return the data associated with the alert item, or <code>null</code>
- * if there is no data
- */
- public DmtData getData() {
- return data;
- }
-
- /**
- * Returns the string representation of this alert item. The returned string
- * includes all parameters of the alert item, and has the following format:
- *
- * <pre>
- * AlertItem(<source>, <type>, <mark>, <data>)
- * </pre>
- *
- * The last parameter is the string representation of the data value. The
- * format of the data is not explicitly included.
- *
- * @return the string representation of this alert item
- */
- public String toString() {
- return "AlertItem(" + source + ", " + type + ", " + mark + ", " + data
- + ")";
- }
-}
diff --git a/org.osgi.compendium/src/main/java/info/dmtree/notification/NotificationService.java b/org.osgi.compendium/src/main/java/info/dmtree/notification/NotificationService.java
deleted file mode 100644
index f1aa880..0000000
--- a/org.osgi.compendium/src/main/java/info/dmtree/notification/NotificationService.java
+++ /dev/null
@@ -1,99 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2004, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package info.dmtree.notification;
-
-import info.dmtree.DmtException;
-import info.dmtree.DmtSession;
-
-/**
- * NotificationService enables sending aynchronous notifications to a management
- * server. The implementation of <code>NotificationService</code> should
- * register itself in the OSGi service registry as a service.
- *
- * @version $Revision: 5673 $
- */
-public interface NotificationService {
-
- /**
- * Sends a notification to a named principal. It is the responsibility of
- * the <code>NotificationService</code> to route the notification to the
- * given principal using the registered
- * {@link info.dmtree.notification.spi.RemoteAlertSender} services.
- * <p>
- * In remotely initiated sessions the principal name identifies the remote
- * server that created the session, this can be obtained using the session's
- * {@link DmtSession#getPrincipal getPrincipal} call.
- * <p>
- * The principal name may be omitted if the client does not know the
- * principal name. Even in this case the routing might be possible if the
- * Notification Service finds an appropriate default destination (for
- * example if it is only connected to one protocol adapter, which is only
- * connected to one management server).
- * <p>
- * Since sending the notification and receiving acknowledgment for it is
- * potentially a very time-consuming operation, notifications are sent
- * asynchronously. This method should attempt to ensure that the
- * notification can be sent successfully, and should throw an exception if
- * it detects any problems. If the method returns without error, the
- * notification is accepted for sending and the implementation must make a
- * best-effort attempt to deliver it.
- * <p>
- * In case the notification is an asynchronous response to a previous
- * {@link DmtSession#execute(String, String, String) execute} command, a
- * correlation identifier can be specified to provide the association
- * between the execute and the notification.
- * <p>
- * In order to send a notification using this method, the caller must have
- * an <code>AlertPermission</code> with a target string matching the
- * specified principal name. If the <code>principal</code> parameter is
- * <code>null</code> (the principal name is not known), the target of the
- * <code>AlertPermission</code> must be "*".
- * <p>
- * When this method is called with all its parameters <code>null</code> or 0
- * (except <code>principal</code>), it should send a protocol
- * specific default notification to initiate a management session. For
- * example, in case of OMA DM this is alert 1201 "Client Initiated Session".
- * The <code>principal</code> parameter can be used to determine the
- * recipient of the session initiation request.
- *
- * @param principal the principal name which is the recipient of this
- * notification, can be <code>null</code>
- * @param code the alert code, can be 0 if not needed
- * @param correlator optional field that contains the correlation identifier
- * of an associated exec command, can be <code>null</code> if not
- * needed
- * @param items the data of the alert items carried in this alert, can be
- * <code>null</code> or empty if not needed
- * @throws DmtException with the following possible error codes:
- * <ul>
- * <li><code>UNAUTHORIZED</code> when the remote server rejected
- * the request due to insufficient authorization
- * <li><code>ALERT_NOT_ROUTED</code> when the alert can not be
- * routed to the given principal
- * <li><code>REMOTE_ERROR</code> in case of communication
- * problems between the device and the destination
- * <li><code>COMMAND_FAILED</code> for unspecified errors
- * encountered while attempting to complete the command
- * <li><code>FEATURE_NOT_SUPPORTED</code> if the underlying
- * management protocol doesn't support asynchronous notifications
- * </ul>
- * @throws SecurityException if the caller does not have the required
- * <code>AlertPermission</code> with a target matching the
- * <code>principal</code> parameter, as described above
- */
- void sendNotification(String principal, int code, String correlator,
- AlertItem[] items) throws DmtException;
-}
diff --git a/org.osgi.compendium/src/main/java/info/dmtree/notification/spi/RemoteAlertSender.java b/org.osgi.compendium/src/main/java/info/dmtree/notification/spi/RemoteAlertSender.java
deleted file mode 100644
index 8b7bac4..0000000
--- a/org.osgi.compendium/src/main/java/info/dmtree/notification/spi/RemoteAlertSender.java
+++ /dev/null
@@ -1,82 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2004, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package info.dmtree.notification.spi;
-
-import info.dmtree.notification.AlertItem;
-
-/**
- * The RemoteAlertSender can be used to send notifications to (remote) entities
- * identified by principal names. This service is provided by Protocol Adapters,
- * and is used by the {@link info.dmtree.notification.NotificationService} when
- * sending alerts. Implementations of this interface have to be able to connect
- * and send alerts to one or more management servers in a protocol specific way.
- * <p>
- * The properties of the service registration should specify a list of
- * destinations (principals) where the service is capable of sending alerts.
- * This can be done by providing a <code>String</code> array of principal names
- * in the <code>principals</code> registration property. If this property is not
- * registered, the service will be treated as the default sender. The default
- * alert sender is only used when a more specific alert sender cannot be found.
- * <p>
- * The <code>principals</code> registration property is used when the
- * {@link info.dmtree.notification.NotificationService#sendNotification} method
- * is called, to find the proper <code>RemoteAlertSender</code> for the given
- * destination. If the caller does not specify a principal, the alert is only
- * sent if the Notification Sender finds a default alert sender, or if the
- * choice is unambiguous for some other reason (for example if only one alert
- * sender is registered).
- *
- * @version $Revision: 5673 $
- */
-public interface RemoteAlertSender {
- /**
- * Sends an alert to a server identified by its principal name. In case the
- * alert is sent in response to a previous
- * {@link info.dmtree.DmtSession#execute(String, String, String) execute}
- * command, a correlation identifier can be specified to provide the
- * association between the execute and the alert.
- * <p>
- * The <code>principal</code> parameter specifies which server the alert
- * should be sent to. This parameter can be <code>null</code> if the
- * client does not know the name of the destination. The alert should still
- * be delivered if possible; for example if the alert sender is only
- * connected to one destination.
- * <p>
- * Any exception thrown on this method will be propagated to the original
- * sender of the event, wrapped in a <code>DmtException</code> with the
- * code <code>REMOTE_ERROR</code>.
- * <p>
- * Since sending the alert and receiving acknowledgment for it is
- * potentially a very time-consuming operation, alerts are sent
- * asynchronously. This method should attempt to ensure that the alert can
- * be sent successfully, and should throw an exception if it detects any
- * problems. If the method returns without error, the alert is accepted for
- * sending and the implementation must make a best-effort attempt to deliver
- * it.
- *
- * @param principal the name identifying the server where the alert should
- * be sent, can be <code>null</code>
- * @param code the alert code, can be 0 if not needed
- * @param correlator the correlation identifier of an associated EXEC
- * command, or <code>null</code> if there is no associated EXEC
- * @param items the data of the alert items carried in this alert, can be
- * empty or <code>null</code> if no alert items are needed
- * @throws Exception if the alert can not be sent to the server
- */
- void sendAlert(String principal, int code, String correlator,
- AlertItem[] items) throws Exception;
-}
diff --git a/org.osgi.compendium/src/main/java/info/dmtree/registry/DmtServiceFactory.java b/org.osgi.compendium/src/main/java/info/dmtree/registry/DmtServiceFactory.java
deleted file mode 100644
index b94634a..0000000
--- a/org.osgi.compendium/src/main/java/info/dmtree/registry/DmtServiceFactory.java
+++ /dev/null
@@ -1,95 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2004, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package info.dmtree.registry;
-
-import info.dmtree.DmtAdmin;
-import info.dmtree.notification.NotificationService;
-
-import org.osgi.framework.BundleContext;
-import org.osgi.framework.ServiceReference;
-
-/**
- * This class is the central access point for Device Management services.
- * Applications can use the static factory methods provided in this class to
- * obtain access to the different Device Management related services, such as
- * the DmtAdmin for manipulating the tree, or the Notification Service for
- * sending notifications to management servers.
- * <p>
- * These methods are not needed in an OSGi environment, clients should retrieve
- * the required service objects from the OSGi Service Registry.
- *
- * @version $Revision: 5673 $
- */
-public final class DmtServiceFactory {
- private static BundleContext context = null;
-
- /**
- * A private constructor to suppress the default public constructor.
- */
- private DmtServiceFactory() {}
-
- /**
- * This method is used to obtain access to <code>DmtAdmin</code>, which
- * enables applications to manipulate the Device Management Tree.
- *
- * @return a DmtAdmin service object
- */
- public static DmtAdmin getDmtAdmin() {
- if(context == null)
- throw new IllegalStateException("Cannot retrieve Dmt Admin " +
- "service, implementation bundle not started yet.");
-
- ServiceReference dmtAdminRef =
- context.getServiceReference(DmtAdmin.class.getName());
- if(dmtAdminRef == null)
- throw new IllegalStateException("Dmt Admin service not found in " +
- "service registry.");
-
- DmtAdmin dmtAdmin = (DmtAdmin) context.getService(dmtAdminRef);
- if(dmtAdmin == null)
- throw new IllegalStateException("Dmt Admin service not found in " +
- "service registry.");
-
- return dmtAdmin;
- }
-
- /**
- * This method is used to obtain access to <code>NotificationService</code>,
- * which enables applications to send asynchronous notifications to
- * management servers.
- *
- * @return a NotificationService service object
- */
- public static NotificationService getNotificationService() {
- if(context == null)
- throw new IllegalStateException("Cannot retrieve Notification " +
- "service, implementation bundle not started yet.");
-
- ServiceReference notificationServiceRef =
- context.getServiceReference(NotificationService.class.getName());
- if(notificationServiceRef == null)
- throw new IllegalStateException("Notification service not found " +
- "in service registry.");
-
- NotificationService notificationService =
- (NotificationService) context.getService(notificationServiceRef);
- if(notificationService == null)
- throw new IllegalStateException("Notification service not found " +
- "in service registry.");
-
- return notificationService;
- }
-}
diff --git a/org.osgi.compendium/src/main/java/info/dmtree/security/AlertPermission.java b/org.osgi.compendium/src/main/java/info/dmtree/security/AlertPermission.java
deleted file mode 100644
index 99395d5..0000000
--- a/org.osgi.compendium/src/main/java/info/dmtree/security/AlertPermission.java
+++ /dev/null
@@ -1,264 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2004, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package info.dmtree.security;
-
-import java.security.Permission;
-import java.security.PermissionCollection;
-import java.util.ArrayList;
-import java.util.Collections;
-import java.util.Enumeration;
-import java.util.Iterator;
-
-/**
- * Indicates the callers authority to send alerts to management servers,
- * identified by their principal names.
- * <p>
- * <code>AlertPermission</code> has a target string which controls the principal
- * names where alerts can be sent. A wildcard is allowed at the end of the
- * target string, to allow sending alerts to any principal with a name matching
- * the given prefix. The "*" target means that alerts can be sent to
- * any destination.
- *
- * @version $Revision: 5673 $
- */
-public class AlertPermission extends Permission {
- private static final long serialVersionUID = -3206463101788245739L;
-
- // specifies whether the target string had a wildcard at the end
- private final boolean isPrefix;
-
- // the target string without the wildcard (if there was one)
- private final String serverId;
-
- /**
- * Creates a new <code>AlertPermission</code> object with its name set to
- * the target string. Name must be non-null and non-empty.
- *
- * @param target the name of a principal, can end with <code>*</code> to
- * match any principal identifier with the given prefix
- * @throws NullPointerException if <code>name</code> is <code>null</code>
- * @throws IllegalArgumentException if <code>name</code> is empty
- */
- public AlertPermission(String target) {
- super(target);
-
- if (target == null)
- throw new NullPointerException(
- "'target' parameter must not be null.");
-
- if (target.equals(""))
- throw new IllegalArgumentException(
- "'target' parameter must not be empty.");
-
- isPrefix = target.endsWith("*");
- if (isPrefix)
- serverId = target.substring(0, target.length() - 1);
- else
- serverId = target;
- }
-
- /**
- * Creates a new <code>AlertPermission</code> object using the 'canonical'
- * two argument constructor. In this version this class does not define any
- * actions, the second argument of this constructor must be "*" so that this
- * class can later be extended in a backward compatible way.
- *
- * @param target the name of the server, can end with <code>*</code> to
- * match any server identifier with the given prefix
- * @param actions no actions defined, must be "*" for forward compatibility
- * @throws NullPointerException if <code>name</code> or
- * <code>actions</code> is <code>null</code>
- * @throws IllegalArgumentException if <code>name</code> is empty or
- * <code>actions</code> is not "*"
- */
- public AlertPermission(String target, String actions) {
- this(target);
-
- if (actions == null)
- throw new NullPointerException(
- "'actions' parameter must not be null.");
-
- if (!actions.equals("*"))
- throw new IllegalArgumentException(
- "'actions' parameter must be \"*\".");
- }
-
- /**
- * Checks whether the given object is equal to this AlertPermission
- * instance. Two AlertPermission instances are equal if they have the same
- * target string.
- *
- * @param obj the object to compare to this AlertPermission instance
- * @return <code>true</code> if the parameter represents the same
- * permissions as this instance
- */
- public boolean equals(Object obj) {
- if (obj == this)
- return true;
-
- if (!(obj instanceof AlertPermission))
- return false;
-
- AlertPermission other = (AlertPermission) obj;
-
- return isPrefix == other.isPrefix && serverId.equals(other.serverId);
- }
-
- /**
- * Returns the action list (always <code>*</code> in the current version).
- *
- * @return the action string "*"
- */
- public String getActions() {
- return "*";
- }
-
- /**
- * Returns the hash code for this permission object. If two AlertPermission
- * objects are equal according to the {@link #equals} method, then calling
- * this method on each of the two AlertPermission objects must produce the
- * same integer result.
- *
- * @return hash code for this permission object
- */
- public int hashCode() {
- return new Boolean(isPrefix).hashCode() ^ serverId.hashCode();
- }
-
- /**
- * Checks if this AlertPermission object implies the specified permission.
- * Another AlertPermission instance is implied by this permission either if
- * the target strings are identical, or if this target can be made identical
- * to the other target by replacing a trailing "*" with any
- * string.
- *
- * @param p the permission to check for implication
- * @return true if this AlertPermission instance implies the specified
- * permission
- */
- public boolean implies(Permission p) {
- if (!(p instanceof AlertPermission))
- return false;
-
- AlertPermission other = (AlertPermission) p;
-
- return impliesServer(other);
- }
-
- /**
- * Returns a new PermissionCollection object for storing AlertPermission
- * objects.
- *
- * @return the new PermissionCollection
- */
- public PermissionCollection newPermissionCollection() {
- return new DmtAlertPermissionCollection();
- }
-
- /*
- * Returns true if the server name parameter of the given AlertPermission is
- * implied by the server name of this permission, i.e. this server name is a
- * prefix of the other one but ends with a *, or the two server names are
- * equal.
- */
- boolean impliesServer(AlertPermission p) {
- return isPrefix ? p.serverId.startsWith(serverId) : !p.isPrefix
- && p.serverId.equals(serverId);
- }
-}
-
-/**
- * Represents a homogeneous collection of AlertPermission objects.
- */
-final class DmtAlertPermissionCollection extends PermissionCollection {
- private static final long serialVersionUID = 2288462124510043429L;
-
- private ArrayList perms;
-
- /**
- * Create an empty DmtAlertPermissionCollection object.
- */
- public DmtAlertPermissionCollection() {
- perms = new ArrayList();
- }
-
- /**
- * Adds a permission to the DmtAlertPermissionCollection.
- *
- * @param permission the Permission object to add
- * @exception IllegalArgumentException if the permission is not a
- * AlertPermission
- * @exception SecurityException if this DmtAlertPermissionCollection object
- * has been marked readonly
- */
- public void add(Permission permission) {
- if (!(permission instanceof AlertPermission))
- throw new IllegalArgumentException(
- "Cannot add permission, invalid permission type: "
- + permission);
- if (isReadOnly())
- throw new SecurityException(
- "Cannot add permission, collection is marked read-only.");
-
- // only add new permission if it is not already implied by the
- // permissions in the collection
- if (!implies(permission)) {
- // remove all permissions that are implied by the new one
- Iterator i = perms.iterator();
- while (i.hasNext())
- if (permission.implies((AlertPermission) i.next()))
- i.remove();
-
- // no need to synchronize because all adds are done sequentially
- // before any implies() calls
- perms.add(permission);
-
- }
- }
-
- /**
- * Check whether this set of permissions implies the permission specified in
- * the parameter.
- *
- * @param permission the Permission object to compare
- * @return true if the parameter permission is a proper subset of the
- * permissions in the collection, false otherwise
- */
- public boolean implies(Permission permission) {
- if (!(permission instanceof AlertPermission))
- return false;
-
- AlertPermission other = (AlertPermission) permission;
-
- Iterator i = perms.iterator();
- while (i.hasNext())
- if (((AlertPermission) i.next()).impliesServer(other))
- return true;
-
- return false;
- }
-
- /**
- * Returns an enumeration of all the AlertPermission objects in the
- * container. The returned value cannot be <code>null</code>.
- *
- * @return an enumeration of all the AlertPermission objects
- */
- public Enumeration elements() {
- // Convert Iterator into Enumeration
- return Collections.enumeration(perms);
- }
-}
diff --git a/org.osgi.compendium/src/main/java/info/dmtree/security/DmtPermission.java b/org.osgi.compendium/src/main/java/info/dmtree/security/DmtPermission.java
deleted file mode 100644
index 0415076..0000000
--- a/org.osgi.compendium/src/main/java/info/dmtree/security/DmtPermission.java
+++ /dev/null
@@ -1,445 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2004, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package info.dmtree.security;
-
-import info.dmtree.Acl;
-import info.dmtree.Uri;
-
-import java.security.Permission;
-import java.security.PermissionCollection;
-import java.util.ArrayList;
-import java.util.Collections;
-import java.util.Enumeration;
-import java.util.Iterator;
-import java.util.StringTokenizer;
-
-/**
- * Controls access to management objects in the Device Management Tree (DMT). It
- * is intended to control local access to the DMT. DmtPermission target string
- * identifies the management object URI and the action field lists the OMA DM
- * commands that are permitted on the management object. Example:
- *
- * <pre>
- * DmtPermission("./OSGi/bundles", "Add,Replace,Get");
- * </pre>
- *
- * This means that owner of this permission can execute Add, Replace and Get
- * commands on the ./OSGi/bundles management object. It is possible to use
- * wildcards in both the target and the actions field. Wildcard in the target
- * field means that the owner of the permission can access children nodes of the
- * target node. Example:
- *
- * <pre>
- * DmtPermission("./OSGi/bundles/*", "Get");
- * </pre>
- *
- * This means that owner of this permission has Get access on every child node
- * of ./OSGi/bundles. The asterix does not necessarily have to follow a '/'
- * character. For example the <code>"./OSGi/a*"</code> target matches
- * the <code>./OSGi/applications</code> subtree.
- * <p>
- * If wildcard is present in the actions field, all legal OMA DM commands are
- * allowed on the designated nodes(s) by the owner of the permission. Action
- * names are interpreted case-insensitively, but the canonical action string
- * returned by {@link #getActions} uses the forms defined by the action
- * constants.
- *
- * @version $Revision: 7942 $
- */
-public class DmtPermission extends Permission {
- private static final long serialVersionUID = -1910969921419407809L;
-
- /**
- * Holders of DmtPermission with the Add action present can create new nodes
- * in the DMT, that is they are authorized to execute the
- * createInteriorNode() and createLeafNode() methods of the DmtSession. This
- * action is also required for the copy() command, which needs to perform
- * node creation operations (among others).
- */
- public static final String ADD = "Add";
-
- /**
- * Holders of DmtPermission with the Delete action present can delete nodes
- * from the DMT, that is they are authorized to execute the deleteNode()
- * method of the DmtSession.
- */
- public static final String DELETE = "Delete";
-
- /**
- * Holders of DmtPermission with the Exec action present can execute nodes
- * in the DMT, that is they are authorized to call the execute() method of
- * the DmtSession.
- */
- public static final String EXEC = "Exec";
-
- /**
- * Holders of DmtPermission with the Get action present can query DMT node
- * value or properties, that is they are authorized to execute the
- * isLeafNode(), getNodeAcl(), getEffectiveNodeAcl(), getMetaNode(),
- * getNodeValue(), getChildNodeNames(), getNodeTitle(), getNodeVersion(),
- * getNodeTimeStamp(), getNodeSize() and getNodeType() methods of the
- * DmtSession. This action is also required for the copy() command, which
- * needs to perform node query operations (among others).
- */
- public static final String GET = "Get";
-
- /**
- * Holders of DmtPermission with the Replace action present can update DMT
- * node value or properties, that is they are authorized to execute the
- * setNodeAcl(), setNodeTitle(), setNodeValue(), setNodeType() and
- * renameNode() methods of the DmtSession. This action is also be required
- * for the copy() command if the original node had a title property (which
- * must be set in the new node).
- */
- public static final String REPLACE = "Replace";
-
- // does this permission have a wildcard at the end?
- private final boolean prefixPath;
-
- // the name without the wildcard on the end
- private final String path;
-
- // the actions mask
- private final int mask;
-
- // the canonical action string (redundant)
- private final String actions;
-
- /**
- * Creates a new DmtPermission object for the specified DMT URI with the
- * specified actions. The given URI can be:
- * <ul>
- * <li> <code>"*"</code>, which matches all valid
- * (see {@link Uri#isValidUri}) absolute URIs;
- * <li> the prefix of an absolute URI followed by the <code>*</code>
- * character (for example <code>"./OSGi/L*"</code>), which matches all valid
- * absolute URIs beginning with the given prefix;
- * <li> a valid absolute URI, which matches itself.
- * </ul>
- * <p>
- * Since the <code>*</code> character is itself a valid URI character, it
- * can appear as the last character of a valid absolute URI. To distinguish
- * this case from using <code>*</code> as a wildcard, the <code>*</code>
- * character at the end of the URI must be escaped with the <code>\</code>
- * charater. For example the URI <code>"./a*"</code> matches
- * <code>"./a"</code>, <code>"./aa"</code>, <code>"./a/b"</code> etc. while
- * <code>"./a\*"</code> matches <code>"./a*"</code> only.
- * <p>
- * The actions string must either be "*" to allow all actions, or it must
- * contain a non-empty subset of the valid actions, defined as constants in
- * this class.
- *
- * @param dmtUri URI of the management object (or subtree)
- * @param actions OMA DM actions allowed
- * @throws NullPointerException if any of the parameters are
- * <code>null</code>
- * @throws IllegalArgumentException if any of the parameters are invalid
- */
- public DmtPermission(String dmtUri, String actions) {
- super(dmtUri);
- mask = getMask(actions);
- this.actions = canonicalActions(mask);
-
- if (dmtUri == null)
- throw new NullPointerException("'dmtUri' parameter must not be " +
- "null.");
-
- prefixPath = dmtUri.endsWith("*") && !dmtUri.endsWith("\\*");
-
- if(prefixPath) {
- dmtUri = dmtUri.substring(0, dmtUri.length() - 1);
-
- // the single "*" as dmtUri is the only valid non-absolute URI param
- if(dmtUri.length() == 0) {
- path = "";
- return;
- }
- }
-
- // if URI ends with "/*", remove it before the validity check
- if(prefixPath && dmtUri.endsWith("/") && !dmtUri.endsWith("\\/"))
- checkUri(dmtUri.substring(0, dmtUri.length() - 1));
- else
- checkUri(dmtUri);
-
- // canonicalize URI: remove escapes from non-special characters
- StringBuffer sb = new StringBuffer(dmtUri);
- int i = 0;
- while(i < sb.length()) { // length can decrease during the loop!
- if(sb.charAt(i) == '\\') {
- // there must be a next character after a '\' in a valid URI
- char nextCh = sb.charAt(i+1);
- if(nextCh != '/' && nextCh != '\\')
- sb.deleteCharAt(i); // remove the extra '\'
- else
- i++;
- }
- i++;
- }
- path = sb.toString();
- }
-
- private void checkUri(String dmtUri) throws IllegalArgumentException {
- if(!Uri.isValidUri(dmtUri))
- throw new IllegalArgumentException("'dmtUri' parameter does not " +
- "contain a valid URI.");
-
- if(!Uri.isAbsoluteUri(dmtUri))
- throw new IllegalArgumentException("'dmtUri' parameter does not " +
- "contain an absolute URI.");
- }
-
- /**
- * Checks whether the given object is equal to this DmtPermission instance.
- * Two DmtPermission instances are equal if they have the same target string
- * and the same action mask. The "*" action mask is considered equal to a
- * mask containing all actions.
- *
- * @param obj the object to compare to this DmtPermission instance
- * @return <code>true</code> if the parameter represents the same
- * permissions as this instance
- */
- public boolean equals(Object obj) {
- if (obj == this)
- return true;
-
- if (!(obj instanceof DmtPermission))
- return false;
-
- DmtPermission other = (DmtPermission) obj;
-
- return mask == other.mask && prefixPath == other.prefixPath
- && path.equals(other.path);
- }
-
- /**
- * Returns the String representation of the action list. The allowed actions
- * are listed in the following order: Add, Delete, Exec, Get, Replace. The
- * wildcard character is not used in the returned string, even if the class
- * was created using the "*" wildcard.
- *
- * @return canonical action list for this permission object
- */
- public String getActions() {
- return actions;
- }
-
- /**
- * Returns the hash code for this permission object. If two DmtPermission
- * objects are equal according to the {@link #equals} method, then calling
- * this method on each of the two DmtPermission objects must produce the
- * same integer result.
- *
- * @return hash code for this permission object
- */
- public int hashCode() {
- return new Integer(mask).hashCode()
- ^ new Boolean(prefixPath).hashCode() ^ path.hashCode();
- }
-
- /**
- * Checks if this DmtPermission object "implies" the specified
- * permission. This method returns <code>false</code> if and only if at
- * least one of the following conditions are fulfilled for the specified
- * permission:
- * <ul>
- * <li>it is not a DmtPermission
- * <li>its set of actions contains an action not allowed by this permission
- * <li>the set of nodes defined by its path contains a node not defined by
- * the path of this permission
- * </ul>
- *
- * @param p the permission to check for implication
- * @return true if this DmtPermission instance implies the specified
- * permission
- */
- public boolean implies(Permission p) {
- if (!(p instanceof DmtPermission))
- return false;
-
- DmtPermission other = (DmtPermission) p;
-
- if ((mask & other.mask) != other.mask)
- return false;
-
- return impliesPath(other);
- }
-
- /**
- * Returns a new PermissionCollection object for storing DmtPermission
- * objects.
- *
- * @return the new PermissionCollection
- */
- public PermissionCollection newPermissionCollection() {
- return new DmtPermissionCollection();
- }
-
- // parses the given action string, and returns the corresponding action mask
- private static int getMask(String actions) {
- int mask = 0;
-
- if (actions == null)
- throw new NullPointerException(
- "'actions' parameter cannot be null.");
-
- if (actions.equals("*"))
- return Acl.ALL_PERMISSION;
-
- // empty tokens (swallowed by StringTokenizer) are not considered errors
- StringTokenizer st = new StringTokenizer(actions, ",");
- while (st.hasMoreTokens()) {
- String action = st.nextToken().trim();
- if (action.equalsIgnoreCase(GET)) {
- mask |= Acl.GET;
- } else if (action.equalsIgnoreCase(ADD)) {
- mask |= Acl.ADD;
- } else if (action.equalsIgnoreCase(REPLACE)) {
- mask |= Acl.REPLACE;
- } else if (action.equalsIgnoreCase(DELETE)) {
- mask |= Acl.DELETE;
- } else if (action.equalsIgnoreCase(EXEC)) {
- mask |= Acl.EXEC;
- } else
- throw new IllegalArgumentException("Invalid action '" + action
- + "'");
- }
-
- if (mask == 0)
- throw new IllegalArgumentException("Action mask cannot be empty.");
-
- return mask;
- }
-
- // generates the canonical string representation of the action list
- private static String canonicalActions(int mask) {
- StringBuffer sb = new StringBuffer();
- addAction(sb, mask, Acl.ADD, ADD);
- addAction(sb, mask, Acl.DELETE, DELETE);
- addAction(sb, mask, Acl.EXEC, EXEC);
- addAction(sb, mask, Acl.GET, GET);
- addAction(sb, mask, Acl.REPLACE, REPLACE);
- return sb.toString();
- }
-
- // if 'flag' appears in 'mask', appends the 'action' string to the contents
- // of 'sb', separated by a comma if needed
- private static void addAction(StringBuffer sb, int mask, int flag,
- String action) {
- if ((mask & flag) != 0) {
- if (sb.length() > 0)
- sb.append(',');
- sb.append(action);
- }
- }
-
- // used by DmtPermissionCollection to retrieve the action mask
- int getMask() {
- return mask;
- }
-
- // returns true if the path parameter of the given DmtPermission is
- // implied by the path of this permission, i.e. this path is a prefix of the
- // other path, but ends with a *, or the two path strings are equal
- boolean impliesPath(DmtPermission p) {
- return prefixPath ? p.path.startsWith(path) : !p.prefixPath
- && p.path.equals(path);
- }
-}
-
-/**
- * Represents a homogeneous collection of DmtPermission objects.
- */
-final class DmtPermissionCollection extends PermissionCollection {
- private static final long serialVersionUID = -4172481774562012941L;
-
- // OPTIMIZE keep a special flag for permissions of "*" path
-
- private ArrayList perms;
-
- /**
- * Create an empty DmtPermissionCollection object.
- */
- public DmtPermissionCollection() {
- perms = new ArrayList();
- }
-
- /**
- * Adds a permission to the DmtPermissionCollection.
- *
- * @param permission the Permission object to add
- * @exception IllegalArgumentException if the permission is not a
- * DmtPermission
- * @exception SecurityException if this DmtPermissionCollection object has
- * been marked readonly
- */
- public void add(Permission permission) {
- if (!(permission instanceof DmtPermission))
- throw new IllegalArgumentException(
- "Cannot add permission, invalid permission type: "
- + permission);
- if (isReadOnly())
- throw new SecurityException(
- "Cannot add permission, collection is marked read-only.");
-
- // No need to synchronize because all adds are done sequentially
- // before any implies() calls
- perms.add(permission);
- }
-
- /**
- * Check whether this set of permissions implies the permission specified in
- * the parameter.
- *
- * @param permission the Permission object to compare
- * @return true if the parameter permission is a proper subset of the
- * permissions in the collection, false otherwise
- */
- public boolean implies(Permission permission) {
- if (!(permission instanceof DmtPermission))
- return false;
-
- DmtPermission other = (DmtPermission) permission;
-
- int required = other.getMask();
- int available = 0;
- int needed = required;
-
- Iterator i = perms.iterator();
- while (i.hasNext()) {
- DmtPermission p = (DmtPermission) i.next();
- if (((needed & p.getMask()) != 0) && p.impliesPath(other)) {
- available |= p.getMask();
- if ((available & required) == required)
- return true;
- needed = (required ^ available);
- }
- }
-
- return false;
- }
-
- /**
- * Returns an enumeration of all the DmtPermission objects in the container.
- * The returned value cannot be <code>null</code>.
- *
- * @return an enumeration of all the DmtPermission objects
- */
- public Enumeration elements() {
- // Convert Iterator into Enumeration
- return Collections.enumeration(perms);
- }
-}
diff --git a/org.osgi.compendium/src/main/java/info/dmtree/security/DmtPrincipalPermission.java b/org.osgi.compendium/src/main/java/info/dmtree/security/DmtPrincipalPermission.java
deleted file mode 100644
index 9052454..0000000
--- a/org.osgi.compendium/src/main/java/info/dmtree/security/DmtPrincipalPermission.java
+++ /dev/null
@@ -1,266 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2004, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package info.dmtree.security;
-
-import java.security.Permission;
-import java.security.PermissionCollection;
-import java.util.ArrayList;
-import java.util.Collections;
-import java.util.Enumeration;
-import java.util.Iterator;
-
-/**
- * Indicates the callers authority to create DMT sessions on behalf of a remote
- * management server. Only protocol adapters communicating with management
- * servers should be granted this permission.
- * <p>
- * <code>DmtPrincipalPermission</code> has a target string which controls the
- * name of the principal on whose behalf the protocol adapter can act. A
- * wildcard is allowed at the end of the target string, to allow using any
- * principal name with the given prefix. The "*" target means the
- * adapter can create a session in the name of any principal.
- *
- * @version $Revision: 5673 $
- */
-public class DmtPrincipalPermission extends Permission {
- private static final long serialVersionUID = 6388752177325038332L;
-
- // specifies whether the target string had a wildcard at the end
- private final boolean isPrefix;
-
- // the target string without the wildcard (if there was one)
- private final String principal;
-
- /**
- * Creates a new <code>DmtPrincipalPermission</code> object with its name
- * set to the target string. Name must be non-null and non-empty.
- *
- * @param target the name of the principal, can end with <code>*</code> to
- * match any principal with the given prefix
- * @throws NullPointerException if <code>name</code> is <code>null</code>
- * @throws IllegalArgumentException if <code>name</code> is empty
- */
- public DmtPrincipalPermission(String target) {
- super(target);
-
- if (target == null)
- throw new NullPointerException(
- "'target' parameter must not be null.");
-
- if (target.equals(""))
- throw new IllegalArgumentException(
- "'target' parameter must not be empty.");
-
- isPrefix = target.endsWith("*");
- if (isPrefix)
- principal = target.substring(0, target.length() - 1);
- else
- principal = target;
- }
-
- /**
- * Creates a new <code>DmtPrincipalPermission</code> object using the
- * 'canonical' two argument constructor. In this version this class does not
- * define any actions, the second argument of this constructor must be "*"
- * so that this class can later be extended in a backward compatible way.
- *
- * @param target the name of the principal, can end with <code>*</code> to
- * match any principal with the given prefix
- * @param actions no actions defined, must be "*" for forward compatibility
- * @throws NullPointerException if <code>name</code> or
- * <code>actions</code> is <code>null</code>
- * @throws IllegalArgumentException if <code>name</code> is empty or
- * <code>actions</code> is not "*"
- */
- public DmtPrincipalPermission(String target, String actions) {
- this(target);
-
- if (actions == null)
- throw new NullPointerException(
- "'actions' parameter must not be null.");
-
- if (!actions.equals("*"))
- throw new IllegalArgumentException(
- "'actions' parameter must be \"*\".");
- }
-
- /**
- * Checks whether the given object is equal to this DmtPrincipalPermission
- * instance. Two DmtPrincipalPermission instances are equal if they have the
- * same target string.
- *
- * @param obj the object to compare to this DmtPrincipalPermission instance
- * @return <code>true</code> if the parameter represents the same
- * permissions as this instance
- */
- public boolean equals(Object obj) {
- if (obj == this)
- return true;
-
- if (!(obj instanceof DmtPrincipalPermission))
- return false;
-
- DmtPrincipalPermission other = (DmtPrincipalPermission) obj;
-
- return isPrefix == other.isPrefix && principal.equals(other.principal);
- }
-
- /**
- * Returns the action list (always <code>*</code> in the current version).
- *
- * @return the action string "*"
- */
- public String getActions() {
- return "*";
- }
-
- /**
- * Returns the hash code for this permission object. If two
- * DmtPrincipalPermission objects are equal according to the {@link #equals}
- * method, then calling this method on each of the two
- * DmtPrincipalPermission objects must produce the same integer result.
- *
- * @return hash code for this permission object
- */
- public int hashCode() {
- return new Boolean(isPrefix).hashCode() ^ principal.hashCode();
- }
-
- /**
- * Checks if this DmtPrincipalPermission object implies the specified
- * permission. Another DmtPrincipalPermission instance is implied by this
- * permission either if the target strings are identical, or if this target
- * can be made identical to the other target by replacing a trailing
- * "*" with any string.
- *
- * @param p the permission to check for implication
- * @return true if this DmtPrincipalPermission instance implies the
- * specified permission
- */
- public boolean implies(Permission p) {
- if (!(p instanceof DmtPrincipalPermission))
- return false;
-
- DmtPrincipalPermission other = (DmtPrincipalPermission) p;
-
- return impliesPrincipal(other);
- }
-
- /**
- * Returns a new PermissionCollection object for storing
- * DmtPrincipalPermission objects.
- *
- * @return the new PermissionCollection
- */
- public PermissionCollection newPermissionCollection() {
- return new DmtPrincipalPermissionCollection();
- }
-
- /*
- * Returns true if the principal parameter of the given
- * DmtPrincipalPermission is implied by the principal of this permission,
- * i.e. this principal is a prefix of the other principal but ends with a *,
- * or the two principal strings are equal.
- */
- boolean impliesPrincipal(DmtPrincipalPermission p) {
- return isPrefix ? p.principal.startsWith(principal) : !p.isPrefix
- && p.principal.equals(principal);
- }
-}
-
-/**
- * Represents a homogeneous collection of DmtPrincipalPermission objects.
- */
-final class DmtPrincipalPermissionCollection extends PermissionCollection {
- private static final long serialVersionUID = -6692103535775802684L;
-
- private ArrayList perms;
-
- /**
- * Create an empty DmtPrincipalPermissionCollection object.
- */
- public DmtPrincipalPermissionCollection() {
- perms = new ArrayList();
- }
-
- /**
- * Adds a permission to the DmtPrincipalPermissionCollection.
- *
- * @param permission the Permission object to add
- * @exception IllegalArgumentException if the permission is not a
- * DmtPrincipalPermission
- * @exception SecurityException if this DmtPrincipalPermissionCollection
- * object has been marked readonly
- */
- public void add(Permission permission) {
- if (!(permission instanceof DmtPrincipalPermission))
- throw new IllegalArgumentException(
- "Cannot add permission, invalid permission type: "
- + permission);
- if (isReadOnly())
- throw new SecurityException(
- "Cannot add permission, collection is marked read-only.");
-
- // only add new permission if it is not already implied by the
- // permissions in the collection
- if (!implies(permission)) {
- // remove all permissions that are implied by the new one
- Iterator i = perms.iterator();
- while (i.hasNext())
- if (permission.implies((DmtPrincipalPermission) i.next()))
- i.remove();
-
- // no need to synchronize because all adds are done sequentially
- // before any implies() calls
- perms.add(permission);
-
- }
- }
-
- /**
- * Check whether this set of permissions implies the permission specified in
- * the parameter.
- *
- * @param permission the Permission object to compare
- * @return true if the parameter permission is a proper subset of the
- * permissions in the collection, false otherwise
- */
- public boolean implies(Permission permission) {
- if (!(permission instanceof DmtPrincipalPermission))
- return false;
-
- DmtPrincipalPermission other = (DmtPrincipalPermission) permission;
-
- Iterator i = perms.iterator();
- while (i.hasNext())
- if (((DmtPrincipalPermission) i.next()).impliesPrincipal(other))
- return true;
-
- return false;
- }
-
- /**
- * Returns an enumeration of all the DmtPrincipalPermission objects in the
- * container. The returned value cannot be <code>null</code>.
- *
- * @return an enumeration of all the DmtPrincipalPermission objects
- */
- public Enumeration elements() {
- // Convert Iterator into Enumeration
- return Collections.enumeration(perms);
- }
-}
diff --git a/org.osgi.compendium/src/main/java/info/dmtree/spi/DataPlugin.java b/org.osgi.compendium/src/main/java/info/dmtree/spi/DataPlugin.java
deleted file mode 100644
index 19fe359..0000000
--- a/org.osgi.compendium/src/main/java/info/dmtree/spi/DataPlugin.java
+++ /dev/null
@@ -1,137 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2004, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package info.dmtree.spi;
-
-import info.dmtree.DmtException;
-import info.dmtree.DmtSession;
-
-/**
- * An implementation of this interface takes the responsibility of handling data
- * requests in a subtree of the DMT.
- * <p>
- * In an OSGi environment such implementations should be registered at the OSGi
- * service registry specifying the list of root node URIs in a
- * <code>String</code> array in the <code>dataRootURIs</code> registration
- * parameter.
- * <p>
- * When the first reference in a session is made to a node handled by this
- * plugin, the DmtAdmin calls one of the <code>open...</code> methods to
- * retrieve a plugin session object for processing the request. The called
- * method depends on the lock type of the current session. In case of
- * {@link #openReadWriteSession(String[], DmtSession)} and
- * {@link #openAtomicSession(String[], DmtSession)}, the plugin may return
- * <code>null</code> to indicate that the specified lock type is not supported.
- * In this case the DmtAdmin may call
- * {@link #openReadOnlySession(String[], DmtSession)} to start a read-only
- * plugin session, which can be used as long as there are no write operations on
- * the nodes handled by this plugin.
- * <p>
- * The <code>sessionRoot</code> parameter of each method is a String array
- * containing the segments of the URI pointing to the root of the session. This
- * is an absolute path, so the first segment is always ".". Special
- * characters appear escaped in the segments.
- * <p>
- *
- * @version $Revision: 5673 $
- */
-public interface DataPlugin {
-
- /**
- * This method is called to signal the start of a read-only session when the
- * first reference is made within a <code>DmtSession</code> to a node
- * which is handled by this plugin. Session information is given as it is
- * needed for sending alerts back from the plugin.
- * <p>
- * The plugin can assume that there are no writing sessions open on any
- * subtree that has any overlap with the subtree of this session.
- *
- * @param sessionRoot the path to the subtree which is accessed in the
- * current session, must not be <code>null</code>
- * @param session the session from which this plugin instance is accessed,
- * must not be <code>null</code>
- * @return a plugin session capable of executing read operations
- * @throws DmtException with the following possible error codes:
- * <ul>
- * <li><code>NODE_NOT_FOUND</code> if <code>sessionRoot</code>
- * points to a non-existing node
- * <li><code>COMMAND_FAILED</code> if some unspecified error is
- * encountered while attempting to complete the command
- * </ul>
- * @throws SecurityException if some underlying operation failed because of
- * lack of permissions
- */
- ReadableDataSession openReadOnlySession(String[] sessionRoot,
- DmtSession session) throws DmtException;
-
- /**
- * This method is called to signal the start of a non-atomic read-write
- * session when the first reference is made within a <code>DmtSession</code>
- * to a node which is handled by this plugin. Session information is given
- * as it is needed for sending alerts back from the plugin.
- * <p>
- * The plugin can assume that there are no other sessions open on any
- * subtree that has any overlap with the subtree of this session.
- *
- * @param sessionRoot the path to the subtree which is locked in the current
- * session, must not be <code>null</code>
- * @param session the session from which this plugin instance is accessed,
- * must not be <code>null</code>
- * @return a plugin session capable of executing read-write operations, or
- * <code>null</code> if the plugin does not support non-atomic
- * read-write sessions
- * @throws DmtException with the following possible error codes:
- * <ul>
- * <li><code>NODE_NOT_FOUND</code> if <code>sessionRoot</code>
- * points to a non-existing node
- * <li><code>COMMAND_FAILED</code> if some unspecified error is
- * encountered while attempting to complete the command
- * </ul>
- * @throws SecurityException if some underlying operation failed because of
- * lack of permissions
- */
- ReadWriteDataSession openReadWriteSession(String[] sessionRoot,
- DmtSession session) throws DmtException;
-
- /**
- * This method is called to signal the start of an atomic read-write session
- * when the first reference is made within a <code>DmtSession</code> to a
- * node which is handled by this plugin. Session information is given as it
- * is needed for sending alerts back from the plugin.
- * <p>
- * The plugin can assume that there are no other sessions open on any
- * subtree that has any overlap with the subtree of this session.
- *
- * @param sessionRoot the path to the subtree which is locked in the current
- * session, must not be <code>null</code>
- * @param session the session from which this plugin instance is accessed,
- * must not be <code>null</code>
- * @return a plugin session capable of executing read-write operations in an
- * atomic block, or <code>null</code> if the plugin does not
- * support atomic read-write sessions
- * @throws DmtException with the following possible error codes:
- * <ul>
- * <li><code>NODE_NOT_FOUND</code> if <code>sessionRoot</code>
- * points to a non-existing node
- * <li><code>COMMAND_FAILED</code> if some unspecified error is
- * encountered while attempting to complete the command
- * </ul>
- * @throws SecurityException if some underlying operation failed because of
- * lack of permissions
- */
- TransactionalDataSession openAtomicSession(String[] sessionRoot,
- DmtSession session) throws DmtException;
-}
diff --git a/org.osgi.compendium/src/main/java/info/dmtree/spi/ExecPlugin.java b/org.osgi.compendium/src/main/java/info/dmtree/spi/ExecPlugin.java
deleted file mode 100644
index c72784c..0000000
--- a/org.osgi.compendium/src/main/java/info/dmtree/spi/ExecPlugin.java
+++ /dev/null
@@ -1,74 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2004, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package info.dmtree.spi;
-
-import info.dmtree.DmtException;
-import info.dmtree.DmtSession;
-
-/**
- * An implementation of this interface takes the responsibility of handling node
- * execute requests requests in a subtree of the DMT.
- * <p>
- * In an OSGi environment such implementations should be registered at the OSGi
- * service registry specifying the list of root node URIs in a
- * <code>String</code> array in the <code>execRootURIs</code> registration
- * parameter.
- *
- * @version $Revision: 5673 $
- */
-public interface ExecPlugin {
-
- /**
- * Execute the given node with the given data. This operation corresponds to
- * the EXEC command in OMA DM.
- * <p>
- * The semantics of an execute operation and the data parameter it takes
- * depends on the definition of the managed object on which the command is
- * issued. Session information is given as it is needed for sending alerts
- * back from the plugin. If a correlation ID is specified, it should be used
- * as the <code>correlator</code> parameter for alerts sent in response to
- * this execute operation.
- * <p>
- * The <code>nodePath</code> parameter contains an array of path segments
- * identifying the node to be executed in the subtree of this plugin. This
- * is an absolute path, so the first segment is always ".".
- * Special characters appear escaped in the segments.
- *
- * @param session a reference to the session in which the operation was
- * issued, must not be <code>null</code>
- * @param nodePath the absolute path of the node to be executed, must not be
- * <code>null</code>
- * @param correlator an identifier to associate this operation with any
- * alerts sent in response to it, can be <code>null</code>
- * @param data the parameter of the execute operation, can be
- * <code>null</code>
- * @throws DmtException with the following possible error codes:
- * <ul>
- * <li><code>NODE_NOT_FOUND</code> if the node does not exist and
- * the plugin does not allow executing unexisting nodes
- * <li><code>METADATA_MISMATCH</code> if the command failed
- * because of meta-data restrictions
- * <li><code>DATA_STORE_FAILURE</code> if an error occurred while
- * accessing the data store
- * <li><code>COMMAND_FAILED</code> if some unspecified error is
- * encountered while attempting to complete the command
- * </ul>
- * @see DmtSession#execute(String, String)
- * @see DmtSession#execute(String, String, String)
- */
- void execute(DmtSession session, String[] nodePath, String correlator,
- String data) throws DmtException;
-}
diff --git a/org.osgi.compendium/src/main/java/info/dmtree/spi/ReadWriteDataSession.java b/org.osgi.compendium/src/main/java/info/dmtree/spi/ReadWriteDataSession.java
deleted file mode 100644
index 3ec4a56..0000000
--- a/org.osgi.compendium/src/main/java/info/dmtree/spi/ReadWriteDataSession.java
+++ /dev/null
@@ -1,299 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2004, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package info.dmtree.spi;
-
-import info.dmtree.DmtData;
-import info.dmtree.DmtException;
-import info.dmtree.DmtSession;
-import info.dmtree.MetaNode;
-
-/**
- * Provides non-atomic read-write access to the part of the tree handled by the
- * plugin that created this session.
- * <p>
- * The <code>nodePath</code> parameters appearing in this interface always
- * contain an array of path segments identifying a node in the subtree of this
- * plugin. This parameter contains an absolute path, so the first segment is
- * always ".". Special characters appear escaped in the segments.
- * <p>
- * <strong>Error handling</strong>
- * <p>
- * When a tree manipulation command is called on the DmtAdmin service, it must
- * perform an extensive set of checks on the parameters and the authority of the
- * caller before delegating the call to a plugin. Therefore plugins can take
- * certain circumstances for granted: that the path is valid and is within the
- * subtree of the plugin and the session, the command can be applied to the
- * given node (e.g. the target of <code>setNodeValue</code> is a leaf node),
- * etc. All errors described by the error codes {@link DmtException#INVALID_URI}, {@link DmtException#URI_TOO_LONG}, {@link DmtException#PERMISSION_DENIED},
- * {@link DmtException#COMMAND_NOT_ALLOWED} and
- * {@link DmtException#TRANSACTION_ERROR} are fully filtered out before control
- * reaches the plugin.
- * <p>
- * If the plugin provides meta-data for a node, the DmtAdmin service must also
- * check the constraints specified by it, as described in {@link MetaNode}. If
- * the plugin does not provide meta-data, it must perform the necessary checks
- * for itself and use the {@link DmtException#METADATA_MISMATCH} error code to
- * indicate such discrepancies.
- * <p>
- * The DmtAdmin also ensures that the targeted nodes exist before calling the
- * plugin (or that they do not exist, in case of node creation). However, some
- * small amount of time elapses between the check and the call, so in case of
- * plugins where the node structure can change independantly from the DMT, the
- * target node might appear/disappear in that time. For example, a whole subtree
- * can disappear when a Monitorable application is unregistered, which might
- * happen in the middle of a DMT session accessing it. Plugins managing such
- * nodes always need to check the existance or non-existance of nodes and throw
- * {@link DmtException#NODE_NOT_FOUND} or
- * {@link DmtException#NODE_ALREADY_EXISTS} as necessary, but for more static
- * subtrees there is no need for the plugin to use these error codes.
- * <p>
- * The plugin can use the remaining error codes as needed. If an error does not
- * fit into any other category, the {@link DmtException#COMMAND_FAILED} code
- * should be used.
- *
- * @version $Revision: 5673 $
- */
-public interface ReadWriteDataSession extends ReadableDataSession {
-
- /**
- * Create a copy of a node or a whole subtree. Beside the structure and
- * values of the nodes, most properties managed by the plugin must also be
- * copied, with the exception of the Timestamp and Version properties.
- *
- * @param nodePath an absolute path specifying the node or the root of a
- * subtree to be copied
- * @param newNodePath the absolute path of the new node or root of a subtree
- * @param recursive <code>false</code> if only a single node is copied,
- * <code>true</code> if the whole subtree is copied
- * @throws DmtException with the following possible error codes:
- * <ul>
- * <li><code>NODE_NOT_FOUND</code> if <code>nodePath</code>
- * points to a non-existing node, or if <code>newNodePath</code>
- * points to a node that cannot exist in the tree
- * <li><code>NODE_ALREADY_EXISTS</code> if
- * <code>newNodePath</code> points to a node that already exists
- * <li><code>METADATA_MISMATCH</code> if the node could not be
- * copied because of meta-data restrictions
- * <li><code>FEATURE_NOT_SUPPORTED</code> if the copy operation
- * is not supported by the plugin
- * <li><code>DATA_STORE_FAILURE</code> if an error occurred while
- * accessing the data store
- * <li><code>COMMAND_FAILED</code> if some unspecified error is
- * encountered while attempting to complete the command
- * </ul>
- * @throws SecurityException if the caller does not have the necessary
- * permissions to execute the underlying management operation
- * @see DmtSession#copy(String, String, boolean)
- */
- void copy(String[] nodePath, String[] newNodePath, boolean recursive)
- throws DmtException;
-
- /**
- * Create an interior node with a given type. The type of interior node, if
- * specified, is a URI identifying a DDF document.
- *
- * @param nodePath the absolute path of the node to create
- * @param type the type URI of the interior node, can be <code>null</code>
- * if no node type is defined
- * @throws DmtException with the following possible error codes:
- * <ul>
- * <li><code>NODE_NOT_FOUND</code> if <code>nodePath</code>
- * points to a node that cannot exist in the tree
- * <li><code>NODE_ALREADY_EXISTS</code> if <code>nodeUri</code>
- * points to a node that already exists
- * <li><code>METADATA_MISMATCH</code> if the node could not be
- * created because of meta-data restrictions
- * <li><code>DATA_STORE_FAILURE</code> if an error occurred while
- * accessing the data store
- * <li><code>COMMAND_FAILED</code> if some unspecified error is
- * encountered while attempting to complete the command
- * </ul>
- * @throws SecurityException if the caller does not have the necessary
- * permissions to execute the underlying management operation
- * @see DmtSession#createInteriorNode(String)
- * @see DmtSession#createInteriorNode(String, String)
- */
- void createInteriorNode(String[] nodePath, String type) throws DmtException;
-
- /**
- * Create a leaf node with a given value and MIME type. If the specified
- * value or MIME type is <code>null</code>, their default values must be
- * taken.
- *
- * @param nodePath the absolute path of the node to create
- * @param value the value to be given to the new node, can be
- * <code>null</code>
- * @param mimeType the MIME type to be given to the new node, can be
- * <code>null</code>
- * @throws DmtException with the following possible error codes:
- * <ul>
- * <li><code>NODE_NOT_FOUND</code> if <code>nodePath</code>
- * points to a node that cannot exist in the tree
- * <li><code>NODE_ALREADY_EXISTS</code> if <code>nodePath</code>
- * points to a node that already exists
- * <li><code>METADATA_MISMATCH</code> if the node could not be
- * created because of meta-data restrictions
- * <li><code>DATA_STORE_FAILURE</code> if an error occurred while
- * accessing the data store
- * <li><code>COMMAND_FAILED</code> if some unspecified error is
- * encountered while attempting to complete the command
- * </ul>
- * @throws SecurityException if the caller does not have the necessary
- * permissions to execute the underlying management operation
- * @see DmtSession#createLeafNode(String)
- * @see DmtSession#createLeafNode(String, DmtData)
- * @see DmtSession#createLeafNode(String, DmtData, String)
- */
- void createLeafNode(String[] nodePath, DmtData value, String mimeType)
- throws DmtException;
-
- /**
- * Delete the given node. Deleting interior nodes is recursive, the whole
- * subtree under the given node is deleted.
- *
- * @param nodePath the absolute path of the node to delete
- * @throws DmtException with the following possible error codes:
- * <ul>
- * <li><code>NODE_NOT_FOUND</code> if <code>nodePath</code>
- * points to a non-existing node
- * <li><code>METADATA_MISMATCH</code> if the node could not be
- * deleted because of meta-data restrictions
- * <li><code>DATA_STORE_FAILURE</code> if an error occurred while
- * accessing the data store
- * <li><code>COMMAND_FAILED</code> if some unspecified error is
- * encountered while attempting to complete the command
- * </ul>
- * @throws SecurityException if the caller does not have the necessary
- * permissions to execute the underlying management operation
- * @see DmtSession#deleteNode(String)
- */
- void deleteNode(String[] nodePath) throws DmtException;
-
- /**
- * Rename a node. This operation only changes the name of the node (updating
- * the timestamp and version properties if they are supported), the value
- * and the other properties are not changed. The new name of the node must
- * be provided, the new path is constructed from the base of the old path
- * and the given name.
- *
- * @param nodePath the absolute path of the node to rename
- * @param newName the new name property of the node
- * @throws DmtException with the following possible error codes:
- * <ul>
- * <li><code>NODE_NOT_FOUND</code> if <code>nodePath</code>
- * points to a non-existing node, or if the new node is not defined
- * in the tree
- * <li><code>NODE_ALREADY_EXISTS</code> if there already exists a
- * sibling of <code>nodePath</code> with the name
- * <code>newName</code>
- * <li><code>METADATA_MISMATCH</code> if the node could not be
- * renamed because of meta-data restrictions
- * <li><code>DATA_STORE_FAILURE</code> if an error occurred while
- * accessing the data store
- * <li><code>COMMAND_FAILED</code> if some unspecified error is
- * encountered while attempting to complete the command
- * </ul>
- * @throws SecurityException if the caller does not have the necessary
- * permissions to execute the underlying management operation
- * @see DmtSession#renameNode(String, String)
- */
- void renameNode(String[] nodePath, String newName) throws DmtException;
-
- /**
- * Set the title property of a node. The length of the title is guaranteed
- * not to exceed the limit of 255 bytes in UTF-8 encoding.
- *
- * @param nodePath the absolute path of the node
- * @param title the title text of the node, can be <code>null</code>
- * @throws DmtException with the following possible error codes:
- * <ul>
- * <li><code>NODE_NOT_FOUND</code> if <code>nodePath</code>
- * points to a non-existing node
- * <li><code>METADATA_MISMATCH</code> if the title could not be
- * set because of meta-data restrictions
- * <li><code>FEATURE_NOT_SUPPORTED</code> if the Title property
- * is not supported by the plugin
- * <li><code>DATA_STORE_FAILURE</code> if an error occurred while
- * accessing the data store
- * <li><code>COMMAND_FAILED</code> if some unspecified error is
- * encountered while attempting to complete the command
- * </ul>
- * @throws SecurityException if the caller does not have the necessary
- * permissions to execute the underlying management operation
- * @see DmtSession#setNodeTitle(String, String)
- */
- void setNodeTitle(String[] nodePath, String title) throws DmtException;
-
- /**
- * Set the type of a node. The type of leaf node is the MIME type of the
- * data it contains. The type of an interior node is a URI identifying a DDF
- * document.
- * <p>
- * For interior nodes, the <code>null</code> type should remove the
- * reference (if any) to a DDF document overriding the tree structure
- * defined by the ancestors. For leaf nodes, it requests that the default
- * MIME type is used for the given node.
- *
- * @param nodePath the absolute path of the node
- * @param type the type of the node, can be <code>null</code>
- * @throws DmtException with the following possible error codes:
- * <ul>
- * <li><code>NODE_NOT_FOUND</code> if <code>nodePath</code>
- * points to a non-existing node
- * <li><code>METADATA_MISMATCH</code> if the type could not be
- * set because of meta-data restrictions
- * <li><code>DATA_STORE_FAILURE</code> if an error occurred while
- * accessing the data store
- * <li><code>COMMAND_FAILED</code> if some unspecified error is
- * encountered while attempting to complete the command
- * </ul>
- * @throws SecurityException if the caller does not have the necessary
- * permissions to execute the underlying management operation
- * @see DmtSession#setNodeType(String, String)
- */
- void setNodeType(String[] nodePath, String type) throws DmtException;
-
- /**
- * Set the value of a leaf or interior node. The format of the node is
- * contained in the <code>DmtData</code> object. For interior nodes, the
- * format is <code>FORMAT_NODE</code>, while for leaf nodes this format is
- * never used.
- * <p>
- * If the specified value is <code>null</code>, the default value must be
- * taken; if there is no default value, a <code>DmtException</code> with
- * error code <code>METADATA_MISMATCH</code> must be thrown.
- *
- * @param nodePath the absolute path of the node
- * @param data the data to be set, can be <code>null</code>
- * @throws DmtException with the following possible error codes:
- * <ul>
- * <li><code>NODE_NOT_FOUND</code> if <code>nodePath</code>
- * points to a non-existing node
- * <li><code>METADATA_MISMATCH</code> if the value could not be
- * set because of meta-data restrictions
- * <li><code>FEATURE_NOT_SUPPORTED</code> if the specified node is
- * an interior node and does not support Java object values
- * <li><code>DATA_STORE_FAILURE</code> if an error occurred while
- * accessing the data store
- * <li><code>COMMAND_FAILED</code> if some unspecified error is
- * encountered while attempting to complete the command
- * </ul>
- * @throws SecurityException if the caller does not have the necessary
- * permissions to execute the underlying management operation
- * @see DmtSession#setNodeValue(String, DmtData)
- */
- void setNodeValue(String[] nodePath, DmtData data) throws DmtException;
-}
diff --git a/org.osgi.compendium/src/main/java/info/dmtree/spi/ReadableDataSession.java b/org.osgi.compendium/src/main/java/info/dmtree/spi/ReadableDataSession.java
deleted file mode 100644
index 389e989..0000000
--- a/org.osgi.compendium/src/main/java/info/dmtree/spi/ReadableDataSession.java
+++ /dev/null
@@ -1,361 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2004, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package info.dmtree.spi;
-
-import info.dmtree.DmtData;
-import info.dmtree.DmtException;
-import info.dmtree.MetaNode;
-
-import java.util.Date;
-
-/**
- * Provides read-only access to the part of the tree handled by the plugin that
- * created this session.
- * <p>
- * Since the {@link ReadWriteDataSession} and {@link TransactionalDataSession}
- * interfaces inherit from this interface, some of the method descriptions do
- * not apply for an instance that is only a <code>ReadableDataSession</code>.
- * For example, the {@link #close} method description also contains information
- * about its behaviour when invoked as part of a transactional session.
- * <p>
- * The <code>nodePath</code> parameters appearing in this interface always
- * contain an array of path segments identifying a node in the subtree of this
- * plugin. This parameter contains an absolute path, so the first segment is
- * always ".". Special characters appear escaped in the segments.
- * <p>
- * <strong>Error handling</strong>
- * <p>
- * When a tree access command is called on the DmtAdmin service, it must perform
- * an extensive set of checks on the parameters and the authority of the caller
- * before delegating the call to a plugin. Therefore plugins can take certain
- * circumstances for granted: that the path is valid and is within the subtree
- * of the plugin and the session, the command can be applied to the given node
- * (e.g. the target of <code>getChildNodeNames</code> is an interior node), etc.
- * All errors described by the error codes {@link DmtException#INVALID_URI},
- * {@link DmtException#URI_TOO_LONG}, {@link DmtException#PERMISSION_DENIED},
- * {@link DmtException#COMMAND_NOT_ALLOWED} and
- * {@link DmtException#TRANSACTION_ERROR} are fully filtered out before control
- * reaches the plugin.
- * <p>
- * If the plugin provides meta-data for a node, the DmtAdmin service must also
- * check the constraints specified by it, as described in {@link MetaNode}. If
- * the plugin does not provide meta-data, it must perform the necessary checks
- * for itself and use the {@link DmtException#METADATA_MISMATCH} error code to
- * indicate such discrepancies.
- * <p>
- * The DmtAdmin also ensures that the targeted nodes exist before calling the
- * plugin (except, of course, before the <code>isNodeUri</code> call). However,
- * some small amount of time elapses between the check and the call, so in case
- * of plugins where the node structure can change independantly from the DMT,
- * the target node might disappear in that time. For example, a whole subtree
- * can disappear when a Monitorable application is unregistered, which might
- * happen in the middle of a DMT session accessing it. Plugins managing such
- * nodes always need to check whether they still exist and throw
- * {@link DmtException#NODE_NOT_FOUND} as necessary, but for more static
- * subtrees there is no need for the plugin to use this error code.
- * <p>
- * The plugin can use the remaining error codes as needed. If an error does not
- * fit into any other category, the {@link DmtException#COMMAND_FAILED} code
- * should be used.
- *
- * @version $Revision: 5673 $
- */
-public interface ReadableDataSession {
- /**
- * Notifies the plugin that the given node has changed outside the scope of
- * the plugin, therefore the Version and Timestamp properties must be
- * updated (if supported). This method is needed because the ACL property of
- * a node is managed by the DmtAdmin instead of the plugin. The DmtAdmin
- * must call this method whenever the ACL property of a node changes.
- *
- * @param nodePath the absolute path of the node that has changed
- * @throws DmtException with the following possible error codes:
- * <ul>
- * <li><code>NODE_NOT_FOUND</code> if <code>nodePath</code>
- * points to a non-existing node
- * <li><code>DATA_STORE_FAILURE</code> if an error occurred while
- * accessing the data store
- * <li><code>COMMAND_FAILED</code> if some unspecified error is
- * encountered while attempting to complete the command
- * </ul>
- */
- void nodeChanged(String[] nodePath) throws DmtException;
-
- /**
- * Closes a session. This method is always called when the session ends for
- * any reason: if the session is closed, if a fatal error occurs in any
- * method, or if any error occurs during commit or rollback. In case the
- * session was invalidated due to an exception during commit or rollback, it
- * is guaranteed that no methods are called on the plugin until it is
- * closed. In case the session was invalidated due to a fatal exception in
- * one of the tree manipulation methods, only the rollback method is called
- * before this (and only in atomic sessions).
- * <p>
- * This method should not perform any data manipulation, only cleanup
- * operations. In non-atomic read-write sessions the data manipulation
- * should be done instantly during each tree operation, while in atomic
- * sessions the <code>DmtAdmin</code> always calls
- * {@link TransactionalDataSession#commit} automatically before the session
- * is actually closed.
- *
- * @throws DmtException with the error code <code>COMMAND_FAILED</code> if
- * the plugin failed to close for any reason
- */
- void close() throws DmtException;
-
- /**
- * Get the list of children names of a node. The returned array contains the
- * names - not the URIs - of the immediate children nodes of the given node.
- * The returned child names must be mangled ({@link info.dmtree.Uri#mangle(String)}).
- * The returned array may contain <code>null</code> entries, but these are
- * removed by the DmtAdmin before returning it to the client.
- *
- * @param nodePath the absolute path of the node
- * @return the list of child node names as a string array or an empty string
- * array if the node has no children
- * @throws DmtException with the following possible error codes:
- * <ul>
- * <li><code>NODE_NOT_FOUND</code> if <code>nodePath</code>
- * points to a non-existing node
- * <li><code>METADATA_MISMATCH</code> if the information could
- * not be retrieved because of meta-data restrictions
- * <li><code>DATA_STORE_FAILURE</code> if an error occurred while
- * accessing the data store
- * <li><code>COMMAND_FAILED</code> if some unspecified error is
- * encountered while attempting to complete the command
- * </ul>
- * @throws SecurityException if the caller does not have the necessary
- * permissions to execute the underlying management operation
- */
- String[] getChildNodeNames(String[] nodePath) throws DmtException;
-
- /**
- * Get the meta data which describes a given node. Meta data can be only
- * inspected, it can not be changed.
- * <p>
- * Meta data support by plugins is an optional feature. It can be used, for
- * example, when a data plugin is implemented on top of a data store or
- * another API that has their own metadata, such as a relational database,
- * in order to avoid metadata duplication and inconsistency. The meta data
- * specific to the plugin returned by this method is complemented by meta
- * data from the DmtAdmin before returning it to the client. If there are
- * differences in the meta data elements known by the plugin and the
- * <code>DmtAdmin</code> then the plugin specific elements take
- * precedence.
- * <p>
- * Note, that a node does not have to exist for having meta-data associated
- * with it. This method may provide meta-data for any node that can possibly
- * exist in the tree (any node defined by the Management Object provided by
- * the plugin). For nodes that are not defined, a <code>DmtException</code>
- * may be thrown with the <code>NODE_NOT_FOUND</code> error code. To allow
- * easier implementation of plugins that do not provide meta-data, it is
- * allowed to return <code>null</code> for any node, regardless of whether
- * it is defined or not.
- *
- * @param nodePath the absolute path of the node
- * @return a MetaNode which describes meta data information, can be
- * <code>null</code> if there is no meta data available for the
- * given node
- * @throws DmtException with the following possible error codes:
- * <ul>
- * <li><code>NODE_NOT_FOUND</code> if <code>nodeUri</code>
- * points to a node that is not defined in the tree (see above)
- * <li><code>DATA_STORE_FAILURE</code> if an error occurred while
- * accessing the data store
- * <li><code>COMMAND_FAILED</code> if some unspecified error is
- * encountered while attempting to complete the command
- * </ul>
- * @throws SecurityException if the caller does not have the necessary
- * permissions to execute the underlying management operation
- */
- MetaNode getMetaNode(String[] nodePath) throws DmtException;
-
- /**
- * Get the size of the data in a leaf node. The value to return depends on
- * the format of the data in the node, see the description of the
- * {@link DmtData#getSize()} method for the definition of node size for each
- * format.
- *
- * @param nodePath the absolute path of the leaf node
- * @return the size of the data in the node
- * @throws DmtException with the following possible error codes:
- * <ul>
- * <li><code>NODE_NOT_FOUND</code> if <code>nodePath</code>
- * points to a non-existing node
- * <li><code>METADATA_MISMATCH</code> if the information could
- * not be retrieved because of meta-data restrictions
- * <li><code>FEATURE_NOT_SUPPORTED</code> if the Size property is
- * not supported by the plugin
- * <li><code>DATA_STORE_FAILURE</code> if an error occurred while
- * accessing the data store
- * <li><code>COMMAND_FAILED</code> if some unspecified error is
- * encountered while attempting to complete the command
- * </ul>
- * @throws SecurityException if the caller does not have the necessary
- * permissions to execute the underlying management operation
- * @see DmtData#getSize
- */
- int getNodeSize(String[] nodePath) throws DmtException;
-
- /**
- * Get the timestamp when the node was last modified.
- *
- * @param nodePath the absolute path of the node
- * @return the timestamp of the last modification
- * @throws DmtException with the following possible error codes:
- * <ul>
- * <li><code>NODE_NOT_FOUND</code> if <code>nodePath</code>
- * points to a non-existing node
- * <li><code>METADATA_MISMATCH</code> if the information could
- * not be retrieved because of meta-data restrictions
- * <li><code>FEATURE_NOT_SUPPORTED</code> if the Timestamp
- * property is not supported by the plugin
- * <li><code>DATA_STORE_FAILURE</code> if an error occurred while
- * accessing the data store
- * <li><code>COMMAND_FAILED</code> if some unspecified error is
- * encountered while attempting to complete the command
- * </ul>
- * @throws SecurityException if the caller does not have the necessary
- * permissions to execute the underlying management operation
- */
- Date getNodeTimestamp(String[] nodePath) throws DmtException;
-
- /**
- * Get the title of a node. There might be no title property set for a node.
- *
- * @param nodePath the absolute path of the node
- * @return the title of the node, or <code>null</code> if the node has no
- * title
- * @throws DmtException with the following possible error codes:
- * <ul>
- * <li><code>NODE_NOT_FOUND</code> if <code>nodePath</code>
- * points to a non-existing node
- * <li><code>METADATA_MISMATCH</code> if the information could
- * not be retrieved because of meta-data restrictions
- * <li><code>FEATURE_NOT_SUPPORTED</code> if the Title property
- * is not supported by the plugin
- * <li><code>DATA_STORE_FAILURE</code> if an error occurred while
- * accessing the data store
- * <li><code>COMMAND_FAILED</code> if some unspecified error is
- * encountered while attempting to complete the command
- * </ul>
- * @throws SecurityException if the caller does not have the necessary
- * permissions to execute the underlying management operation
- */
- String getNodeTitle(String[] nodePath) throws DmtException;
-
- /**
- * Get the type of a node. The type of leaf node is the MIME type of the
- * data it contains. The type of an interior node is a URI identifying a DDF
- * document; a <code>null</code> type means that there is no DDF document
- * overriding the tree structure defined by the ancestors.
- *
- * @param nodePath the absolute path of the node
- * @return the type of the node, can be <code>null</code>
- * @throws DmtException with the following possible error codes:
- * <ul>
- * <li><code>NODE_NOT_FOUND</code> if <code>nodePath</code>
- * points to a non-existing node
- * <li><code>METADATA_MISMATCH</code> if the information could
- * not be retrieved because of meta-data restrictions
- * <li><code>DATA_STORE_FAILURE</code> if an error occurred while
- * accessing the data store
- * <li><code>COMMAND_FAILED</code> if some unspecified error is
- * encountered while attempting to complete the command
- * </ul>
- * @throws SecurityException if the caller does not have the necessary
- * permissions to execute the underlying management operation
- */
- String getNodeType(String[] nodePath) throws DmtException;
-
- /**
- * Check whether the specified path corresponds to a valid node in the DMT.
- *
- * @param nodePath the absolute path to check
- * @return true if the given node exists in the DMT
- */
- boolean isNodeUri(String[] nodePath);
-
- /**
- * Tells whether a node is a leaf or an interior node of the DMT.
- *
- * @param nodePath the absolute path of the node
- * @return true if the given node is a leaf node
- * @throws DmtException with the following possible error codes:
- * <ul>
- * <li><code>NODE_NOT_FOUND</code> if <code>nodePath</code>
- * points to a non-existing node
- * <li><code>METADATA_MISMATCH</code> if the information could
- * not be retrieved because of meta-data restrictions
- * <li><code>DATA_STORE_FAILURE</code> if an error occurred while
- * accessing the data store
- * <li><code>COMMAND_FAILED</code> if some unspecified error is
- * encountered while attempting to complete the command
- * </ul>
- * @throws SecurityException if the caller does not have the necessary
- * permissions to execute the underlying management operation
- */
- boolean isLeafNode(String[] nodePath) throws DmtException;
-
- /**
- * Get the data contained in a leaf or interior node.
- *
- * @param nodePath the absolute path of the node to retrieve
- * @return the data of the leaf node, must not be <code>null</code>
- * @throws DmtException with the following possible error codes:
- * <ul>
- * <li><code>NODE_NOT_FOUND</code> if <code>nodePath</code>
- * points to a non-existing node
- * <li><code>METADATA_MISMATCH</code> if the information could
- * not be retrieved because of meta-data restrictions
- * <li><code>FEATURE_NOT_SUPPORTED</code> if the specified node is
- * an interior node and does not support Java object values
- * <li><code>DATA_STORE_FAILURE</code> if an error occurred while
- * accessing the data store
- * <li><code>COMMAND_FAILED</code> if some unspecified error is
- * encountered while attempting to complete the command
- * </ul>
- * @throws SecurityException if the caller does not have the necessary
- * permissions to execute the underlying management operation
- */
- DmtData getNodeValue(String[] nodePath) throws DmtException;
-
- /**
- * Get the version of a node. The version can not be set, it is calculated
- * automatically by the device. It is incremented modulo 0x10000 at every
- * modification of the value or any other property of the node, for both
- * leaf and interior nodes. When a node is created the initial value is 0.
- *
- * @param nodePath the absolute path of the node
- * @return the version of the node
- * @throws DmtException with the following possible error codes:
- * <ul>
- * <li><code>NODE_NOT_FOUND</code> if <code>nodePath</code>
- * points to a non-existing node
- * <li><code>METADATA_MISMATCH</code> if the information could
- * not be retrieved because of meta-data restrictions
- * <li><code>FEATURE_NOT_SUPPORTED</code> if the Version property
- * is not supported by the plugin
- * <li><code>DATA_STORE_FAILURE</code> if an error occurred while
- * accessing the data store
- * <li><code>COMMAND_FAILED</code> if some unspecified error is
- * encountered while attempting to complete the command
- * </ul>
- * @throws SecurityException if the caller does not have the necessary
- * permissions to execute the underlying management operation
- */
- int getNodeVersion(String[] nodePath) throws DmtException;
-}
diff --git a/org.osgi.compendium/src/main/java/info/dmtree/spi/TransactionalDataSession.java b/org.osgi.compendium/src/main/java/info/dmtree/spi/TransactionalDataSession.java
deleted file mode 100644
index 477bd05..0000000
--- a/org.osgi.compendium/src/main/java/info/dmtree/spi/TransactionalDataSession.java
+++ /dev/null
@@ -1,77 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2004, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package info.dmtree.spi;
-
-import info.dmtree.DmtException;
-
-/**
- * Provides atomic read-write access to the part of the tree handled by the
- * plugin that created this session.
- *
- * @version $Revision: 5673 $
- */
-public interface TransactionalDataSession extends ReadWriteDataSession {
-
- /**
- * Commits a series of DMT operations issued in the current atomic session
- * since the last transaction boundary. Transaction boundaries are the
- * creation of this object that starts the session, and all subsequent
- * {@link #commit} and {@link #rollback} calls.
- * <p>
- * This method can fail even if all operations were successful. This can
- * happen due to some multi-node semantic constraints defined by a specific
- * implementation. For example, node A can be required to always have
- * children A/B, A/C and A/D. If this condition is broken when
- * <code>commit()</code> is executed, the method will fail, and throw a
- * <code>METADATA_MISMATCH</code> exception.
- * <p>
- * In many cases the tree is not the only way to manage a given part of the
- * system. It may happen that while modifying some nodes in an atomic
- * session, the underlying settings are modified parallelly outside the
- * scope of the DMT. If this is detected during commit, an exception with
- * the code <code>CONCURRENT_ACCESS</code> is thrown.
- *
- * @throws DmtException with the following possible error codes
- * <ul>
- * <li><code>METADATA_MISMATCH</code> if the operation failed
- * because of meta-data restrictions
- * <li><code>CONCURRENT_ACCESS</code> if it is detected that some
- * modification has been made outside the scope of the DMT to the
- * nodes affected in the session's operations
- * <li><code>DATA_STORE_FAILURE</code> if an error occurred while
- * accessing the data store
- * <li><code>COMMAND_FAILED</code> if some unspecified error is
- * encountered while attempting to complete the command
- * </ul>
- * @throws SecurityException if the caller does not have the necessary
- * permissions to execute the underlying management operation
- */
- void commit() throws DmtException;
-
- /**
- * Rolls back a series of DMT operations issued in the current atomic
- * session since the last transaction boundary. Transaction boundaries are
- * the creation of this object that starts the session, and all subsequent
- * {@link #commit} and {@link #rollback} calls.
- *
- * @throws DmtException with the error code <code>ROLLBACK_FAILED</code>
- * in case the rollback did not succeed
- * @throws SecurityException if the caller does not have the necessary
- * permissions to execute the underlying management operation
- */
- void rollback() throws DmtException;
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/application/ApplicationContext.java b/org.osgi.compendium/src/main/java/org/osgi/application/ApplicationContext.java
deleted file mode 100644
index 2420faf..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/application/ApplicationContext.java
+++ /dev/null
@@ -1,353 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2005, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.osgi.application;
-
-import java.util.Dictionary;
-import java.util.Map;
-
-import org.osgi.framework.Constants;
-import org.osgi.framework.ServiceRegistration;
-
-/**
- * <code>ApplicationContext</code> is the access point for an OSGi-aware
- * application to the features of the OSGi Service Platform. Each application
- * instance will have its own <code>ApplicationContext</code> instance, which
- * will not be reused after destroying the corresponding application instance.
- * <p>
- * Application instances can obtain their <code>ApplicationContext</code> using
- * the {@link Framework#getApplicationContext} method.
- * <p>
- * The lifecycle of an <code>ApplicationContext</code> instance is bound to the
- * lifecycle of the corresponding application instance. The
- * <code>ApplicationContext</code> becomes available when the application is
- * started and it is invalidated when the application instance is stopped (i.e.
- * the "stop" method of the application activator object returned). All method
- * calls (except {@link #getApplicationId()} and {@link #getInstanceId()}) to an
- * invalidated context object result an <code>IllegalStateException</code>.
- *
- * @see org.osgi.application.Framework
- *
- * @version $Revision: 7937 $
- */
-public interface ApplicationContext {
-
- /**
- * Adds the specified {@link ApplicationServiceListener} object to this context
- * application instance's list of listeners. The specified <code>referenceName</code> is a
- * reference name specified in the descriptor of the corresponding application. The registered
- * <code>listener> will only receive the {@link ApplicationServiceEvent}s related to the referred service.
- * <p>
- * If the <code>listener</code> was already added, calling this method will overwrite the previous
- * registration.
- * <p>
- *
- * @param listener
- * The {@link org.osgi.application.ApplicationServiceListener} to be added. It must
- * not be <code>null</code>
- * @param referenceName the reference name of a service from the descriptor of the corresponding
- * application. It must not be <code>null</code>.
- * @throws java.lang.IllegalStateException
- * If this context application instance has stopped.
- * @throws java.lang.NullPointerException If <code>listener</code> or <code>referenceName</code>
- * is <code>null</code>
- * @throws java.lang.IllegalArgumentException If there is no service in the
- * application descriptor with the specified <code>referenceName</code>.
- */
- public void addServiceListener(ApplicationServiceListener listener, String referenceName) throws java.lang.IllegalArgumentException;
-
- /**
- * Adds the specified {@link ApplicationServiceListener} object to this context
- * application instance's list of listeners. The <code>referenceNames</code> parameter is an
- * array of reference name specified in the descriptor of the corresponding application. The registered
- * <code>listener> will only receive the {@link ApplicationServiceEvent}s related to the referred
- * services.
- * <p>
- * If the <code>listener</code> was already added, calling this method will overwrite the previous
- * registration.
- * <p>
- *
- * @param listener
- * The {@link org.osgi.application.ApplicationServiceListener} to be added. It must not
- * be <code>null</code>
- * @param referenceNames and array of service reference names from the descriptor of the corresponding
- * application. It must not be <code>null</code> and it must not be empty.
- * @throws java.lang.IllegalStateException
- * If this context application instance has stopped.
- * @throws java.lang.NullPointerException If <code>listener</code> or <code>referenceNames</code>
- * is <code>null</code>
- * @throws java.lang.IllegalArgumentException If <code>referenceNames</code> array is empty or it
- * contains unknown references
- */
- public void addServiceListener(ApplicationServiceListener listener, String[] referenceNames) throws java.lang.IllegalArgumentException;
-
- /**
- * Removes the specified {@link org.osgi.application.ApplicationServiceListener} object from this
- * context application instances's list of listeners.
- * <p>
- * If <code>listener</code> is not contained in this context application
- * instance's list of listeners, this method does nothing.
- *
- * @param listener
- * The {@link org.osgi.application.ApplicationServiceListener} object to be removed.
- * @throws java.lang.IllegalStateException
- * If this context application instance has stopped.
- */
- public void removeServiceListener(ApplicationServiceListener listener);
-
- /**
- * This method returns the identifier of the corresponding application instance.
- * This identifier is guaranteed to be unique within the scope of the device.
- *
- * Note: this method can safely be called on an invalid
- * <code>ApplicationContext</code> as well.
- *
- * @see org.osgi.service.application.ApplicationHandle#getInstanceId()
- *
- * @return the unique identifier of the corresponding application instance
- */
- public String getInstanceId();
-
- /**
- * This method return the identifier of the corresponding application type. This identifier
- * is the same for the different instances of the same application but it is different for
- * different application type.
- * <p>
- * Note: this method can safely be called on an invalid
- * <code>ApplicationContext</code> as well.
- *
- * @see org.osgi.service.application.ApplicationDescriptor#getApplicationId()
- *
- * @return the identifier of the application type.
- */
- public String getApplicationId();
-
- /**
- * This method returns the service object for the specified
- * <code>referenceName</code>. If the cardinality of the reference is
- * 0..n or 1..n and multiple services are bound to the reference, the
- * service with the highest ranking (as specified in its
- * {@link org.osgi.framework.Constants#SERVICE_RANKING} property) is returned. If there
- * is a tie in ranking, the service with the lowest service ID (as specified
- * in its {@link org.osgi.framework.Constants#SERVICE_ID} property); that is, the
- * service that was registered first is returned.
- *
- * @param referenceName
- * The name of a reference as specified in a reference element in
- * this context applications's description. It must not be <code>null</code>
- * @return A service object for the referenced service or <code>null</code>
- * if the reference cardinality is 0..1 or 0..n and no bound service
- * is available.
- * @throws java.lang.NullPointerException If <code>referenceName</code> is <code>null</code>.
- * @throws java.lang.IllegalArgumentException If there is no service in the
- * application descriptor with the specified <code>referenceName</code>.
- * @throws java.lang.IllegalStateException
- * If this context application instance has stopped.
- */
- public Object locateService(String referenceName);
-
- /**
- * This method returns the service objects for the specified
- * <code>referenceName</code>.
- *
- * @param referenceName
- * The name of a reference as specified in a reference element in
- * this context applications's description. It must not be
- * <code>null</code>.
- * @return An array of service object for the referenced service or
- * <code>null</code> if the reference cardinality is 0..1 or 0..n
- * and no bound service is available.
- * @throws java.lang.NullPointerException If <code>referenceName</code> is <code>null</code>.
- * @throws java.lang.IllegalArgumentException If there is no service in the
- * application descriptor with the specified <code>referenceName</code>.
- * @throws java.lang.IllegalStateException
- * If this context application instance has stopped.
- */
- public Object[] locateServices(String referenceName);
-
- /**
- * Returns the startup parameters specified when calling the
- * {@link org.osgi.service.application.ApplicationDescriptor#launch}
- * method.
- * <p>
- * Startup arguments can be specified as name, value pairs. The name
- * must be of type {@link java.lang.String}, which must not be
- * <code>null</code> or empty {@link java.lang.String} (<code>""</code>),
- * the value can be any object including <code>null</code>.
- *
- * @return a {@link java.util.Map} containing the startup arguments.
- * It can be <code>null</code>.
- * @throws java.lang.IllegalStateException
- * If this context application instance has stopped.
- */
- public Map getStartupParameters();
-
- /**
- * Application can query the service properties of a service object
- * it is bound to. Application gets bound to a service object when
- * it first obtains a reference to the service by calling
- * <code>locateService</code> or <code>locateServices</code> methods.
- *
- * @param serviceObject A service object the application is bound to.
- * It must not be null.
- * @return The service properties associated with the specified service
- * object.
- * @throws NullPointerException if the specified <code>serviceObject</code>
- * is <code>null</code>
- * @throws IllegalArgumentException if the application is not
- * bound to the specified service object or it is not a service
- * object at all.
- * @throws java.lang.IllegalStateException
- * If this context application instance has stopped.
- */
- public Map getServiceProperties(Object serviceObject);
-
-
- /**
- * Registers the specified service object with the specified properties
- * under the specified class names into the Framework. A
- * {@link org.osgi.framework.ServiceRegistration} object is returned. The
- * {@link org.osgi.framework.ServiceRegistration} object is for the private use of the
- * application registering the service and should not be shared with other
- * applications. The registering application is defined to be the context application.
- * Bundles can locate the service by using either the
- * {@link org.osgi.framework.BundleContext#getServiceReferences} or
- * {@link org.osgi.framework.BundleContext#getServiceReference} method. Other applications
- * can locate this service by using {@link #locateService(String)} or {@link #locateServices(String)}
- * method, if they declared their dependence on the registered service.
- *
- * <p>
- * An application can register a service object that implements the
- * {@link org.osgi.framework.ServiceFactory} interface to have more flexibility in providing
- * service objects to other applications or bundles.
- *
- * <p>
- * The following steps are required to register a service:
- * <ol>
- * <li>If <code>service</code> is not a <code>ServiceFactory</code>,
- * an <code>IllegalArgumentException</code> is thrown if
- * <code>service</code> is not an <code>instanceof</code> all the
- * classes named.
- * <li>The Framework adds these service properties to the specified
- * <code>Dictionary</code> (which may be <code>null</code>): a property
- * named {@link org.osgi.framework.Constants#SERVICE_ID} identifying the registration number of
- * the service and a property named {@link org.osgi.framework.Constants#OBJECTCLASS} containing
- * all the specified classes. If any of these properties have already been
- * specified by the registering bundle, their values will be overwritten by
- * the Framework.
- * <li>The service is added to the Framework service registry and may now
- * be used by others.
- * <li>A service event of type {@link org.osgi.framework.ServiceEvent#REGISTERED} is
- * fired. This event triggers the corresponding {@link ApplicationServiceEvent} to be
- * delivered to the applications that registered the appropriate listener.
- * <li>A <code>ServiceRegistration</code> object for this registration is
- * returned.
- * </ol>
- *
- * @param clazzes The class names under which the service can be located.
- * The class names in this array will be stored in the service's
- * properties under the key {@link org.osgi.framework.Constants#OBJECTCLASS}.
- * This parameter must not be <code>null</code>.
- * @param service The service object or a <code>ServiceFactory</code>
- * object.
- * @param properties The properties for this service. The keys in the
- * properties object must all be <code>String</code> objects. See
- * {@link org.osgi.framework.Constants} for a list of standard service property keys.
- * Changes should not be made to this object after calling this
- * method. To update the service's properties the
- * {@link org.osgi.framework.ServiceRegistration#setProperties} method must be called.
- * The set of properties may be <code>null</code> if the service
- * has no properties.
- *
- * @return A {@link org.osgi.framework.ServiceRegistration} object for use by the application
- * registering the service to update the service's properties or to
- * unregister the service.
- *
- * @throws java.lang.IllegalArgumentException If one of the following is
- * true:
- * <ul>
- * <li><code>service</code> is <code>null</code>.
- * <li><code>service</code> is not a <code>ServiceFactory</code>
- * object and is not an instance of all the named classes in
- * <code>clazzes</code>.
- * <li><code>properties</code> contains case variants of the same
- * key name.
- * </ul>
- * @throws NullPointerException if <code>clazzes</code> is <code>null</code>
- *
- * @throws java.lang.SecurityException If the caller does not have the
- * <code>ServicePermission</code> to register the service for all
- * the named classes and the Java Runtime Environment supports
- * permissions.
- *
- * @throws java.lang.IllegalStateException If this ApplicationContext is no
- * longer valid.
- *
- * @see org.osgi.framework.BundleContext#registerService(java.lang.String[], java.lang.Object, java.util.Dictionary)
- * @see org.osgi.framework.ServiceRegistration
- * @see org.osgi.framework.ServiceFactory
- */
- public ServiceRegistration registerService(String[] clazzes,
- Object service, Dictionary properties);
-
- /**
- * Registers the specified service object with the specified properties
- * under the specified class name with the Framework.
- *
- * <p>
- * This method is otherwise identical to
- * {@link #registerService(java.lang.String[], java.lang.Object,
- * java.util.Dictionary)} and is provided as a convenience when
- * <code>service</code> will only be registered under a single class name.
- * Note that even in this case the value of the service's
- * {@link Constants#OBJECTCLASS} property will be an array of strings,
- * rather than just a single string.
- *
- * @param clazz The class name under which the service can be located. It
- * must not be <code>null</code>
- * @param service The service object or a <code>ServiceFactory</code>
- * object.
- * @param properties The properties for this service.
- *
- * @return A <code>ServiceRegistration</code> object for use by the application
- * registering the service to update the service's properties or to
- * unregister the service.
- *
- * @throws java.lang.IllegalArgumentException If one of the following is
- * true:
- * <ul>
- * <li><code>service</code> is <code>null</code>.
- * <li><code>service</code> is not a <code>ServiceFactory</code>
- * object and is not an instance of the named class in
- * <code>clazz</code>.
- * <li><code>properties</code> contains case variants of the same
- * key name.
- * </ul>
- * @throws NullPointerException if <code>clazz</code> is <code>null</code>
- *
- * @throws java.lang.SecurityException If the caller does not have the
- * <code>ServicePermission</code> to register the service
- * the named class and the Java Runtime Environment supports
- * permissions.
- *
- * @throws java.lang.IllegalStateException If this ApplicationContext is no
- * longer valid.
- * @see #registerService(java.lang.String[], java.lang.Object,
- * java.util.Dictionary)
- */
- public ServiceRegistration registerService(String clazz, Object service,
- Dictionary properties);
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/application/ApplicationServiceEvent.java b/org.osgi.compendium/src/main/java/org/osgi/application/ApplicationServiceEvent.java
deleted file mode 100644
index f5ab444..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/application/ApplicationServiceEvent.java
+++ /dev/null
@@ -1,81 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2005, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.osgi.application;
-
-import org.osgi.framework.ServiceEvent;
-import org.osgi.framework.ServiceReference;
-
-/**
- * An event from the Framework describing a service lifecycle change.
- * <p>
- * <code>ApplicationServiceEvent</code> objects are delivered to a
- * <code>ApplicationServiceListener</code> objects when a change occurs in this service's
- * lifecycle. The delivery of an <code>ApplicationServiceEvent</code> is
- * always triggered by a {@link org.osgi.framework.ServiceEvent}.
- * <code>ApplicationServiceEvent</code> extends the content of <code>ServiceEvent</code>
- * with the service object the event is referring to as applications has no means to
- * find the corresponding service object for a {@link org.osgi.framework.ServiceReference}.
- * A type code is used to identify the event type for future
- * extendability. The available type codes are defined in {@link org.osgi.framework.ServiceEvent}.
- *
- * <p>
- * OSGi Alliance reserves the right to extend the set of types.
- *
- * @see org.osgi.framework.ServiceEvent
- * @see ApplicationServiceListener
- *
- * @version $Revision: 7937 $
- */
-public class ApplicationServiceEvent extends ServiceEvent {
-
- private static final long serialVersionUID = -4762149286971897323L;
- final Object serviceObject;
-
- /**
- * Creates a new application service event object.
- *
- * @param type The event type. Available type codes are defines in
- * {@link org.osgi.framework.ServiceEvent}
- * @param reference A <code>ServiceReference</code> object to the service
- * that had a lifecycle change. This reference will be used as the <code>source</code>
- * in the {@link java.util.EventObject} baseclass, therefore, it must not be
- * null.
- * @param serviceObject The service object bound to this application instance. It can
- * be <code>null</code> if this application is not bound to this service yet.
- * @throws IllegalArgumentException if the specified <code>reference</code> is null.
- */
- public ApplicationServiceEvent(int type, ServiceReference reference, Object serviceObject) {
- super(type, reference);
- this.serviceObject = serviceObject;
- }
-
- /**
- * This method returns the service object of this service bound to the listener
- * application instance. A service object becomes bound to the application when it
- * first obtains a service object reference to that service by calling the
- * <code>ApplicationContext.locateService</code> or <code>locateServices</code>
- * methods. If the application is not bound to the service yet, this method returns
- * <code>null</code>.
- *
- * @return the service object bound to the listener application or <code>null</code>
- * if it isn't bound to this service yet.
- */
- public Object getServiceObject() {
- return this.serviceObject;
- }
-
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/application/ApplicationServiceListener.java b/org.osgi.compendium/src/main/java/org/osgi/application/ApplicationServiceListener.java
deleted file mode 100644
index eb7f0c7..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/application/ApplicationServiceListener.java
+++ /dev/null
@@ -1,66 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2005, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.osgi.application;
-
-import java.util.EventListener;
-
-import org.osgi.framework.*;
-
-/**
- * An <code>ApplicationServiceEvent</code> listener. When a
- * <code>ServiceEvent</code> is
- * fired, it is converted to an <code>ApplictionServiceEvent</code>
- * and it is synchronously delivered to an <code>ApplicationServiceListener</code>.
- *
- * <p>
- * <code>ApplicationServiceListener</code> is a listener interface that may be
- * implemented by an application developer.
- * <p>
- * An <code>ApplicationServiceListener</code> object is registered with the Framework
- * using the <code>ApplicationContext.addServiceListener</code> method.
- * <code>ApplicationServiceListener</code> objects are called with an
- * <code>ApplicationServiceEvent</code> object when a service is registered, modified, or
- * is in the process of unregistering.
- *
- * <p>
- * <code>ApplicationServiceEvent</code> object delivery to
- * <code>ApplicationServiceListener</code>
- * objects is filtered by the filter specified when the listener was registered.
- * If the Java Runtime Environment supports permissions, then additional
- * filtering is done. <code>ApplicationServiceEvent</code> objects are only delivered to
- * the listener if the application which defines the listener object's class has the
- * appropriate <code>ServicePermission</code> to get the service using at
- * least one of the named classes the service was registered under, and the application
- * specified its dependence on the corresponding service in the application metadata.
- *
- * <p>
- * <code>ApplicationServiceEvent</code> object delivery to <code>ApplicationServiceListener</code>
- * objects is further filtered according to package sources as defined in
- * {@link ServiceReference#isAssignableTo(Bundle, String)}.
- *
- * @version $Revision: 7937 $
- * @see ApplicationServiceEvent
- * @see ServicePermission
- */
-public interface ApplicationServiceListener extends EventListener {
- /**
- * Receives notification that a service has had a lifecycle change.
- *
- * @param event The <code>ApplicationServiceEvent</code> object.
- */
- public void serviceChanged(ApplicationServiceEvent event);
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/application/Framework.java b/org.osgi.compendium/src/main/java/org/osgi/application/Framework.java
deleted file mode 100644
index b81e93c..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/application/Framework.java
+++ /dev/null
@@ -1,59 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2005, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.osgi.application;
-
-import java.util.Hashtable;
-
-/**
- * Using this class, OSGi-aware applications can obtain their
- * {@link ApplicationContext}.
- *
- * @version $Revision: 5673 $
- */
-public final class Framework {
-
- private Framework() { }
-
- private static Hashtable appContextHash;
-
- /**
- * This method needs an argument, an object that represents the application instance.
- * An application consists of a set of object, however there is a single object, which
- * is used by the corresponding application container to manage the lifecycle on the
- * application instance. The lifetime of this object equals the lifetime of
- * the application instance; therefore, it is suitable to represent the instance.
- * <P>
- * The returned {@link ApplicationContext} object is singleton for the
- * specified application instance. Subsequent calls to this method with the same
- * application instance must return the same context object
- *
- * @param applicationInstance is the activator object of an application instance
- * @throws java.lang.NullPointerException If <code>applicationInstance</code>
- * is <code>null</code>
- * @throws java.lang.IllegalArgumentException if called with an object that is not
- * the activator object of an application.
- * @return the {@link ApplicationContext} of the specified application instance.
- */
- public static ApplicationContext getApplicationContext(Object applicationInstance) {
- if( applicationInstance == null )
- throw new NullPointerException( "Instance cannot be null!" );
- ApplicationContext appContext = (ApplicationContext)appContextHash.get( applicationInstance );
- if( appContext == null )
- throw new IllegalArgumentException( "ApplicationContext not found!" );
- return appContext;
- }
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/application/ApplicationAdminPermission.java b/org.osgi.compendium/src/main/java/org/osgi/service/application/ApplicationAdminPermission.java
deleted file mode 100644
index 1993330..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/application/ApplicationAdminPermission.java
+++ /dev/null
@@ -1,352 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2004, 2009). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.osgi.service.application;
-
-import java.security.Permission;
-import java.util.Hashtable;
-import java.util.StringTokenizer;
-import java.util.Vector;
-
-import org.osgi.framework.Filter;
-import org.osgi.framework.FrameworkUtil;
-import org.osgi.framework.InvalidSyntaxException;
-
-/**
- * This class implements permissions for manipulating applications and their
- * instances.
- * <P>
- * ApplicationAdminPermission can be targeted to applications that matches the
- * specified filter.
- * <P>
- * ApplicationAdminPermission may be granted for different actions:
- * <code>lifecycle</code>, <code>schedule</code> and <code>lock</code>. The
- * permission <code>schedule</code> implies the permission
- * <code>lifecycle</code>.
- *
- * @version $Revision: 6860 $
- */
-public class ApplicationAdminPermission extends Permission {
- private static final long serialVersionUID = 1L;
-
- /**
- * Allows the lifecycle management of the target applications.
- */
- public static final String LIFECYCLE_ACTION = "lifecycle";
-
- /**
- * Allows scheduling of the target applications. The permission to
- * schedule an application implies that the scheduler can also
- * manage the lifecycle of that application i.e. <code>schedule</code>
- * implies <code>lifecycle</code>
- */
- public static final String SCHEDULE_ACTION = "schedule";
-
- /**
- * Allows setting/unsetting the locking state of the target applications.
- */
- public static final String LOCK_ACTION = "lock";
-
- private ApplicationDescriptor applicationDescriptor;
-
- /**
- * Constructs an ApplicationAdminPermission. The <code>filter</code>
- * specifies the target application. The <code>filter</code> is an
- * LDAP-style filter, the recognized properties are <code>signer</code>
- * and <code>pid</code>. The pattern specified in the <code>signer</code>
- * is matched with the Distinguished Name chain used to sign the application.
- * Wildcards in a DN are not matched according to the filter string rules,
- * but according to the rules defined for a DN chain. The attribute
- * <code>pid</code> is matched with the PID of the application according to
- * the filter string rules.
- * <p>
- * If the <code>filter</code> is <code>null</code> then it matches
- * <code>"*"</code>. If
- * <code>actions</code> is <code>"*"</code> then it identifies all the
- * possible actions.
- *
- * @param filter
- * filter to identify application. The value <code>null</code>
- * is equivalent to <code>"*"</code> and it indicates "all application".
- * @param actions
- * comma-separated list of the desired actions granted on the
- * applications or "*" means all the actions. It must not be
- * <code>null</code>. The order of the actions in the list is
- * not significant.
- * @throws InvalidSyntaxException
- * is thrown if the specified <code>filter</code> is not syntactically
- * correct.
- *
- * @exception NullPointerException
- * is thrown if the actions parameter is <code>null</code>
- *
- * @see ApplicationDescriptor
- * @see org.osgi.framework.AdminPermission
- */
- public ApplicationAdminPermission(String filter, String actions) throws InvalidSyntaxException {
- super(filter == null ? "*" : filter);
-
- if( filter == null )
- filter = "*";
-
- if( actions == null )
- throw new NullPointerException( "Action string cannot be null!" );
-
- this.applicationDescriptor = null;
- this.filter = (filter == null ? "*" : filter);
- this.actions = actions;
-
- if( !filter.equals( "*" ) && !filter.equals( "<<SELF>>" ) )
- FrameworkUtil.createFilter( this.filter ); // check if the filter is valid
- init();
- }
-
- /**
- * This contructor should be used when creating <code>ApplicationAdminPermission</code>
- * instance for <code>checkPermission</code> call.
- * @param application the tareget of the operation, it must not be <code>null</code>
- * @param actions the required operation. it must not be <code>null</code>
- * @throws NullPointerException if any of the arguments is null.
- */
- public ApplicationAdminPermission(ApplicationDescriptor application, String actions) {
- super(application.getApplicationId());
-
- if( application == null || actions == null )
- throw new NullPointerException( "ApplicationDescriptor and action string cannot be null!" );
-
- this.filter = application.getApplicationId();
- this.applicationDescriptor = application;
- this.actions = actions;
-
- init();
- }
-
- /**
- * This method can be used in the {@link java.security.ProtectionDomain}
- * implementation in the <code>implies</code> method to insert the
- * application ID of the current application into the permission being
- * checked. This enables the evaluation of the
- * <code><<SELF>></code> pseudo targets.
- * @param applicationId the ID of the current application.
- * @return the permission updated with the ID of the current application
- */
- public ApplicationAdminPermission setCurrentApplicationId(String applicationId) {
- ApplicationAdminPermission newPerm = null;
-
- if( this.applicationDescriptor == null ) {
- try {
- newPerm = new ApplicationAdminPermission( this.filter, this.actions );
- }catch( InvalidSyntaxException e ) {
- throw new RuntimeException(e); /* this can never happen */
- }
- }
- else
- newPerm = new ApplicationAdminPermission( this.applicationDescriptor, this.actions );
-
- newPerm.applicationID = applicationId;
-
- return newPerm;
- }
-
- /**
- * Checks if the specified <code>permission</code> is implied by this permission.
- * The method returns true under the following conditions:
- * <UL>
- * <LI> This permission was created by specifying a filter (see {@link #ApplicationAdminPermission(String, String)})
- * <LI> The implied <code>otherPermission</code> was created for a particular {@link ApplicationDescriptor}
- * (see {@link #ApplicationAdminPermission(ApplicationDescriptor, String)})
- * <LI> The <code>filter</code> of this permission mathes the <code>ApplicationDescriptor</code> specified
- * in the <code>otherPermission</code>. If the filter in this permission is the
- * <code><<SELF>></code> pseudo target, then the currentApplicationId set in the
- * <code>otherPermission</code> is compared to the application Id of the target
- * <code>ApplicationDescriptor</code>.
- * <LI> The list of permitted actions in this permission contains all actions required in the
- * <code>otherPermission</code>
- * </UL>
- * Otherwise the method returns false.
- * @param otherPermission the implied permission
- * @return true if this permission implies the <code>otherPermission</code>, false otherwise.
- */
- public boolean implies(Permission otherPermission) {
- if( otherPermission == null )
- return false;
-
- if(!(otherPermission instanceof ApplicationAdminPermission))
- return false;
-
- ApplicationAdminPermission other = (ApplicationAdminPermission) otherPermission;
-
- if( !filter.equals("*") ) {
- if( other.applicationDescriptor == null )
- return false;
-
- if( filter.equals( "<<SELF>>") ) {
- if( other.applicationID == null )
- return false; /* it cannot be, this might be a bug */
-
- if( !other.applicationID.equals( other.applicationDescriptor.getApplicationId() ) )
- return false;
- }
- else {
- Hashtable props = new Hashtable();
- props.put( "pid", other.applicationDescriptor.getApplicationId() );
- props.put( "signer", new SignerWrapper( other.applicationDescriptor ) );
-
- Filter flt = getFilter();
- if( flt == null )
- return false;
-
- if( !flt.match( props ) )
- return false;
- }
- }
-
- if( !actionsVector.containsAll( other.actionsVector ) )
- return false;
-
- return true;
- }
-
- public boolean equals(Object with) {
- if( with == null || !(with instanceof ApplicationAdminPermission) )
- return false;
-
- ApplicationAdminPermission other = (ApplicationAdminPermission)with;
-
- // Compare actions:
- if( other.actionsVector.size() != actionsVector.size() )
- return false;
-
- for( int i=0; i != actionsVector.size(); i++ )
- if( !other.actionsVector.contains( actionsVector.get( i ) ) )
- return false;
-
-
- return equal(this.filter, other.filter ) && equal(this.applicationDescriptor, other.applicationDescriptor)
- && equal(this.applicationID, other.applicationID);
- }
-
- /**
- * Compares parameters for equality. If both object are null, they are considered
- * equal.
- * @param a object to compare
- * @param b other object to compare
- * @return true if both objects are equal or both are null
- */
- private static boolean equal(Object a, Object b) {
- // This equation is true if both references are null or both point
- // to the same object. In both cases they are considered as equal.
- if( a == b ) {
- return true;
- }
-
- return a.equals(b);
- }
-
- public int hashCode() {
- int hc = 0;
- for( int i=0; i != actionsVector.size(); i++ )
- hc ^= ((String)actionsVector.get( i )).hashCode();
- hc ^= (null == this.filter )? 0 : this.filter.hashCode();
- hc ^= (null == this.applicationDescriptor) ? 0 : this.applicationDescriptor.hashCode();
- hc ^= (null == this.applicationID) ? 0 : this.applicationID.hashCode();
- return hc;
- }
-
- /**
- * Returns the actions of this permission.
- * @return the actions specified when this permission was created
- */
- public String getActions() {
- return actions;
- }
-
- private String applicationID;
-
- private static final Vector ACTIONS = new Vector();
- private Vector actionsVector;
- private final String filter;
- private final String actions;
- private Filter appliedFilter = null;
-
- static {
- ACTIONS.add(LIFECYCLE_ACTION);
- ACTIONS.add(SCHEDULE_ACTION);
- ACTIONS.add(LOCK_ACTION);
- }
-
- private static Vector actionsVector(String actions) {
- Vector v = new Vector();
- StringTokenizer t = new StringTokenizer(actions.toUpperCase(), ",");
- while (t.hasMoreTokens()) {
- String action = t.nextToken().trim();
- v.add(action.toLowerCase());
- }
-
- if( v.contains( SCHEDULE_ACTION ) && !v.contains( LIFECYCLE_ACTION ) )
- v.add( LIFECYCLE_ACTION );
-
- return v;
- }
-
-
- private static class SignerWrapper extends Object {
- private String pattern;
- private ApplicationDescriptor appDesc;
-
- /**
- * @param pattern
- */
- public SignerWrapper(String pattern) {
- this.pattern = pattern;
- }
-
- SignerWrapper(ApplicationDescriptor appDesc) {
- this.appDesc = appDesc;
- }
-
- public boolean equals(Object o) {
- if (!(o instanceof SignerWrapper))
- return false;
- SignerWrapper other = (SignerWrapper) o;
- ApplicationDescriptor matchAppDesc = (ApplicationDescriptor) (appDesc != null ? appDesc : other.appDesc);
- String matchPattern = appDesc != null ? other.pattern : pattern;
- return matchAppDesc.matchDNChain(matchPattern);
- }
- }
-
- private void init() {
- actionsVector = actionsVector( actions );
-
- if ( actions.equals("*") )
- actionsVector = actionsVector( LIFECYCLE_ACTION + "," + SCHEDULE_ACTION + "," + LOCK_ACTION );
- else if (!ACTIONS.containsAll(actionsVector))
- throw new IllegalArgumentException("Illegal action!");
-
- applicationID = null;
- }
-
- private Filter getFilter() {
- if (appliedFilter == null) {
- try {
- appliedFilter = FrameworkUtil.createFilter(filter);
- } catch (InvalidSyntaxException e) {
- //we will return null
- }
- }
- return appliedFilter;
- }
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/application/ApplicationDescriptor.java b/org.osgi.compendium/src/main/java/org/osgi/service/application/ApplicationDescriptor.java
deleted file mode 100644
index bf50131..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/application/ApplicationDescriptor.java
+++ /dev/null
@@ -1,722 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2004, 2009). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.osgi.service.application;
-
-import java.lang.reflect.InvocationTargetException;
-import java.lang.reflect.Method;
-import java.security.AccessController;
-import java.security.PrivilegedAction;
-import java.security.PrivilegedExceptionAction;
-import java.util.Map;
-
-import org.osgi.framework.Constants;
-import org.osgi.framework.InvalidSyntaxException;
-
-/**
- * An OSGi service that represents an installed application and stores
- * information about it. The application descriptor can be used for instance
- * creation.
- *
- * @version $Revision: 7938 $
- */
-
-public abstract class ApplicationDescriptor {
- /*
- * NOTE: An implementor may also choose to replace this class in
- * their distribution with a class that directly interfaces with the
- * org.osgi.service.application implementation. This replacement class MUST NOT alter the
- * public/protected signature of this class.
- */
-
- /**
- * The property key for the localized name of the application.
- */
- public static final String APPLICATION_NAME = "application.name";
-
- /**
- * The property key for the localized icon of the application.
- */
- public static final String APPLICATION_ICON = "application.icon";
-
- /**
- * The property key for the unique identifier (PID) of the application.
- */
- public static final String APPLICATION_PID = Constants.SERVICE_PID;
-
- /**
- * The property key for the version of the application.
- */
- public static final String APPLICATION_VERSION = "application.version";
-
- /**
- * The property key for the name of the application vendor.
- */
- public static final String APPLICATION_VENDOR = Constants.SERVICE_VENDOR;
-
-
- /**
- * The property key for the visibility property of the application.
- */
- public static final String APPLICATION_VISIBLE = "application.visible";
-
- /**
- * The property key for the launchable property of the application.
- */
- public static final String APPLICATION_LAUNCHABLE = "application.launchable";
-
- /**
- * The property key for the locked property of the application.
- */
- public static final String APPLICATION_LOCKED = "application.locked";
-
- /**
- * The property key for the localized description of the application.
- */
- public static final String APPLICATION_DESCRIPTION = "application.description";
-
- /**
- * The property key for the localized documentation of the application.
- */
- public static final String APPLICATION_DOCUMENTATION = "application.documentation";
-
- /**
- * The property key for the localized copyright notice of the application.
- */
- public static final String APPLICATION_COPYRIGHT = "application.copyright";
-
- /**
- * The property key for the localized license of the application.
- */
- public static final String APPLICATION_LICENSE = "application.license";
-
- /**
- * The property key for the application container of the application.
- */
- public static final String APPLICATION_CONTAINER = "application.container";
-
- /**
- * The property key for the location of the application.
- */
- public static final String APPLICATION_LOCATION = "application.location";
-
-
- private final String pid;
-
-
- /**
- * Constructs the <code>ApplicationDescriptor</code>.
- *
- * @param applicationId
- * The identifier of the application. Its value is also available
- * as the <code>service.pid</code> service property of this
- * <code>ApplicationDescriptor</code> service. This parameter must not
- * be <code>null</code>.
- * @throws NullPointerException if the specified <code>applicationId</code> is null.
- */
- protected ApplicationDescriptor(String applicationId) {
- if(null == applicationId ) {
- throw new NullPointerException("Application ID must not be null!");
- }
-
- this.pid = applicationId;
- try {
- delegate = new Delegate();
- delegate.setApplicationDescriptor( this, applicationId );
- }
- catch (Exception e) {
- // Too bad ...
- e.printStackTrace();
- System.err
- .println("No implementation available for ApplicationDescriptor, property is: "
- + Delegate.cName);
- }
- }
-
- /**
- * Returns the identifier of the represented application.
- *
- * @return the identifier of the represented application
- */
- public final String getApplicationId() {
- return pid;
- }
-
- /**
- * This method verifies whether the specified <code>pattern</code>
- * matches the Distinguished Names of any of the certificate chains
- * used to authenticate this application.
- * <P>
- * The <code>pattern</code> must adhere to the
- * syntax defined in {@link org.osgi.service.application.ApplicationAdminPermission}
- * for signer attributes.
- * <p>
- * This method is used by {@link ApplicationAdminPermission#implies(java.security.Permission)} method
- * to match target <code>ApplicationDescriptor</code> and filter.
- *
- * @param pattern a pattern for a chain of Distinguished Names. It must not be null.
- * @return <code>true</code> if the specified pattern matches at least
- * one of the certificate chains used to authenticate this application
- * @throws NullPointerException if the specified <code>pattern</code> is null.
- * @throws IllegalStateException if the application descriptor was
- * unregistered
- */
- public abstract boolean matchDNChain( String pattern );
-
- /**
- * Returns the properties of the application descriptor as key-value pairs.
- * The return value contains the locale aware and unaware properties as
- * well. The returned <code>Map</code> will include the service
- * properties of this <code>ApplicationDescriptor</code> as well.
- * <p>
- * This method will call the <code>getPropertiesSpecific</code> method
- * to enable the container implementation to insert application model and/or
- * container implementation specific properties.
- * <P>
- * The returned {@link java.util.Map} will contain the standard OSGi service
- * properties as well
- * (e.g. service.id, service.vendor etc.) and specialized application
- * descriptors may offer further service properties. The returned Map contains
- * a snapshot of the properties. It will not reflect further changes in the
- * property values nor will the update of the Map change the corresponding
- * service property.
- *
- * @param locale
- * the locale string, it may be null, the value null means the
- * default locale. If the provided locale is the empty String
- * (<code>""</code>)then raw (non-localized) values are returned.
- *
- * @return copy of the service properties of this application descriptor service,
- * according to the specified locale. If locale is null then the
- * default locale's properties will be returned. (Since service
- * properties are always exist it cannot return null.)
- *
- * @throws IllegalStateException
- * if the application descriptor is unregistered
- */
- public final Map getProperties(String locale) {
- Map props = getPropertiesSpecific( locale );
-
- /* currently the ApplicationDescriptor manages the load/save of locking */
- boolean isLocked = delegate.isLocked(); // the real locking state
- Boolean containerLocked = (Boolean)props.remove( APPLICATION_LOCKED );
- if( containerLocked != null && containerLocked.booleanValue() != isLocked ) {
- try {
- if( isLocked ) /* if the container's information is not correct */
- lockSpecific(); /* about the locking state (after loading the lock states) */
- else
- unlockSpecific();
- }catch( Exception e ) {}
- }
- /* replace the container's lock with the application model's lock, that's the correct */
- props.put( APPLICATION_LOCKED, new Boolean( isLocked ) );
- return props;
- }
-
- /**
- * Container implementations can provide application model specific
- * and/or container implementation specific properties via this
- * method.
- *
- * Localizable properties must be returned localized if the provided
- * <code>locale</code> argument is not the empty String. The value
- * <code>null</code> indicates to use the default locale, for other
- * values the specified locale should be used.
- *
- * The returned {@link java.util.Map} must contain the standard OSGi service
- * properties as well
- * (e.g. service.id, service.vendor etc.) and specialized application
- * descriptors may offer further service properties.
- * The returned <code>Map</code>
- * contains a snapshot of the properties. It will not reflect further changes in the
- * property values nor will the update of the Map change the corresponding
- * service property.
-
- * @param locale the locale to be used for localizing the properties.
- * If <code>null</code> the default locale should be used. If it is
- * the empty String (<code>""</code>) then raw (non-localized) values
- * should be returned.
- *
- * @return the application model specific and/or container implementation
- * specific properties of this application descriptor.
- *
- * @throws IllegalStateException
- * if the application descriptor is unregistered
- */
- protected abstract Map getPropertiesSpecific(String locale);
-
- /**
- * Launches a new instance of an application. The <code>args</code> parameter specifies
- * the startup parameters for the instance to be launched, it may be null.
- * <p>
- * The following steps are made:
- * <UL>
- * <LI>Check for the appropriate permission.
- * <LI>Check the locking state of the application. If locked then throw
- * an {@link ApplicationException} with the reason code
- * {@link ApplicationException#APPLICATION_LOCKED}.
- * <LI>Calls the <code>launchSpecific()</code> method to create and start an application
- * instance.
- * <LI>Returns the <code>ApplicationHandle</code> returned by the
- * launchSpecific()
- * </UL>
- * The caller has to have ApplicationAdminPermission(applicationPID,
- * "launch") in order to be able to perform this operation.
- * <P>
- * The <code>Map</code> argument of the launch method contains startup
- * arguments for the
- * application. The keys used in the Map must be non-null, non-empty <code>String<code>
- * objects. They can be standard or application
- * specific. OSGi defines the <code>org.osgi.triggeringevent</code>
- * key to be used to
- * pass the triggering event to a scheduled application, however
- * in the future it is possible that other well-known keys will be defined.
- * To avoid unwanted clashes of keys, the following rules should be applied:
- * <ul>
- * <li>The keys starting with the dash (-) character are application
- * specific, no well-known meaning should be associated with them.</li>
- * <li>Well-known keys should follow the reverse domain name based naming.
- * In particular, the keys standardized in OSGi should start with
- * <code>org.osgi.</code>.</li>
- * </ul>
- * <P>
- * The method is synchronous, it return only when the application instance was
- * successfully started or the attempt to start it failed.
- * <P>
- * This method never returns <code>null</code>. If launching an application fails,
- * the appropriate exception is thrown.
- *
- * @param arguments
- * Arguments for the newly launched application, may be null
- *
- * @return the registered ApplicationHandle, which represents the newly
- * launched application instance. Never returns <code>null</code>.
- *
- * @throws SecurityException
- * if the caller doesn't have "lifecycle"
- * ApplicationAdminPermission for the application.
- * @throws ApplicationException
- * if starting the application failed
- * @throws IllegalStateException
- * if the application descriptor is unregistered
- * @throws IllegalArgumentException
- * if the specified <code>Map</code> contains invalid keys
- * (null objects, empty <code>String</code> or a key that is not
- * <code>String</code>)
- */
- public final ApplicationHandle launch(Map arguments)
- throws ApplicationException {
- try {
- delegate.launch(arguments);
- }catch( SecurityException se ) {
- isLaunchableSpecific(); /* check whether the bundle was uninstalled */
- /* if yes, throws IllegalStateException */
- throw se; /* otherwise throw the catched SecurityException */
- }
- if( !isLaunchableSpecific() )
- throw new ApplicationException(ApplicationException.APPLICATION_NOT_LAUNCHABLE,
- "Cannot launch the application!");
- try {
- return launchSpecific(arguments);
- } catch(IllegalStateException ise) {
- throw ise;
- } catch(SecurityException se) {
- throw se;
- } catch( ApplicationException ae) {
- throw ae;
- } catch(Exception t) {
- throw new ApplicationException(ApplicationException.APPLICATION_INTERNAL_ERROR, t);
- }
- }
-
- /**
- * Called by launch() to create and start a new instance in an application
- * model specific way. It also creates and registeres the application handle
- * to represent the newly created and started instance and registeres it.
- * The method is synchronous, it return only when the application instance was
- * successfully started or the attempt to start it failed.
- * <P>
- * This method must not return <code>null</code>. If launching the application
- * failed, and exception must be thrown.
- *
- * @param arguments
- * the startup parameters of the new application instance, may be
- * null
- *
- * @return the registered application model
- * specific application handle for the newly created and started
- * instance.
- *
- * @throws IllegalStateException
- * if the application descriptor is unregistered
- * @throws Exception
- * if any problem occurs.
- */
- protected abstract ApplicationHandle launchSpecific(Map arguments)
- throws Exception;
-
- /**
- * This method is called by launch() to verify that according to the
- * container, the application is launchable.
- *
- * @return true, if the application is launchable according to the
- * container, false otherwise.
- *
- * @throws IllegalStateException
- * if the application descriptor is unregistered
- */
- protected abstract boolean isLaunchableSpecific();
-
- /**
- * Schedules the application at a specified event. Schedule information
- * should not get lost even if the framework or the device restarts so it
- * should be stored in a persistent storage. The method registers a
- * {@link ScheduledApplication} service in Service Registry, representing
- * the created schedule.
- * <p>
- * The <code>Map</code> argument of the method contains startup
- * arguments for the application. The keys used in the Map must be non-null,
- * non-empty <code>String<code> objects. The argument values must be
- * of primitive types, wrapper classes of primitive types, <code>String</code>
- * or arrays or collections of these.
- * <p>
- * The created schedules have a unique identifier within the scope of this
- * <code>ApplicationDescriptor</code>. This identifier can be specified
- * in the <code>scheduleId</code> argument. If this argument is <code>null</code>,
- * the identifier is automatically generated.
- *
- * @param scheduleId
- * the identifier of the created schedule. It can be <code>null</code>,
- * in this case the identifier is automatically generated.
- * @param arguments
- * the startup arguments for the scheduled application, may be
- * null
- * @param topic
- * specifies the topic of the triggering event, it may contain a
- * trailing asterisk as wildcard, the empty string is treated as
- * "*", must not be null
- * @param eventFilter
- * specifies and LDAP filter to filter on the properties of the
- * triggering event, may be null
- * @param recurring
- * if the recurring parameter is false then the application will
- * be launched only once, when the event firstly occurs. If the
- * parameter is true then scheduling will take place for every
- * event occurrence; i.e. it is a recurring schedule
- *
- * @return the registered scheduled application service
- *
- * @throws NullPointerException
- * if the topic is <code>null</code>
- * @throws InvalidSyntaxException
- * if the specified <code>eventFilter</code> is not syntactically correct
- * @throws ApplicationException
- * if the schedule couldn't be created. The possible error
- * codes are
- * <ul>
- * <li> {@link ApplicationException#APPLICATION_DUPLICATE_SCHEDULE_ID}
- * if the specified <code>scheduleId</code> is already used
- * for this <code>ApplicationDescriptor</code>
- * <li> {@link ApplicationException#APPLICATION_SCHEDULING_FAILED}
- * if the scheduling failed due to some internal reason
- * (e.g. persistent storage error).
- * <li> {@link ApplicationException#APPLICATION_INVALID_STARTUP_ARGUMENT}
- * if the specified startup argument doesn't satisfy the
- * type or value constraints of startup arguments.
- * </ul>
- * @throws SecurityException
- * if the caller doesn't have "schedule"
- * ApplicationAdminPermission for the application.
- * @throws IllegalStateException
- * if the application descriptor is unregistered
- * @throws IllegalArgumentException
- * if the specified <code>Map</code> contains invalid keys
- * (null objects, empty <code>String</code> or a key that is not
- * <code>String</code>)
- */
- public final ScheduledApplication schedule(String scheduleId, Map arguments, String topic,
- String eventFilter, boolean recurring) throws InvalidSyntaxException,
- ApplicationException {
- isLaunchableSpecific(); // checks if the ApplicationDescriptor was already unregistered
- try {
- return delegate.schedule(scheduleId, arguments, topic, eventFilter, recurring);
- }catch( SecurityException se ) {
- isLaunchableSpecific(); /* check whether the bundle was uninstalled */
- /* if yes, throws IllegalStateException */
- throw se; /* otherwise throw the catched SecurityException */
- }
- }
-
- /**
- * Sets the lock state of the application. If an application is locked then
- * launching a new instance is not possible. It does not affect the already
- * launched instances.
- *
- * @throws SecurityException
- * if the caller doesn't have "lock" ApplicationAdminPermission
- * for the application.
- * @throws IllegalStateException
- * if the application descriptor is unregistered
- */
- public final void lock() {
- try {
- delegate.lock();
- }catch( SecurityException se ) {
- isLaunchableSpecific(); /* check whether the bundle was uninstalled */
- /* if yes, throws IllegalStateException */
- throw se; /* otherwise throw the catched SecurityException */
- }
- lockSpecific();
- }
-
- /**
- * This method is used to notify the container implementation that the
- * corresponding application has been locked and it should update the
- * <code>application.locked</code> service property accordingly.
- * @throws IllegalStateException
- * if the application descriptor is unregistered
- */
- protected abstract void lockSpecific();
-
- /**
- * Unsets the lock state of the application.
- *
- * @throws SecurityException
- * if the caller doesn't have "lock" ApplicationAdminPermission
- * for the application.
- * @throws IllegalStateException
- * if the application descriptor is unregistered
- */
- public final void unlock() {
- try {
- delegate.unlock();
- }catch( SecurityException se ) {
- isLaunchableSpecific(); /* check whether the bundle was uninstalled */
- /* if yes, throws IllegalStateException */
- throw se; /* otherwise throw the catched SecurityException */
- }
- unlockSpecific();
- }
-
- /**
- * This method is used to notify the container implementation that the
- * corresponding application has been unlocked and it should update the
- * <code>application.locked</code> service property accordingly.
-
- * @throws IllegalStateException
- * if the application descriptor is unregistered
- */
- protected abstract void unlockSpecific();
-
- Delegate delegate;
- /**
- * This class will load the class named
- * by the org.osgi.vendor.application.ApplicationDescriptor and delegate
- * method calls to an instance of the class.
- */
- static class Delegate {
- static String cName;
- static Class implementation;
- static Method setApplicationDescriptor;
- static Method isLocked;
- static Method lock;
- static Method unlock;
- static Method schedule;
- static Method launch;
-
- static {
- AccessController.doPrivileged(new PrivilegedAction() {
- public Object run() {
- cName = System.getProperty("org.osgi.vendor.application.ApplicationDescriptor");
- if (cName == null) {
- throw new NoClassDefFoundError("org.osgi.vendor.application.ApplicationDescriptor property must be set");
- }
-
- try {
- implementation = Class.forName(cName);
- }
- catch (ClassNotFoundException e) {
- throw new NoClassDefFoundError(e.toString());
- }
-
- try {
- setApplicationDescriptor = implementation.getMethod("setApplicationDescriptor",
- new Class[] {ApplicationDescriptor.class, String.class});
- isLocked = implementation.getMethod("isLocked",
- new Class[] {});
- lock = implementation.getMethod("lock",
- new Class[] {});
- unlock = implementation.getMethod("unlock",
- new Class[] {});
- schedule = implementation.getMethod("schedule",
- new Class[] {String.class, Map.class, String.class, String.class,
- boolean.class});
- launch = implementation.getMethod("launch",
- new Class[] {Map.class});
- }
- catch (NoSuchMethodException e) {
- throw new NoSuchMethodError(e.toString());
- }
-
- return null;
- }
- });
- }
-
- Object target;
-
- Delegate() throws Exception {
- target = AccessController.doPrivileged(new PrivilegedExceptionAction() {
- public Object run() throws Exception {
- return implementation.newInstance();
- }
- });
- }
-
- void setApplicationDescriptor(ApplicationDescriptor d, String pid ) {
- try {
- try {
- setApplicationDescriptor.invoke(target, new Object[] {d, pid});
- }
- catch (InvocationTargetException e) {
- throw e.getTargetException();
- }
- }
- catch (Error e) {
- throw e;
- }
- catch (RuntimeException e) {
- throw e;
- }
- catch (Throwable e) {
- throw new RuntimeException(e);
- }
- }
-
- boolean isLocked() {
- try {
- try {
- return ((Boolean)isLocked.invoke(target, new Object[] {})).booleanValue();
- }
- catch (InvocationTargetException e) {
- throw e.getTargetException();
- }
- }
- catch (Error e) {
- throw e;
- }
- catch (RuntimeException e) {
- throw e;
- }
- catch (Throwable e) {
- throw new RuntimeException(e);
- }
- }
-
- void lock() {
- try {
- try {
- lock.invoke(target, new Object[] {});
- }
- catch (InvocationTargetException e) {
- throw e.getTargetException();
- }
- }
- catch (Error e) {
- throw e;
- }
- catch (RuntimeException e) {
- throw e;
- }
- catch (Throwable e) {
- throw new RuntimeException(e);
- }
- }
-
- void unlock() {
- try {
- try {
- unlock.invoke(target, new Object[] {});
- }
- catch (InvocationTargetException e) {
- throw e.getTargetException();
- }
- }
- catch (Error e) {
- throw e;
- }
- catch (RuntimeException e) {
- throw e;
- }
- catch (Throwable e) {
- throw new RuntimeException(e);
- }
- }
-
- ScheduledApplication schedule(String scheduleId, Map args, String topic, String filter,
- boolean recurs) throws InvalidSyntaxException, ApplicationException {
- try {
- try {
- return (ScheduledApplication)schedule.invoke(target, new Object[] {scheduleId, args, topic, filter,
- new Boolean(recurs)});
- }
- catch (InvocationTargetException e) {
- throw e.getTargetException();
- }
- }
- catch (InvalidSyntaxException e) {
- throw e;
- }
- catch (ApplicationException e) {
- throw e;
- }
- catch (Error e) {
- throw e;
- }
- catch (RuntimeException e) {
- throw e;
- }
- catch (Throwable e) {
- throw new RuntimeException(e);
- }
- }
-
- void launch(Map arguments) throws ApplicationException {
- try {
- try {
- launch.invoke(target, new Object[] {arguments});
- }
- catch (InvocationTargetException e) {
- throw e.getTargetException();
- }
- }
- catch (ApplicationException e) {
- throw e;
- }
- catch (Error e) {
- throw e;
- }
- catch (RuntimeException e) {
- throw e;
- }
- catch (Throwable e) {
- throw new RuntimeException(e);
- }
- }
- }
-
-
-}
\ No newline at end of file
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/application/ApplicationException.java b/org.osgi.compendium/src/main/java/org/osgi/service/application/ApplicationException.java
deleted file mode 100644
index 485f71d..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/application/ApplicationException.java
+++ /dev/null
@@ -1,161 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2005, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.osgi.service.application;
-
-/**
- * This exception is used to indicate problems related to application lifecycle
- * management.
- *
- * <code>ApplicationException</code> object is created by the Application Admin
- * to denote an exception condition in the lifecycle of an application.
- * <code>ApplicationException</code>s should not be created by developers. <br/>
- * <code>ApplicationException</code>s are associated with an error code. This
- * code describes the type of problem reported in this exception. The possible
- * codes are:
- * <ul>
- * <li> {@link #APPLICATION_LOCKED} - The application couldn't be launched
- * because it is locked.</li>
- * <li> {@link #APPLICATION_NOT_LAUNCHABLE} - The application is not in
- * launchable state.</li>
- * <li> {@link #APPLICATION_INTERNAL_ERROR} - An exception was thrown by the
- * application or its container during launch.</li>
- * <li> {@link #APPLICATION_SCHEDULING_FAILED} - The scheduling of an application
- * failed.
- * <li> {@link #APPLICATION_DUPLICATE_SCHEDULE_ID} - The application scheduling
- * failed because the specified identifier is already in use.
- * <li> {@link #APPLICATION_EXITVALUE_NOT_AVAILABLE} - The exit value is not
- * available for an application instance because the instance has not
- * terminated.
- * <li> {@link #APPLICATION_INVALID_STARTUP_ARGUMENT} - One of the specified
- * startup arguments is invalid, for example its type is not permitted.
- * </ul>
- *
- * @version $Revision: 6083 $
- */
-public class ApplicationException extends Exception {
- private static final long serialVersionUID = -7173190453622508207L;
- private final int errorCode;
-
- /**
- * The application couldn't be launched because it is locked.
- */
- public static final int APPLICATION_LOCKED = 0x01;
-
- /**
- * The application is not in launchable state, it's
- * {@link ApplicationDescriptor#APPLICATION_LAUNCHABLE}
- * attribute is false.
- */
- public static final int APPLICATION_NOT_LAUNCHABLE = 0x02;
-
- /**
- * An exception was thrown by the application or the corresponding container
- * during launch. The exception is available from <code>getCause()</code>.
- */
- public static final int APPLICATION_INTERNAL_ERROR = 0x03;
-
- /**
- * The application schedule could not be created due to some internal error
- * (for example, the schedule information couldn't be saved due to some
- * storage error).
- */
- public static final int APPLICATION_SCHEDULING_FAILED = 0x04;
-
- /**
- * The application scheduling failed because the specified identifier
- * is already in use.
- */
- public static final int APPLICATION_DUPLICATE_SCHEDULE_ID = 0x05;
-
- /**
- * The exit value is not available for an application instance because the
- * instance has not terminated.
- *
- * @since 1.1
- */
- public static final int APPLICATION_EXITVALUE_NOT_AVAILABLE = 0x06;
-
- /**
- * One of the specified startup arguments is invalid, for example its
- * type is not permitted.
- *
- * @since 1.1
- */
- public static final int APPLICATION_INVALID_STARTUP_ARGUMENT = 0x07;
-
- /**
- * Creates an <code>ApplicationException</code> with the specified error code.
- * @param errorCode The code of the error
- */
- public ApplicationException(int errorCode) {
- super();
- this.errorCode = errorCode;
- }
-
- /**
- * Creates a <code>ApplicationException</code> that wraps another exception.
- *
- * @param errorCode The code of the error
- * @param cause The cause of this exception.
- */
- public ApplicationException(int errorCode, Throwable cause) {
- super(cause);
- this.errorCode = errorCode;
- }
-
- /**
- * Creates an <code>ApplicationException</code> with the specified error code.
- * @param errorCode The code of the error
- * @param message The associated message
- */
- public ApplicationException(int errorCode, String message) {
- super(message);
- this.errorCode = errorCode;
- }
-
- /**
- * Creates a <code>ApplicationException</code> that wraps another exception.
- *
- * @param errorCode The code of the error
- * @param message The associated message.
- * @param cause The cause of this exception.
- */
- public ApplicationException(int errorCode, String message, Throwable cause) {
- super(message, cause);
- this.errorCode = errorCode;
- }
-
- /**
- * Returns the cause of this exception or <code>null</code> if no cause was
- * set.
- *
- * @return The cause of this exception or <code>null</code> if no cause was
- * set.
- */
- public Throwable getCause() {
- return super.getCause();
- }
-
- /**
- * Returns the error code associated with this exception.
- *
- * @return The error code of this exception.
- */
- public int getErrorCode() {
- return errorCode;
- }
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/application/ApplicationHandle.java b/org.osgi.compendium/src/main/java/org/osgi/service/application/ApplicationHandle.java
deleted file mode 100644
index 7168269..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/application/ApplicationHandle.java
+++ /dev/null
@@ -1,340 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2004, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.osgi.service.application;
-
-import java.lang.reflect.InvocationTargetException;
-import java.lang.reflect.Method;
-import java.security.AccessController;
-import java.security.PrivilegedAction;
-import java.security.PrivilegedExceptionAction;
-
-import org.osgi.framework.Constants;
-
-/**
- * ApplicationHandle is an OSGi service interface which represents an instance
- * of an application. It provides the functionality to query and manipulate the
- * lifecycle state of the represented application instance. It defines constants
- * for the lifecycle states.
- *
- * @version $Revision: 5901 $
- */
-public abstract class ApplicationHandle {
- /*
- * NOTE: An implementor may also choose to replace this class in
- * their distribution with a class that directly interfaces with the
- * org.osgi.service.application implementation. This replacement class MUST NOT alter the
- * public/protected signature of this class.
- */
-
- /**
- * The property key for the unique identifier (PID) of the application
- * instance.
- */
- public static final String APPLICATION_PID = Constants.SERVICE_PID;
-
- /**
- * The property key for the pid of the corresponding application descriptor.
- */
- public final static String APPLICATION_DESCRIPTOR = "application.descriptor";
-
- /**
- * The property key for the state of this application instance.
- */
- public final static String APPLICATION_STATE = "application.state";
-
- /**
- * The property key for the supports exit value property of this application
- * instance.
- *
- * @since 1.1
- */
- public final static String APPLICATION_SUPPORTS_EXITVALUE = "application.supports.exitvalue";
-
- /**
- * The application instance is running. This is the initial state of a newly
- * created application instance.
- */
- public final static String RUNNING = "RUNNING";
-
- /**
- * The application instance is being stopped. This is the state of the
- * application instance during the execution of the <code>destroy()</code>
- * method.
- */
- public final static String STOPPING = "STOPPING";
-
- private final String instanceId;
-
- private final ApplicationDescriptor descriptor;
-
- /**
- * Application instance identifier is specified by the container when the
- * instance is created. The instance identifier must remain static for the
- * lifetime of the instance, it must remain the same even across framework
- * restarts for the same application instance. This value must be the same
- * as the <code>service.pid</code> service property of this application
- * handle.
- * <p>
- * The instance identifier should follow the following scheme:
- * <<i>application descriptor PID</i>>.<<i>index</i>>
- * where <<i>application descriptor PID</i>> is the PID of the
- * corresponding <code>ApplicationDescriptor</code> and <<i>index</i>>
- * is a unique integer index assigned by the application container.
- * Even after destroying the application index the same index value should not
- * be reused in a reasonably long timeframe.
- *
- * @param instanceId the instance identifier of the represented application
- * instance. It must not be null.
- *
- * @param descriptor the <code>ApplicationDescriptor</code> of the represented
- * application instance. It must not be null.
- *
- * @throws NullPointerException if any of the arguments is null.
- */
- protected ApplicationHandle(String instanceId, ApplicationDescriptor descriptor ) {
- if( (null == instanceId) || (null == descriptor) ) {
- throw new NullPointerException("Parameters must not be null!");
- }
-
- this.instanceId = instanceId;
- this.descriptor = descriptor;
-
- try {
- delegate = new Delegate();
- delegate.setApplicationHandle( this, descriptor.delegate );
- }
- catch (Exception e) {
- // Too bad ...
- e.printStackTrace();
- System.err
- .println("No implementation available for ApplicationDescriptor, property is: "
- + Delegate.cName);
- }
- }
-
- /**
- * Retrieves the <code>ApplicationDescriptor</code> to which this
- * <code>ApplicationHandle</code> belongs.
- *
- * @return The corresponding <code>ApplicationDescriptor</code>
- */
- public final ApplicationDescriptor getApplicationDescriptor() {
- return descriptor;
- }
-
- /**
- * Get the state of the application instance.
- *
- * @return the state of the application.
- *
- * @throws IllegalStateException
- * if the application handle is unregistered
- */
- public abstract String getState();
-
- /**
- * Returns the exit value for the application instance. The timeout
- * specifies how the method behaves when the application has not yet
- * terminated. A negative, zero or positive value may be used.
- * <ul>
- * <li> negative - The method does not wait for termination. If the
- * application has not terminated then an <code>ApplicationException</code>
- * is thrown.</li>
- *
- * <li> zero - The method waits until the application terminates.</li>
- *
- * <li> positive - The method waits until the application terminates or the
- * timeout expires. If the timeout expires and the application has not
- * terminated then an <code>ApplicationException</code> is thrown.</li>
- * </ul>
- * <p>
- * The default implementation throws an
- * <code>UnsupportedOperationException</code>. The application model should
- * override this method if exit values are supported.
- * </p>
- *
- * @param timeout The maximum time in milliseconds to wait for the
- * application to timeout.
- * @return The exit value for the application instance. The value is
- * application specific.
- * @throws UnsupportedOperationException If the application model does not
- * support exit values.
- * @throws InterruptedException If the thread is interrupted while waiting
- * for the timeout.
- * @throws ApplicationException If the application has not terminated. The
- * error code will be
- * {@link ApplicationException#APPLICATION_EXITVALUE_NOT_AVAILABLE}.
- *
- * @since 1.1
- */
- public Object getExitValue(long timeout) throws ApplicationException, InterruptedException{
- throw new UnsupportedOperationException();
- }
-
- /**
- * Returns the unique identifier of this instance. This value is also
- * available as a service property of this application handle's service.pid.
- *
- * @return the unique identifier of the instance
- */
- public final String getInstanceId() {
- return instanceId;
- }
-
- /**
- * The application instance's lifecycle state can be influenced by this
- * method. It lets the application instance perform operations to stop
- * the application safely, e.g. saving its state to a permanent storage.
- * <p>
- * The method must check if the lifecycle transition is valid; a STOPPING
- * application cannot be stopped. If it is invalid then the method must
- * exit. Otherwise the lifecycle state of the application instance must be
- * set to STOPPING. Then the destroySpecific() method must be called to
- * perform any application model specific steps for safe stopping of the
- * represented application instance.
- * <p>
- * At the end the <code>ApplicationHandle</code> must be unregistered.
- * This method should free all the resources related to this
- * <code>ApplicationHandle</code>.
- * <p>
- * When this method is completed the application instance has already made
- * its operations for safe stopping, the ApplicationHandle has been
- * unregistered and its related resources has been freed. Further calls on
- * this application should not be made because they may have unexpected
- * results.
- *
- * @throws SecurityException
- * if the caller doesn't have "lifecycle"
- * <code>ApplicationAdminPermission</code> for the corresponding application.
- *
- * @throws IllegalStateException
- * if the application handle is unregistered
- */
- public final void destroy() {
- try {
- delegate.destroy();
- }catch( SecurityException se ) {
- descriptor.isLaunchableSpecific(); /* check whether the bundle was uninstalled */
- /* if yes, throws IllegalStateException */
- throw se; /* otherwise throw the caught SecurityException */
- }
- destroySpecific();
- }
-
- /**
- * Called by the destroy() method to perform application model specific
- * steps to stop and destroy an application instance safely.
- *
- * @throws IllegalStateException
- * if the application handle is unregistered
- */
- protected abstract void destroySpecific();
-
- Delegate delegate;
-
-
- /**
- * This class will load the class named
- * by the org.osgi.vendor.application.ApplicationHandle and delegate
- * method calls to an instance of the class.
- */
- static class Delegate {
- static String cName;
- static Class implementation;
- static Method setApplicationHandle;
- static Method destroy;
-
- static {
- AccessController.doPrivileged(new PrivilegedAction() {
- public Object run(){
- cName = System.getProperty("org.osgi.vendor.application.ApplicationHandle");
- if (cName == null) {
- throw new NoClassDefFoundError("org.osgi.vendor.application.ApplicationHandle property must be set");
- }
-
- try {
- implementation = Class.forName(cName);
- }
- catch (ClassNotFoundException e) {
- throw new NoClassDefFoundError(e.toString());
- }
-
- try {
- setApplicationHandle = implementation.getMethod("setApplicationHandle",
- new Class[] {ApplicationHandle.class, Object.class});
- destroy = implementation.getMethod("destroy",
- new Class[] {});
- }
- catch (NoSuchMethodException e) {
- throw new NoSuchMethodError(e.toString());
- }
-
- return null;
- }
- });
- }
-
- Object target;
-
- Delegate() throws Exception {
- target = AccessController.doPrivileged(new PrivilegedExceptionAction() {
- public Object run() throws Exception {
- return implementation.newInstance();
- }
- });
- }
-
- void setApplicationHandle(ApplicationHandle d, ApplicationDescriptor.Delegate descriptor ) {
- try {
- try {
- setApplicationHandle.invoke(target, new Object[] {d, descriptor.target});
- }
- catch (InvocationTargetException e) {
- throw e.getTargetException();
- }
- }
- catch (Error e) {
- throw e;
- }
- catch (RuntimeException e) {
- throw e;
- }
- catch (Throwable e) {
- throw new RuntimeException(e);
- }
- }
- void destroy() {
- try {
- try {
- destroy.invoke(target, new Object[] {});
- }
- catch (InvocationTargetException e) {
- throw e.getTargetException();
- }
- }
- catch (Error e) {
- throw e;
- }
- catch (RuntimeException e) {
- throw e;
- }
- catch (Throwable e) {
- throw new RuntimeException(e);
- }
- }
- }
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/application/ScheduledApplication.java b/org.osgi.compendium/src/main/java/org/osgi/service/application/ScheduledApplication.java
deleted file mode 100644
index 02d776f..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/application/ScheduledApplication.java
+++ /dev/null
@@ -1,176 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2004, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.osgi.service.application;
-
-import java.util.Map;
-
-/**
- * It is allowed to schedule an application based on a specific event.
- * ScheduledApplication service keeps the schedule information. When the
- * specified event is fired a new instance must be launched. Note that launching
- * operation may fail because e.g. the application is locked.
- * <p>
- * Each <code>ScheduledApplication</code> instance has an identifier which is
- * unique within the scope of the application being scheduled.
- * <p>
- * <code>ScheduledApplication</code> instances are registered as services. The
- * {@link #APPLICATION_PID} service property contains the PID of the application
- * being scheduled, the {@link #SCHEDULE_ID} service property contains the
- * schedule identifier.
- *
- * @version $Revision: 5673 $
- */
-public interface ScheduledApplication {
-
- /**
- * The property key for the identifier of the application being scheduled.
- */
- public static final String APPLICATION_PID = ApplicationDescriptor.APPLICATION_PID;
-
- /**
- * The property key for the schedule identifier. The identifier is unique
- * within the scope of the application being scheduled.
- */
- public static final String SCHEDULE_ID = "schedule.id";
-
- /**
- * The key for the startup argument used to pass the event object that
- * triggered the schedule to launch the application instance.
- * The event is passed in a {@link java.security.GuardedObject}
- * protected by the corresponding
- * {@link org.osgi.service.event.TopicPermission}.
- */
- public static final String TRIGGERING_EVENT = "org.osgi.triggeringevent";
-
- /**
- * The topic name for the virtual timer topic. Time based schedules
- * should be created using this topic.
- */
- public static final String TIMER_TOPIC = "org/osgi/application/timer";
-
- /**
- * The name of the <i>year</i> attribute of a virtual timer event. The value is
- * defined by {@link java.util.Calendar#YEAR}.
- */
- public static final String YEAR = "year";
-
- /**
- * The name of the <i>month</i> attribute of a virtual timer event. The value is
- * defined by {@link java.util.Calendar#MONTH}.
- */
- public static final String MONTH = "month";
-
- /**
- * The name of the <i>day of month</i> attribute of a virtual timer event. The value is
- * defined by {@link java.util.Calendar#DAY_OF_MONTH}.
- */
- public static final String DAY_OF_MONTH = "day_of_month";
-
- /**
- * The name of the <i>day of week</i> attribute of a virtual timer event. The value is
- * defined by {@link java.util.Calendar#DAY_OF_WEEK}.
- */
- public static final String DAY_OF_WEEK = "day_of_week";
-
- /**
- * The name of the <i>hour of day</i> attribute of a virtual timer event. The value is
- * defined by {@link java.util.Calendar#HOUR_OF_DAY}.
- */
- public static final String HOUR_OF_DAY = "hour_of_day";
-
- /**
- * The name of the <i>minute</i> attribute of a virtual timer event. The value is
- * defined by {@link java.util.Calendar#MINUTE}.
- */
- public static final String MINUTE = "minute";
-
-
- /**
- * Returns the identifier of this schedule. The identifier is unique within
- * the scope of the application that the schedule is related to.
- * @return the identifier of this schedule
- *
- */
- public String getScheduleId();
-
- /**
- * Queries the topic of the triggering event. The topic may contain a
- * trailing asterisk as wildcard.
- *
- * @return the topic of the triggering event
- *
- * @throws IllegalStateException
- * if the scheduled application service is unregistered
- */
- public String getTopic();
-
- /**
- * Queries the event filter for the triggering event.
- *
- * @return the event filter for triggering event
- *
- * @throws IllegalStateException
- * if the scheduled application service is unregistered
- */
- public String getEventFilter();
-
- /**
- * Queries if the schedule is recurring.
- *
- * @return true if the schedule is recurring, otherwise returns false
- *
- * @throws IllegalStateException
- * if the scheduled application service is unregistered
- */
- public boolean isRecurring();
-
- /**
- * Retrieves the ApplicationDescriptor which represents the application and
- * necessary for launching.
- *
- * @return the application descriptor that
- * represents the scheduled application
- *
- * @throws IllegalStateException
- * if the scheduled application service is unregistered
- */
- public ApplicationDescriptor getApplicationDescriptor();
-
- /**
- * Queries the startup arguments specified when the application was
- * scheduled. The method returns a copy of the arguments, it is not possible
- * to modify the arguments after scheduling.
- *
- * @return the startup arguments of the scheduled application. It may be
- * null if null argument was specified.
- *
- * @throws IllegalStateException
- * if the scheduled application service is unregistered
- */
- public Map getArguments();
-
- /**
- * Cancels this schedule of the application.
- *
- * @throws SecurityException
- * if the caller doesn't have "schedule"
- * ApplicationAdminPermission for the scheduled application.
- * @throws IllegalStateException
- * if the scheduled application service is unregistered
- */
- public void remove();
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/container/BlueprintContainer.java b/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/container/BlueprintContainer.java
deleted file mode 100644
index 23cb758..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/container/BlueprintContainer.java
+++ /dev/null
@@ -1,100 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2008, 2009). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.service.blueprint.container;
-
-import java.util.Collection;
-import java.util.Set;
-
-import org.osgi.service.blueprint.reflect.BeanMetadata;
-import org.osgi.service.blueprint.reflect.ComponentMetadata;
-import org.osgi.service.blueprint.reflect.ReferenceListMetadata;
-import org.osgi.service.blueprint.reflect.ReferenceMetadata;
-import org.osgi.service.blueprint.reflect.ServiceMetadata;
-import org.osgi.service.blueprint.reflect.ServiceReferenceMetadata;
-
-/**
- * A Blueprint Container represents the managed state of a Blueprint bundle.
- *
- * A Blueprint Container provides access to all managed components. These are
- * the beans, services, and service references. Only bundles in the
- * <code>ACTIVE</code> state (and also the <code>STARTING</code> state for
- * bundles awaiting lazy activation) can have an associated Blueprint Container.
- * A given Bundle Context has at most one associated Blueprint Container.
- *
- * A Blueprint Container can be obtained by injecting the predefined
- * "blueprintContainer" component id. The Blueprint Container is also
- * registered as a service and its managed components can be queried.
- *
- * @ThreadSafe
- * @version $Revision: 7556 $
- */
-public interface BlueprintContainer {
- /**
- * Returns the set of component ids managed by this Blueprint Container.
- *
- * @return An immutable Set of Strings, containing the ids of all of the
- * components managed within this Blueprint Container.
- */
- Set/* <String> */getComponentIds();
-
- /**
- * Return the component instance for the specified component id.
- *
- * If the component's manager has not yet been activated, calling this
- * operation will atomically activate it. If the component has singleton
- * scope, the activation will cause the component instance to be created and
- * initialized. If the component has prototype scope, then each call to this
- * method will return a new component instance.
- *
- * @param id The component id for the requested component instance.
- * @return A component instance for the component with the specified
- * component id.
- * @throws NoSuchComponentException If no component with the specified
- * component id is managed by this Blueprint Container.
- */
- Object getComponentInstance(String id);
-
- /**
- * Return the Component Metadata object for the component with the specified
- * component id.
- *
- * @param id The component id for the requested Component Metadata.
- * @return The Component Metadata object for the component with the
- * specified component id.
- * @throws NoSuchComponentException If no component with the specified
- * component id is managed by this Blueprint Container.
- */
- ComponentMetadata getComponentMetadata(String id);
-
- /**
- * Return all {@link ComponentMetadata} objects of the specified Component
- * Metadata type. The supported Component Metadata types are
- * {@link ComponentMetadata} (which returns the Component Metadata for all
- * defined manager types), {@link BeanMetadata} ,
- * {@link ServiceReferenceMetadata} (which returns both
- * {@link ReferenceMetadata} and {@link ReferenceListMetadata} objects), and
- * {@link ServiceMetadata}. The collection will include all Component
- * Metadata objects of the requested type, including components that are
- * declared inline.
- *
- * @param type The super type or type of the requested Component Metadata
- * objects.
- * @return An immutable collection of Component Metadata objects of the
- * specified type.
- */
- /* <T extends ComponentMetadata> */Collection/* <T> */getMetadata(
- Class/* <T> */type);
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/container/BlueprintEvent.java b/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/container/BlueprintEvent.java
deleted file mode 100644
index 2233563..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/container/BlueprintEvent.java
+++ /dev/null
@@ -1,366 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2008, 2009). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.service.blueprint.container;
-
-import org.osgi.framework.Bundle;
-
-/**
- * A Blueprint Event.
- *
- * <p>
- * <code>BlueprintEvent</code> objects are delivered to all registered
- * {@link BlueprintListener} services. Blueprint Events must be asynchronously
- * delivered in chronological order with respect to each listener.
- *
- * <p>
- * In addition, after a Blueprint Listener is registered, the Blueprint extender
- * will synchronously send to this Blueprint Listener the last Blueprint Event
- * for each ready Blueprint bundle managed by this extender. This
- * <em>replay</em> of Blueprint Events is designed so that the new Blueprint
- * Listener can be informed of the state of each Blueprint bundle. Blueprint
- * Events sent during this replay will have the {@link #isReplay()} flag set.
- * The Blueprint extender must ensure that this replay phase does not interfere
- * with new Blueprint Events so that the chronological order of all Blueprint
- * Events received by the Blueprint Listener is preserved. If the last Blueprint
- * Event for a given Blueprint bundle is {@link #DESTROYED}, the extender must
- * not send it during this replay phase.
- *
- * <p>
- * A type code is used to identify the type of event. The following event types
- * are defined:
- * <ul>
- * <li>{@link #CREATING}</li>
- * <li>{@link #CREATED}</li>
- * <li>{@link #DESTROYING}</li>
- * <li>{@link #DESTROYED}</li>
- * <li>{@link #FAILURE}</li>
- * <li>{@link #GRACE_PERIOD}</li>
- * <li>{@link #WAITING}</li>
- * </ul>
- *
- * <p>
- * In addition to calling the registered {@link BlueprintListener} services, the
- * Blueprint extender must also send those events to the Event Admin service, if
- * it is available.
- *
- * @see BlueprintListener
- * @see EventConstants
- * @Immutable
- * @version $Revision: 7590 $
- */
-public class BlueprintEvent {
-
- /**
- * The Blueprint extender has started creating a Blueprint Container for the
- * bundle.
- */
- public static final int CREATING = 1;
- /**
- * The Blueprint extender has created a Blueprint Container for the bundle.
- * This event is sent after the Blueprint Container has been registered as a
- * service.
- */
- public static final int CREATED = 2;
- /**
- * The Blueprint extender has started destroying the Blueprint Container for
- * the bundle.
- */
- public static final int DESTROYING = 3;
- /**
- * The Blueprint Container for the bundle has been completely destroyed.
- * This event is sent after the Blueprint Container has been unregistered as
- * a service.
- */
- public static final int DESTROYED = 4;
- /**
- * The Blueprint Container creation for the bundle has failed. If this event
- * is sent after a timeout in the Grace Period, the
- * {@link #getDependencies()} method must return an array of missing
- * mandatory dependencies. The event must also contain the cause of the
- * failure as a <code>Throwable</code> through the {@link #getCause()}
- * method.
- */
- public static final int FAILURE = 5;
- /**
- * The Blueprint Container has entered the grace period. The list of missing
- * dependencies must be made available through the
- * {@link #getDependencies()} method. During the grace period, a
- * {@link #GRACE_PERIOD} event is sent each time the set of unsatisfied
- * dependencies changes.
- */
- public static final int GRACE_PERIOD = 6;
- /**
- * The Blueprint Container is waiting on the availability of a service to
- * satisfy an invocation on a referenced service. The missing dependency
- * must be made available through the {@link #getDependencies()} method
- * which will return an array containing one filter object as a String.
- */
- public static final int WAITING = 7;
-
- /**
- * Type of this event.
- *
- * @see #getType()
- */
- private final int type;
- /**
- * The time when the event occurred.
- *
- * @see #getTimestamp()
- */
- private final long timestamp;
- /**
- * The Blueprint bundle.
- *
- * @see #getBundle()
- */
- private final Bundle bundle;
- /**
- * The Blueprint extender bundle.
- *
- * @see #getExtenderBundle()
- */
- private final Bundle extenderBundle;
- /**
- * An array containing filters identifying the missing dependencies. Must
- * not be <code>null</code> when the event type requires it.
- *
- * @see #getDependencies()
- */
- private final String[] dependencies;
- /**
- * Cause of the failure.
- *
- * @see #getCause()
- */
- private final Throwable cause;
- /**
- * Indicate if this event is a replay event or not.
- *
- * @see #isReplay()
- */
- private final boolean replay;
-
- /**
- * Create a simple <code>BlueprintEvent</code> object.
- *
- * @param type The type of this event.
- * @param bundle The Blueprint bundle associated with this event. This
- * parameter must not be <code>null</code>.
- * @param extenderBundle The Blueprint extender bundle that is generating
- * this event. This parameter must not be <code>null</code>.
- */
- public BlueprintEvent(int type, Bundle bundle, Bundle extenderBundle) {
- this(type, bundle, extenderBundle, null, null);
- }
-
- /**
- * Create a <code>BlueprintEvent</code> object associated with a set of
- * dependencies.
- *
- * @param type The type of this event.
- * @param bundle The Blueprint bundle associated with this event. This
- * parameter must not be <code>null</code>.
- * @param extenderBundle The Blueprint extender bundle that is generating
- * this event. This parameter must not be <code>null</code>.
- * @param dependencies An array of <code>String</code> filters for each
- * dependency associated with this event. Must be a non-empty array
- * for event types {@link #GRACE_PERIOD} and {@link #WAITING}. It is
- * optional for event type {@link #FAILURE}. Must be
- * <code>null</code> for other event types.
- */
- public BlueprintEvent(int type, Bundle bundle, Bundle extenderBundle,
- String[] dependencies) {
- this(type, bundle, extenderBundle, dependencies, null);
- }
-
- /**
- * Create a <code>BlueprintEvent</code> object associated with a failure
- * cause.
- *
- * @param type The type of this event.
- * @param bundle The Blueprint bundle associated with this event. This
- * parameter must not be <code>null</code>.
- * @param extenderBundle The Blueprint extender bundle that is generating
- * this event. This parameter must not be <code>null</code>.
- * @param cause A <code>Throwable</code> object describing the root cause of
- * the event. May be <code>null</code>.
- */
- public BlueprintEvent(int type, Bundle bundle, Bundle extenderBundle,
- Throwable cause) {
- this(type, bundle, extenderBundle, null, cause);
- }
-
- /**
- * Create a <code>BlueprintEvent</code> object associated with a failure
- * cause and a set of dependencies.
- *
- * @param type The type of this event.
- * @param bundle The Blueprint bundle associated with this event. This
- * parameter must not be <code>null</code>.
- * @param extenderBundle The Blueprint extender bundle that is generating
- * this event. This parameter must not be <code>null</code>.
- * @param dependencies An array of <code>String</code> filters for each
- * dependency associated with this event. Must be a non-empty array
- * for event types {@link #GRACE_PERIOD} and {@link #WAITING}. It is
- * optional for event type {@link #FAILURE}. Must be
- * <code>null</code> for other event types.
- * @param cause A <code>Throwable</code> object describing the root cause of
- * this event. May be <code>null</code>.
- */
- public BlueprintEvent(int type, Bundle bundle, Bundle extenderBundle,
- String[] dependencies, Throwable cause) {
- this.type = type;
- this.timestamp = System.currentTimeMillis();
- this.bundle = bundle;
- this.extenderBundle = extenderBundle;
- this.dependencies = dependencies;
- this.cause = cause;
- this.replay = false;
- if (bundle == null) {
- throw new NullPointerException("bundle must not be null");
- }
- if (extenderBundle == null) {
- throw new NullPointerException("extenderBundle must not be null");
- }
- switch (type) {
- case WAITING :
- case GRACE_PERIOD :
- if (dependencies == null) {
- throw new NullPointerException(
- "dependencies must not be null");
- }
- if (dependencies.length == 0) {
- throw new IllegalArgumentException(
- "dependencies must not be length zero");
- }
- break;
- case FAILURE :
- if ((dependencies != null) && (dependencies.length == 0)) {
- throw new IllegalArgumentException(
- "dependencies must not be length zero");
- }
- break;
- default :
- if (dependencies != null) {
- throw new IllegalArgumentException(
- "dependencies must be null");
- }
- break;
- }
- }
-
- /**
- * Create a new <code>BlueprintEvent</code> from the specified
- * <code>BlueprintEvent</code>. The <code>timestamp</code> property will be
- * copied from the original event and only the replay property will be
- * overridden with the given value.
- *
- * @param event The original <code>BlueprintEvent</code> to copy. Must not
- * be <code>null</code>.
- * @param replay <code>true</code> if this event should be used as a replay
- * event.
- */
- public BlueprintEvent(BlueprintEvent event, boolean replay) {
- this.type = event.type;
- this.timestamp = event.timestamp;
- this.bundle = event.bundle;
- this.extenderBundle = event.extenderBundle;
- this.dependencies = event.dependencies;
- this.cause = event.cause;
- this.replay = replay;
- }
-
- /**
- * Return the type of this event.
- * <p>
- * The type values are:
- * <ul>
- * <li>{@link #CREATING}</li>
- * <li>{@link #CREATED}</li>
- * <li>{@link #DESTROYING}</li>
- * <li>{@link #DESTROYED}</li>
- * <li>{@link #FAILURE}</li>
- * <li>{@link #GRACE_PERIOD}</li>
- * <li>{@link #WAITING}</li>
- * </ul>
- *
- * @return The type of this event.
- */
- public int getType() {
- return type;
- }
-
- /**
- * Return the time at which this event was created.
- *
- * @return The time at which this event was created.
- */
- public long getTimestamp() {
- return timestamp;
- }
-
- /**
- * Return the Blueprint bundle associated with this event.
- *
- * @return The Blueprint bundle associated with this event.
- */
- public Bundle getBundle() {
- return bundle;
- }
-
- /**
- * Return the Blueprint extender bundle that is generating this event.
- *
- * @return The Blueprint extender bundle that is generating this event.
- */
- public Bundle getExtenderBundle() {
- return extenderBundle;
- }
-
- /**
- * Return the filters identifying the missing dependencies that caused this
- * event.
- *
- * @return The filters identifying the missing dependencies that caused this
- * event if the event type is one of {@link #WAITING},
- * {@link #GRACE_PERIOD} or {@link #FAILURE} or <code>null</code>
- * for the other event types.
- */
- public String[] getDependencies() {
- return dependencies == null ? null : (String[]) dependencies.clone();
- }
-
- /**
- * Return the cause for this {@link #FAILURE} event.
- *
- * @return The cause of the failure for this event. May be <code>null</code>
- * .
- */
- public Throwable getCause() {
- return cause;
- }
-
- /**
- * Return whether this event is a replay event.
- *
- * @return <code>true</code> if this event is a replay event and
- * <code>false</code> otherwise.
- */
- public boolean isReplay() {
- return replay;
- }
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/container/BlueprintListener.java b/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/container/BlueprintListener.java
deleted file mode 100644
index 937898e..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/container/BlueprintListener.java
+++ /dev/null
@@ -1,52 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2008, 2009). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.service.blueprint.container;
-
-/**
- * A <code>BlueprintEvent</code> Listener.
- *
- * <p>
- * To receive Blueprint Events, a bundle must register a Blueprint Listener
- * service.
- *
- * After a Blueprint Listener is registered, the Blueprint extender must
- * synchronously send to this Blueprint Listener the last Blueprint Event for
- * each ready Blueprint bundle managed by this extender. This replay of
- * Blueprint Events is designed so that the new Blueprint Listener can be
- * informed of the state of each Blueprint bundle. Blueprint Events sent during
- * this replay will have the {@link BlueprintEvent#isReplay() isReplay()} flag
- * set. The Blueprint extender must ensure that this replay phase does not
- * interfere with new Blueprint Events so that the chronological order of all
- * Blueprint Events received by the Blueprint Listener is preserved. If the last
- * Blueprint Event for a given Blueprint bundle is
- * {@link BlueprintEvent#DESTROYED DESTROYED}, the extender must not send it
- * during this replay phase.
- *
- * @see BlueprintEvent
- * @ThreadSafe
- * @version $Revision: 7564 $
- */
-public interface BlueprintListener {
-
- /**
- * Receives notifications of a Blueprint Event.
- *
- * Implementers should quickly process the event and return.
- *
- * @param event The {@link BlueprintEvent}.
- */
- void blueprintEvent(BlueprintEvent event);
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/container/ComponentDefinitionException.java b/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/container/ComponentDefinitionException.java
deleted file mode 100644
index 0e29850..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/container/ComponentDefinitionException.java
+++ /dev/null
@@ -1,65 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2008, 2009). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.service.blueprint.container;
-
-/**
- * A Blueprint exception indicating that a component definition is in error.
- *
- * This exception is thrown when a configuration-related error occurs during
- * creation of a Blueprint Container.
- *
- * @version $Revision: 7556 $
- */
-public class ComponentDefinitionException extends RuntimeException {
- private static final long serialVersionUID = 1L;
-
- /**
- * Creates a Component Definition Exception with no message or exception
- * cause.
- */
- public ComponentDefinitionException() {
- super();
- }
-
- /**
- * Creates a Component Definition Exception with the specified message
- *
- * @param explanation The associated message.
- */
- public ComponentDefinitionException(String explanation) {
- super(explanation);
- }
-
- /**
- * Creates a Component Definition Exception with the specified message and
- * exception cause.
- *
- * @param explanation The associated message.
- * @param cause The cause of this exception.
- */
- public ComponentDefinitionException(String explanation, Throwable cause) {
- super(explanation, cause);
- }
-
- /**
- * Creates a Component Definition Exception with the exception cause.
- *
- * @param cause The cause of this exception.
- */
- public ComponentDefinitionException(Throwable cause) {
- super(cause);
- }
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/container/Converter.java b/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/container/Converter.java
deleted file mode 100644
index ca6517b..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/container/Converter.java
+++ /dev/null
@@ -1,51 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2008, 2009). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.service.blueprint.container;
-
-/**
- * Type converter to convert an object to a target type.
- *
- * @ThreadSafe
- * @version $Revision: 7564 $
- */
-public interface Converter {
-
- /**
- * Return if this converter is able to convert the specified object to the
- * specified type.
- *
- * @param sourceObject The source object <code>s</code> to convert.
- * @param targetType The target type <code>T</code>.
- *
- * @return <code>true</code> if the conversion is possible,
- * <code>false</code> otherwise.
- */
- boolean canConvert(Object sourceObject, ReifiedType targetType);
-
- /**
- * Convert the specified object to an instance of the specified type.
- *
- * @param sourceObject The source object <code>s</code> to convert.
- * @param targetType The target type <code>T</code>.
- * @return An instance with a type that is assignable from targetType's raw
- * class
- * @throws Exception If the conversion cannot succeed. This exception should
- * not be thrown when the {@link #canConvert canConvert} method has
- * returned <code>true</code>.
- */
- Object convert(Object sourceObject, ReifiedType targetType)
- throws Exception;
-}
\ No newline at end of file
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/container/EventConstants.java b/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/container/EventConstants.java
deleted file mode 100644
index d149ab0..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/container/EventConstants.java
+++ /dev/null
@@ -1,189 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2008, 2009). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.service.blueprint.container;
-
-/**
- * Event property names used in Event Admin events published by a Blueprint
- * Container.
- *
- * <p>
- * Each type of event is sent to a different topic:
- *
- * <p>
- * <code>org/osgi/service/blueprint/container/</code><em><event-type></em>
- *
- * <p>
- * where <em><event-type></em> can have the values
- * {@link BlueprintEvent#CREATING CREATING}, {@link BlueprintEvent#CREATED
- * CREATED}, {@link BlueprintEvent#DESTROYING DESTROYING},
- * {@link BlueprintEvent#DESTROYED DESTROYED}, {@link BlueprintEvent#FAILURE
- * FAILURE}, {@link BlueprintEvent#GRACE_PERIOD GRACE_PERIOD}, or
- * {@link BlueprintEvent#WAITING WAITING}.
- *
- * <p>
- * Such events have the following properties:
- * <ul>
- * <li>{@link #TYPE type}</li>
- * <li>{@link #EVENT event}</li>
- * <li>{@link #TIMESTAMP timestamp}</li>
- * <li>{@link #BUNDLE bundle}</li>
- * <li>{@link #BUNDLE_SYMBOLICNAME bundle.symbolicName}</li>
- * <li>{@link #BUNDLE_ID bundle.id}</li>
- * <li>{@link #BUNDLE_VERSION bundle.version}</li>
- * <li>{@link #EXTENDER_BUNDLE_SYMBOLICNAME extender.bundle.symbolicName}</li>
- * <li>{@link #EXTENDER_BUNDLE_ID extender.bundle.id}</li>
- * <li>{@link #EXTENDER_BUNDLE_VERSION extender.bundle.version}</li>
- * <li>{@link #DEPENDENCIES dependencies}</li>
- * <li>{@link #CAUSE cause}</li>
- * </ul>
- *
- * @Immutable
- * @version $Revision: 7564 $
- */
-public class EventConstants {
- private EventConstants() {
- // non-instantiable class
- }
-
- /**
- * The type of the event that has been issued. This property is of type
- * <code>Integer</code> and can take one of the values defined in
- * {@link BlueprintEvent}.
- */
- public static final String TYPE = "type";
-
- /**
- * The <code>BlueprintEvent</code> object that caused this event. This
- * property is of type {@link BlueprintEvent}.
- */
- public static final String EVENT = "event";
-
- /**
- * The time the event was created. This property is of type
- * <code>Long</code>.
- */
- public static final String TIMESTAMP = "timestamp";
-
- /**
- * The Blueprint bundle associated with this event. This property is of type
- * <code>Bundle</code>.
- */
- public static final String BUNDLE = "bundle";
-
- /**
- * The bundle id of the Blueprint bundle associated with this event. This
- * property is of type <code>Long</code>.
- */
- public static final String BUNDLE_ID = "bundle.id";
-
- /**
- * The bundle symbolic name of the Blueprint bundle associated with this
- * event. This property is of type <code>String</code>.
- */
- public static final String BUNDLE_SYMBOLICNAME = "bundle.symbolicName";
-
- /**
- * The bundle version of the Blueprint bundle associated with this event.
- * This property is of type <code>Version</code>.
- */
- public static final String BUNDLE_VERSION = "bundle.version";
-
- /**
- * The Blueprint extender bundle that is generating this event. This
- * property is of type <code>Bundle</code>.
- */
- public static final String EXTENDER_BUNDLE = "extender.bundle";
-
- /**
- * The bundle id of the Blueprint extender bundle that is generating this
- * event. This property is of type <code>Long</code>.
- */
- public static final String EXTENDER_BUNDLE_ID = "extender.bundle.id";
-
- /**
- * The bundle symbolic of the Blueprint extender bundle that is generating
- * this event. This property is of type <code>String</code>.
- */
- public static final String EXTENDER_BUNDLE_SYMBOLICNAME = "extender.bundle.symbolicName";
-
- /**
- * The bundle version of the Blueprint extender bundle that is generating
- * this event. This property is of type <code>Version</code>.
- */
- public static final String EXTENDER_BUNDLE_VERSION = "extender.bundle.version";
-
- /**
- * The filters identifying the missing dependencies that caused this event
- * for a {@link BlueprintEvent#FAILURE FAILURE},
- * {@link BlueprintEvent#GRACE_PERIOD GRACE_PERIOD}, or
- * {@link BlueprintEvent#WAITING WAITING} event. This property type is an
- * array of <code>String</code>.
- */
- public static final String DEPENDENCIES = "dependencies";
-
- /**
- * The cause for a {@link BlueprintEvent#FAILURE FAILURE} event. This
- * property is of type <code>Throwable</code>.
- */
- public static final String CAUSE = "cause";
-
- /**
- * Topic prefix for all events issued by the Blueprint Container
- */
- public static final String TOPIC_BLUEPRINT_EVENTS = "org/osgi/service/blueprint/container";
-
- /**
- * Topic for Blueprint Container CREATING events
- */
- public static final String TOPIC_CREATING = TOPIC_BLUEPRINT_EVENTS
- + "/CREATING";
-
- /**
- * Topic for Blueprint Container CREATED events
- */
- public static final String TOPIC_CREATED = TOPIC_BLUEPRINT_EVENTS
- + "/CREATED";
-
- /**
- * Topic for Blueprint Container DESTROYING events
- */
- public static final String TOPIC_DESTROYING = TOPIC_BLUEPRINT_EVENTS
- + "/DESTROYING";
-
- /**
- * Topic for Blueprint Container DESTROYED events
- */
- public static final String TOPIC_DESTROYED = TOPIC_BLUEPRINT_EVENTS
- + "/DESTROYED";
-
- /**
- * Topic for Blueprint Container FAILURE events
- */
- public static final String TOPIC_FAILURE = TOPIC_BLUEPRINT_EVENTS
- + "/FAILURE";
-
- /**
- * Topic for Blueprint Container GRACE_PERIOD events
- */
- public static final String TOPIC_GRACE_PERIOD = TOPIC_BLUEPRINT_EVENTS
- + "/GRACE_PERIOD";
-
- /**
- * Topic for Blueprint Container WAITING events
- */
- public static final String TOPIC_WAITING = TOPIC_BLUEPRINT_EVENTS
- + "/WAITING";
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/container/NoSuchComponentException.java b/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/container/NoSuchComponentException.java
deleted file mode 100644
index 0ee9b30..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/container/NoSuchComponentException.java
+++ /dev/null
@@ -1,65 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2008, 2009). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.service.blueprint.container;
-
-/**
- * A Blueprint exception indicating that a component does not exist in a
- * Blueprint Container.
- *
- * This exception is thrown when an attempt is made to create a component
- * instance or lookup Component Metadata using a component id that does not
- * exist in the Blueprint Container.
- *
- * @version $Revision: 7556 $
- */
-public class NoSuchComponentException extends RuntimeException {
- private static final long serialVersionUID = 1L;
- /**
- * The requested component id that generated the exception.
- */
- private final String componentId;
-
- /**
- * Create a No Such Component Exception for a non-existent component.
- *
- * @param msg The associated message.
- * @param id The id of the non-existent component.
- */
- public NoSuchComponentException(String msg, String id) {
- super(msg);
- this.componentId = id;
- }
-
- /**
- * Create a No Such Component Exception for a non-existent component.
- *
- * @param id The id of the non-existent component.
- */
- public NoSuchComponentException(String id) {
- super("No component with id '" + (id == null ? "<null>" : id)
- + "' could be found");
- this.componentId = id;
- }
-
- /**
- * Returns the id of the non-existent component.
- *
- * @return The id of the non-existent component.
- */
- public String getComponentId() {
- return componentId;
- }
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/container/ReifiedType.java b/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/container/ReifiedType.java
deleted file mode 100644
index a923bcd..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/container/ReifiedType.java
+++ /dev/null
@@ -1,127 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2008, 2009). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.service.blueprint.container;
-
-/**
- * Provides access to a concrete type and its optional generic type parameters.
- *
- * <p>
- * Java 5 and later support generic types. These types consist of a raw class
- * with type parameters. This class models such a <code>Type</code> class but
- * ensures that the type is <em>reified</em>. Reification means that the Type
- * graph associated with a Java 5 <code>Type</code> instance is traversed until
- * the type becomes a concrete class. This class is available with the
- * {@link #getRawClass()} method. The optional type parameters are recursively
- * represented as Reified Types.
- *
- * <p>
- * In Java 1.4, a class has by definition no type parameters. This class
- * implementation provides the Reified Type for Java 1.4 by making the raw class
- * the Java 1.4 class and using a Reified Type based on the <code>Object</code>
- * class for any requested type parameter.
- *
- * <p>
- * A Blueprint extender implementations can subclass this class and provide
- * access to the generic type parameter graph for conversion. Such a subclass
- * must <em>reify</em> the different Java 5 <code>Type</code> instances into the
- * reified form. That is, a form where the raw Class is available with its
- * optional type parameters as Reified Types.
- *
- * @Immutable
- * @version $Revision: 7564 $
- */
-public class ReifiedType {
- private final static ReifiedType OBJECT = new ReifiedType(Object.class);
-
- private final Class clazz;
-
- /**
- * Create a Reified Type for a raw Java class without any generic type
- * parameters. Subclasses can provide the optional generic type parameter
- * information. Without subclassing, this instance has no type parameters.
- *
- * @param clazz The raw class of the Reified Type.
- */
- public ReifiedType(Class clazz) {
- this.clazz = clazz;
- }
-
- /**
- * Return the raw class represented by this type.
- *
- * The raw class represents the concrete class that is associated with a
- * type declaration. This class could have been deduced from the generics
- * type parameter graph of the declaration. For example, in the following
- * example:
- *
- * <pre>
- * Map<String, ? extends Metadata>
- * </pre>
- *
- * The raw class is the Map class.
- *
- * @return The raw class represented by this type.
- */
- public Class getRawClass() {
- return clazz;
- }
-
- /**
- * Return a type parameter for this type.
- *
- * The type parameter refers to a parameter in a generic type declaration
- * given by the zero-based index <code>i</code>.
- *
- * For example, in the following example:
- *
- * <pre>
- * Map<String, ? extends Metadata>
- * </pre>
- *
- * type parameter 0 is <code>String</code>, and type parameter 1 is
- * <code>Metadata</code>.
- *
- * <p>
- * This implementation returns a Reified Type that has <code>Object</code>
- * as class. Any object is assignable to Object and therefore no conversion
- * is then necessary. This is compatible with versions of Java language
- * prior to Java 5.
- *
- * This method should be overridden by a subclass that provides access to
- * the generic type parameter information for Java 5 and later.
- *
- * @param i The zero-based index of the requested type parameter.
- * @return The <code>ReifiedType</code> for the generic type parameter at
- * the specified index.
- */
- public ReifiedType getActualTypeArgument(int i) {
- return OBJECT;
- }
-
- /**
- * Return the number of type parameters for this type.
- *
- * <p>
- * This implementation returns <code>0</code>. This method should be
- * overridden by a subclass that provides access to the generic type
- * parameter information for Java 5 and later.
- *
- * @return The number of type parameters for this type.
- */
- public int size() {
- return 0;
- }
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/container/ServiceUnavailableException.java b/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/container/ServiceUnavailableException.java
deleted file mode 100644
index e0ef284..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/container/ServiceUnavailableException.java
+++ /dev/null
@@ -1,69 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2008, 2009). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.service.blueprint.container;
-
-import org.osgi.framework.ServiceException;
-
-/**
- * A Blueprint exception indicating that a service is unavailable.
- *
- * This exception is thrown when an invocation is made on a service reference
- * and a backing service is not available.
- *
- * @version $Revision: 7556 $
- */
-public class ServiceUnavailableException extends ServiceException {
- private static final long serialVersionUID = 1L;
- /**
- * The filter string associated with the exception.
- */
- private final String filter;
-
- /**
- * Creates a Service Unavailable Exception with the specified message.
- *
- * @param message The associated message.
- * @param filter The filter used for the service lookup.
- */
- public ServiceUnavailableException(String message, String filter) {
- super(message, UNREGISTERED);
- this.filter = filter;
- }
-
- /**
- * Creates a Service Unavailable Exception with the specified message and
- * exception cause.
- *
- * @param message The associated message.
- * @param filter The filter used for the service lookup.
- * @param cause The cause of this exception.
- */
- public ServiceUnavailableException(String message, String filter,
- Throwable cause) {
- super(message, UNREGISTERED, cause);
- this.filter = filter;
- }
-
- /**
- * Returns the filter expression that a service would have needed to satisfy
- * in order for the invocation to proceed.
- *
- * @return The failing filter.
- */
- public String getFilter() {
- return this.filter;
- }
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/reflect/BeanArgument.java b/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/reflect/BeanArgument.java
deleted file mode 100644
index 9811a42..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/reflect/BeanArgument.java
+++ /dev/null
@@ -1,62 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2008, 2009). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.service.blueprint.reflect;
-
-/**
- * Metadata for a factory method or constructor argument of a bean. The
- * arguments of a bean are obtained from {@link BeanMetadata#getArguments()}.
- *
- * This is specified by the <code>argument</code> elements of a bean.
- *
- * @ThreadSafe
- * @version $Revision: 7563 $
- */
-public interface BeanArgument {
-
- /**
- * Return the Metadata for the argument value.
- *
- * This is specified by the <code>value</code> attribute.
- *
- * @return The Metadata for the argument value.
- */
- Metadata getValue();
-
- /**
- * Return the name of the value type to match the argument and convert the
- * value into when invoking the constructor or factory method.
- *
- * This is specified by the <code>type</code> attribute.
- *
- * @return The name of the value type to convert the value into, or
- * <code>null</code> if no type is specified.
- */
- String getValueType();
-
- /**
- * Return the zero-based index into the parameter list of the factory method
- * or constructor to be invoked for this argument. This is determined by
- * specifying the <code>index</code> attribute for the bean. If not
- * explicitly set, this will return -1 and the initial ordering is defined
- * by its position in the {@link BeanMetadata#getArguments()} list.
- *
- * This is specified by the <code>index</code> attribute.
- *
- * @return The zero-based index of the parameter, or -1 if no index is
- * specified.
- */
- int getIndex();
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/reflect/BeanMetadata.java b/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/reflect/BeanMetadata.java
deleted file mode 100644
index 1a28270..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/reflect/BeanMetadata.java
+++ /dev/null
@@ -1,144 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2008, 2009). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.service.blueprint.reflect;
-
-import java.util.List;
-
-/**
- * Metadata for a Bean component.
- *
- * <p>
- * This is specified by the <code>bean</code> element.
- *
- * @ThreadSafe
- * @version $Revision: 7773 $
- */
-public interface BeanMetadata extends Target, ComponentMetadata {
-
- /**
- * The bean has <code>singleton</code> scope.
- *
- * @see #getScope()
- */
- static final String SCOPE_SINGLETON = "singleton";
-
- /**
- * The bean has <code>prototype</code> scope.
- *
- * @see #getScope()
- */
- static final String SCOPE_PROTOTYPE = "prototype";
-
- /**
- * Return the name of the class specified for the bean.
- *
- * This is specified by the <code>class</code> attribute of the bean
- * definition.
- *
- * @return The name of the class specified for the bean. If no class is
- * specified in the bean definition, because the a factory component
- * is used instead, then this method will return <code>null</code>.
- */
- String getClassName();
-
- /**
- * Return the name of the init method specified for the bean.
- *
- * This is specified by the <code>init-method</code> attribute of the bean
- * definition.
- *
- * @return The name of the init method specified for the bean, or
- * <code>null</code> if no init method is specified.
- */
- String getInitMethod();
-
- /**
- * Return the name of the destroy method specified for the bean.
- *
- * This is specified by the <code>destroy-method</code> attribute of the
- * bean definition.
- *
- * @return The name of the destroy method specified for the bean, or
- * <code>null</code> if no destroy method is specified.
- */
- String getDestroyMethod();
-
- /**
- * Return the arguments for the factory method or constructor of the bean.
- *
- * This is specified by the child <code>argument<code> elements.
- *
- * @return An immutable List of {@link BeanArgument} objects for the factory
- * method or constructor of the bean. The List is empty if no
- * arguments are specified for the bean.
- */
- List/* <BeanArgument> */getArguments();
-
- /**
- * Return the properties for the bean.
- *
- * This is specified by the child <code>property</code> elements.
- *
- * @return An immutable List of {@link BeanProperty} objects, with one entry
- * for each property to be injected in the bean. The List is empty
- * if no property injection is specified for the bean.
- *
- */
- List /* <BeanProperty> */getProperties();
-
- /**
- * Return the name of the factory method for the bean.
- *
- * This is specified by the <code>factory-method</code> attribute of the
- * bean.
- *
- * @return The name of the factory method of the bean or <code>null</code>
- * if no factory method is specified for the bean.
- */
- String getFactoryMethod();
-
- /**
- * Return the Metadata for the factory component on which to invoke the
- * factory method for the bean.
- *
- * This is specified by the <code>factory-ref</code> attribute of the bean.
- *
- * <p>
- * When a factory method and factory component have been specified for the
- * bean, this method returns the factory component on which to invoke the
- * factory method for the bean. When no factory component has been specified
- * this method will return <code>null</code>.
- *
- * When a factory method has been specified for the bean but a factory
- * component has not been specified, the factory method must be invoked as a
- * static method on the bean's class.
- *
- * @return The Metadata for the factory component on which to invoke the
- * factory method for the bean or <code>null</code> if no factory
- * component is specified.
- */
- Target getFactoryComponent();
-
- /**
- * Return the scope for the bean.
- *
- * @return The scope for the bean. Returns <code>null</code> if the scope
- * has not been explicitly specified in the bean definition.
- * @see #SCOPE_SINGLETON
- * @see #SCOPE_PROTOTYPE
- */
- String getScope();
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/reflect/BeanProperty.java b/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/reflect/BeanProperty.java
deleted file mode 100644
index c65077d..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/reflect/BeanProperty.java
+++ /dev/null
@@ -1,48 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2008, 2009). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.service.blueprint.reflect;
-
-/**
- * Metadata for a property to be injected into a bean. The properties of a bean
- * are obtained from {@link BeanMetadata#getProperties()}.
- *
- * This is specified by the <code>property</code> elements of a bean. Properties
- * are defined according to the Java Beans conventions.
- *
- * @ThreadSafe
- * @version $Revision: 7563 $
- */
-public interface BeanProperty {
-
- /**
- * Return the name of the property to be injected. The name follows Java
- * Beans conventions.
- *
- * This is specified by the <code>name</code> attribute.
- *
- * @return The name of the property to be injected.
- */
- String getName();
-
- /**
- * Return the Metadata for the value to be injected into a bean.
- *
- * This is specified by the <code>value</code> attribute or in inlined text.
- *
- * @return The Metadata for the value to be injected into a bean.
- */
- Metadata getValue();
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/reflect/CollectionMetadata.java b/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/reflect/CollectionMetadata.java
deleted file mode 100644
index ff493ca..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/reflect/CollectionMetadata.java
+++ /dev/null
@@ -1,57 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2008, 2009). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.service.blueprint.reflect;
-
-import java.util.List;
-
-/**
- * Metadata for a collection based value. Values of the collection are defined
- * by Metadata objects. This Collection Metadata can constrain the values of the
- * collection to a specific type.
- *
- * @ThreadSafe
- * @version $Revision: 7563 $
- */
-
-public interface CollectionMetadata extends NonNullMetadata {
-
- /**
- * Return the type of the collection.
- *
- * The possible types are: array (<code>Object[]</code>), <code>Set</code>,
- * and <code>List</code>. This information is specified in the element name.
- *
- * @return The type of the collection. <code>Object[]</code> is returned to
- * indicate an array.
- */
- Class/* <?> */getCollectionClass();
-
- /**
- * Return the type specified for the values of the collection.
- *
- * The <code>value-type</code> attribute specified this information.
- *
- * @return The type specified for the values of the collection.
- */
- String getValueType();
-
- /**
- * Return Metadata for the values of the collection.
- *
- * @return A List of Metadata for the values of the collection.
- */
- List /* <Metadata> */getValues();
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/reflect/ComponentMetadata.java b/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/reflect/ComponentMetadata.java
deleted file mode 100644
index ddfb3a6..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/reflect/ComponentMetadata.java
+++ /dev/null
@@ -1,75 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2008, 2009). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.service.blueprint.reflect;
-
-import java.util.List;
-
-/**
- * Metadata for managed components. This is the base type for
- * {@link BeanMetadata}, {@link ServiceMetadata} and
- * {@link ServiceReferenceMetadata}.
- *
- * @ThreadSafe
- * @version $Revision: 7563 $
- */
-public interface ComponentMetadata extends NonNullMetadata {
-
- /**
- * The component's manager must eagerly activate the component.
- *
- * @see #getActivation()
- */
- static final int ACTIVATION_EAGER = 1;
-
- /**
- * The component's manager must lazily activate the component.
- *
- * @see #getActivation()
- */
- static final int ACTIVATION_LAZY = 2;
-
- /**
- * Return the id of the component.
- *
- * @return The id of the component. The component id can be
- * <code>null</code> if this is an anonymously defined and/or
- * inlined component.
- */
- String getId();
-
- /**
- * Return the activation strategy for the component.
- *
- * This is specified by the <code>activation</code> attribute of a component
- * definition. If this is not set, then the <code>default-activation</code>
- * in the <code>blueprint</code> element is used. If that is also not set,
- * then the activation strategy is {@link #ACTIVATION_EAGER}.
- *
- * @return The activation strategy for the component.
- * @see #ACTIVATION_EAGER
- * @see #ACTIVATION_LAZY
- */
- int getActivation();
-
- /**
- * Return the ids of any components listed in a <code>depends-on</code>
- * attribute for the component.
- *
- * @return An immutable List of component ids that are explicitly declared
- * as a dependency, or an empty List if none.
- */
- List/* <String> */getDependsOn();
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/reflect/IdRefMetadata.java b/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/reflect/IdRefMetadata.java
deleted file mode 100644
index d362873..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/reflect/IdRefMetadata.java
+++ /dev/null
@@ -1,36 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2008, 2009). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.service.blueprint.reflect;
-
-/**
- * Metadata for the verified id of another component managed by the Blueprint
- * Container. The id itself will be injected, not the component to which the id
- * refers. No implicit dependency is created.
- *
- * @ThreadSafe
- * @version $Revision: 7563 $
- */
-public interface IdRefMetadata extends NonNullMetadata {
- /**
- * Return the id of the referenced component.
- *
- * This is specified by the <code>component-id</code> attribute of a
- * component.
- *
- * @return The id of the referenced component.
- */
- String getComponentId();
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/reflect/MapEntry.java b/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/reflect/MapEntry.java
deleted file mode 100644
index 0635a74..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/reflect/MapEntry.java
+++ /dev/null
@@ -1,48 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2008, 2009). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.osgi.service.blueprint.reflect;
-
-/**
- * Metadata for a map entry.
- *
- * This type is used by {@link MapMetadata}, {@link PropsMetadata} and
- * {@link ServiceMetadata}.
- *
- * @ThreadSafe
- * @version $Revision: 7563 $
- */
-public interface MapEntry {
- /**
- * Return the Metadata for the key of the map entry.
- *
- * This is specified by the <code>key</code> attribute or element.
- *
- * @return The Metadata for the key of the map entry. This must not be
- * <code>null</code>.
- */
- NonNullMetadata getKey();
-
- /**
- * Return the Metadata for the value of the map entry.
- *
- * This is specified by the <code>value</code> attribute or element.
- *
- * @return The Metadata for the value of the map entry. This must not be
- * <code>null</code>.
- */
- Metadata getValue();
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/reflect/MapMetadata.java b/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/reflect/MapMetadata.java
deleted file mode 100644
index d6819ea..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/reflect/MapMetadata.java
+++ /dev/null
@@ -1,58 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2008, 2009). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.service.blueprint.reflect;
-
-import java.util.List;
-
-/**
- * Metadata for a Map based value.
- *
- * <p>
- * This is specified by the <code>map</code> element.
- *
- * @ThreadSafe
- * @version $Revision: 7563 $
- */
-public interface MapMetadata extends NonNullMetadata {
- /**
- * Return the name of the type of the map keys.
- *
- * This is specified by the <code>key-type</code> attribute of the map.
- *
- * @return The name of the type of the map keys, or <code>null</code> if
- * none is specified.
- */
- String getKeyType();
-
- /**
- * Return the name of the type of the map values.
- *
- * This is specified by the <code>value-type</code> attribute of the map.
- *
- * @return The name of the type of the map values, or <code>null</code> if
- * none is specified.
- */
- String getValueType();
-
- /**
- * Return the entries for the map.
- *
- * @return An immutable List of {@link MapEntry} objects for each entry in
- * the map. The List is empty if no entries are specified for the
- * map.
- */
- List /* <MapEntry> */getEntries();
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/reflect/Metadata.java b/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/reflect/Metadata.java
deleted file mode 100644
index b078993..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/reflect/Metadata.java
+++ /dev/null
@@ -1,26 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2009). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.service.blueprint.reflect;
-
-/**
- * Top level Metadata type. All Metdata types extends this base type.
- *
- * @ThreadSafe
- * @version $Revision: 7563 $
- */
-public interface Metadata {
- // marker interface
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/reflect/NonNullMetadata.java b/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/reflect/NonNullMetadata.java
deleted file mode 100644
index ea926e9..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/reflect/NonNullMetadata.java
+++ /dev/null
@@ -1,31 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2008, 2009). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.service.blueprint.reflect;
-
-/**
- * Metadata for a value that cannot <code>null</code>. All Metadata subtypes
- * extend this type except for {@link NullMetadata}.
- *
- * <p>
- * This Metadata type is used for keys in Maps because they cannot be
- * <code>null</code>.
- *
- * @ThreadSafe
- * @version $Revision: 7563 $
- */
-public interface NonNullMetadata extends Metadata {
- // marker interface
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/reflect/NullMetadata.java b/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/reflect/NullMetadata.java
deleted file mode 100644
index 2a26dcc..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/reflect/NullMetadata.java
+++ /dev/null
@@ -1,33 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2008, 2009). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.service.blueprint.reflect;
-
-/**
- * Metadata for a value specified to be <code>null</code> via the <null>
- * element.
- *
- * @ThreadSafe
- * @version $Revision: 7563 $
- */
-public interface NullMetadata extends Metadata {
-
- /**
- * Singleton instance of <code>NullMetadata</code>.
- */
- static final NullMetadata NULL = new NullMetadata() {
- // empty body
- };
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/reflect/PropsMetadata.java b/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/reflect/PropsMetadata.java
deleted file mode 100644
index 7edb347..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/reflect/PropsMetadata.java
+++ /dev/null
@@ -1,43 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2008, 2009). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.service.blueprint.reflect;
-
-import java.util.List;
-
-/**
- * Metadata for a <code>java.util.Properties</code> based value.
- *
- * <p>
- * The {@link MapEntry} objects of properties are defined with keys and values
- * of type <code>String</code>.
- *
- * <p>
- * This is specified by the <code>props</code> element.
- *
- * @ThreadSafe
- * @version $Revision: 7564 $
- */
-public interface PropsMetadata extends NonNullMetadata {
-
- /**
- * Return the entries for the properties.
- *
- * @return An immutable List of {@link MapEntry} objects for each entry in
- * the properties. The List is empty if no entries are specified for
- * the properties.
- */
- List/* <MapEntry> */getEntries();
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/reflect/RefMetadata.java b/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/reflect/RefMetadata.java
deleted file mode 100644
index 8746b0f..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/reflect/RefMetadata.java
+++ /dev/null
@@ -1,35 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2008, 2009). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.service.blueprint.reflect;
-
-/**
- * Metadata for a reference to another component managed by the Blueprint
- * Container.
- *
- * @ThreadSafe
- * @version $Revision: 7563 $
- */
-public interface RefMetadata extends Target, NonNullMetadata {
- /**
- * Return the id of the referenced component.
- *
- * This is specified by the <code>component-id</code> attribute of a
- * component.
- *
- * @return The id of the referenced component.
- */
- String getComponentId();
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/reflect/ReferenceListMetadata.java b/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/reflect/ReferenceListMetadata.java
deleted file mode 100644
index a03618e..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/reflect/ReferenceListMetadata.java
+++ /dev/null
@@ -1,56 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2008, 2009). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.service.blueprint.reflect;
-
-/**
- * Metadata for a list of service references.
- *
- * <p>
- * This is specified by the <code>reference-list</code> element.
- *
- * @ThreadSafe
- * @version $Revision: 7563 $
- */
-public interface ReferenceListMetadata extends ServiceReferenceMetadata {
-
- /**
- * Reference list values must be proxies to the actual service objects.
- *
- * @see #getMemberType()
- */
- static final int USE_SERVICE_OBJECT = 1;
-
- /**
- * Reference list values must be <code>ServiceReference</code> objects.
- *
- * @see #getMemberType()
- */
- static final int USE_SERVICE_REFERENCE = 2;
-
- /**
- * Return whether the List will contain service object proxies or
- * <code>ServiceReference</code> objects.
- *
- * This is specified by the <code>member-type</code> attribute of the
- * reference list.
- *
- * @return Whether the List will contain service object proxies or
- * <code>ServiceReference</code> objects.
- * @see #USE_SERVICE_OBJECT
- * @see #USE_SERVICE_REFERENCE
- */
- int getMemberType();
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/reflect/ReferenceListener.java b/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/reflect/ReferenceListener.java
deleted file mode 100644
index fa24577..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/reflect/ReferenceListener.java
+++ /dev/null
@@ -1,60 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2008, 2009). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.service.blueprint.reflect;
-
-/**
- * Metadata for a reference listener interested in the reference bind and unbind
- * events for a service reference.
- *
- * @ThreadSafe
- * @version $Revision: 7563 $
- */
-public interface ReferenceListener {
-
- /**
- * Return the Metadata for the component that will receive bind and unbind
- * events.
- *
- * This is specified by the <code>ref</code> attribute or via an inlined
- * component.
- *
- * @return The Metadata for the component that will receive bind and unbind
- * events.
- */
- Target getListenerComponent();
-
- /**
- * Return the name of the bind method. The bind method will be invoked when
- * a matching service is bound to the reference.
- *
- * This is specified by the <code>bind-method</code> attribute of the
- * reference listener.
- *
- * @return The name of the bind method.
- */
- String getBindMethod();
-
- /**
- * Return the name of the unbind method. The unbind method will be invoked
- * when a matching service is unbound from the reference.
- *
- * This is specified by the <code>unbind-method</code> attribute of the
- * reference listener.
- *
- * @return The name of the unbind method.
- */
- String getUnbindMethod();
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/reflect/ReferenceMetadata.java b/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/reflect/ReferenceMetadata.java
deleted file mode 100644
index 55f2db7..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/reflect/ReferenceMetadata.java
+++ /dev/null
@@ -1,40 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2008, 2009). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.service.blueprint.reflect;
-
-/**
- * Metadata for a reference that will bind to a single matching service in the
- * service registry.
- *
- * <p>
- * This is specified by the <code>reference</code> element.
- *
- * @ThreadSafe
- * @version $Revision: 7563 $
- */
-public interface ReferenceMetadata extends Target, ServiceReferenceMetadata {
-
- /**
- * Return the timeout for service invocations when a backing service is is
- * unavailable.
- *
- * This is specified by the <code>timeout</code> attribute of the reference.
- *
- * @return The timeout, in milliseconds, for service invocations when a
- * backing service is is unavailable.
- */
- long getTimeout();
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/reflect/RegistrationListener.java b/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/reflect/RegistrationListener.java
deleted file mode 100644
index 77dc5fc..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/reflect/RegistrationListener.java
+++ /dev/null
@@ -1,66 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2008, 2009). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.service.blueprint.reflect;
-
-/**
- * Metadata for a registration listener interested in service registration and
- * unregistration events for a service.
- *
- * <p>
- * The registration listener is called with the initial state of the service
- * when the registration listener is actuated.
- *
- * @ThreadSafe
- * @version $Revision: 7563 $
- */
-public interface RegistrationListener {
-
- /**
- * Return the Metadata for the component that will receive registration and
- * unregistration events.
- *
- * This is specified by the <code>ref</code> attribute or via an inlined
- * component.
- *
- * @return The Metadata for the component that will receive registration and
- * unregistration events.
- */
- Target getListenerComponent();
-
- /**
- * Return the name of the registration method. The registration method will
- * be invoked when the associated service is registered with the service
- * registry.
- *
- * This is specified by the <code>registration-method</code> attribute of
- * the registration listener.
- *
- * @return The name of the registration method.
- */
- String getRegistrationMethod();
-
- /**
- * Return the name of the unregistration method. The unregistration method
- * will be invoked when the associated service is unregistered from the
- * service registry.
- *
- * This is specified by the <code>unregistration-method</code> attribute of
- * the registration listener.
- *
- * @return The name of the unregistration method.
- */
- String getUnregistrationMethod();
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/reflect/ServiceMetadata.java b/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/reflect/ServiceMetadata.java
deleted file mode 100644
index 86728b1..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/reflect/ServiceMetadata.java
+++ /dev/null
@@ -1,138 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2008, 2009). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.service.blueprint.reflect;
-
-import java.util.Collection;
-import java.util.List;
-
-/**
- * Metadata for a service to be registered by the Blueprint Container when
- * enabled.
- *
- * <p>
- * This is specified by the <code>service</code> element.
- *
- * @ThreadSafe
- * @version $Revision: 7563 $
- */
-public interface ServiceMetadata extends ComponentMetadata {
-
- /**
- * Do not auto-detect types for advertised service interfaces
- *
- * @see #getAutoExport()
- */
- static final int AUTO_EXPORT_DISABLED = 1;
-
- /**
- * Advertise all Java interfaces implemented by the component instance type
- * as service interfaces.
- *
- * @see #getAutoExport()
- */
- static final int AUTO_EXPORT_INTERFACES = 2;
-
- /**
- * Advertise all Java classes in the hierarchy of the component instance
- * type as service interfaces.
- *
- * @see #getAutoExport()
- */
- static final int AUTO_EXPORT_CLASS_HIERARCHY = 3;
-
- /**
- * Advertise all Java classes and interfaces in the component instance type
- * as service interfaces.
- *
- * @see #getAutoExport()
- */
- static final int AUTO_EXPORT_ALL_CLASSES = 4;
-
- /**
- * Return the Metadata for the component to be exported as a service.
- *
- * This is specified inline or via the <code>ref</code> attribute of the
- * service.
- *
- * @return The Metadata for the component to be exported as a service.
- */
- Target getServiceComponent();
-
- /**
- * Return the type names of the interfaces that the service should be
- * advertised as supporting.
- *
- * This is specified in the <code>interface</code> attribute or child
- * <code>interfaces</code> element of the service.
- *
- * @return An immutable List of <code>String</code> for the type names of
- * the interfaces that the service should be advertised as
- * supporting. The List is empty if using <code>auto-export</code>
- * or no interface names are specified for the service.
- */
- List/* <String> */getInterfaces();
-
- /**
- * Return the auto-export mode for the service.
- *
- * This is specified by the <code>auto-export</code> attribute of the
- * service.
- *
- * @return The auto-export mode for the service.
- * @see #AUTO_EXPORT_DISABLED
- * @see #AUTO_EXPORT_INTERFACES
- * @see #AUTO_EXPORT_CLASS_HIERARCHY
- * @see #AUTO_EXPORT_ALL_CLASSES
- */
- int getAutoExport();
-
- /**
- * Return the user declared properties to be advertised with the service.
- *
- * This is specified by the <code>service-properties</code> element of the
- * service.
- *
- * @return An immutable List of {@link MapEntry} objects for the user
- * declared properties to be advertised with the service. The List
- * is empty if no service properties are specified for the service.
- */
- List/* <MapEntry> */getServiceProperties();
-
- /**
- * Return the ranking value to use when advertising the service. If the
- * ranking value is zero, the service must be registered without a
- * <code>service.ranking</code> service property.
- *
- * This is specified by the <code>ranking</code> attribute of the service.
- *
- * @return The ranking value to use when advertising the service.
- */
- int getRanking();
-
- /**
- * Return the registration listeners to be notified when the service is
- * registered and unregistered with the framework.
- *
- * This is specified by the <code>registration-listener</code> elements of
- * the service.
- *
- * @return An immutable Collection of {@link RegistrationListener} objects
- * to be notified when the service is registered and unregistered
- * with the framework. The Collection is empty if no registration
- * listeners are specified for the service.
- */
- Collection /* <RegistrationListener> */getRegistrationListeners();
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/reflect/ServiceReferenceMetadata.java b/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/reflect/ServiceReferenceMetadata.java
deleted file mode 100644
index e57577e..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/reflect/ServiceReferenceMetadata.java
+++ /dev/null
@@ -1,102 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2008, 2009). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.service.blueprint.reflect;
-
-import java.util.Collection;
-
-/**
- * Metadata for a reference to an OSGi service. This is the base type for
- * {@link ReferenceListMetadata} and {@link ReferenceMetadata}.
- *
- * @ThreadSafe
- * @version $Revision: 7563 $
- */
-public interface ServiceReferenceMetadata extends ComponentMetadata {
-
- /**
- * A matching service is required at all times.
- *
- * @see #getAvailability()
- */
- static final int AVAILABILITY_MANDATORY = 1;
-
- /**
- * A matching service is not required to be present.
- *
- * @see #getAvailability()
- */
- static final int AVAILABILITY_OPTIONAL = 2;
-
- /**
- * Return whether or not a matching service is required at all times.
- *
- * This is specified in the <code>availability</code> attribute of the
- * service reference.
- *
- * @return Whether or not a matching service is required at all times.
- * @see #AVAILABILITY_MANDATORY
- * @see #AVAILABILITY_OPTIONAL
- */
- int getAvailability();
-
- /**
- * Return the name of the interface type that a matching service must
- * support.
- *
- * This is specified in the <code>interface</code> attribute of the service
- * reference.
- *
- * @return The name of the interface type that a matching service must
- * support or <code>null</code> when no interface name is specified.
- */
- String getInterface();
-
- /**
- * Return the value of the <code>component-name</code> attribute of the
- * service reference. This specifies the id of a component that is
- * registered in the service registry. This will create an automatic filter,
- * appended with the filter if set, to select this component based on its
- * automatic <code>id</code> attribute.
- *
- * @return The value of the <code>component-name</code> attribute of the
- * service reference or <code>null</code> if the attribute is not
- * specified.
- */
- String getComponentName();
-
- /**
- * Return the filter expression that a matching service must match.
- *
- * This is specified by the <code>filter</code> attribute of the service
- * reference.
- *
- * @return The filter expression that a matching service must match or
- * <code>null</code> if a filter is not specified.
- */
- String getFilter();
-
- /**
- * Return the reference listeners to receive bind and unbind events.
- *
- * This is specified by the <code>reference-listener</code> elements of the
- * service reference.
- *
- * @return An immutable Collection of {@link ReferenceListener} objects to
- * receive bind and unbind events. The Collection is empty if no
- * reference listeners are specified for the service reference.
- */
- Collection /* <ReferenceListener> */getReferenceListeners();
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/reflect/Target.java b/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/reflect/Target.java
deleted file mode 100644
index a96a4b0..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/reflect/Target.java
+++ /dev/null
@@ -1,32 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2008, 2009). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.service.blueprint.reflect;
-
-/**
- * A common interface for managed components that can be used as a direct target
- * for method calls. These are <code>bean</code>, <code>reference</code>, and
- * <code>ref</code>, where the <code>ref</code> must refer to a bean or
- * reference component.
- *
- * @see BeanMetadata
- * @see ReferenceMetadata
- * @see RefMetadata
- * @ThreadSafe
- * @version $Revision: 7563 $
- */
-public interface Target extends NonNullMetadata {
- // marker interface
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/reflect/ValueMetadata.java b/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/reflect/ValueMetadata.java
deleted file mode 100644
index 7609234..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/blueprint/reflect/ValueMetadata.java
+++ /dev/null
@@ -1,45 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2008, 2009). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.service.blueprint.reflect;
-
-/**
- * Metadata for a simple <code>String</code> value that will be type-converted
- * if necessary before injecting.
- *
- * @ThreadSafe
- * @version $Revision: 7563 $
- */
-public interface ValueMetadata extends NonNullMetadata {
- /**
- * Return the unconverted string representation of the value.
- *
- * This is specified by the <code>value</code> attribute or text part of the
- * <code>value</code> element.
- *
- * @return The unconverted string representation of the value.
- */
- String getStringValue();
-
- /**
- * Return the name of the type to which the value should be converted.
- *
- * This is specified by the <code>type</code> attribute.
- *
- * @return The name of the type to which the value should be converted or
- * <code>null</code> if no type is specified.
- */
- String getType();
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/cm/Configuration.java b/org.osgi.compendium/src/main/java/org/osgi/service/cm/Configuration.java
deleted file mode 100644
index 7c17cf1..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/cm/Configuration.java
+++ /dev/null
@@ -1,225 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2001, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.service.cm;
-
-import java.io.IOException;
-import java.util.Dictionary;
-
-/**
- * The configuration information for a <code>ManagedService</code> or
- * <code>ManagedServiceFactory</code> object.
- *
- * The Configuration Admin service uses this interface to represent the
- * configuration information for a <code>ManagedService</code> or for a
- * service instance of a <code>ManagedServiceFactory</code>.
- *
- * <p>
- * A <code>Configuration</code> object contains a configuration dictionary and
- * allows the properties to be updated via this object. Bundles wishing to
- * receive configuration dictionaries do not need to use this class - they
- * register a <code>ManagedService</code> or
- * <code>ManagedServiceFactory</code>. Only administrative bundles, and
- * bundles wishing to update their own configurations need to use this class.
- *
- * <p>
- * The properties handled in this configuration have case insensitive
- * <code>String</code> objects as keys. However, case is preserved from the
- * last set key/value.
- * <p>
- * A configuration can be <i>bound </i> to a bundle location (
- * <code>Bundle.getLocation()</code>). The purpose of binding a
- * <code>Configuration</code> object to a location is to make it impossible
- * for another bundle to forge a PID that would match this configuration. When a
- * configuration is bound to a specific location, and a bundle with a different
- * location registers a corresponding <code>ManagedService</code> object or
- * <code>ManagedServiceFactory</code> object, then the configuration is not
- * passed to the updated method of that object.
- *
- * <p>
- * If a configuration's location is <code>null</code>, it is not yet bound to
- * a location. It will become bound to the location of the first bundle that
- * registers a <code>ManagedService</code> or
- * <code>ManagedServiceFactory</code> object with the corresponding PID.
- * <p>
- * The same <code>Configuration</code> object is used for configuring both a
- * Managed Service Factory and a Managed Service. When it is important to
- * differentiate between these two the term "factory configuration" is used.
- *
- * @version $Revision: 5673 $
- */
-public interface Configuration {
- /**
- * Get the PID for this <code>Configuration</code> object.
- *
- * @return the PID for this <code>Configuration</code> object.
- * @throws IllegalStateException if this configuration has been deleted
- */
- public String getPid();
-
- /**
- * Return the properties of this <code>Configuration</code> object.
- *
- * The <code>Dictionary</code> object returned is a private copy for the
- * caller and may be changed without influencing the stored configuration.
- * The keys in the returned dictionary are case insensitive and are always
- * of type <code>String</code>.
- *
- * <p>
- * If called just after the configuration is created and before update has
- * been called, this method returns <code>null</code>.
- *
- * @return A private copy of the properties for the caller or
- * <code>null</code>. These properties must not contain the
- * "service.bundleLocation" property. The value of this property may
- * be obtained from the <code>getBundleLocation</code> method.
- * @throws IllegalStateException if this configuration has been deleted
- */
- public Dictionary getProperties();
-
- /**
- * Update the properties of this <code>Configuration</code> object.
- *
- * Stores the properties in persistent storage after adding or overwriting
- * the following properties:
- * <ul>
- * <li>"service.pid" : is set to be the PID of this configuration.</li>
- * <li>"service.factoryPid" : if this is a factory configuration it is set
- * to the factory PID else it is not set.</li>
- * </ul>
- * These system properties are all of type <code>String</code>.
- *
- * <p>
- * If the corresponding Managed Service/Managed Service Factory is
- * registered, its updated method must be called asynchronously. Else, this
- * callback is delayed until aforementioned registration occurs.
- *
- * <p>
- * Also initiates an asynchronous call to all
- * <code>ConfigurationListener</code>s with a
- * <code>ConfigurationEvent.CM_UPDATED</code> event.
- *
- * @param properties the new set of properties for this configuration
- * @throws IOException if update cannot be made persistent
- * @throws IllegalArgumentException if the <code>Dictionary</code> object
- * contains invalid configuration types or contains case variants of
- * the same key name.
- * @throws IllegalStateException if this configuration has been deleted
- */
- public void update(Dictionary properties) throws IOException;
-
- /**
- * Delete this <code>Configuration</code> object.
- *
- * Removes this configuration object from the persistent store. Notify
- * asynchronously the corresponding Managed Service or Managed Service
- * Factory. A <code>ManagedService</code> object is notified by a call to
- * its <code>updated</code> method with a <code>null</code> properties
- * argument. A <code>ManagedServiceFactory</code> object is notified by a
- * call to its <code>deleted</code> method.
- *
- * <p>
- * Also initiates an asynchronous call to all
- * <code>ConfigurationListener</code>s with a
- * <code>ConfigurationEvent.CM_DELETED</code> event.
- *
- * @throws IOException If delete fails
- * @throws IllegalStateException if this configuration has been deleted
- */
- public void delete() throws IOException;
-
- /**
- * For a factory configuration return the PID of the corresponding Managed
- * Service Factory, else return <code>null</code>.
- *
- * @return factory PID or <code>null</code>
- * @throws IllegalStateException if this configuration has been deleted
- */
- public String getFactoryPid();
-
- /**
- * Update the <code>Configuration</code> object with the current
- * properties.
- *
- * Initiate the <code>updated</code> callback to the Managed Service or
- * Managed Service Factory with the current properties asynchronously.
- *
- * <p>
- * This is the only way for a bundle that uses a Configuration Plugin
- * service to initiate a callback. For example, when that bundle detects a
- * change that requires an update of the Managed Service or Managed Service
- * Factory via its <code>ConfigurationPlugin</code> object.
- *
- * @see ConfigurationPlugin
- * @throws IOException if update cannot access the properties in persistent
- * storage
- * @throws IllegalStateException if this configuration has been deleted
- */
- public void update() throws IOException;
-
- /**
- * Bind this <code>Configuration</code> object to the specified bundle
- * location.
- *
- * If the bundleLocation parameter is <code>null</code> then the
- * <code>Configuration</code> object will not be bound to a location. It
- * will be set to the bundle's location before the first time a Managed
- * Service/Managed Service Factory receives this <code>Configuration</code>
- * object via the updated method and before any plugins are called. The
- * bundle location will be set persistently.
- *
- * @param bundleLocation a bundle location or <code>null</code>
- * @throws IllegalStateException If this configuration has been deleted.
- * @throws SecurityException If the caller does not have
- * <code>ConfigurationPermission[*,CONFIGURE]</code>.
- */
- public void setBundleLocation(String bundleLocation);
-
- /**
- * Get the bundle location.
- *
- * Returns the bundle location to which this configuration is bound, or
- * <code>null</code> if it is not yet bound to a bundle location.
- *
- * @return location to which this configuration is bound, or
- * <code>null</code>.
- * @throws IllegalStateException If this <code>Configuration</code> object
- * has been deleted.
- * @throws SecurityException If the caller does not have
- * <code>ConfigurationPermission[*,CONFIGURE]</code>.
- */
- public String getBundleLocation();
-
- /**
- * Equality is defined to have equal PIDs
- *
- * Two Configuration objects are equal when their PIDs are equal.
- *
- * @param other <code>Configuration</code> object to compare against
- * @return <code>true</code> if equal, <code>false</code> if not a
- * <code>Configuration</code> object or one with a different PID.
- */
- public boolean equals(Object other);
-
- /**
- * Hash code is based on PID.
- *
- * The hashcode for two Configuration objects must be the same when the
- * Configuration PID's are the same.
- *
- * @return hash code for this Configuration object
- */
- public int hashCode();
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/cm/ConfigurationAdmin.java b/org.osgi.compendium/src/main/java/org/osgi/service/cm/ConfigurationAdmin.java
deleted file mode 100644
index 066548f..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/cm/ConfigurationAdmin.java
+++ /dev/null
@@ -1,255 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2001, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.service.cm;
-
-import java.io.IOException;
-import java.util.Dictionary;
-
-import org.osgi.framework.InvalidSyntaxException;
-
-/**
- * Service for administering configuration data.
- *
- * <p>
- * The main purpose of this interface is to store bundle configuration data
- * persistently. This information is represented in <code>Configuration</code>
- * objects. The actual configuration data is a <code>Dictionary</code> of
- * properties inside a <code>Configuration</code> object.
- *
- * <p>
- * There are two principally different ways to manage configurations. First
- * there is the concept of a Managed Service, where configuration data is
- * uniquely associated with an object registered with the service registry.
- *
- * <p>
- * Next, there is the concept of a factory where the Configuration Admin service
- * will maintain 0 or more <code>Configuration</code> objects for a Managed
- * Service Factory that is registered with the Framework.
- *
- * <p>
- * The first concept is intended for configuration data about "things/services"
- * whose existence is defined externally, e.g. a specific printer. Factories are
- * intended for "things/services" that can be created any number of times, e.g.
- * a configuration for a DHCP server for different networks.
- *
- * <p>
- * Bundles that require configuration should register a Managed Service or a
- * Managed Service Factory in the service registry. A registration property
- * named <code>service.pid</code> (persistent identifier or PID) must be used to
- * identify this Managed Service or Managed Service Factory to the Configuration
- * Admin service.
- *
- * <p>
- * When the ConfigurationAdmin detects the registration of a Managed Service, it
- * checks its persistent storage for a configuration object whose
- * <code>service.pid</code> property matches the PID service property (
- * <code>service.pid</code>) of the Managed Service. If found, it calls
- * {@link ManagedService#updated} method with the new properties. The
- * implementation of a Configuration Admin service must run these call-backs
- * asynchronously to allow proper synchronization.
- *
- * <p>
- * When the Configuration Admin service detects a Managed Service Factory
- * registration, it checks its storage for configuration objects whose
- * <code>service.factoryPid</code> property matches the PID service property of
- * the Managed Service Factory. For each such <code>Configuration</code>
- * objects, it calls the <code>ManagedServiceFactory.updated</code> method
- * asynchronously with the new properties. The calls to the <code>updated</code>
- * method of a <code>ManagedServiceFactory</code> must be executed sequentially
- * and not overlap in time.
- *
- * <p>
- * In general, bundles having permission to use the Configuration Admin service
- * can only access and modify their own configuration information. Accessing or
- * modifying the configuration of another bundle requires
- * <code>ConfigurationPermission[*,CONFIGURE]</code>.
- *
- * <p>
- * <code>Configuration</code> objects can be <i>bound </i> to a specified bundle
- * location. In this case, if a matching Managed Service or Managed Service
- * Factory is registered by a bundle with a different location, then the
- * Configuration Admin service must not do the normal callback, and it should
- * log an error. In the case where a <code>Configuration</code> object is not
- * bound, its location field is <code>null</code>, the Configuration Admin
- * service will bind it to the location of the bundle that registers the first
- * Managed Service or Managed Service Factory that has a corresponding PID
- * property. When a <code>Configuration</code> object is bound to a bundle
- * location in this manner, the Configuration Admin service must detect if the
- * bundle corresponding to the location is uninstalled. If this occurs, the
- * <code>Configuration</code> object is unbound, that is its location field is
- * set back to <code>null</code>.
- *
- * <p>
- * The method descriptions of this class refer to a concept of "the calling
- * bundle". This is a loose way of referring to the bundle which obtained the
- * Configuration Admin service from the service registry. Implementations of
- * <code>ConfigurationAdmin</code> must use a
- * {@link org.osgi.framework.ServiceFactory} to support this concept.
- *
- * @version $Revision: 7356 $
- */
-public interface ConfigurationAdmin {
- /**
- * Configuration property naming the Factory PID in the configuration
- * dictionary. The property's value is of type <code>String</code>.
- *
- * @since 1.1
- */
- public final static String SERVICE_FACTORYPID = "service.factoryPid";
- /**
- * Configuration property naming the location of the bundle that is
- * associated with a a <code>Configuration</code> object. This property can
- * be searched for but must not appear in the configuration dictionary for
- * security reason. The property's value is of type <code>String</code>.
- *
- * @since 1.1
- */
- public final static String SERVICE_BUNDLELOCATION = "service.bundleLocation";
-
- /**
- * Create a new factory <code>Configuration</code> object with a new PID.
- *
- * The properties of the new <code>Configuration</code> object are
- * <code>null</code> until the first time that its
- * {@link Configuration#update(Dictionary)} method is called.
- *
- * <p>
- * It is not required that the <code>factoryPid</code> maps to a
- * registered Managed Service Factory.
- * <p>
- * The <code>Configuration</code> object is bound to the location of the
- * calling bundle.
- *
- * @param factoryPid PID of factory (not <code>null</code>).
- * @return A new <code>Configuration</code> object.
- * @throws IOException if access to persistent storage fails.
- * @throws SecurityException if caller does not have <code>ConfigurationPermission[*,CONFIGURE]</code> and <code>factoryPid</code> is bound to another bundle.
- */
- public Configuration createFactoryConfiguration(String factoryPid)
- throws IOException;
-
- /**
- * Create a new factory <code>Configuration</code> object with a new PID.
- *
- * The properties of the new <code>Configuration</code> object are
- * <code>null</code> until the first time that its
- * {@link Configuration#update(Dictionary)} method is called.
- *
- * <p>
- * It is not required that the <code>factoryPid</code> maps to a
- * registered Managed Service Factory.
- *
- * <p>
- * The <code>Configuration</code> is bound to the location specified. If
- * this location is <code>null</code> it will be bound to the location of
- * the first bundle that registers a Managed Service Factory with a
- * corresponding PID.
- *
- * @param factoryPid PID of factory (not <code>null</code>).
- * @param location A bundle location string, or <code>null</code>.
- * @return a new <code>Configuration</code> object.
- * @throws IOException if access to persistent storage fails.
- * @throws SecurityException if caller does not have <code>ConfigurationPermission[*,CONFIGURE]</code>.
- */
- public Configuration createFactoryConfiguration(String factoryPid, String location)
- throws IOException;
-
- /**
- * Get an existing <code>Configuration</code> object from the persistent
- * store, or create a new <code>Configuration</code> object.
- *
- * <p>
- * If a <code>Configuration</code> with this PID already exists in
- * Configuration Admin service return it. The location parameter is ignored
- * in this case.
- *
- * <p>
- * Else, return a new <code>Configuration</code> object. This new object
- * is bound to the location and the properties are set to <code>null</code>.
- * If the location parameter is <code>null</code>, it will be set when a
- * Managed Service with the corresponding PID is registered for the first
- * time.
- *
- * @param pid Persistent identifier.
- * @param location The bundle location string, or <code>null</code>.
- * @return An existing or new <code>Configuration</code> object.
- * @throws IOException if access to persistent storage fails.
- * @throws SecurityException if the caller does not have <code>ConfigurationPermission[*,CONFIGURE]</code>.
- */
- public Configuration getConfiguration(String pid, String location)
- throws IOException;
-
- /**
- * Get an existing or new <code>Configuration</code> object from the
- * persistent store.
- *
- * If the <code>Configuration</code> object for this PID does not exist,
- * create a new <code>Configuration</code> object for that PID, where
- * properties are <code>null</code>. Bind its location to the calling
- * bundle's location.
- *
- * <p>
- * Otherwise, if the location of the existing <code>Configuration</code> object
- * is <code>null</code>, set it to the calling bundle's location.
- *
- * @param pid persistent identifier.
- * @return an existing or new <code>Configuration</code> matching the PID.
- * @throws IOException if access to persistent storage fails.
- * @throws SecurityException if the <code>Configuration</code> object is bound to a location different from that of the calling bundle and it has no <code>ConfigurationPermission[*,CONFIGURE]</code>.
- */
- public Configuration getConfiguration(String pid) throws IOException;
-
- /**
- * List the current <code>Configuration</code> objects which match the
- * filter.
- *
- * <p>
- * Only <code>Configuration</code> objects with non- <code>null</code>
- * properties are considered current. That is,
- * <code>Configuration.getProperties()</code> is guaranteed not to return
- * <code>null</code> for each of the returned <code>Configuration</code>
- * objects.
- *
- * <p>
- * Normally only <code>Configuration</code> objects that are bound to the
- * location of the calling bundle are returned, or all if the caller has
- * <code>ConfigurationPermission[*,CONFIGURE]</code>.
- *
- * <p>
- * The syntax of the filter string is as defined in the
- * {@link org.osgi.framework.Filter} class. The filter can test any
- * configuration properties including the following:
- * <ul>
- * <li><code>service.pid</code>-<code>String</code>- the PID under which
- * this is registered</li>
- * <li><code>service.factoryPid</code>-<code>String</code>- the factory if
- * applicable</li>
- * <li><code>service.bundleLocation</code>-<code>String</code>- the bundle
- * location</li>
- * </ul>
- * The filter can also be <code>null</code>, meaning that all
- * <code>Configuration</code> objects should be returned.
- *
- * @param filter A filter string, or <code>null</code> to retrieve all
- * <code>Configuration</code> objects.
- * @return All matching <code>Configuration</code> objects, or
- * <code>null</code> if there aren't any.
- * @throws IOException if access to persistent storage fails
- * @throws InvalidSyntaxException if the filter string is invalid
- */
- public Configuration[] listConfigurations(String filter) throws IOException,
- InvalidSyntaxException;
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/cm/ConfigurationEvent.java b/org.osgi.compendium/src/main/java/org/osgi/service/cm/ConfigurationEvent.java
deleted file mode 100644
index f17007f..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/cm/ConfigurationEvent.java
+++ /dev/null
@@ -1,170 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2004, 2009). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.service.cm;
-
-import java.util.Dictionary;
-
-import org.osgi.framework.ServiceReference;
-
-/**
- * A Configuration Event.
- *
- * <p>
- * <code>ConfigurationEvent</code> objects are delivered to all registered
- * <code>ConfigurationListener</code> service objects. ConfigurationEvents
- * must be asynchronously delivered in chronological order with respect to each
- * listener.
- *
- * <p>
- * A type code is used to identify the type of event. The following event types
- * are defined:
- * <ul>
- * <li>{@link #CM_UPDATED}
- * <li>{@link #CM_DELETED}
- * </ul>
- * Additional event types may be defined in the future.
- *
- * <p>
- * Security Considerations. <code>ConfigurationEvent</code> objects do not
- * provide <code>Configuration</code> objects, so no sensitive configuration
- * information is available from the event. If the listener wants to locate the
- * <code>Configuration</code> object for the specified pid, it must use
- * <code>ConfigurationAdmin</code>.
- *
- * @see ConfigurationListener
- *
- * @version $Revision: 6180 $
- * @since 1.2
- */
-public class ConfigurationEvent {
- /**
- * A <code>Configuration</code> has been updated.
- *
- * <p>
- * This <code>ConfigurationEvent</code> type that indicates that a
- * <code>Configuration</code> object has been updated with new properties.
- *
- * An event is fired when a call to {@link Configuration#update(Dictionary)}
- * successfully changes a configuration.
- *
- * <p>
- * The value of <code>CM_UPDATED</code> is 1.
- */
- public static final int CM_UPDATED = 1;
- /**
- * A <code>Configuration</code> has been deleted.
- *
- * <p>
- * This <code>ConfigurationEvent</code> type that indicates that a
- * <code>Configuration</code> object has been deleted.
- *
- * An event is fired when a call to {@link Configuration#delete()}
- * successfully deletes a configuration.
- *
- * <p>
- * The value of <code>CM_DELETED</code> is 2.
- */
- public static final int CM_DELETED = 2;
- /**
- * Type of this event.
- *
- * @see #getType
- */
- private final int type;
- /**
- * The factory pid associated with this event.
- */
- private final String factoryPid;
- /**
- * The pid associated with this event.
- */
- private final String pid;
- /**
- * The ConfigurationAdmin service which created this event.
- */
- private final ServiceReference reference;
-
- /**
- * Constructs a <code>ConfigurationEvent</code> object from the given
- * <code>ServiceReference</code> object, event type, and pids.
- *
- * @param reference The <code>ServiceReference</code> object of the
- * Configuration Admin service that created this event.
- * @param type The event type. See {@link #getType}.
- * @param factoryPid The factory pid of the associated configuration if the
- * target of the configuration is a ManagedServiceFactory. Otherwise
- * <code>null</code> if the target of the configuration is a
- * ManagedService.
- * @param pid The pid of the associated configuration.
- */
- public ConfigurationEvent(ServiceReference reference, int type,
- String factoryPid, String pid) {
- this.reference = reference;
- this.type = type;
- this.factoryPid = factoryPid;
- this.pid = pid;
- if ((reference == null) || (pid == null)) {
- throw new NullPointerException("reference and pid must not be null");
- }
- }
-
- /**
- * Returns the factory pid of the associated configuration.
- *
- * @return Returns the factory pid of the associated configuration if the
- * target of the configuration is a ManagedServiceFactory. Otherwise
- * <code>null</code> if the target of the configuration is a
- * ManagedService.
- */
- public String getFactoryPid() {
- return factoryPid;
- }
-
- /**
- * Returns the pid of the associated configuration.
- *
- * @return Returns the pid of the associated configuration.
- */
- public String getPid() {
- return pid;
- }
-
- /**
- * Return the type of this event.
- * <p>
- * The type values are:
- * <ul>
- * <li>{@link #CM_UPDATED}
- * <li>{@link #CM_DELETED}
- * </ul>
- *
- * @return The type of this event.
- */
- public int getType() {
- return type;
- }
-
- /**
- * Return the <code>ServiceReference</code> object of the Configuration
- * Admin service that created this event.
- *
- * @return The <code>ServiceReference</code> object for the Configuration
- * Admin service that created this event.
- */
- public ServiceReference getReference() {
- return reference;
- }
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/cm/ConfigurationException.java b/org.osgi.compendium/src/main/java/org/osgi/service/cm/ConfigurationException.java
deleted file mode 100644
index 300f5c8..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/cm/ConfigurationException.java
+++ /dev/null
@@ -1,104 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2001, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.service.cm;
-
-/**
- * An <code>Exception</code> class to inform the Configuration Admin service
- * of problems with configuration data.
- *
- * @version $Revision: 6083 $
- */
-public class ConfigurationException extends Exception {
- static final long serialVersionUID = -1690090413441769377L;
-
- private final String property;
- private final String reason;
-
- /**
- * Create a <code>ConfigurationException</code> object.
- *
- * @param property name of the property that caused the problem,
- * <code>null</code> if no specific property was the cause
- * @param reason reason for failure
- */
- public ConfigurationException(String property, String reason) {
- super(property + " : " + reason);
- this.property = property;
- this.reason = reason;
- }
-
- /**
- * Create a <code>ConfigurationException</code> object.
- *
- * @param property name of the property that caused the problem,
- * <code>null</code> if no specific property was the cause
- * @param reason reason for failure
- * @param cause The cause of this exception.
- * @since 1.2
- */
- public ConfigurationException(String property, String reason,
- Throwable cause) {
- super(property + " : " + reason, cause);
- this.property = property;
- this.reason = reason;
- }
-
- /**
- * Return the property name that caused the failure or null.
- *
- * @return name of property or null if no specific property caused the
- * problem
- */
- public String getProperty() {
- return property;
- }
-
- /**
- * Return the reason for this exception.
- *
- * @return reason of the failure
- */
- public String getReason() {
- return reason;
- }
-
- /**
- * Returns the cause of this exception or <code>null</code> if no cause was
- * set.
- *
- * @return The cause of this exception or <code>null</code> if no cause was
- * set.
- * @since 1.2
- */
- public Throwable getCause() {
- return super.getCause();
- }
-
- /**
- * Initializes the cause of this exception to the specified value.
- *
- * @param cause The cause of this exception.
- * @return This exception.
- * @throws IllegalArgumentException If the specified cause is this
- * exception.
- * @throws IllegalStateException If the cause of this exception has already
- * been set.
- * @since 1.2
- */
- public Throwable initCause(Throwable cause) {
- return super.initCause(cause);
- }
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/cm/ConfigurationListener.java b/org.osgi.compendium/src/main/java/org/osgi/service/cm/ConfigurationListener.java
deleted file mode 100644
index 5d7793d..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/cm/ConfigurationListener.java
+++ /dev/null
@@ -1,48 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2004, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.service.cm;
-
-/**
- * Listener for Configuration Events. When a <code>ConfigurationEvent</code>
- * is fired, it is asynchronously delivered to a
- * <code>ConfigurationListener</code>.
- *
- * <p>
- * <code>ConfigurationListener</code> objects are registered with the
- * Framework service registry and are notified with a
- * <code>ConfigurationEvent</code> object when an event is fired.
- * <p>
- * <code>ConfigurationListener</code> objects can inspect the received
- * <code>ConfigurationEvent</code> object to determine its type, the pid of
- * the <code>Configuration</code> object with which it is associated, and the
- * Configuration Admin service that fired the event.
- *
- * <p>
- * Security Considerations. Bundles wishing to monitor configuration events will
- * require <code>ServicePermission[ConfigurationListener,REGISTER]</code> to
- * register a <code>ConfigurationListener</code> service.
- *
- * @version $Revision: 5673 $
- * @since 1.2
- */
-public interface ConfigurationListener {
- /**
- * Receives notification of a Configuration that has changed.
- *
- * @param event The <code>ConfigurationEvent</code>.
- */
- public void configurationEvent(ConfigurationEvent event);
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/cm/ConfigurationPermission.java b/org.osgi.compendium/src/main/java/org/osgi/service/cm/ConfigurationPermission.java
deleted file mode 100644
index 3af9088..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/cm/ConfigurationPermission.java
+++ /dev/null
@@ -1,220 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2004, 2009). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.osgi.service.cm;
-
-import java.security.BasicPermission;
-import java.security.Permission;
-import java.security.PermissionCollection;
-import java.util.Enumeration;
-import java.util.NoSuchElementException;
-
-/**
- * Indicates a bundle's authority to configure bundles.
- *
- * This permission has only a single action: CONFIGURE.
- *
- * @ThreadSafe
- * @version $Revision: 6381 $
- * @since 1.2
- */
-
-public final class ConfigurationPermission extends BasicPermission {
- static final long serialVersionUID = 5716868734811965383L;
- /**
- * The action string <code>configure</code>.
- */
- public final static String CONFIGURE = "configure";
-
- /**
- * Create a new ConfigurationPermission.
- *
- * @param name Name must be "*".
- * @param actions <code>configure</code> (canonical order).
- */
-
- public ConfigurationPermission(String name, String actions) {
- super(name);
- if (!name.equals("*")) {
- throw new IllegalArgumentException("name must be *");
- }
- actions = actions.trim();
- if (actions.equalsIgnoreCase(CONFIGURE)||actions.equals("*"))
- return;
-
- throw new IllegalArgumentException("actions must be " + CONFIGURE);
- }
-
- /**
- * Determines if a <code>ConfigurationPermission</code> object "implies"
- * the specified permission.
- *
- * @param p The target permission to check.
- * @return <code>true</code> if the specified permission is implied by
- * this object; <code>false</code> otherwise.
- */
-
- public boolean implies(Permission p) {
- return p instanceof ConfigurationPermission;
- }
-
- /**
- * Determines the equality of two <code>ConfigurationPermission</code>
- * objects.
- * <p>
- * Two <code>ConfigurationPermission</code> objects are equal.
- *
- * @param obj The object being compared for equality with this object.
- * @return <code>true</code> if <code>obj</code> is equivalent to this
- * <code>ConfigurationPermission</code>; <code>false</code>
- * otherwise.
- */
- public boolean equals(Object obj) {
- return obj instanceof ConfigurationPermission;
- }
-
- /**
- * Returns the hash code value for this object.
- *
- * @return Hash code value for this object.
- */
-
- public int hashCode() {
- int h = 31 * 17 + getName().hashCode();
- h = 31 * h + getActions().hashCode();
- return h;
- }
-
- /**
- * Returns the canonical string representation of the
- * <code>ConfigurationPermission</code> actions.
- *
- * <p>
- * Always returns present <code>ConfigurationPermission</code> actions in
- * the following order: <code>CONFIGURE</code>
- *
- * @return Canonical string representation of the
- * <code>ConfigurationPermission</code> actions.
- */
- public String getActions() {
- return CONFIGURE;
- }
-
- /**
- * Returns a new <code>PermissionCollection</code> object suitable for
- * storing <code>ConfigurationPermission</code>s.
- *
- * @return A new <code>PermissionCollection</code> object.
- */
- public PermissionCollection newPermissionCollection() {
- return new ConfigurationPermissionCollection();
- }
-}
-
-/**
- * Stores a set of <code>ConfigurationPermission</code> permissions.
- *
- * @see java.security.Permission
- * @see java.security.Permissions
- * @see java.security.PermissionCollection
- */
-final class ConfigurationPermissionCollection extends PermissionCollection {
- static final long serialVersionUID = -6917638867081695839L;
- /**
- * True if collection is non-empty.
- *
- * @serial
- */
- private volatile boolean hasElement;
-
- /**
- * Creates an empty <tt>ConfigurationPermissionCollection</tt> object.
- *
- */
- public ConfigurationPermissionCollection() {
- hasElement = false;
- }
-
- /**
- * Adds the specified permission to the
- * <tt>ConfigurationPermissionCollection</tt>. The key for the hash is
- * the interface name of the service.
- *
- * @param permission The <tt>Permission</tt> object to add.
- *
- * @exception IllegalArgumentException If the permission is not an
- * <tt>ConfigurationPermission</tt>.
- *
- * @exception SecurityException If this ConfigurationPermissionCollection
- * object has been marked read-only.
- */
-
- public void add(Permission permission) {
- if (!(permission instanceof ConfigurationPermission)) {
- throw new IllegalArgumentException("invalid permission: "
- + permission);
- }
-
- if (isReadOnly())
- throw new SecurityException("attempt to add a Permission to a "
- + "readonly PermissionCollection");
-
- hasElement = true;
- }
-
- /**
- * Determines if the specified set of permissions implies the permissions
- * expressed in the parameter <tt>permission</tt>.
- *
- * @param p The Permission object to compare.
- *
- * @return true if permission is a proper subset of a permission in the set;
- * false otherwise.
- */
-
- public boolean implies(Permission p) {
- return hasElement && (p instanceof ConfigurationPermission);
- }
-
- /**
- * Returns an enumeration of an <tt>ConfigurationPermission</tt> object.
- *
- * @return Enumeration of an <tt>ConfigurationPermission</tt> object.
- */
-
- public Enumeration elements() {
- final boolean nonEmpty = hasElement;
- return new Enumeration() {
- private boolean more = nonEmpty;
-
- public boolean hasMoreElements() {
- return more;
- }
-
- public Object nextElement() {
- if (more) {
- more = false;
-
- return new ConfigurationPermission("*",
- ConfigurationPermission.CONFIGURE);
- }
- else {
- throw new NoSuchElementException();
- }
- }
- };
- }
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/cm/ConfigurationPlugin.java b/org.osgi.compendium/src/main/java/org/osgi/service/cm/ConfigurationPlugin.java
deleted file mode 100644
index 574466e..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/cm/ConfigurationPlugin.java
+++ /dev/null
@@ -1,129 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2001, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.service.cm;
-
-import java.util.Dictionary;
-
-import org.osgi.framework.ServiceReference;
-
-/**
- * A service interface for processing configuration dictionary before the
- * update.
- *
- * <p>
- * A bundle registers a <code>ConfigurationPlugin</code> object in order to
- * process configuration updates before they reach the Managed Service or
- * Managed Service Factory. The Configuration Admin service will detect
- * registrations of Configuration Plugin services and must call these services
- * every time before it calls the <code>ManagedService</code> or
- * <code>ManagedServiceFactory</code>
- * <code>updated</code> method. The
- * Configuration Plugin service thus has the opportunity to view and modify the
- * properties before they are passed to the Managed Service or Managed Service
- * Factory.
- *
- * <p>
- * Configuration Plugin (plugin) services have full read/write access to all
- * configuration information. Therefore, bundles using this facility should be
- * trusted. Access to this facility should be limited with
- * <code>ServicePermission[ConfigurationPlugin,REGISTER]</code>.
- * Implementations of a Configuration Plugin service should assure that they
- * only act on appropriate configurations.
- *
- * <p>
- * The <code>Integer</code> <code>service.cmRanking</code> registration
- * property may be specified. Not specifying this registration property, or
- * setting it to something other than an <code>Integer</code>, is the same as
- * setting it to the <code>Integer</code> zero. The
- * <code>service.cmRanking</code> property determines the order in which
- * plugins are invoked. Lower ranked plugins are called before higher ranked
- * ones. In the event of more than one plugin having the same value of
- * <code>service.cmRanking</code>, then the Configuration Admin service
- * arbitrarily chooses the order in which they are called.
- *
- * <p>
- * By convention, plugins with <code>service.cmRanking< 0</code> or
- * <code>service.cmRanking > 1000</code> should not make modifications to
- * the properties.
- *
- * <p>
- * The Configuration Admin service has the right to hide properties from
- * plugins, or to ignore some or all the changes that they make. This might be
- * done for security reasons. Any such behavior is entirely implementation
- * defined.
- *
- * <p>
- * A plugin may optionally specify a <code>cm.target</code> registration
- * property whose value is the PID of the Managed Service or Managed Service
- * Factory whose configuration updates the plugin is intended to intercept. The
- * plugin will then only be called with configuration updates that are targeted
- * at the Managed Service or Managed Service Factory with the specified PID.
- * Omitting the <code>cm.target</code> registration property means that the
- * plugin is called for all configuration updates.
- *
- * @version $Revision: 5673 $
- */
-public interface ConfigurationPlugin {
- /**
- * A service property to limit the Managed Service or Managed Service
- * Factory configuration dictionaries a Configuration Plugin service
- * receives.
- *
- * This property contains a <code>String[]</code> of PIDs. A Configuration
- * Admin service must call a Configuration Plugin service only when this
- * property is not set, or the target service's PID is listed in this
- * property.
- */
- public static final String CM_TARGET = "cm.target";
- /**
- * A service property to specify the order in which plugins are invoked.
- *
- * This property contains an <code>Integer</code> ranking of the plugin.
- * Not specifying this registration property, or setting it to something
- * other than an <code>Integer</code>, is the same as setting it to the
- * <code>Integer</code> zero. This property determines the order in which
- * plugins are invoked. Lower ranked plugins are called before higher ranked
- * ones.
- *
- * @since 1.2
- */
- public static final String CM_RANKING = "service.cmRanking";
-
- /**
- * View and possibly modify the a set of configuration properties before
- * they are sent to the Managed Service or the Managed Service Factory. The
- * Configuration Plugin services are called in increasing order of their
- * <code>service.cmRanking</code> property. If this property is undefined
- * or is a non- <code>Integer</code> type, 0 is used.
- *
- * <p>
- * This method should not modify the properties unless the
- * <code>service.cmRanking</code> of this plugin is in the range
- * <code>0 <= service.cmRanking <= 1000</code>.
- * <p>
- * If this method throws any <code>Exception</code>, the Configuration
- * Admin service must catch it and should log it.
- *
- * @param reference reference to the Managed Service or Managed Service
- * Factory
- * @param properties The configuration properties. This argument must not
- * contain the "service.bundleLocation" property. The value of this
- * property may be obtained from the
- * <code>Configuration.getBundleLocation</code> method.
- */
- public void modifyConfiguration(ServiceReference reference,
- Dictionary properties);
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/cm/ManagedService.java b/org.osgi.compendium/src/main/java/org/osgi/service/cm/ManagedService.java
deleted file mode 100644
index 6812434..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/cm/ManagedService.java
+++ /dev/null
@@ -1,138 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2001, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.service.cm;
-
-import java.util.Dictionary;
-
-/**
- * A service that can receive configuration data from a Configuration Admin
- * service.
- *
- * <p>
- * A Managed Service is a service that needs configuration data. Such an object
- * should be registered with the Framework registry with the
- * <code>service.pid</code> property set to some unique identifier called a
- * PID.
- *
- * <p>
- * If the Configuration Admin service has a <code>Configuration</code> object
- * corresponding to this PID, it will callback the <code>updated()</code>
- * method of the <code>ManagedService</code> object, passing the properties of
- * that <code>Configuration</code> object.
- *
- * <p>
- * If it has no such <code>Configuration</code> object, then it calls back
- * with a <code>null</code> properties argument. Registering a Managed Service
- * will always result in a callback to the <code>updated()</code> method
- * provided the Configuration Admin service is, or becomes active. This callback
- * must always be done asynchronously.
- *
- * <p>
- * Else, every time that either of the <code>updated()</code> methods is
- * called on that <code>Configuration</code> object, the
- * <code>ManagedService.updated()</code> method with the new properties is
- * called. If the <code>delete()</code> method is called on that
- * <code>Configuration</code> object, <code>ManagedService.updated()</code>
- * is called with a <code>null</code> for the properties parameter. All these
- * callbacks must be done asynchronously.
- *
- * <p>
- * The following example shows the code of a serial port that will create a port
- * depending on configuration information.
- *
- * <pre>
- *
- * class SerialPort implements ManagedService {
- *
- * ServiceRegistration registration;
- * Hashtable configuration;
- * CommPortIdentifier id;
- *
- * synchronized void open(CommPortIdentifier id,
- * BundleContext context) {
- * this.id = id;
- * registration = context.registerService(
- * ManagedService.class.getName(),
- * this,
- * getDefaults()
- * );
- * }
- *
- * Hashtable getDefaults() {
- * Hashtable defaults = new Hashtable();
- * defaults.put( "port", id.getName() );
- * defaults.put( "product", "unknown" );
- * defaults.put( "baud", "9600" );
- * defaults.put( Constants.SERVICE_PID,
- * "com.acme.serialport." + id.getName() );
- * return defaults;
- * }
- *
- * public synchronized void updated(
- * Dictionary configuration ) {
- * if ( configuration ==
- * <code>
- * null
- * </code>
- * )
- * registration.setProperties( getDefaults() );
- * else {
- * setSpeed( configuration.get("baud") );
- * registration.setProperties( configuration );
- * }
- * }
- * ...
- * }
- *
- * </pre>
- *
- * <p>
- * As a convention, it is recommended that when a Managed Service is updated, it
- * should copy all the properties it does not recognize into the service
- * registration properties. This will allow the Configuration Admin service to
- * set properties on services which can then be used by other applications.
- *
- * @version $Revision: 5673 $
- */
-public interface ManagedService {
- /**
- * Update the configuration for a Managed Service.
- *
- * <p>
- * When the implementation of <code>updated(Dictionary)</code> detects any
- * kind of error in the configuration properties, it should create a new
- * <code>ConfigurationException</code> which describes the problem. This
- * can allow a management system to provide useful information to a human
- * administrator.
- *
- * <p>
- * If this method throws any other <code>Exception</code>, the
- * Configuration Admin service must catch it and should log it.
- * <p>
- * The Configuration Admin service must call this method asynchronously
- * which initiated the callback. This implies that implementors of Managed
- * Service can be assured that the callback will not take place during
- * registration when they execute the registration in a synchronized method.
- *
- * @param properties A copy of the Configuration properties, or
- * <code>null</code>. This argument must not contain the
- * "service.bundleLocation" property. The value of this property may
- * be obtained from the <code>Configuration.getBundleLocation</code>
- * method.
- * @throws ConfigurationException when the update fails
- */
- public void updated(Dictionary properties) throws ConfigurationException;
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/cm/ManagedServiceFactory.java b/org.osgi.compendium/src/main/java/org/osgi/service/cm/ManagedServiceFactory.java
deleted file mode 100644
index 8c334c0..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/cm/ManagedServiceFactory.java
+++ /dev/null
@@ -1,160 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2001, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.service.cm;
-
-import java.util.Dictionary;
-
-/**
- * Manage multiple service instances.
- *
- * Bundles registering this interface are giving the Configuration Admin service
- * the ability to create and configure a number of instances of a service that
- * the implementing bundle can provide. For example, a bundle implementing a
- * DHCP server could be instantiated multiple times for different interfaces
- * using a factory.
- *
- * <p>
- * Each of these <i>service instances </i> is represented, in the persistent
- * storage of the Configuration Admin service, by a factory
- * <code>Configuration</code> object that has a PID. When such a
- * <code>Configuration</code> is updated, the Configuration Admin service
- * calls the <code>ManagedServiceFactory</code> updated method with the new
- * properties. When <code>updated</code> is called with a new PID, the Managed
- * Service Factory should create a new factory instance based on these
- * configuration properties. When called with a PID that it has seen before, it
- * should update that existing service instance with the new configuration
- * information.
- *
- * <p>
- * In general it is expected that the implementation of this interface will
- * maintain a data structure that maps PIDs to the factory instances that it has
- * created. The semantics of a factory instance are defined by the Managed
- * Service Factory. However, if the factory instance is registered as a service
- * object with the service registry, its PID should match the PID of the
- * corresponding <code>Configuration</code> object (but it should <b>not </b>
- * be registered as a Managed Service!).
- *
- * <p>
- * An example that demonstrates the use of a factory. It will create serial
- * ports under command of the Configuration Admin service.
- *
- * <pre>
- *
- * class SerialPortFactory
- * implements ManagedServiceFactory {
- * ServiceRegistration registration;
- * Hashtable ports;
- * void start(BundleContext context) {
- * Hashtable properties = new Hashtable();
- * properties.put( Constants.SERVICE_PID,
- * "com.acme.serialportfactory" );
- * registration = context.registerService(
- * ManagedServiceFactory.class.getName(),
- * this,
- * properties
- * );
- * }
- * public void updated( String pid,
- * Dictionary properties ) {
- * String portName = (String) properties.get("port");
- * SerialPortService port =
- * (SerialPort) ports.get( pid );
- * if ( port == null ) {
- * port = new SerialPortService();
- * ports.put( pid, port );
- * port.open();
- * }
- * if ( port.getPortName().equals(portName) )
- * return;
- * port.setPortName( portName );
- * }
- * public void deleted( String pid ) {
- * SerialPortService port =
- * (SerialPort) ports.get( pid );
- * port.close();
- * ports.remove( pid );
- * }
- * ...
- * }
- *
- * </pre>
- *
- * @version $Revision: 5673 $
- */
-public interface ManagedServiceFactory {
- /**
- * Return a descriptive name of this factory.
- *
- * @return the name for the factory, which might be localized
- */
- public String getName();
-
- /**
- * Create a new instance, or update the configuration of an existing
- * instance.
- *
- * If the PID of the <code>Configuration</code> object is new for the
- * Managed Service Factory, then create a new factory instance, using the
- * configuration <code>properties</code> provided. Else, update the
- * service instance with the provided <code>properties</code>.
- *
- * <p>
- * If the factory instance is registered with the Framework, then the
- * configuration <code>properties</code> should be copied to its registry
- * properties. This is not mandatory and security sensitive properties
- * should obviously not be copied.
- *
- * <p>
- * If this method throws any <code>Exception</code>, the Configuration
- * Admin service must catch it and should log it.
- *
- * <p>
- * When the implementation of updated detects any kind of error in the
- * configuration properties, it should create a new
- * {@link ConfigurationException} which describes the problem.
- *
- * <p>
- * The Configuration Admin service must call this method asynchronously.
- * This implies that implementors of the <code>ManagedServiceFactory</code>
- * class can be assured that the callback will not take place during
- * registration when they execute the registration in a synchronized method.
- *
- * @param pid The PID for this configuration.
- * @param properties A copy of the configuration properties. This argument
- * must not contain the service.bundleLocation" property. The value
- * of this property may be obtained from the
- * <code>Configuration.getBundleLocation</code> method.
- * @throws ConfigurationException when the configuration properties are
- * invalid.
- */
- public void updated(String pid, Dictionary properties)
- throws ConfigurationException;
-
- /**
- * Remove a factory instance.
- *
- * Remove the factory instance associated with the PID. If the instance was
- * registered with the service registry, it should be unregistered.
- * <p>
- * If this method throws any <code>Exception</code>, the Configuration
- * Admin service must catch it and should log it.
- * <p>
- * The Configuration Admin service must call this method asynchronously.
- *
- * @param pid the PID of the service to be removed
- */
- public void deleted(String pid);
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/component/ComponentConstants.java b/org.osgi.compendium/src/main/java/org/osgi/service/component/ComponentConstants.java
deleted file mode 100644
index 2f9d089..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/component/ComponentConstants.java
+++ /dev/null
@@ -1,118 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2004, 2009). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.osgi.service.component;
-
-/**
- * Defines standard names for Service Component constants.
- *
- * @version $Revision: 6454 $
- */
-public interface ComponentConstants {
- /**
- * Manifest header specifying the XML documents within a bundle that contain
- * the bundle's Service Component descriptions.
- * <p>
- * The attribute value may be retrieved from the <code>Dictionary</code>
- * object returned by the <code>Bundle.getHeaders</code> method.
- */
- public static final String SERVICE_COMPONENT = "Service-Component";
-
- /**
- * A component property for a component configuration that contains the name
- * of the component as specified in the <code>name</code> attribute of the
- * <code>component</code> element. The value of this property must be of
- * type <code>String</code>.
- */
- public final static String COMPONENT_NAME = "component.name";
-
- /**
- * A component property that contains the generated id for a component
- * configuration. The value of this property must be of type
- * <code>Long</code>.
- *
- * <p>
- * The value of this property is assigned by the Service Component Runtime
- * when a component configuration is created. The Service Component Runtime
- * assigns a unique value that is larger than all previously assigned values
- * since the Service Component Runtime was started. These values are NOT
- * persistent across restarts of the Service Component Runtime.
- */
- public final static String COMPONENT_ID = "component.id";
-
- /**
- * A service registration property for a Component Factory that contains the
- * value of the <code>factory</code> attribute. The value of this property
- * must be of type <code>String</code>.
- */
- public final static String COMPONENT_FACTORY = "component.factory";
-
- /**
- * The suffix for reference target properties. These properties contain the
- * filter to select the target services for a reference. The value of this
- * property must be of type <code>String</code>.
- */
- public final static String REFERENCE_TARGET_SUFFIX = ".target";
-
- /**
- * The reason the component configuration was deactivated is unspecified.
- *
- * @since 1.1
- */
- public static final int DEACTIVATION_REASON_UNSPECIFIED = 0;
-
- /**
- * The component configuration was deactivated because the component was disabled.
- *
- * @since 1.1
- */
- public static final int DEACTIVATION_REASON_DISABLED = 1;
-
- /**
- * The component configuration was deactivated because a reference became unsatisfied.
- *
- * @since 1.1
- */
- public static final int DEACTIVATION_REASON_REFERENCE = 2;
-
- /**
- * The component configuration was deactivated because its configuration was changed.
- *
- * @since 1.1
- */
- public static final int DEACTIVATION_REASON_CONFIGURATION_MODIFIED = 3;
-
- /**
- * The component configuration was deactivated because its configuration was deleted.
- *
- * @since 1.1
- */
- public static final int DEACTIVATION_REASON_CONFIGURATION_DELETED = 4;
-
- /**
- * The component configuration was deactivated because the component was disposed.
- *
- * @since 1.1
- */
- public static final int DEACTIVATION_REASON_DISPOSED = 5;
-
- /**
- * The component configuration was deactivated because the bundle was stopped.
- *
- * @since 1.1
- */
- public static final int DEACTIVATION_REASON_BUNDLE_STOPPED = 6;
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/component/ComponentContext.java b/org.osgi.compendium/src/main/java/org/osgi/service/component/ComponentContext.java
deleted file mode 100644
index aad348c..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/component/ComponentContext.java
+++ /dev/null
@@ -1,191 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2004, 2009). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.osgi.service.component;
-
-import java.util.Dictionary;
-
-import org.osgi.framework.Bundle;
-import org.osgi.framework.BundleContext;
-import org.osgi.framework.ServiceReference;
-
-/**
- * A Component Context object is used by a component instance to interact with
- * its execution context including locating services by reference name. Each
- * component instance has a unique Component Context.
- *
- * <p>
- * A component instance may have an activate method. If a component instance has
- * a suitable and accessible activate method, this method will be called when a
- * component configuration is activated. If the activate method takes a
- * <code>ComponentContext</code> argument, it will be passed the component
- * instance's Component Context object. If the activate method takes a
- * <code>BundleContext</code> argument, it will be passed the component
- * instance's Bundle Context object. If the activate method takes a
- * <code>Map</code> argument, it will be passed an unmodifiable Map containing
- * the component properties.
- *
- * <p>
- * A component instance may have a deactivate method. If a component instance
- * has a suitable and accessible deactivate method, this method will be called
- * when the component configuration is deactivated. If the deactivate method
- * takes a <code>ComponentContext</code> argument, it will be passed the
- * component instance's Component Context object. If the deactivate method takes
- * a <code>BundleContext</code> argument, it will be passed the component
- * instance's Bundle Context object. If the deactivate method takes a
- * <code>Map</code> argument, it will be passed an unmodifiable Map containing
- * the component properties. If the deactivate method takes an <code>int</code>
- * or <code>Integer</code> argument, it will be passed the reason code for the
- * component instance's deactivation.
- *
- * @ThreadSafe
- * @version $Revision: 6462 $
- */
-public interface ComponentContext {
- /**
- * Returns the component properties for this Component Context.
- *
- * @return The properties for this Component Context. The Dictionary is read
- * only and cannot be modified.
- */
- public Dictionary getProperties();
-
- /**
- * Returns the service object for the specified reference name.
- *
- * <p>
- * If the cardinality of the reference is <code>0..n</code> or
- * <code>1..n</code> and multiple services are bound to the reference, the
- * service with the highest ranking (as specified in its
- * <code>Constants.SERVICE_RANKING</code> property) is returned. If there is
- * a tie in ranking, the service with the lowest service ID (as specified in
- * its <code>Constants.SERVICE_ID</code> property); that is, the service
- * that was registered first is returned.
- *
- * @param name The name of a reference as specified in a
- * <code>reference</code> element in this component's description.
- * @return A service object for the referenced service or <code>null</code>
- * if the reference cardinality is <code>0..1</code> or
- * <code>0..n</code> and no bound service is available.
- * @throws ComponentException If the Service Component Runtime catches an
- * exception while activating the bound service.
- */
- public Object locateService(String name);
-
- /**
- * Returns the service object for the specified reference name and
- * <code>ServiceReference</code>.
- *
- * @param name The name of a reference as specified in a
- * <code>reference</code> element in this component's description.
- * @param reference The <code>ServiceReference</code> to a bound service.
- * This must be a <code>ServiceReference</code> provided to the
- * component via the bind or unbind method for the specified
- * reference name.
- * @return A service object for the referenced service or <code>null</code>
- * if the specified <code>ServiceReference</code> is not a bound
- * service for the specified reference name.
- * @throws ComponentException If the Service Component Runtime catches an
- * exception while activating the bound service.
- */
- public Object locateService(String name, ServiceReference reference);
-
- /**
- * Returns the service objects for the specified reference name.
- *
- * @param name The name of a reference as specified in a
- * <code>reference</code> element in this component's description.
- * @return An array of service objects for the referenced service or
- * <code>null</code> if the reference cardinality is
- * <code>0..1</code> or <code>0..n</code> and no bound service is
- * available. If the reference cardinality is <code>0..1</code> or
- * <code>1..1</code> and a bound service is available, the array
- * will have exactly one element.
- * @throws ComponentException If the Service Component Runtime catches an
- * exception while activating a bound service.
- */
- public Object[] locateServices(String name);
-
- /**
- * Returns the <code>BundleContext</code> of the bundle which contains this
- * component.
- *
- * @return The <code>BundleContext</code> of the bundle containing this
- * component.
- */
- public BundleContext getBundleContext();
-
- /**
- * If the component instance is registered as a service using the
- * <code>servicefactory="true"</code> attribute, then this method
- * returns the bundle using the service provided by the component instance.
- * <p>
- * This method will return <code>null</code> if:
- * <ul>
- * <li>The component instance is not a service, then no bundle can be using
- * it as a service.
- * <li>The component instance is a service but did not specify the
- * <code>servicefactory="true"</code> attribute, then all bundles
- * using the service provided by the component instance will share the same
- * component instance.
- * <li>The service provided by the component instance is not currently being
- * used by any bundle.
- * </ul>
- *
- * @return The bundle using the component instance as a service or
- * <code>null</code>.
- */
- public Bundle getUsingBundle();
-
- /**
- * Returns the Component Instance object for the component instance
- * associated with this Component Context.
- *
- * @return The Component Instance object for the component instance.
- */
- public ComponentInstance getComponentInstance();
-
- /**
- * Enables the specified component name. The specified component name must
- * be in the same bundle as this component.
- *
- * @param name The name of a component or <code>null</code> to indicate all
- * components in the bundle.
- */
- public void enableComponent(String name);
-
- /**
- * Disables the specified component name. The specified component name must
- * be in the same bundle as this component.
- *
- * @param name The name of a component.
- */
- public void disableComponent(String name);
-
- /**
- * If the component instance is registered as a service using the
- * <code>service</code> element, then this method returns the service
- * reference of the service provided by this component instance.
- * <p>
- * This method will return <code>null</code> if the component instance is
- * not registered as a service.
- *
- * @return The <code>ServiceReference</code> object for the component
- * instance or <code>null</code> if the component instance is not
- * registered as a service.
- */
- public ServiceReference getServiceReference();
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/component/ComponentException.java b/org.osgi.compendium/src/main/java/org/osgi/service/component/ComponentException.java
deleted file mode 100644
index 0aee948..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/component/ComponentException.java
+++ /dev/null
@@ -1,79 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2004, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.osgi.service.component;
-
-/**
- * Unchecked exception which may be thrown by the Service Component Runtime.
- *
- * @version $Revision: 6083 $
- */
-public class ComponentException extends RuntimeException {
- static final long serialVersionUID = -7438212656298726924L;
-
- /**
- * Construct a new ComponentException with the specified message and cause.
- *
- * @param message The message for the exception.
- * @param cause The cause of the exception. May be <code>null</code>.
- */
- public ComponentException(String message, Throwable cause) {
- super(message, cause);
- }
-
- /**
- * Construct a new ComponentException with the specified message.
- *
- * @param message The message for the exception.
- */
- public ComponentException(String message) {
- super(message);
- }
-
- /**
- * Construct a new ComponentException with the specified cause.
- *
- * @param cause The cause of the exception. May be <code>null</code>.
- */
- public ComponentException(Throwable cause) {
- super(cause);
- }
-
- /**
- * Returns the cause of this exception or <code>null</code> if no cause was
- * set.
- *
- * @return The cause of this exception or <code>null</code> if no cause was
- * set.
- */
- public Throwable getCause() {
- return super.getCause();
- }
-
- /**
- * Initializes the cause of this exception to the specified value.
- *
- * @param cause The cause of this exception.
- * @return This exception.
- * @throws IllegalArgumentException If the specified cause is this
- * exception.
- * @throws IllegalStateException If the cause of this exception has already
- * been set.
- */
- public Throwable initCause(Throwable cause) {
- return super.initCause(cause);
- }
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/component/ComponentFactory.java b/org.osgi.compendium/src/main/java/org/osgi/service/component/ComponentFactory.java
deleted file mode 100644
index 1c77177..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/component/ComponentFactory.java
+++ /dev/null
@@ -1,47 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2004, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.osgi.service.component;
-
-import java.util.Dictionary;
-
-/**
- * When a component is declared with the <code>factory</code> attribute on its
- * <code>component</code> element, the Service Component Runtime will register
- * a Component Factory service to allow new component configurations to be
- * created and activated rather than automatically creating and activating
- * component configuration as necessary.
- *
- * @ThreadSafe
- * @version $Revision: 5654 $
- */
-public interface ComponentFactory {
- /**
- * Create and activate a new component configuration. Additional properties
- * may be provided for the component configuration.
- *
- * @param properties Additional properties for the component configuration
- * or <code>null</code> if there are no additional properties.
- * @return A <code>ComponentInstance</code> object encapsulating the
- * component instance of the component configuration. The component
- * configuration has been activated and, if the component specifies
- * a <code>service</code> element, the component instance has been
- * registered as a service.
- * @throws ComponentException If the Service Component Runtime is unable to
- * activate the component configuration.
- */
- public ComponentInstance newInstance(Dictionary properties);
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/component/ComponentInstance.java b/org.osgi.compendium/src/main/java/org/osgi/service/component/ComponentInstance.java
deleted file mode 100644
index f2bd2cb..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/component/ComponentInstance.java
+++ /dev/null
@@ -1,46 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2004, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.osgi.service.component;
-
-/**
- * A ComponentInstance encapsulates a component instance of an activated
- * component configuration. ComponentInstances are created whenever a component
- * configuration is activated.
- *
- * <p>
- * ComponentInstances are never reused. A new ComponentInstance object will be
- * created when the component configuration is activated again.
- *
- * @ThreadSafe
- * @version $Revision: 5654 $
- */
-public interface ComponentInstance {
- /**
- * Dispose of the component configuration for this component instance. The
- * component configuration will be deactivated. If the component
- * configuration has already been deactivated, this method does nothing.
- */
- public void dispose();
-
- /**
- * Returns the component instance of the activated component configuration.
- *
- * @return The component instance or <code>null</code> if the component
- * configuration has been deactivated.
- */
- public Object getInstance();
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/deploymentadmin/BundleInfo.java b/org.osgi.compendium/src/main/java/org/osgi/service/deploymentadmin/BundleInfo.java
deleted file mode 100644
index f945e6a..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/deploymentadmin/BundleInfo.java
+++ /dev/null
@@ -1,41 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2005, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.osgi.service.deploymentadmin;
-
-import org.osgi.framework.Version;
-
-/**
- * Represents a bundle in the array given back by the {@link DeploymentPackage#getBundleInfos()}
- * method.
- */
-public interface BundleInfo {
-
- /**
- * Returns the Bundle Symbolic Name of the represented bundle.
- *
- * @return the Bundle Symbolic Name
- */
- String getSymbolicName();
-
- /**
- * Returns the version of the represented bundle.
- *
- * @return the version of the represented bundle
- */
- Version getVersion();
-
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/deploymentadmin/DeploymentAdmin.java b/org.osgi.compendium/src/main/java/org/osgi/service/deploymentadmin/DeploymentAdmin.java
deleted file mode 100644
index 4647baf..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/deploymentadmin/DeploymentAdmin.java
+++ /dev/null
@@ -1,137 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2005, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.osgi.service.deploymentadmin;
-
-import java.io.InputStream;
-
-import org.osgi.framework.Bundle;
-
-/**
- * This is the interface of the Deployment Admin service.<p>
- *
- * The OSGi Service Platform provides mechanisms to manage the life cycle of
- * bundles, configuration objects, permission objects, etc. but the overall consistency
- * of the runtime configuration is the responsibility of the management
- * agent. In other words, the management agent decides to install, update,
- * or uninstall bundles, create or delete configuration or permission objects, as
- * well as manage other resource types, etc.<p>
- *
- * The Deployment Admin service standardizes the access to some of the responsibilities
- * of the management agent. The service provides functionality to manage Deployment Packages
- * (see {@link DeploymentPackage}). A Deployment Package groups resources as a unit
- * of management. A Deployment Package is something that can be installed, updated,
- * and uninstalled as a unit.<p>
- *
- * The Deployment Admin functionality is exposed as a standard OSGi service with no
- * mandatory service parameters.
- */
-public interface DeploymentAdmin {
-
- /**
- * Installs a Deployment Package from an input stream. If a version of that Deployment Package
- * is already installed and the versions are different, the installed version is updated
- * with this new version even if it is older (downgrade). If the two versions are the same, then this
- * method simply returns with the old (target) Deployment Package without any action.
- *
- * @param in the input stream the Deployment Package can be read from. It mustn't be <code>null</code>.
- * @return A DeploymentPackage object representing the newly installed/updated Deployment Package.
- * It is never <code>null</code>.
- * @throws IllegalArgumentException if the got InputStream parameter is <code>null</code>
- * @throws DeploymentException if the installation was not successful. For detailed error code description
- * see {@link DeploymentException}.
- * @throws SecurityException if the caller doesn't have the appropriate
- * {@link DeploymentAdminPermission}("<filter>", "install") permission.
- * @see DeploymentAdminPermission
- * @see DeploymentPackage
- * @see DeploymentPackage
- */
- DeploymentPackage installDeploymentPackage(InputStream in) throws DeploymentException;
-
- /**
- * Lists the Deployment Packages currently installed on the platform.<p>
- *
- * {@link DeploymentAdminPermission}("<filter>", "list") is
- * needed for this operation to the effect that only those packages are listed in
- * the array to which the caller has appropriate DeploymentAdminPermission. It has
- * the consequence that the method never throws SecurityException only doesn't
- * put certain Deployment Packages into the array.<p>
- *
- * During an installation of an existing package (update) or during an uninstallation,
- * the target must remain in this list until the installation (uninstallation) process
- * is completed, after which the source (or <code>null</code> in case of uninstall)
- * replaces the target.
- *
- * @return the array of <code>DeploymentPackage</code> objects representing all the
- * installed Deployment Packages. The return value cannot be <code>null</code>.
- * In case of missing permissions it may give back an empty array.
- * @see DeploymentPackage
- * @see DeploymentAdminPermission
- */
- DeploymentPackage[] listDeploymentPackages();
-
- /**
- * Gets the currently installed {@link DeploymentPackage} instance which has the given
- * symbolic name.<p>
- *
- * During an installation of an existing package (update) or during an uninstallation,
- * the target Deployment Package must remain the return value until the installation
- * (uninstallation) process is completed, after which the source (or <code>null</code>
- * in case of uninstall) is the return value.
- *
- * @param symbName the symbolic name of the Deployment Package to be retrieved. It mustn't be
- * <code>null</code>.
- * @return The <code>DeploymentPackage</code> for the given symbolic name.
- * If there is no Deployment Package with that symbolic name currently installed,
- * <code>null</code> is returned.
- * @throws IllegalArgumentException if the given <code>symbName</code> is <code>null</code>
- * @throws SecurityException if the caller doesn't have the appropriate
- * {@link DeploymentAdminPermission}("<filter>", "list") permission.
- * @see DeploymentPackage
- * @see DeploymentAdminPermission
- */
- DeploymentPackage getDeploymentPackage(String symbName);
-
- /**
- * Gives back the installed {@link DeploymentPackage} that owns the bundle. Deployment Packages own their
- * bundles by their Bundle Symbolic Name. It means that if a bundle belongs to an installed
- * Deployment Packages (and at most to one) the Deployment Admin assigns the bundle to its owner
- * Deployment Package by the Symbolic Name of the bundle.<p>
- *
- * @param bundle the bundle whose owner is queried
- * @return the Deployment Package Object that owns the bundle or <code>null</code> if the bundle doesn't
- * belong to any Deployment Packages (standalone bundles)
- * @throws IllegalArgumentException if the given <code>bundle</code> is <code>null</code>
- * @throws SecurityException if the caller doesn't have the appropriate
- * {@link DeploymentAdminPermission}("<filter>", "list") permission.
- * @see DeploymentPackage
- * @see DeploymentAdminPermission
- */
- DeploymentPackage getDeploymentPackage(Bundle bundle);
-
- /**
- * This method cancels the currently active deployment session. This method addresses the need
- * to cancel the processing of excessively long running, or resource consuming install, update
- * or uninstall operations.<p>
- *
- * @return true if there was an active session and it was successfully canceled.
- * @throws SecurityException if the caller doesn't have the appropriate
- * {@link DeploymentAdminPermission}("<filter>", "cancel") permission.
- * @see DeploymentAdminPermission
- */
- boolean cancel();
-
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/deploymentadmin/DeploymentAdminPermission.java b/org.osgi.compendium/src/main/java/org/osgi/service/deploymentadmin/DeploymentAdminPermission.java
deleted file mode 100644
index 86ea75f..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/deploymentadmin/DeploymentAdminPermission.java
+++ /dev/null
@@ -1,332 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2005, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.osgi.service.deploymentadmin;
-
-import java.io.InputStream;
-import java.lang.reflect.Constructor;
-import java.lang.reflect.InvocationTargetException;
-import java.security.AccessController;
-import java.security.Permission;
-import java.security.PermissionCollection;
-import java.security.PrivilegedAction;
-
-import org.osgi.framework.Bundle;
-
-/**
- * DeploymentAdminPermission controls access to the Deployment Admin service.<p>
- *
- * The permission uses a filter string formatted similarly to the {@link org.osgi.framework.Filter}.
- * The filter determines the target of the permission. The <code>DeploymentAdminPermission</code> uses the
- * <code>name</code> and the <code>signer</code> filter attributes only. The value of the <code>signer</code>
- * attribute is matched against the signer chain (represented with its semicolon separated Distinguished Name chain)
- * of the Deployment Package, and the value of the <code>name</code> attribute is matched against the value of the
- * "DeploymentPackage-Name" manifest header of the Deployment Package. Example:
- *
- * <ul>
- * <li>(signer=cn = Bugs Bunny, o = ACME, c = US)</li>
- * <li>(name=org.osgi.ExampleApp)</li>
- * </ul>
- *
- * Wildcards also can be used:<p>
- *
- * <pre>
- * (signer=cn=*,o=ACME,c=*)
- * </pre>
- * "cn" and "c" may have an arbitrary value
- *
- * <pre>
- * (signer=*, o=ACME, c=US)
- * </pre>
- * Only the value of "o" and "c" are significant
- *
- * <pre>
- * (signer=* ; ou=S & V, o=Tweety Inc., c=US)
- * </pre>
- * The first element of the certificate chain is
- * not important, only the second (the
- * Distinguished Name of the root certificate)
- *
- * <pre>
- * (signer=- ; *, o=Tweety Inc., c=US)
- * </pre>
- * The same as the previous but '-' represents
- * zero or more certificates, whereas the asterisk
- * only represents a single certificate
- *
- * <pre>
- * (name=*)
- * </pre>
- * The name of the Deployment Package doesn't matter
- *
- * <pre>
- * (name=org.osgi.*)
- * </pre>
- * The name has to begin with "org.osgi."
- *
- * <p>The following actions are allowed:<p>
- *
- * <b>list</b>
- * <p>
- * A holder of this permission can access the inventory information of the deployment
- * packages selected by the <filter> string. The filter selects the deployment packages
- * on which the holder of the permission can acquire detailed inventory information.
- * See {@link DeploymentAdmin#getDeploymentPackage(Bundle)},
- * {@link DeploymentAdmin#getDeploymentPackage(String)} and
- * {@link DeploymentAdmin#listDeploymentPackages}.<p>
- *
- * <b>install</b><p>
- *
- * A holder of this permission can install/update deployment packages if the deployment
- * package satisfies the <filter> string. See {@link DeploymentAdmin#installDeploymentPackage}.<p>
- *
- * <b>uninstall</b><p>
- *
- * A holder of this permission can uninstall deployment packages if the deployment
- * package satisfies the <filter> string. See {@link DeploymentPackage#uninstall}.<p>
- *
- * <b>uninstall_forced</b><p>
- *
- * A holder of this permission can forcefully uninstall deployment packages if the deployment
- * package satisfies the <filter> string. See {@link DeploymentPackage#uninstallForced}.<p>
- *
- * <b>cancel</b><p>
- *
- * A holder of this permission can cancel an active deployment action. This action being
- * canceled could correspond to the install, update or uninstall of a deployment package
- * that satisfies the <filter> string. See {@link DeploymentAdmin#cancel}<p>
- *
- * <b>metadata</b><p>
- *
- * A holder of this permission is able to retrieve metadata information about a Deployment
- * Package (e.g. is able to ask its manifest headers).
- * See {@link org.osgi.service.deploymentadmin.DeploymentPackage#getBundle(String)},
- * {@link org.osgi.service.deploymentadmin.DeploymentPackage#getBundleInfos()},
- * {@link org.osgi.service.deploymentadmin.DeploymentPackage#getHeader(String)},
- * {@link org.osgi.service.deploymentadmin.DeploymentPackage#getResourceHeader(String, String)},
- * {@link org.osgi.service.deploymentadmin.DeploymentPackage#getResourceProcessor(String)},
- * {@link org.osgi.service.deploymentadmin.DeploymentPackage#getResources()}<p>
- *
- * The actions string is converted to lower case before processing.
- */
-public final class DeploymentAdminPermission extends Permission {
-
- /**
- *
- */
- private static final long serialVersionUID = 1L;
-
- /**
- * Constant String to the "install" action.<p>
- *
- * @see DeploymentAdmin#installDeploymentPackage(InputStream)
- */
- public static final String INSTALL = "install";
-
- /**
- * Constant String to the "list" action.<p>
- *
- * @see DeploymentAdmin#listDeploymentPackages()
- * @see DeploymentAdmin#getDeploymentPackage(String)
- * @see DeploymentAdmin#getDeploymentPackage(Bundle)
- */
- public static final String LIST = "list";
-
- /**
- * Constant String to the "uninstall" action.<p>
- *
- * @see DeploymentPackage#uninstall()
- */
- public static final String UNINSTALL = "uninstall";
-
- /**
- * Constant String to the "uninstall_forced" action.<p>
- *
- * @see DeploymentPackage#uninstallForced()
- */
- public static final String UNINSTALL_FORCED = "uninstall_forced";
-
- /**
- * Constant String to the "cancel" action.<p>
- *
- * @see DeploymentAdmin#cancel
- */
- public static final String CANCEL = "cancel";
-
- /**
- * Constant String to the "metadata" action.<p>
- *
- * @see org.osgi.service.deploymentadmin.DeploymentPackage#getBundle(String)
- * @see org.osgi.service.deploymentadmin.DeploymentPackage#getBundleInfos()
- * @see org.osgi.service.deploymentadmin.DeploymentPackage#getHeader(String)
- * @see org.osgi.service.deploymentadmin.DeploymentPackage#getResourceHeader(String, String)
- * @see org.osgi.service.deploymentadmin.DeploymentPackage#getResourceProcessor(String)
- * @see org.osgi.service.deploymentadmin.DeploymentPackage#getResources()
- */
- public static final String METADATA = "metadata";
-
- private static final String delegateProperty = "org.osgi.vendor.deploymentadmin";
- private static final Constructor constructor;
- private final Permission delegate;
- static {
- constructor = (Constructor) AccessController.doPrivileged(new PrivilegedAction() {
- public Object run() {
- String pckg = System.getProperty(delegateProperty);
- if (null == pckg)
- throw new RuntimeException("Property '" + delegateProperty + "' is not set");
- try {
- Class c = Class.forName(pckg + ".DeploymentAdminPermission");
- return c.getConstructor(new Class[] {String.class, String.class});
- }
- catch (Exception e) {
- throw new RuntimeException(e);
- }
- }});
- }
-
- /**
- * Creates a new <code>DeploymentAdminPermission</code> object for the given <code>name</code> and
- * <code>action</code>.<p>
- * The <code>name</code> parameter identifies the target deployment package the permission
- * relates to. The <code>actions</code> parameter contains the comma separated list of allowed actions.
- *
- * @param name filter string, must not be null.
- * @param actions action string, must not be null. "*" means all the possible actions.
- * @throws IllegalArgumentException if the filter is invalid, the list of actions
- * contains unknown operations or one of the parameters is null
- */
- public DeploymentAdminPermission(String name, String actions) {
- super(name);
- try {
- try {
- delegate = (Permission) constructor.newInstance(new Object[] {name, actions});
- }
- catch (InvocationTargetException e) {
- throw e.getTargetException();
- }
- }
- catch (Error e) {
- throw e;
- }
- catch (RuntimeException e) {
- throw e;
- }
- catch (Throwable e) {
- throw new RuntimeException(e);
- }
- }
-
- /**
- * Checks two DeploymentAdminPermission objects for equality.
- * Two permission objects are equal if: <p>
- *
- * <ul>
- * <li>their target filters are semantically equal and</li>
- * <li>their actions are the same</li>
- * </ul>
- *
- * @param obj The reference object with which to compare.
- * @return true if the two objects are equal.
- * @see java.lang.Object#equals(java.lang.Object)
- */
- public boolean equals(Object obj) {
- if (obj == this)
- return true;
- if (!(obj instanceof DeploymentAdminPermission))
- return false;
- DeploymentAdminPermission dap = (DeploymentAdminPermission) obj;
- return delegate.equals(dap.delegate);
- }
-
- /**
- * Returns hash code for this permission object.
- *
- * @return Hash code for this permission object.
- * @see java.lang.Object#hashCode()
- */
- public int hashCode() {
- return delegate.hashCode();
- }
-
- /**
- * Returns the String representation of the action list.<p>
- * The method always gives back the actions in the following (alphabetical) order:
- * <code>cancel, install, list, metadata, uninstall, uninstall_forced</code>
- *
- * @return Action list of this permission instance. This is a comma-separated
- * list that reflects the action parameter of the constructor.
- * @see java.security.Permission#getActions()
- */
- public String getActions() {
- return delegate.getActions();
- }
-
- /**
- * Checks if this DeploymentAdminPermission would imply the parameter permission.<p>
- * Precondition of the implication is that the action set of this permission is the superset
- * of the action set of the other permission. Further rules of implication are determined
- * by the {@link org.osgi.framework.Filter} rules and the "OSGi Service Platform, Core
- * Specification Release 4, Chapter Certificate Matching".<p>
- *
- * The allowed attributes are: <code>name</code> (the symbolic name of the deployment
- * package) and <code>signer</code> (the signer of the deployment package). In both cases
- * wildcards can be used.<p>
- *
- * Examples:
- *
- * <pre>
- * 1. DeploymentAdminPermission("(name=org.osgi.ExampleApp)", "list")
- * 2. DeploymentAdminPermission("(name=org.osgi.ExampleApp)", "list, install")
- * 3. DeploymentAdminPermission("(name=org.osgi.*)", "list")
- * 4. DeploymentAdminPermission("(signer=*, o=ACME, c=US)", "list")
- * 5. DeploymentAdminPermission("(signer=cn = Bugs Bunny, o = ACME, c = US)", "list")
- * </pre><p>
- *
- * <pre>
- * 1. implies 1.
- * 2. implies 1.
- * 1. doesn't implies 2.
- * 3. implies 1.
- * 4. implies 5.
- * </pre>
- *
- * @param permission Permission to check.
- * @return true if this DeploymentAdminPermission object implies the
- * specified permission.
- * @see java.security.Permission#implies(java.security.Permission)
- * @see org.osgi.framework.Filter
- */
- public boolean implies(Permission permission) {
- if (!(permission instanceof DeploymentAdminPermission))
- return false;
-
- DeploymentAdminPermission dap = (DeploymentAdminPermission) permission;
-
- return delegate.implies(dap.delegate);
- }
-
- /**
- * Returns a new PermissionCollection object for storing DeploymentAdminPermission
- * objects.
- *
- * @return The new PermissionCollection.
- * @see java.security.Permission#newPermissionCollection()
- */
- public PermissionCollection newPermissionCollection() {
- return delegate.newPermissionCollection();
- }
-
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/deploymentadmin/DeploymentException.java b/org.osgi.compendium/src/main/java/org/osgi/service/deploymentadmin/DeploymentException.java
deleted file mode 100644
index 3433740..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/deploymentadmin/DeploymentException.java
+++ /dev/null
@@ -1,275 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2005, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.osgi.service.deploymentadmin;
-
-import java.io.InputStream;
-
-/**
- * Checked exception received when something fails during any deployment
- * processes. A <code>DeploymentException</code> always contains an error code
- * (one of the constants specified in this class), and may optionally contain
- * the textual description of the error condition and a nested cause exception.
- */
-public class DeploymentException extends Exception {
-
- /**
- *
- */
- private static final long serialVersionUID = 916011169146851101L;
-
- /**
- * {@link DeploymentAdmin#installDeploymentPackage(InputStream)},
- * {@link DeploymentPackage#uninstall()} and {@link DeploymentPackage#uninstallForced()}
- * methods can throw {@link DeploymentException} with this error code if the
- * {@link DeploymentAdmin#cancel()} method is called from another thread.
- */
- public static final int CODE_CANCELLED = 401;
-
- /**
- * {@link DeploymentAdmin#installDeploymentPackage(InputStream)}
- * methods can throw {@link DeploymentException} with this error code if
- * the got InputStream is not a jar.
- */
- public static final int CODE_NOT_A_JAR = 404;
-
- /**
- * Order of files in the deployment package is bad. The right order is the
- * following:<p>
- *
- * <ol>
- * <li>META-INF/MANIFEST.MF</li>
- * <li>META-INF/*.SF, META-INF/*.DSA, META-INF/*.RS</li>
- * <li>Localization files</li>
- * <li>Bundles</li>
- * <li>Resources</li>
- * </ol>
- *
- * {@link DeploymentAdmin#installDeploymentPackage(InputStream)}
- * throws exception with this error code.
- */
- public static final int CODE_ORDER_ERROR = 450;
-
- /**
- * Missing mandatory manifest header.<p>
- *
- * {@link DeploymentAdmin#installDeploymentPackage(InputStream)} can throw
- * exception with this error code.
- */
- public static final int CODE_MISSING_HEADER = 451;
-
- /**
- * Syntax error in any manifest header.<p>
- *
- * {@link DeploymentAdmin#installDeploymentPackage(InputStream)}
- * throws exception with this error code.
- */
- public static final int CODE_BAD_HEADER = 452;
-
- /**
- * Fix pack version range doesn't fit to the version of the target
- * deployment package or the target deployment package of the fix pack
- * doesn't exist.<p>
- *
- * {@link DeploymentAdmin#installDeploymentPackage(InputStream)}
- * throws exception with this error code.
- */
- public static final int CODE_MISSING_FIXPACK_TARGET = 453;
-
- /**
- * A bundle in the deployment package is marked as DeploymentPackage-Missing
- * but there is no such bundle in the target deployment package.<p>
- *
- * {@link DeploymentAdmin#installDeploymentPackage(InputStream)}
- * throws exception with this error code.
- */
- public static final int CODE_MISSING_BUNDLE = 454;
-
- /**
- * A resource in the source deployment package is marked as
- * DeploymentPackage-Missing but there is no such resource in the target
- * deployment package.<p>
- *
- * {@link DeploymentAdmin#installDeploymentPackage(InputStream)}
- * throws exception with this error code.
- */
- public static final int CODE_MISSING_RESOURCE = 455;
-
- /**
- * Bad deployment package signing.<p>
- *
- * {@link DeploymentAdmin#installDeploymentPackage(InputStream)}
- * throws exception with this error code.
- */
- public static final int CODE_SIGNING_ERROR = 456;
-
- /**
- * Bundle symbolic name is not the same as defined by the deployment package
- * manifest.<p>
- *
- * {@link DeploymentAdmin#installDeploymentPackage(InputStream)}
- * throws exception with this error code.
- */
- public static final int CODE_BUNDLE_NAME_ERROR = 457;
-
- /**
- * Matched resource processor service is a customizer from another
- * deployment package.<p>
- *
- * {@link DeploymentAdmin#installDeploymentPackage(InputStream)}
- * throws exception with this error code.
- */
- public static final int CODE_FOREIGN_CUSTOMIZER = 458;
-
- /**
- * Bundle with the same symbolic name already exists.<p>
- *
- * {@link DeploymentAdmin#installDeploymentPackage(InputStream)}
- * throws exception with this error code.
- */
- public static final int CODE_BUNDLE_SHARING_VIOLATION = 460;
-
- /**
- * An artifact of any resource already exists.<p>
- *
- * This exception is thrown when the called resource processor throws a
- * <code>ResourceProcessorException</code> with the
- * {@link org.osgi.service.deploymentadmin.spi.ResourceProcessorException#CODE_RESOURCE_SHARING_VIOLATION}
- * error code.<p>
- *
- * {@link DeploymentAdmin#installDeploymentPackage(InputStream)}
- * throws exception with this error code.
- */
- public static final int CODE_RESOURCE_SHARING_VIOLATION = 461;
-
- /**
- * Exception with this error code is thrown when one of the Resource Processors
- * involved in the deployment session threw a <code>ResourceProcessorException</code> with the
- * {@link org.osgi.service.deploymentadmin.spi.ResourceProcessorException#CODE_PREPARE} error
- * code.<p>
- *
- * {@link DeploymentAdmin#installDeploymentPackage(InputStream)} and
- * {@link DeploymentPackage#uninstall()} methods throw exception with this error code.
- */
- public static final int CODE_COMMIT_ERROR = 462;
-
- /**
- * Other error condition.<p>
- *
- * All Deployment Admin methods which throw <code>DeploymentException</code>
- * can throw an exception with this error code if the error condition cannot be
- * categorized.
- */
- public static final int CODE_OTHER_ERROR = 463;
-
- /**
- * The Resource Processor service with the given PID (see
- * <code>Resource-Processor</code> manifest header) is not found.<p>
- *
- * {@link DeploymentAdmin#installDeploymentPackage(InputStream)},
- * {@link DeploymentPackage#uninstall()} and
- * {@link DeploymentPackage#uninstallForced()}
- * throws exception with this error code.
- */
- public static final int CODE_PROCESSOR_NOT_FOUND = 464;
-
- /**
- * When a client requests a new session with an install or uninstall
- * operation, it must block that call until the earlier session is
- * completed. The Deployment Admin service must throw a Deployment Exception
- * with this error code when the session can not be created after an appropriate
- * time out period.<p>
- *
- * {@link DeploymentAdmin#installDeploymentPackage(InputStream)},
- * {@link DeploymentPackage#uninstall()} and
- * {@link DeploymentPackage#uninstallForced()}
- * throws exception with this error code.
- */
- public static final int CODE_TIMEOUT = 465;
-
- private final int code;
-
- /**
- * Create an instance of the exception.
- *
- * @param code The error code of the failure. Code should be one of the
- * predefined integer values (<code>CODE_X</code>).
- * @param message Message associated with the exception
- * @param cause the originating exception
- */
- public DeploymentException(int code, String message, Throwable cause) {
- super(message, cause);
- this.code = code;
- }
-
- /**
- * Create an instance of the exception. Cause exception is implicitly set to
- * null.
- *
- * @param code The error code of the failure. Code should be one of the
- * predefined integer values (<code>CODE_X</code>).
- * @param message Message associated with the exception
- */
- public DeploymentException(int code, String message) {
- super(message);
- this.code = code;
- }
-
- /**
- * Create an instance of the exception. Cause exception and message are
- * implicitly set to null.
- *
- * @param code The error code of the failure. Code should be one of the
- * predefined integer values (<code>CODE_X</code>).
- */
- public DeploymentException(int code) {
- super();
- this.code = code;
- }
-
- /**
- * Returns the cause of this exception or <code>null</code> if no cause was
- * set.
- *
- * @return The cause of this exception or <code>null</code> if no cause was
- * set.
- */
- public Throwable getCause() {
- return super.getCause();
- }
-
- /**
- * Initializes the cause of this exception to the specified value.
- *
- * @param cause The cause of this exception.
- * @return This exception.
- * @throws IllegalArgumentException If the specified cause is this
- * exception.
- * @throws IllegalStateException If the cause of this exception has already
- * been set.
- * @since 1.1
- */
- public Throwable initCause(Throwable cause) {
- return super.initCause(cause);
- }
-
- /**
- * @return Returns the code.
- */
- public int getCode() {
- return code;
- }
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/deploymentadmin/DeploymentPackage.java b/org.osgi.compendium/src/main/java/org/osgi/service/deploymentadmin/DeploymentPackage.java
deleted file mode 100644
index 69e5029..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/deploymentadmin/DeploymentPackage.java
+++ /dev/null
@@ -1,362 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2005, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.osgi.service.deploymentadmin;
-
-import java.net.URL;
-
-import org.osgi.framework.Bundle;
-import org.osgi.framework.ServiceReference;
-import org.osgi.framework.Version;
-
-/**
- * The <code>DeploymentPackage</code> object represents a deployment package
- * (already installed or being currently processed). A Deployment Package groups
- * resources as a unit of management. A deployment package is something that can
- * be installed, updated, and uninstalled as a unit. A deployment package is a
- * reified concept, like a bundle, in an OSGi Service Platform. It is not known
- * by the OSGi Framework, but it is managed by the Deployment Admin service. A
- * deployment package is a stream of resources (including bundles) which, once
- * processed, will result in new artifacts (effects on the system) being added
- * to the OSGi platform. These new artifacts can include installed Bundles, new
- * configuration objects added to the Configuration Admin service, new Wire
- * objects added to the Wire Admin service, or changed system properties, etc.
- * All the changes caused by the processing of a deployment package are
- * persistently associated with the deployment package, so that they can be
- * appropriately cleaned up when the deployment package is uninstalled. There is
- * a strict no overlap rule imposed on deployment packages. Two deployment
- * packages are not allowed to create or manipulate the same artifact.
- * Obviously, this means that a bundle cannot be in two different deployment
- * packages. Any violation of this no overlap rule is considered an error and
- * the install or update of the offending deployment package must be aborted.
- * <p>
- *
- * The Deployment Admin service should do as much as possible to ensure
- * transactionality. It means that if a deployment package installation, update
- * or removal (uninstall) fails all the side effects caused by the process
- * should be disappeared and the system should be in the state in which it was
- * before the process.
- * <p>
- *
- * If a deployment package is being updated the old version is visible through
- * the <code>DeploymentPackage</code> interface until the update process ends.
- * After the package is updated the updated version is visible and the old one
- * is not accessible any more.
- */
-public interface DeploymentPackage {
- /**
- * The name of the Deployment Package. This name is the same name as that
- * specified in the DeploymentPackage-SymbolicName Manifest header.
- *
- * @since 1.1
- */
- String EVENT_DEPLOYMENTPACKAGE_NAME = "deploymentpackage.name";
-
- /**
- * The human readable name of the DP localized to the default locale.
- *
- * @since 1.1
- */
- String EVENT_DEPLOYMENTPACKAGE_READABLENAME = "deploymentpackage.readablename";
-
- /**
- * The currently installed version of the Deployment Package. The attribute
- * is not present, if no version is installed:
- * <ul>
- * <li>in the INSTALL event, when an installDeploymentPackage was called and
- * no earlier version is present
- * <li>in the COMPLETE event after the _successfully_ completing an
- * uninstallDeploymentPackage call
- * </ul>
- * The value for this event must be a Version object.
- *
- * @since 1.1
- */
- String EVENT_DEPLOYMENTPACKAGE_CURRENTVERSION = "deploymentpackage.currentversion";
-
- /**
- * The version of DP after the successful completion of the install
- * operation (used in INSTALL event only).
- *
- * The value for this event must be a Version object.
- *
- * @since 1.1
- */
- String EVENT_DEPLOYMENTPACKAGE_NEXTVERSION = "deploymentpackage.nextversion";
-
- /**
- * Gives back the state of the deployment package whether it is stale or
- * not). After uninstall of a deployment package it becomes stale. Any
- * active method calls to a stale deployment package raise
- * {@link IllegalStateException}. Active methods are the following:
- * <p>
- *
- * <ul>
- * <li>{@link #getBundle(String)}</li>
- * <li>{@link #getResourceProcessor(String)}</li>
- * <li>{@link #uninstall()}</li>
- * <li>{@link #uninstallForced()}</li>
- * </ul>
- *
- * @return <code>true</code> if the deployment package is stale.
- * <code>false</code> otherwise
- * @see #uninstall
- * @see #uninstallForced
- */
- boolean isStale();
-
- /**
- * Returns the Deployment Package Symbolic Name of the package.
- *
- * @return The name of the deployment package. It cannot be null.
- */
- String getName();
-
- /**
- * Returns the Deployment Package human readable name.
- *
- * This method returns the localized human readable name as set with the
- * <code>DeploymentPackage-Name</code> manifest header using the default
- * locale. If no header is set, this method will return <code>null</code>.
- *
- * @return The human readable name of the deployment package or
- * <code>null</code> if header is not set.
- * @since 1.1
- */
- String getDisplayName();
-
- /**
- * Returns the version of the deployment package.
- *
- * @return version of the deployment package. It cannot be null.
- */
- Version getVersion();
-
- /**
- * Returns an array of {@link BundleInfo} objects representing the bundles
- * specified in the manifest of this deployment package. Its size is equal
- * to the number of the bundles in the deployment package.
- *
- * @return array of <code>BundleInfo</code> objects
- * @throws SecurityException
- * if the caller doesn't have the appropriate
- * {@link DeploymentAdminPermission} with "metadata" action
- */
- BundleInfo[] getBundleInfos();
-
- /**
- * Returns a URL pointing to an image that represents the icon for this
- * Deployment Package.
- *
- * The <code>DeploymentPackage-Icon</code> header can set an icon for the
- * the deployment package. This method returns an absolute URL that is
- * defined by this header. The Deployment Admin service must provide this
- * icon as a local resource. That is, the Deployment Admin must make a local
- * copy of the specified icon. The returned <code>URL</code>'s must point to
- * a local resource.
- *
- * @return An absolute URL to a local (device resident) image resource or
- * <code>null</code> if not found
- * @since 1.1
- */
- URL getIcon();
-
- /**
- * Returns the bundle instance, which is part of this deployment package,
- * that corresponds to the bundle's symbolic name passed in the
- * <code>symbolicName</code> parameter. This method will return null for
- * request for bundles that are not part of this deployment package.
- * <p>
- *
- * As this instance is transient (i.e. a bundle can be removed at any time
- * because of the dynamic nature of the OSGi platform), this method may also
- * return null if the bundle is part of this deployment package, but is not
- * currently defined to the framework.
- *
- * @param symbolicName
- * the symbolic name of the requested bundle
- * @return The <code>Bundle</code> instance for a given bundle symbolic
- * name.
- * @throws SecurityException
- * if the caller doesn't have the appropriate
- * {@link DeploymentAdminPermission} with "metadata" action
- * @throws IllegalStateException
- * if the package is stale
- */
- Bundle getBundle(String symbolicName);
-
- /**
- * Returns an array of strings representing the resources (including
- * bundles) that are specified in the manifest of this deployment package. A
- * string element of the array is the same as the value of the "Name"
- * attribute in the manifest. The array contains the bundles as well.
- * <p>
- *
- * E.g. if the "Name" section of the resource (or individual-section as the
- * <a
- * href="http://java.sun.com/j2se/1.4.2/docs/guide/jar/jar.html#Manifest%20Specification">Manifest
- * Specification</a> calls it) in the manifest is the following
- *
- * <pre>
- * Name: foo/readme.txt
- * Resource-Processor: foo.rp
- * </pre>
- *
- * then the corresponding array element is the "foo/readme.txt" string.
- * <p>
- *
- * @return The string array corresponding to resources. It cannot be null
- * but its length can be zero.
- * @throws SecurityException
- * if the caller doesn't have the appropriate
- * {@link DeploymentAdminPermission} with "metadata" action
- */
- String[] getResources();
-
- /**
- * At the time of deployment, resource processor service instances are
- * located to resources contained in a deployment package.
- * <p>
- *
- * This call returns a service reference to the corresponding service
- * instance. If the resource is not part of the deployment package or this
- * call is made during deployment, prior to the locating of the service to
- * process a given resource, null will be returned. Services can be updated
- * after a deployment package has been deployed. In this event, this call
- * will return a reference to the updated service, not to the instance that
- * was used at deployment time.
- *
- * @param resource
- * the name of the resource (it is the same as the value of the
- * "Name" attribute in the deployment package's manifest)
- * @return resource processor for the resource or <code>null</code>.
- * @throws SecurityException if the caller doesn't have the appropriate {@link DeploymentAdminPermission}
- * with "metadata" action
- * @throws IllegalStateException if the package is stale
- */
- ServiceReference getResourceProcessor(String resource);
-
- /**
- * Returns the requested deployment package manifest header from the main
- * section. Header names are case insensitive. If the header doesn't exist
- * it returns null.
- * <p>
- *
- * If the header is localized then the localized value is returned (see OSGi
- * Service Platform, Mobile Specification Release 4 - Localization related
- * chapters).
- *
- * @param header
- * the requested header
- * @return the value of the header or <code>null</code> if the header does
- * not exist
- * @throws SecurityException
- * if the caller doesn't have the appropriate
- * {@link DeploymentAdminPermission} with "metadata" action
- */
- String getHeader(String header);
-
- /**
- * Returns the requested deployment package manifest header from the name
- * section determined by the resource parameter. Header names are case
- * insensitive. If the resource or the header doesn't exist it returns null.
- * <p>
- *
- * If the header is localized then the localized value is returned (see OSGi
- * Service Platform, Mobile Specification Release 4 - Localization related
- * chapters).
- *
- * @param resource
- * the name of the resource (it is the same as the value of the
- * "Name" attribute in the deployment package's manifest)
- * @param header
- * the requested header
- * @return the value of the header or <code>null</code> if the resource or
- * the header doesn't exist
- * @throws SecurityException
- * if the caller doesn't have the appropriate
- * {@link DeploymentAdminPermission} with "metadata" action
- */
- String getResourceHeader(String resource, String header);
-
- /**
- * Uninstalls the deployment package. After uninstallation, the deployment
- * package object becomes stale. This can be checked by using
- * {@link #isStale()}, which will return <code>true</code> when stale.
- * <p>
- *
- * @throws DeploymentException
- * if the deployment package could not be successfully
- * uninstalled. For detailed error code description see
- * {@link DeploymentException}.
- * @throws SecurityException
- * if the caller doesn't have the appropriate
- * {@link DeploymentAdminPermission}("<filter>",
- * "uninstall") permission.
- * @throws IllegalStateException
- * if the package is stale
- */
- void uninstall() throws DeploymentException;
-
- /**
- * This method is called to completely uninstall a deployment package, which
- * couldn't be uninstalled using traditional means ({@link #uninstall()})
- * due to exceptions. After uninstallation, the deployment package object
- * becomes stale. This can be checked by using {@link #isStale()}, which
- * will return <code>true</code> when stale.
- * <p>
- *
- * The method forces removal of the Deployment Package from the repository
- * maintained by the Deployment Admin service. This method follows the same
- * steps as {@link #uninstall}. However, any errors or the absence of
- * Resource Processor services are ignored, they must not cause a roll back.
- * These errors should be logged.
- *
- * @return true if the operation was successful
- * @throws DeploymentException
- * only {@link DeploymentException#CODE_TIMEOUT} and
- * {@link DeploymentException#CODE_CANCELLED} can be thrown. For
- * detailed error code description see
- * {@link DeploymentException}.
- * @throws SecurityException
- * if the caller doesn't have the appropriate
- * {@link DeploymentAdminPermission}("<filter>",
- * "uninstall_forced") permission.
- * @throws IllegalStateException
- * if the package is stale
- */
- boolean uninstallForced() throws DeploymentException;
-
- /**
- * Returns a hash code value for the object.
- *
- * @return a hash code value for this object
- */
- int hashCode();
-
- /**
- * Indicates whether some other object is "equal to" this one. Two
- * deployment packages are equal if they have the same deployment package
- * symbolic name and version.
- *
- * @param other
- * the reference object with which to compare.
- * @return true if this object is the same as the <code>other<code> argument; false
- * otherwise.
- */
- boolean equals(Object other);
-
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/deploymentadmin/spi/DeploymentCustomizerPermission.java b/org.osgi.compendium/src/main/java/org/osgi/service/deploymentadmin/spi/DeploymentCustomizerPermission.java
deleted file mode 100644
index fa4534f..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/deploymentadmin/spi/DeploymentCustomizerPermission.java
+++ /dev/null
@@ -1,201 +0,0 @@
-/*
- *
- * Copyright (c) OSGi Alliance (2005, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.osgi.service.deploymentadmin.spi;
-
-import java.lang.reflect.Constructor;
-import java.lang.reflect.InvocationTargetException;
-import java.security.AccessController;
-import java.security.Permission;
-import java.security.PermissionCollection;
-import java.security.PrivilegedAction;
-
-import org.osgi.service.deploymentadmin.DeploymentAdminPermission;
-
-/**
- * The <code>DeploymentCustomizerPermission</code> permission gives the right to
- * Resource Processors to access a bundle's (residing in a Deployment Package) private area.
- * The bundle and the Resource Processor (customizer) have to be in the same Deployment Package.<p>
- *
- * The Resource Processor that has this permission is allowed to access the bundle's
- * private area by calling the {@link DeploymentSession#getDataFile} method during the session
- * (see {@link DeploymentSession}). After the session ends the FilePermissions are withdrawn.
- * The Resource Processor will have <code>FilePermission</code> with "read", "write" and "delete"
- * actions for the returned {@link java.io.File} that represents the the base directory of the
- * persistent storage area and for its subdirectories.<p>
- *
- * The actions string is converted to lowercase before processing.
- */
-public class DeploymentCustomizerPermission extends Permission {
-
- /**
- *
- */
- private static final long serialVersionUID = 1L;
-
- /**
- * Constant String to the "privatearea" action.
- */
- public static final String PRIVATEAREA = "privatearea";
-
- private static final String delegateProperty = "org.osgi.vendor.deploymentadmin";
- private static final Constructor constructor;
- private final Permission delegate;
- static {
- constructor = (Constructor) AccessController.doPrivileged(new PrivilegedAction() {
- public Object run() {
- String pckg = System.getProperty(delegateProperty);
- if (null == pckg)
- throw new RuntimeException("Property '" + delegateProperty + "' is not set");
- try {
- Class c = Class.forName(pckg + ".DeploymentCustomizerPermission");
- return c.getConstructor(new Class[] {String.class, String.class});
- }
- catch (Exception e) {
- throw new RuntimeException(e);
- }
- }});
- }
-
- /**
- * Creates a new <code>DeploymentCustomizerPermission</code> object for the given
- * <code>name</code> and <code>action</code>.<p>
- *
- * The name parameter is a filter string. This filter has the same syntax as an OSGi filter
- * but only the "name" attribute is allowed. The value of the attribute
- * is a Bundle Symbolic Name that represents a bundle. The only allowed action is the
- * "privatearea" action. E.g.
- *
- * <pre>
- * Permission perm = new DeploymentCustomizerPermission("(name=com.acme.bundle)", "privatearea");
- * </pre>
- *
- * The Resource Processor that has this permission is allowed to access the bundle's
- * private area by calling the {@link DeploymentSession#getDataFile} method. The
- * Resource Processor will have <code>FilePermission</code> with "read", "write" and "delete"
- * actions for the returned {@link java.io.File} and its subdirectories during the deployment
- * session.
- *
- * @param name Bundle Symbolic Name of the target bundle, must not be <code>null</code>.
- * @param actions action string (only the "privatearea" or "*" action is valid; "*" means all
- * the possible actions), must not be <code>null</code>.
- * @throws IllegalArgumentException if the filter is invalid, the list of actions
- * contains unknown operations or one of the parameters is <code>null</code>
- */
- public DeploymentCustomizerPermission(String name, String actions) {
- super(name);
- try {
- try {
- delegate = (Permission) constructor.newInstance(new Object[] {name, actions});
- }
- catch (InvocationTargetException e) {
- throw e.getTargetException();
- }
- }
- catch (Error e) {
- throw e;
- }
- catch (RuntimeException e) {
- throw e;
- }
- catch (Throwable e) {
- throw new RuntimeException(e);
- }
- }
-
- /**
- * Checks two DeploymentCustomizerPermission objects for equality.
- * Two permission objects are equal if: <p>
- *
- * <ul>
- * <li>their target filters are equal (semantically and not character by
- * character) and</li>
- * <li>their actions are the same</li>
- * </ul>
- *
- * @param obj the reference object with which to compare.
- * @return true if the two objects are equal.
- * @see java.lang.Object#equals(java.lang.Object)
- */
- public boolean equals(Object obj) {
- if (obj == this)
- return true;
- if (!(obj instanceof DeploymentCustomizerPermission))
- return false;
- DeploymentCustomizerPermission dcp = (DeploymentCustomizerPermission) obj;
- return delegate.equals(dcp.delegate);
- }
-
- /**
- * Returns hash code for this permission object.
- *
- * @return Hash code for this permission object.
- * @see java.lang.Object#hashCode()
- */
- public int hashCode() {
- return delegate.hashCode();
- }
-
- /**
- * Returns the String representation of the action list.
- *
- * @return Action list of this permission instance. It is always "privatearea".
- * @see java.security.Permission#getActions()
- */
- public String getActions() {
- return delegate.getActions();
- }
-
- /**
- * Checks if this DeploymentCustomizerPermission would imply the parameter permission.
- * This permission implies another DeploymentCustomizerPermission permission if:
- *
- * <ul>
- * <li>both of them has the "privatearea" action (other actions are not allowed) and</li>
- * <li>their filters (only name attribute is allowed in the filters) match similarly to
- * {@link DeploymentAdminPermission}.</li>
- * </ul>
- *
- * The value of the name attribute means Bundle Symbolic Name and not Deployment Package
- * Symbolic Name here!<p>
- *
- * @param permission Permission to check.
- * @return true if this DeploymentCustomizerPermission object implies the
- * specified permission.
- * @see java.security.Permission#implies(java.security.Permission)
- */
- public boolean implies(Permission permission) {
- if (!(permission instanceof DeploymentCustomizerPermission))
- return false;
-
- DeploymentCustomizerPermission dcp = (DeploymentCustomizerPermission) permission;
-
- return delegate.implies(dcp.delegate);
- }
-
- /**
- * Returns a new PermissionCollection object for storing DeploymentCustomizerPermission
- * objects.
- *
- * @return The new PermissionCollection.
- * @see java.security.Permission#newPermissionCollection()
- */
- public PermissionCollection newPermissionCollection() {
- return delegate.newPermissionCollection();
- }
-
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/deploymentadmin/spi/DeploymentSession.java b/org.osgi.compendium/src/main/java/org/osgi/service/deploymentadmin/spi/DeploymentSession.java
deleted file mode 100644
index 646a979..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/deploymentadmin/spi/DeploymentSession.java
+++ /dev/null
@@ -1,94 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2005, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.service.deploymentadmin.spi;
-
-import org.osgi.service.deploymentadmin.DeploymentPackage;
-
-/**
- * The session interface represents a currently running deployment session
- * (install/update/uninstall).<p>
- *
- * When a deployment package is installed the target package, when uninstalled the
- * source package is an empty deployment package. The empty deployment package is a virtual
- * entity it doesn't appear for the outside world. It is only visible on the
- * DeploymentSession interface used by Resource Processors. Although the empty package
- * is only visible for Resource Processors it has the following characteristics:<p>
- *
- * <ul>
- * <li>has version 0.0.0</li>
- * <li>its name is an empty string</li>
- * <li>it is stale</li>
- * <li>it has no bundles
- * (see {@link DeploymentPackage#getBundle(String)})</li>
- * <li>it has no resources
- * (see {@link DeploymentPackage#getResources()})</li>
- * <li>it has no headers except <br/>
- * <code>DeploymentPackage-SymbolicName</code> and <br/>
- * <code>DeploymentPackage-Version</code> <br/>
- * (see {@link DeploymentPackage#getHeader(String)})</li>
- * <li>it has no resource headers (see
- * {@link DeploymentPackage#getResourceHeader(String, String)})</li>
- * <li>{@link DeploymentPackage#uninstall()} throws
- * {@link java.lang.IllegalStateException}</li>
- * <li>{@link DeploymentPackage#uninstallForced()} throws
- * {@link java.lang.IllegalStateException}</li>
- * </ul>
- *
- */
-public interface DeploymentSession {
-
- /**
- * If the deployment action is an update or an uninstall, this call returns
- * the <code>DeploymentPackage</code> instance for the installed deployment package. If the
- * deployment action is an install, this call returns the empty deployment package (see
- * {@link DeploymentPackage}).
- *
- * @return the target deployment package
- * @see DeploymentPackage
- */
- DeploymentPackage getTargetDeploymentPackage();
-
- /**
- * If the deployment action is an install or an update, this call returns
- * the <code>DeploymentPackage</code> instance that corresponds to the deployment package
- * being streamed in for this session. If the deployment action is an uninstall, this call
- * returns the empty deployment package (see {@link DeploymentPackage}).
- *
- * @return the source deployment package
- * @see DeploymentPackage
- */
- DeploymentPackage getSourceDeploymentPackage();
-
- /**
- * Returns the private data area of the specified bundle. The bundle must be part of
- * either the source or the target deployment packages. The permission set the caller
- * resource processor needs to manipulate the private area of the bundle is set by the
- * Deployment Admin on the fly when this method is called. The permissions remain available
- * during the deployment action only.<p>
- *
- * The bundle and the caller Resource Processor have to be in the same Deployment Package.
- *
- * @param bundle the bundle the private area belongs to
- * @return file representing the private area of the bundle. It cannot be null.
- * @throws SecurityException if the caller doesn't have the appropriate
- * {@link DeploymentCustomizerPermission}("<filter>", "privatearea") permission.
- * @see DeploymentPackage
- * @see DeploymentCustomizerPermission
- */
- java.io.File getDataFile(org.osgi.framework.Bundle bundle);
-
-}
-
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/deploymentadmin/spi/ResourceProcessor.java b/org.osgi.compendium/src/main/java/org/osgi/service/deploymentadmin/spi/ResourceProcessor.java
deleted file mode 100644
index 98292f3..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/deploymentadmin/spi/ResourceProcessor.java
+++ /dev/null
@@ -1,137 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2005, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.osgi.service.deploymentadmin.spi;
-
-import java.io.InputStream;
-
-/**
- * ResourceProcessor interface is implemented by processors handling resource files
- * in deployment packages. Resource Processors expose their services as standard OSGi services.
- * Bundles exporting the service may arrive in the deployment package (customizers) or may be
- * preregistered (they are installed previously). Resource processors has to define the
- * <code>service.pid</code> standard OSGi service property which should be a unique string.<p>
- *
- * The order of the method calls on a particular Resource Processor in case of install/update
- * session is the following:<p>
- *
- * <ol>
- * <li>{@link #begin(DeploymentSession)}</li>
- * <li>{@link #process(String, InputStream)} calls till there are resources to process
- * or {@link #rollback()} and the further steps are ignored</li>
- * <li>{@link #dropped(String)} calls till there are resources to drop
- * <li>{@link #prepare()}</li>
- * <li>{@link #commit()} or {@link #rollback()}</li>
- * </ol>
- *
- * The order of the method calls on a particular Resource Processor in case of uninstall
- * session is the following:<p>
- *
- * <ol>
- * <li>{@link #begin(DeploymentSession)}</li>
- * <li>{@link #dropAllResources()} or {@link #rollback()} and the further steps are ignored</li>
- * <li>{@link #prepare()}</li>
- * <li>{@link #commit()} or {@link #rollback()}</li>
- * </ol>
- */
-public interface ResourceProcessor {
-
- /**
- * Called when the Deployment Admin starts a new operation on the given deployment package,
- * and the resource processor is associated a resource within the package. Only one
- * deployment package can be processed at a time.
- *
- * @param session object that represents the current session to the resource processor
- * @see DeploymentSession
- */
- void begin(DeploymentSession session);
-
- /**
- * Called when a resource is encountered in the deployment package for which this resource
- * processor has been selected to handle the processing of that resource.
- *
- * @param name The name of the resource relative to the deployment package root directory.
- * @param stream The stream for the resource.
- * @throws ResourceProcessorException if the resource cannot be processed. Only
- * {@link ResourceProcessorException#CODE_RESOURCE_SHARING_VIOLATION} and
- * {@link ResourceProcessorException#CODE_OTHER_ERROR} error codes are allowed.
- */
- void process(String name, InputStream stream) throws ResourceProcessorException;
-
- /**
- * Called when a resource, associated with a particular resource processor, had belonged to
- * an earlier version of a deployment package but is not present in the current version of
- * the deployment package. This provides an opportunity for the processor to cleanup any
- * memory and persistent data being maintained for the particular resource.
- * This method will only be called during "update" deployment sessions.
- *
- * @param resource the name of the resource to drop (it is the same as the value of the
- * "Name" attribute in the deployment package's manifest)
- * @throws ResourceProcessorException if the resource is not allowed to be dropped. Only the
- * {@link ResourceProcessorException#CODE_OTHER_ERROR} error code is allowed
- */
- void dropped(String resource) throws ResourceProcessorException;
-
- /**
- * This method is called during an "uninstall" deployment session.
- * This method will be called on all resource processors that are associated with resources
- * in the deployment package being uninstalled. This provides an opportunity for the processor
- * to cleanup any memory and persistent data being maintained for the deployment package.
- *
- * @throws ResourceProcessorException if all resources could not be dropped. Only the
- * {@link ResourceProcessorException#CODE_OTHER_ERROR} is allowed.
- */
- void dropAllResources() throws ResourceProcessorException;
-
- /**
- * This method is called on the Resource Processor immediately before calling the
- * <code>commit</code> method. The Resource Processor has to check whether it is able
- * to commit the operations since the last <code>begin</code> method call. If it determines
- * that it is not able to commit the changes, it has to raise a
- * <code>ResourceProcessorException</code> with the {@link ResourceProcessorException#CODE_PREPARE}
- * error code.
- *
- * @throws ResourceProcessorException if the resource processor is able to determine it is
- * not able to commit. Only the {@link ResourceProcessorException#CODE_PREPARE} error
- * code is allowed.
- */
- void prepare() throws ResourceProcessorException;
-
- /**
- * Called when the processing of the current deployment package is finished.
- * This method is called if the processing of the current deployment package was successful,
- * and the changes must be made permanent.
- */
- void commit();
-
-
- /**
- * Called when the processing of the current deployment package is finished.
- * This method is called if the processing of the current deployment package was unsuccessful,
- * and the changes made during the processing of the deployment package should be removed.
- */
- void rollback();
-
- /**
- * Processing of a resource passed to the resource processor may take long.
- * The <code>cancel()</code> method notifies the resource processor that it should
- * interrupt the processing of the current resource. This method is called by the
- * <code>DeploymentAdmin</code> implementation after the
- * <code>DeploymentAdmin.cancel()</code> method is called.
- */
- void cancel();
-
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/deploymentadmin/spi/ResourceProcessorException.java b/org.osgi.compendium/src/main/java/org/osgi/service/deploymentadmin/spi/ResourceProcessorException.java
deleted file mode 100644
index 3aceca7..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/deploymentadmin/spi/ResourceProcessorException.java
+++ /dev/null
@@ -1,132 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2005, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.service.deploymentadmin.spi;
-
-import java.io.InputStream;
-
-/**
- * Checked exception received when something fails during a call to a Resource
- * Processor. A <code>ResourceProcessorException</code> always contains an error
- * code (one of the constants specified in this class), and may optionally contain
- * the textual description of the error condition and a nested cause exception.
- */
-public class ResourceProcessorException extends Exception {
-
- /**
- *
- */
- private static final long serialVersionUID = 9135007015668223386L;
-
- /**
- * Resource Processors are allowed to raise an exception with this error code
- * to indicate that the processor is not able to commit the operations it made
- * since the last call of {@link ResourceProcessor#begin(DeploymentSession)} method.<p>
- *
- * Only the {@link ResourceProcessor#prepare()} method is allowed to throw exception
- * with this error code.
- */
- public static final int CODE_PREPARE = 1;
-
- /**
- * An artifact of any resource already exists.<p>
- *
- * Only the {@link ResourceProcessor#process(String, InputStream)} method
- * is allowed to throw exception with this error code.
- */
- public static final int CODE_RESOURCE_SHARING_VIOLATION = 461;
-
- /**
- * Other error condition.<p>
- *
- * All Resource Processor methods which throw <code>ResourceProcessorException</code>
- * is allowed throw an exception with this error code if the error condition cannot be
- * categorized.
- */
- public static final int CODE_OTHER_ERROR = 463;
-
- private final int code;
-
- /**
- * Create an instance of the exception.
- *
- * @param code The error code of the failure. Code should be one of the
- * predefined integer values (<code>CODE_X</code>).
- * @param message Message associated with the exception
- * @param cause the originating exception
- */
- public ResourceProcessorException(int code, String message, Throwable cause) {
- super(message, cause);
- this.code = code;
- }
-
- /**
- * Create an instance of the exception. Cause exception is implicitly set to
- * null.
- *
- * @param code The error code of the failure. Code should be one of the
- * predefined integer values (<code>CODE_X</code>).
- * @param message Message associated with the exception
- */
- public ResourceProcessorException(int code, String message) {
- super(message);
- this.code = code;
- }
-
- /**
- * Create an instance of the exception. Cause exception and message are
- * implicitly set to null.
- *
- * @param code The error code of the failure. Code should be one of the
- * predefined integer values (<code>CODE_X</code>).
- */
- public ResourceProcessorException(int code) {
- super();
- this.code = code;
- }
-
- /**
- * Returns the cause of this exception or <code>null</code> if no cause was
- * set.
- *
- * @return The cause of this exception or <code>null</code> if no cause was
- * set.
- */
- public Throwable getCause() {
- return super.getCause();
- }
-
- /**
- * Initializes the cause of this exception to the specified value.
- *
- * @param cause The cause of this exception.
- * @return This exception.
- * @throws IllegalArgumentException If the specified cause is this
- * exception.
- * @throws IllegalStateException If the cause of this exception has already
- * been set.
- * @since 1.0.1
- */
- public Throwable initCause(Throwable cause) {
- return super.initCause(cause);
- }
-
- /**
- * @return Returns the code.
- */
- public int getCode() {
- return code;
- }
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/device/Constants.java b/org.osgi.compendium/src/main/java/org/osgi/service/device/Constants.java
deleted file mode 100644
index 8787256..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/device/Constants.java
+++ /dev/null
@@ -1,73 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2000, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.service.device;
-
-/**
- * This interface defines standard names for property keys associated with
- * {@link Device} and {@link Driver} services.
- *
- * <p>
- * The values associated with these keys are of type <code>java.lang.String</code>,
- * unless otherwise stated.
- *
- * @version $Revision: 5673 $
- * @since 1.1
- * @see Device
- * @see Driver
- */
-public interface Constants {
- /**
- * Property (named "DRIVER_ID") identifying a driver.
- *
- * <p>
- * A <code>DRIVER_ID</code> should start with the reversed domain name of the
- * company that implemented the driver (e.g., <code>com.acme</code>), and
- * must meet the following requirements:
- *
- * <ul>
- * <li>It must be independent of the location from where it is obtained.
- * <li>It must be independent of the {@link DriverLocator} service that
- * downloaded it.
- * <li>It must be unique.
- * <li>It must be different for different revisions of the same driver.
- * </ul>
- *
- * <p>
- * This property is mandatory, i.e., every <code>Driver</code> service must be
- * registered with it.
- */
- public static final String DRIVER_ID = "DRIVER_ID";
- /**
- * Property (named "DEVICE_CATEGORY") containing a human readable
- * description of the device categories implemented by a device. This
- * property is of type <code>String[]</code>
- *
- * <p>
- * Services registered with this property will be treated as devices and
- * discovered by the device manager
- */
- public static final String DEVICE_CATEGORY = "DEVICE_CATEGORY";
- /**
- * Property (named "DEVICE_SERIAL") specifying a device's serial
- * number.
- */
- public static final String DEVICE_SERIAL = "DEVICE_SERIAL";
- /**
- * Property (named "DEVICE_DESCRIPTION") containing a human
- * readable string describing the actual hardware device.
- */
- public static final String DEVICE_DESCRIPTION = "DEVICE_DESCRIPTION";
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/device/Device.java b/org.osgi.compendium/src/main/java/org/osgi/service/device/Device.java
deleted file mode 100644
index 2af0330..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/device/Device.java
+++ /dev/null
@@ -1,62 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2000, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.service.device;
-
-/**
- * <p>
- * Interface for identifying device services.
- *
- * <p>
- * A service must implement this interface or use the
- * {@link Constants#DEVICE_CATEGORY} registration property to indicate that it
- * is a device. Any services implementing this interface or registered with the
- * <code>DEVICE_CATEGORY</code> property will be discovered by the device
- * manager.
- *
- * <p>
- * Device services implementing this interface give the device manager the
- * opportunity to indicate to the device that no drivers were found that could
- * (further) refine it. In this case, the device manager calls the
- * {@link #noDriverFound} method on the <code>Device</code> object.
- *
- * <p>
- * Specialized device implementations will extend this interface by adding
- * methods appropriate to their device category to it.
- *
- * @version $Revision: 5654 $
- * @see Driver
- * @ThreadSafe
- */
-public interface Device {
- /**
- * Return value from {@link Driver#match} indicating that the driver cannot
- * refine the device presented to it by the device manager.
- *
- * The value is zero.
- */
- public static final int MATCH_NONE = 0;
-
- /**
- * Indicates to this <code>Device</code> object that the device manager has
- * failed to attach any drivers to it.
- *
- * <p>
- * If this <code>Device</code> object can be configured differently, the
- * driver that registered this <code>Device</code> object may unregister it
- * and register a different Device service instead.
- */
- public void noDriverFound();
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/device/Driver.java b/org.osgi.compendium/src/main/java/org/osgi/service/device/Driver.java
deleted file mode 100644
index 98e3617..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/device/Driver.java
+++ /dev/null
@@ -1,107 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2000, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.service.device;
-
-import org.osgi.framework.ServiceReference;
-
-/**
- * A <code>Driver</code> service object must be registered by each Driver bundle
- * wishing to attach to Device services provided by other drivers. For each
- * newly discovered {@link Device} object, the device manager enters a bidding
- * phase. The <code>Driver</code> object whose {@link #match} method bids the
- * highest for a particular <code>Device</code> object will be instructed by the
- * device manager to attach to the <code>Device</code> object.
- *
- * @version $Revision: 5654 $
- * @see Device
- * @see DriverLocator
- * @ThreadSafe
- */
-public interface Driver {
- /**
- * Checks whether this Driver service can be attached to the Device service.
- *
- * The Device service is represented by the given {@link ServiceReference}
- * and returns a value indicating how well this driver can support the given
- * Device service, or {@link Device#MATCH_NONE} if it cannot support the
- * given Device service at all.
- *
- * <p>
- * The return value must be one of the possible match values defined in the
- * device category definition for the given Device service, or
- * <code>Device.MATCH_NONE</code> if the category of the Device service is
- * not recognized.
- *
- * <p>
- * In order to make its decision, this Driver service may examine the
- * properties associated with the given Device service, or may get the
- * referenced service object (representing the actual physical device) to
- * talk to it, as long as it ungets the service and returns the physical
- * device to a normal state before this method returns.
- *
- * <p>
- * A Driver service must always return the same match code whenever it is
- * presented with the same Device service.
- *
- * <p>
- * The match function is called by the device manager during the matching
- * process.
- *
- * @param reference the <code>ServiceReference</code> object of the device
- * to match
- *
- * @return value indicating how well this driver can support the given
- * Device service, or <code>Device.MATCH_NONE</code> if it cannot
- * support the Device service at all
- *
- * @throws java.lang.Exception if this Driver service cannot examine the
- * Device service
- */
- public int match(ServiceReference reference) throws Exception;
-
- /**
- * Attaches this Driver service to the Device service represented by the
- * given <code>ServiceReference</code> object.
- *
- * <p>
- * A return value of <code>null</code> indicates that this Driver service
- * has successfully attached to the given Device service. If this Driver
- * service is unable to attach to the given Device service, but knows of a
- * more suitable Driver service, it must return the <code>DRIVER_ID</code>
- * of that Driver service. This allows for the implementation of referring
- * drivers whose only purpose is to refer to other drivers capable of
- * handling a given Device service.
- *
- * <p>
- * After having attached to the Device service, this driver may register the
- * underlying device as a new service exposing driver-specific
- * functionality.
- *
- * <p>
- * This method is called by the device manager.
- *
- * @param reference the <code>ServiceReference</code> object of the device
- * to attach to
- *
- * @return <code>null</code> if this Driver service has successfully
- * attached to the given Device service, or the
- * <code>DRIVER_ID</code> of a more suitable driver
- *
- * @throws java.lang.Exception if the driver cannot attach to the given
- * device and does not know of a more suitable driver
- */
- public String attach(ServiceReference reference) throws Exception;
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/device/DriverLocator.java b/org.osgi.compendium/src/main/java/org/osgi/service/device/DriverLocator.java
deleted file mode 100644
index 2726b99..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/device/DriverLocator.java
+++ /dev/null
@@ -1,65 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2000, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.service.device;
-
-import java.io.IOException;
-import java.io.InputStream;
-import java.util.Dictionary;
-
-/**
- * A Driver Locator service can find and load device driver bundles given a
- * property set. Each driver is represented by a unique <code>DRIVER_ID</code>.
- * <p>
- * Driver Locator services provide the mechanism for dynamically downloading new
- * device driver bundles into an OSGi environment. They are supplied by
- * providers and encapsulate all provider-specific details related to the
- * location and acquisition of driver bundles.
- *
- * @version $Revision: 5654 $
- * @see Driver
- * @ThreadSafe
- */
-public interface DriverLocator {
- /**
- * Returns an array of <code>DRIVER_ID</code> strings of drivers capable of
- * attaching to a device with the given properties.
- *
- * <p>
- * The property keys in the specified <code>Dictionary</code> objects are
- * case-insensitive.
- *
- * @param props the properties of the device for which a driver is sought
- * @return array of driver <code>DRIVER_ID</code> strings of drivers capable
- * of attaching to a Device service with the given properties, or
- * <code>null</code> if this Driver Locator service does not know of
- * any such drivers
- */
- public String[] findDrivers(Dictionary props);
-
- /**
- * Get an <code>InputStream</code> from which the driver bundle providing a
- * driver with the giving <code>DRIVER_ID</code> can be installed.
- *
- * @param id the <code>DRIVER_ID</code> of the driver that needs to be
- * installed.
- * @return An <code>InputStream</code> object from which the driver bundle
- * can be installed or <code>null</code> if the driver with the
- * given ID cannot be located
- * @throws java.io.IOException the input stream for the bundle cannot be
- * created
- */
- public InputStream loadDriver(String id) throws IOException;
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/device/DriverSelector.java b/org.osgi.compendium/src/main/java/org/osgi/service/device/DriverSelector.java
deleted file mode 100644
index 59fd0b9..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/device/DriverSelector.java
+++ /dev/null
@@ -1,54 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2001, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.service.device;
-
-import org.osgi.framework.ServiceReference;
-
-/**
- * When the device manager detects a new Device service, it calls all registered
- * Driver services to determine if anyone matches the Device service. If at
- * least one Driver service matches, the device manager must choose one. If
- * there is a Driver Selector service registered with the Framework, the device
- * manager will ask it to make the selection. If there is no Driver Selector
- * service, or if it returns an invalid result, or throws an
- * <code>Exception</code>, the device manager uses the default selection
- * strategy.
- *
- * @version $Revision: 5654 $
- * @since 1.1
- * @ThreadSafe
- */
-public interface DriverSelector {
- /**
- * Return value from <code>DriverSelector.select</code>, if no Driver
- * service should be attached to the Device service. The value is -1.
- */
- public static final int SELECT_NONE = -1;
-
- /**
- * Select one of the matching Driver services. The device manager calls this
- * method if there is at least one driver bidding for a device. Only Driver
- * services that have responded with nonzero (not {@link Device#MATCH_NONE})
- * <code></code> match values will be included in the list.
- *
- * @param reference the <code>ServiceReference</code> object of the Device
- * service.
- * @param matches the array of all non-zero matches.
- * @return index into the array of <code>Match</code> objects, or
- * <code>SELECT_NONE</code> if no Driver service should be attached
- */
- public int select(ServiceReference reference, Match[] matches);
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/device/Match.java b/org.osgi.compendium/src/main/java/org/osgi/service/device/Match.java
deleted file mode 100644
index 6410659..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/device/Match.java
+++ /dev/null
@@ -1,43 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2001, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.service.device;
-
-import org.osgi.framework.ServiceReference;
-
-/**
- * Instances of <code>Match</code> are used in the {@link DriverSelector#select}
- * method to identify Driver services matching a Device service.
- *
- * @version $Revision: 5654 $
- * @since 1.1
- * @see DriverSelector
- * @ThreadSafe
- */
-public interface Match {
- /**
- * Return the reference to a Driver service.
- *
- * @return <code>ServiceReference</code> object to a Driver service.
- */
- public ServiceReference getDriver();
-
- /**
- * Return the match value of this object.
- *
- * @return the match value returned by this Driver service.
- */
- public int getMatchValue();
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/event/Event.java b/org.osgi.compendium/src/main/java/org/osgi/service/event/Event.java
deleted file mode 100644
index 42cdb1b..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/event/Event.java
+++ /dev/null
@@ -1,263 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2005, 2009). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.osgi.service.event;
-
-import java.util.Collections;
-import java.util.Dictionary;
-import java.util.Enumeration;
-import java.util.HashMap;
-import java.util.Iterator;
-import java.util.Map;
-
-import org.osgi.framework.Filter;
-
-/**
- * An event.
- *
- * <code>Event</code> objects are delivered to <code>EventHandler</code>
- * services which subscribe to the topic of the event.
- *
- * @Immutable
- * @version $Revision: 7003 $
- */
-public class Event {
- /**
- * The topic of this event.
- */
- private final String topic;
- /**
- * The properties carried by this event. Keys are strings and values are
- * objects
- */
- private final Map /* <String,Object> */properties;
-
- /**
- * Constructs an event.
- *
- * @param topic The topic of the event.
- * @param properties The event's properties (may be <code>null</code>). A
- * property whose key is not of type <code>String</code> will be
- * ignored.
- * @throws IllegalArgumentException If topic is not a valid topic name.
- * @since 1.2
- */
- public Event(String topic, Map/* <String,Object> */properties) {
- validateTopicName(topic);
- this.topic = topic;
- int size = (properties == null) ? 1 : (properties.size() + 1);
- Map p = new HashMap(size);
- if (properties != null) {
- for (Iterator iter = properties.keySet().iterator(); iter.hasNext();) {
- Object key = iter.next();
- if (key instanceof String) {
- Object value = properties.get(key);
- p.put(key, value);
- }
- }
- }
- p.put(EventConstants.EVENT_TOPIC, topic);
- this.properties = p; // safely publish the map
- }
-
- /**
- * Constructs an event.
- *
- * @param topic The topic of the event.
- * @param properties The event's properties (may be <code>null</code>). A
- * property whose key is not of type <code>String</code> will be
- * ignored.
- * @throws IllegalArgumentException If topic is not a valid topic name.
- */
- public Event(String topic, Dictionary/* <String,Object> */properties) {
- validateTopicName(topic);
- this.topic = topic;
- int size = (properties == null) ? 1 : (properties.size() + 1);
- Map p = new HashMap(size);
- if (properties != null) {
- for (Enumeration e = properties.keys(); e.hasMoreElements();) {
- Object key = e.nextElement();
- if (key instanceof String) {
- Object value = properties.get(key);
- p.put(key, value);
- }
- }
- }
- p.put(EventConstants.EVENT_TOPIC, topic);
- this.properties = p; // safely publish the map
- }
-
- /**
- * Retrieves a property.
- *
- * @param name the name of the property to retrieve
- * @return The value of the property, or <code>null</code> if not found.
- */
- public final Object getProperty(String name) {
- return properties.get(name);
- }
-
- /**
- * Returns a list of this event's property names.
- *
- * @return A non-empty array with one element per property.
- */
- public final String[] getPropertyNames() {
- return (String[]) properties.keySet().toArray(
- new String[properties.size()]);
- }
-
- /**
- * Returns the topic of this event.
- *
- * @return The topic of this event.
- */
- public final String getTopic() {
- return topic;
- }
-
- /**
- * Tests this event's properties against the given filter using a case
- * sensitive match.
- *
- * @param filter The filter to test.
- * @return true If this event's properties match the filter, false
- * otherwise.
- */
- public final boolean matches(Filter filter) {
- return filter.matchCase(new UnmodifiableDictionary(properties));
- }
-
- /**
- * Compares this <code>Event</code> object to another object.
- *
- * <p>
- * An event is considered to be <b>equal to</b> another event if the topic
- * is equal and the properties are equal.
- *
- * @param object The <code>Event</code> object to be compared.
- * @return <code>true</code> if <code>object</code> is a <code>Event</code>
- * and is equal to this object; <code>false</code> otherwise.
- */
- public boolean equals(Object object) {
- if (object == this) { // quick test
- return true;
- }
-
- if (!(object instanceof Event)) {
- return false;
- }
-
- Event event = (Event) object;
- return topic.equals(event.topic) && properties.equals(event.properties);
- }
-
- /**
- * Returns a hash code value for the object.
- *
- * @return An integer which is a hash code value for this object.
- */
- public int hashCode() {
- int h = 31 * 17 + topic.hashCode();
- h = 31 * h + properties.hashCode();
- return h;
- }
-
- /**
- * Returns the string representation of this event.
- *
- * @return The string representation of this event.
- */
- public String toString() {
- return getClass().getName() + " [topic=" + topic + "]";
- }
-
- /**
- * Called by the constructor to validate the topic name.
- *
- * @param topic The topic name to validate.
- * @throws IllegalArgumentException If the topic name is invalid.
- */
- private static void validateTopicName(String topic) {
- char[] chars = topic.toCharArray();
- int length = chars.length;
- if (length == 0) {
- throw new IllegalArgumentException("empty topic");
- }
- for (int i = 0; i < length; i++) {
- char ch = chars[i];
- if (ch == '/') {
- // Can't start or end with a '/' but anywhere else is okay
- if (i == 0 || (i == length - 1)) {
- throw new IllegalArgumentException(
- "invalid topic: "
- + topic);
- }
- // Can't have "//" as that implies empty token
- if (chars[i-1] == '/') {
- throw new IllegalArgumentException(
- "invalid topic: "
- + topic);
- }
- continue;
- }
- if (('A' <= ch) && (ch <= 'Z')) {
- continue;
- }
- if (('a' <= ch) && (ch <= 'z')) {
- continue;
- }
- if (('0' <= ch) && (ch <= '9')) {
- continue;
- }
- if ((ch == '_') || (ch == '-')) {
- continue;
- }
- throw new IllegalArgumentException("invalid topic: " + topic);
- }
- }
-
- /**
- * Unmodifiable wrapper for Dictionary.
- */
- private static class UnmodifiableDictionary extends Dictionary {
- private final Map wrapped;
- UnmodifiableDictionary(Map wrapped) {
- this.wrapped = wrapped;
- }
- public Enumeration elements() {
- return Collections.enumeration(wrapped.values());
- }
- public Object get(Object key) {
- return wrapped.get(key);
- }
- public boolean isEmpty() {
- return wrapped.isEmpty();
- }
- public Enumeration keys() {
- return Collections.enumeration(wrapped.keySet());
- }
- public Object put(Object key, Object value) {
- throw new UnsupportedOperationException();
- }
- public Object remove(Object key) {
- throw new UnsupportedOperationException();
- }
- public int size() {
- return wrapped.size();
- }
- }
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/event/EventAdmin.java b/org.osgi.compendium/src/main/java/org/osgi/service/event/EventAdmin.java
deleted file mode 100644
index f48a10f..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/event/EventAdmin.java
+++ /dev/null
@@ -1,52 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2005, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.osgi.service.event;
-
-/**
- * The Event Admin service. Bundles wishing to publish events must obtain the
- * Event Admin service and call one of the event delivery methods.
- *
- * @ThreadSafe
- * @version $Revision: 5673 $
- */
-public interface EventAdmin {
- /**
- * Initiate asynchronous delivery of an event. This method returns to the
- * caller before delivery of the event is completed.
- *
- * @param event The event to send to all listeners which subscribe to the
- * topic of the event.
- *
- * @throws SecurityException If the caller does not have
- * <code>TopicPermission[topic,PUBLISH]</code> for the topic
- * specified in the event.
- */
- void postEvent(Event event);
-
- /**
- * Initiate synchronous delivery of an event. This method does not return to
- * the caller until delivery of the event is completed.
- *
- * @param event The event to send to all listeners which subscribe to the
- * topic of the event.
- *
- * @throws SecurityException If the caller does not have
- * <code>TopicPermission[topic,PUBLISH]</code> for the topic
- * specified in the event.
- */
- void sendEvent(Event event);
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/event/EventConstants.java b/org.osgi.compendium/src/main/java/org/osgi/service/event/EventConstants.java
deleted file mode 100644
index ed3d5d0..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/event/EventConstants.java
+++ /dev/null
@@ -1,186 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2005, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.osgi.service.event;
-
-import org.osgi.framework.Bundle;
-import org.osgi.framework.Constants;
-import org.osgi.framework.Filter;
-import org.osgi.framework.ServiceReference;
-import org.osgi.framework.Version;
-
-/**
- * Defines standard names for <code>EventHandler</code> properties.
- *
- * @version $Revision: 7368 $
- */
-public interface EventConstants {
-
- /**
- * Service registration property (named <code>event.topics</code>)
- * specifying the <code>Event</code> topics of interest to a Event Handler
- * service.
- * <p>
- * Event handlers SHOULD be registered with this property. The value of the
- * property is a string or an array of strings that describe the topics in
- * which the handler is interested. An asterisk ('*') may be used as a
- * trailing wildcard. Event Handlers which do not have a value for this
- * property must not receive events. More precisely, the value of each
- * string must conform to the following grammar:
- *
- * <pre>
- * topic-description := '*' | topic ( '/*' )?
- * topic := token ( '/' token )*
- * </pre>
- *
- * @see Event
- */
- public static final String EVENT_TOPIC = "event.topics";
-
- /**
- * Service Registration property (named <code>event.filter</code>)
- * specifying a filter to further select <code>Event</code> s of interest to
- * a Event Handler service.
- * <p>
- * Event handlers MAY be registered with this property. The value of this
- * property is a string containing an LDAP-style filter specification. Any
- * of the event's properties may be used in the filter expression. Each
- * event handler is notified for any event which belongs to the topics in
- * which the handler has expressed an interest. If the event handler is also
- * registered with this service property, then the properties of the event
- * must also match the filter for the event to be delivered to the event
- * handler.
- * <p>
- * If the filter syntax is invalid, then the Event Handler must be ignored
- * and a warning should be logged.
- *
- * @see Event
- * @see Filter
- */
- public static final String EVENT_FILTER = "event.filter";
-
- /**
- * The Distinguished Names of the signers of the bundle relevant to the
- * event. The type of the value for this event property is
- * <code>String</code> or <code>Collection</code> of <code>String</code>.
- */
- public static final String BUNDLE_SIGNER = "bundle.signer";
-
- /**
- * The Bundle Symbolic Name of the bundle relevant to the event. The type of
- * the value for this event property is <code>String</code>.
- */
- public static final String BUNDLE_SYMBOLICNAME = "bundle.symbolicName";
-
- /**
- * The Bundle id of the bundle relevant to the event. The type of the value
- * for this event property is <code>Long</code>.
- *
- * @since 1.1
- */
- public static final String BUNDLE_ID = "bundle.id";
-
- /**
- * The Bundle object of the bundle relevant to the event. The type of the
- * value for this event property is {@link Bundle}.
- *
- * @since 1.1
- */
- public static final String BUNDLE = "bundle";
-
- /**
- * The version of the bundle relevant to the event. The type of the value
- * for this event property is {@link Version}.
- *
- * @since 1.2
- */
- public static final String BUNDLE_VERSION = "bundle.version";
-
- /**
- * The forwarded event object. Used when rebroadcasting an event that was
- * sent via some other event mechanism. The type of the value for this event
- * property is <code>Object</code>.
- */
- public static final String EVENT = "event";
-
- /**
- * An exception or error. The type of the value for this event property is
- * <code>Throwable</code>.
- */
- public static final String EXCEPTION = "exception";
-
- /**
- * The name of the exception type. Must be equal to the name of the class of
- * the exception in the event property {@link #EXCEPTION}. The type of the
- * value for this event property is <code>String</code>.
- *
- * @since 1.1
- */
- public static final String EXCEPTION_CLASS = "exception.class";
-
- /**
- * The exception message. Must be equal to the result of calling
- * <code>getMessage()</code> on the exception in the event property
- * {@link #EXCEPTION}. The type of the value for this event property is
- * <code>String</code>.
- */
- public static final String EXCEPTION_MESSAGE = "exception.message";
-
- /**
- * A human-readable message that is usually not localized. The type of the
- * value for this event property is <code>String</code>.
- */
- public static final String MESSAGE = "message";
-
- /**
- * A service reference. The type of the value for this event property is
- * {@link ServiceReference}.
- */
- public static final String SERVICE = "service";
-
- /**
- * A service's id. The type of the value for this event property is
- * <code>Long</code>.
- */
- public static final String SERVICE_ID = Constants.SERVICE_ID;
-
- /**
- * A service's objectClass. The type of the value for this event property is
- * <code>String[]</code>.
- */
- public static final String SERVICE_OBJECTCLASS = "service.objectClass";
-
- /**
- * A service's persistent identity. The type of the value for this event
- * property is <code>String</code>.
- */
- public static final String SERVICE_PID = Constants.SERVICE_PID;
-
- /**
- * The time when the event occurred, as reported by
- * <code>System.currentTimeMillis()</code>. The type of the value for this
- * event property is <code>Long</code>.
- */
- public static final String TIMESTAMP = "timestamp";
-
- /**
- * This constant was released with an incorrectly spelled name. It has been
- * replaced by {@link #EXCEPTION_CLASS}
- *
- * @deprecated As of 1.1, replaced by EXCEPTION_CLASS
- */
- public static final String EXECPTION_CLASS = "exception.class";
-}
\ No newline at end of file
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/event/EventHandler.java b/org.osgi.compendium/src/main/java/org/osgi/service/event/EventHandler.java
deleted file mode 100644
index d25782f..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/event/EventHandler.java
+++ /dev/null
@@ -1,69 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2005, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.osgi.service.event;
-
-/**
- * Listener for Events.
- *
- * <p>
- * <code>EventHandler</code> objects are registered with the Framework service
- * registry and are notified with an <code>Event</code> object when an event
- * is sent or posted.
- * <p>
- * <code>EventHandler</code> objects can inspect the received
- * <code>Event</code> object to determine its topic and properties.
- *
- * <p>
- * <code>EventHandler</code> objects must be registered with a service
- * property {@link EventConstants#EVENT_TOPIC} whose value is the list of topics
- * in which the event handler is interested.
- * <p>
- * For example:
- *
- * <pre>
- * String[] topics = new String[] {"com/isv/*"};
- * Hashtable ht = new Hashtable();
- * ht.put(EventConstants.EVENT_TOPIC, topics);
- * context.registerService(EventHandler.class.getName(), this, ht);
- * </pre>
- *
- * Event Handler services can also be registered with an
- * {@link EventConstants#EVENT_FILTER} service property to further filter the
- * events. If the syntax of this filter is invalid, then the Event Handler must
- * be ignored by the Event Admin service. The Event Admin service should log a
- * warning.
- * <p>
- * Security Considerations. Bundles wishing to monitor <code>Event</code>
- * objects will require <code>ServicePermission[EventHandler,REGISTER]</code>
- * to register an <code>EventHandler</code> service. The bundle must also have
- * <code>TopicPermission[topic,SUBSCRIBE]</code> for the topic specified in
- * the event in order to receive the event.
- *
- * @see Event
- *
- * @ThreadSafe
- * @version $Revision: 5673 $
- */
-public interface EventHandler {
- /**
- * Called by the {@link EventAdmin} service to notify the listener of an
- * event.
- *
- * @param event The event that occurred.
- */
- void handleEvent(Event event);
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/event/TopicPermission.java b/org.osgi.compendium/src/main/java/org/osgi/service/event/TopicPermission.java
deleted file mode 100644
index ae0d190..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/event/TopicPermission.java
+++ /dev/null
@@ -1,529 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2005, 2009). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.osgi.service.event;
-
-import java.io.IOException;
-import java.security.Permission;
-import java.security.PermissionCollection;
-import java.util.Enumeration;
-import java.util.Hashtable;
-
-/**
- * A bundle's authority to publish or subscribe to event on a topic.
- *
- * <p>
- * A topic is a slash-separated string that defines a topic.
- * <p>
- * For example:
- *
- * <pre>
- * org / osgi / service / foo / FooEvent / ACTION
- * </pre>
- *
- * <p>
- * <code>TopicPermission</code> has two actions: <code>publish</code> and
- * <code>subscribe</code>.
- *
- * @ThreadSafe
- * @version $Revision: 6381 $
- */
-public final class TopicPermission extends Permission {
- static final long serialVersionUID = -5855563886961618300L;
- /**
- * The action string <code>publish</code>.
- */
- public final static String PUBLISH = "publish";
- /**
- * The action string <code>subscribe</code>.
- */
- public final static String SUBSCRIBE = "subscribe";
- private final static int ACTION_PUBLISH = 0x00000001;
- private final static int ACTION_SUBSCRIBE = 0x00000002;
- private final static int ACTION_ALL = ACTION_PUBLISH
- | ACTION_SUBSCRIBE;
- private final static int ACTION_NONE = 0;
- /**
- * The actions mask.
- */
- private transient int action_mask;
-
- /**
- * prefix if the name is wildcarded.
- */
- private transient volatile String prefix;
-
- /**
- * The actions in canonical form.
- *
- * @serial
- */
- private volatile String actions = null;
-
- /**
- * Defines the authority to publich and/or subscribe to a topic within the
- * EventAdmin service.
- * <p>
- * The name is specified as a slash-separated string. Wildcards may be used.
- * For example:
- *
- * <pre>
- * org/osgi/service/fooFooEvent/ACTION
- * com/isv/*
- * *
- * </pre>
- *
- * <p>
- * A bundle that needs to publish events on a topic must have the
- * appropriate <code>TopicPermission</code> for that topic; similarly, a
- * bundle that needs to subscribe to events on a topic must have the
- * appropriate <code>TopicPermssion</code> for that topic.
- * <p>
- *
- * @param name Topic name.
- * @param actions <code>publish</code>,<code>subscribe</code> (canonical
- * order).
- */
- public TopicPermission(String name, String actions) {
- this(name, parseActions(actions));
- }
-
- /**
- * Package private constructor used by TopicPermissionCollection.
- *
- * @param name class name
- * @param mask action mask
- */
- TopicPermission(String name, int mask) {
- super(name);
- setTransients(mask);
- }
-
- /**
- * Called by constructors and when deserialized.
- *
- * @param name topic name
- * @param mask action mask
- */
- private synchronized void setTransients(final int mask) {
- final String name = getName();
- if ((name == null) || name.length() == 0) {
- throw new IllegalArgumentException("invalid name");
- }
-
- if ((mask == ACTION_NONE) || ((mask & ACTION_ALL) != mask)) {
- throw new IllegalArgumentException("invalid action string");
- }
- action_mask = mask;
-
- if (name.equals("*")) {
- prefix = "";
- }
- else {
- if (name.endsWith("/*")) {
- prefix = name.substring(0, name.length() - 1);
- }
- else {
- prefix = null;
- }
- }
- }
-
- /**
- * Returns the current action mask.
- * <p>
- * Used by the TopicPermissionCollection class.
- *
- * @return Current action mask.
- */
- synchronized int getActionsMask() {
- return action_mask;
- }
-
- /**
- * Parse action string into action mask.
- *
- * @param actions Action string.
- * @return action mask.
- */
- private static int parseActions(final String actions) {
- boolean seencomma = false;
- int mask = ACTION_NONE;
- if (actions == null) {
- return mask;
- }
- char[] a = actions.toCharArray();
- int i = a.length - 1;
- if (i < 0)
- return mask;
- while (i != -1) {
- char c;
- // skip whitespace
- while ((i != -1)
- && ((c = a[i]) == ' ' || c == '\r' || c == '\n'
- || c == '\f' || c == '\t'))
- i--;
- // check for the known strings
- int matchlen;
- if (i >= 8 && (a[i - 8] == 's' || a[i - 8] == 'S')
- && (a[i - 7] == 'u' || a[i - 7] == 'U')
- && (a[i - 6] == 'b' || a[i - 6] == 'B')
- && (a[i - 5] == 's' || a[i - 5] == 'S')
- && (a[i - 4] == 'c' || a[i - 4] == 'C')
- && (a[i - 3] == 'r' || a[i - 3] == 'R')
- && (a[i - 2] == 'i' || a[i - 2] == 'I')
- && (a[i - 1] == 'b' || a[i - 1] == 'B')
- && (a[i] == 'e' || a[i] == 'E')) {
- matchlen = 9;
- mask |= ACTION_SUBSCRIBE;
- }
- else
- if (i >= 6 && (a[i - 6] == 'p' || a[i - 6] == 'P')
- && (a[i - 5] == 'u' || a[i - 5] == 'U')
- && (a[i - 4] == 'b' || a[i - 4] == 'B')
- && (a[i - 3] == 'l' || a[i - 3] == 'L')
- && (a[i - 2] == 'i' || a[i - 2] == 'I')
- && (a[i - 1] == 's' || a[i - 1] == 'S')
- && (a[i] == 'h' || a[i] == 'H')) {
- matchlen = 7;
- mask |= ACTION_PUBLISH;
- }
- else {
- // parse error
- throw new IllegalArgumentException("invalid permission: "
- + actions);
- }
- // make sure we didn't just match the tail of a word
- // like "ackbarfpublish". Also, skip to the comma.
- seencomma = false;
- while (i >= matchlen && !seencomma) {
- switch (a[i - matchlen]) {
- case ',' :
- seencomma = true;
- /* FALLTHROUGH */
- case ' ' :
- case '\r' :
- case '\n' :
- case '\f' :
- case '\t' :
- break;
- default :
- throw new IllegalArgumentException(
- "invalid permission: " + actions);
- }
- i--;
- }
- // point i at the location of the comma minus one (or -1).
- i -= matchlen;
- }
- if (seencomma) {
- throw new IllegalArgumentException("invalid permission: " + actions);
- }
- return mask;
- }
-
- /**
- * Determines if the specified permission is implied by this object.
- *
- * <p>
- * This method checks that the topic name of the target is implied by the
- * topic name of this object. The list of <code>TopicPermission</code>
- * actions must either match or allow for the list of the target object to
- * imply the target <code>TopicPermission</code> action.
- *
- * <pre>
- * x/y/*,"publish" -> x/y/z,"publish" is true
- * *,"subscribe" -> x/y,"subscribe" is true
- * *,"publish" -> x/y,"subscribe" is false
- * x/y,"publish" -> x/y/z,"publish" is false
- * </pre>
- *
- * @param p The target permission to interrogate.
- * @return <code>true</code> if the specified <code>TopicPermission</code>
- * action is implied by this object; <code>false</code> otherwise.
- */
- public boolean implies(Permission p) {
- if (p instanceof TopicPermission) {
- TopicPermission requested = (TopicPermission) p;
- int requestedMask = requested.getActionsMask();
- if ((getActionsMask() & requestedMask) == requestedMask) {
- String requestedName = requested.getName();
- String pre = prefix;
- if (pre != null) {
- return requestedName.startsWith(pre);
- }
-
- return requestedName.equals(getName());
- }
- }
- return false;
- }
-
- /**
- * Returns the canonical string representation of the
- * <code>TopicPermission</code> actions.
- *
- * <p>
- * Always returns present <code>TopicPermission</code> actions in the
- * following order: <code>publish</code>,<code>subscribe</code>.
- *
- * @return Canonical string representation of the
- * <code>TopicPermission</code> actions.
- */
- public String getActions() {
- String result = actions;
- if (result == null) {
- StringBuffer sb = new StringBuffer();
- boolean comma = false;
- int mask = getActionsMask();
- if ((mask & ACTION_PUBLISH) == ACTION_PUBLISH) {
- sb.append(PUBLISH);
- comma = true;
- }
- if ((mask & ACTION_SUBSCRIBE) == ACTION_SUBSCRIBE) {
- if (comma)
- sb.append(',');
- sb.append(SUBSCRIBE);
- }
- actions = result = sb.toString();
- }
- return result;
- }
-
- /**
- * Returns a new <code>PermissionCollection</code> object suitable for
- * storing <code>TopicPermission</code> objects.
- *
- * @return A new <code>PermissionCollection</code> object.
- */
- public PermissionCollection newPermissionCollection() {
- return new TopicPermissionCollection();
- }
-
- /**
- * Determines the equality of two <code>TopicPermission</code> objects.
- *
- * This method checks that specified <code>TopicPermission</code> has the
- * same topic name and actions as this <code>TopicPermission</code> object.
- *
- * @param obj The object to test for equality with this
- * <code>TopicPermission</code> object.
- * @return <code>true</code> if <code>obj</code> is a
- * <code>TopicPermission</code>, and has the same topic name and
- * actions as this <code>TopicPermission</code> object;
- * <code>false</code> otherwise.
- */
- public boolean equals(Object obj) {
- if (obj == this) {
- return true;
- }
- if (!(obj instanceof TopicPermission)) {
- return false;
- }
- TopicPermission tp = (TopicPermission) obj;
- return (getActionsMask() == tp.getActionsMask())
- && getName().equals(tp.getName());
- }
-
- /**
- * Returns the hash code value for this object.
- *
- * @return A hash code value for this object.
- */
- public int hashCode() {
- int h = 31 * 17 + getName().hashCode();
- h = 31 * h + getActions().hashCode();
- return h;
- }
-
- /**
- * WriteObject is called to save the state of this permission object to a
- * stream. The actions are serialized, and the superclass takes care of the
- * name.
- */
- private synchronized void writeObject(java.io.ObjectOutputStream s)
- throws IOException {
- // Write out the actions. The superclass takes care of the name
- // call getActions to make sure actions field is initialized
- if (actions == null)
- getActions();
- s.defaultWriteObject();
- }
-
- /**
- * readObject is called to restore the state of this permission from a
- * stream.
- */
- private synchronized void readObject(java.io.ObjectInputStream s)
- throws IOException, ClassNotFoundException {
- // Read in the action, then initialize the rest
- s.defaultReadObject();
- setTransients(parseActions(actions));
- }
-}
-
-/**
- * Stores a set of <code>TopicPermission</code> permissions.
- *
- * @see java.security.Permission
- * @see java.security.Permissions
- * @see java.security.PermissionCollection
- */
-final class TopicPermissionCollection extends PermissionCollection {
- static final long serialVersionUID = -614647783533924048L;
- /**
- * Table of permissions.
- *
- * @serial
- * @GuardedBy this
- */
- private final Hashtable permissions;
- /**
- * Boolean saying if "*" is in the collection.
- *
- * @serial
- * @GuardedBy this
- */
- private boolean all_allowed;
-
- /**
- * Create an empty TopicPermissions object.
- *
- */
- public TopicPermissionCollection() {
- permissions = new Hashtable();
- all_allowed = false;
- }
-
- /**
- * Adds a permission to the <code>TopicPermission</code> objects. The key
- * for the hash is the name.
- *
- * @param permission The <code>TopicPermission</code> object to add.
- *
- * @throws IllegalArgumentException If the permission is not a
- * <code>TopicPermission</code> instance.
- *
- * @throws SecurityException If this <code>TopicPermissionCollection</code>
- * object has been marked read-only.
- */
- public void add(final Permission permission) {
- if (!(permission instanceof TopicPermission)) {
- throw new IllegalArgumentException("invalid permission: "
- + permission);
- }
- if (isReadOnly()) {
- throw new SecurityException("attempt to add a Permission to a "
- + "readonly PermissionCollection");
- }
- final TopicPermission tp = (TopicPermission) permission;
- final String name = tp.getName();
- final int newMask = tp.getActionsMask();
-
- synchronized (this) {
- final TopicPermission existing = (TopicPermission) permissions
- .get(name);
- if (existing != null) {
- final int oldMask = existing.getActionsMask();
- if (oldMask != newMask) {
- permissions.put(name, new TopicPermission(name, oldMask
- | newMask));
- }
- }
- else {
- permissions.put(name, tp);
- }
- if (!all_allowed) {
- if (name.equals("*"))
- all_allowed = true;
- }
- }
- }
-
- /**
- * Determines if the specified permissions implies the permissions expressed
- * in <code>permission</code>.
- *
- * @param permission The Permission object to compare with this
- * <code>TopicPermission</code> object.
- *
- * @return <code>true</code> if <code>permission</code> is a proper subset
- * of a permission in the set; <code>false</code> otherwise.
- */
- public boolean implies(final Permission permission) {
- if (!(permission instanceof TopicPermission)) {
- return false;
- }
- final TopicPermission requested = (TopicPermission) permission;
- String name = requested.getName();
- final int desired = requested.getActionsMask();
- int effective = 0;
-
- TopicPermission x;
- // short circuit if the "*" Permission was added
- synchronized (this) {
- if (all_allowed) {
- x = (TopicPermission) permissions.get("*");
- if (x != null) {
- effective |= x.getActionsMask();
- if ((effective & desired) == desired) {
- return true;
- }
- }
- }
- x = (TopicPermission) permissions.get(name);
- }
- // strategy:
- // Check for full match first. Then work our way up the
- // name looking for matches on a/b/*
- if (x != null) {
- // we have a direct hit!
- effective |= x.getActionsMask();
- if ((effective & desired) == desired) {
- return true;
- }
- }
- // work our way up the tree...
- int last;
- int offset = name.length() - 1;
- while ((last = name.lastIndexOf("/", offset)) != -1) {
- name = name.substring(0, last + 1) + "*";
- synchronized (this) {
- x = (TopicPermission) permissions.get(name);
- }
- if (x != null) {
- effective |= x.getActionsMask();
- if ((effective & desired) == desired) {
- return true;
- }
- }
- offset = last - 1;
- }
- // we don't have to check for "*" as it was already checked
- // at the top (all_allowed), so we just return false
- return false;
- }
-
- /**
- * Returns an enumeration of all <code>TopicPermission</code> objects in the
- * container.
- *
- * @return Enumeration of all <code>TopicPermission</code> objects.
- */
- public Enumeration elements() {
- return permissions.elements();
- }
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/http/HttpContext.java b/org.osgi.compendium/src/main/java/org/osgi/service/http/HttpContext.java
deleted file mode 100644
index e39cd17..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/http/HttpContext.java
+++ /dev/null
@@ -1,166 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2000, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.service.http;
-
-import java.io.IOException;
-import java.net.URL;
-
-import javax.servlet.http.HttpServletRequest;
-import javax.servlet.http.HttpServletResponse;
-
-/**
- * This interface defines methods that the Http Service may call to get
- * information about a registration.
- *
- * <p>
- * Servlets and resources may be registered with an <code>HttpContext</code>
- * object; if no <code>HttpContext</code> object is specified, a default
- * <code>HttpContext</code> object is used. Servlets that are registered using the
- * same <code>HttpContext</code> object will share the same
- * <code>ServletContext</code> object.
- *
- * <p>
- * This interface is implemented by users of the <code>HttpService</code>.
- *
- * @version $Revision: 5673 $
- */
-public interface HttpContext {
- /**
- * <code>HttpServletRequest</code> attribute specifying the name of the
- * authenticated user. The value of the attribute can be retrieved by
- * <code>HttpServletRequest.getRemoteUser</code>. This attribute name is
- * <code>org.osgi.service.http.authentication.remote.user</code>.
- *
- * @since 1.1
- */
- public static final String REMOTE_USER = "org.osgi.service.http.authentication.remote.user";
- /**
- * <code>HttpServletRequest</code> attribute specifying the scheme used in
- * authentication. The value of the attribute can be retrieved by
- * <code>HttpServletRequest.getAuthType</code>. This attribute name is
- * <code>org.osgi.service.http.authentication.type</code>.
- *
- * @since 1.1
- */
- public static final String AUTHENTICATION_TYPE = "org.osgi.service.http.authentication.type";
- /**
- * <code>HttpServletRequest</code> attribute specifying the
- * <code>Authorization</code> object obtained from the
- * <code>org.osgi.service.useradmin.UserAdmin</code> service. The value of the
- * attribute can be retrieved by
- * <code>HttpServletRequest.getAttribute(HttpContext.AUTHORIZATION)</code>.
- * This attribute name is <code>org.osgi.service.useradmin.authorization</code>.
- *
- * @since 1.1
- */
- public static final String AUTHORIZATION = "org.osgi.service.useradmin.authorization";
-
- /**
- * Handles security for the specified request.
- *
- * <p>
- * The Http Service calls this method prior to servicing the specified
- * request. This method controls whether the request is processed in the
- * normal manner or an error is returned.
- *
- * <p>
- * If the request requires authentication and the Authorization header in
- * the request is missing or not acceptable, then this method should set the
- * WWW-Authenticate header in the response object, set the status in the
- * response object to Unauthorized(401) and return <code>false</code>. See
- * also RFC 2617: <i>HTTP Authentication: Basic and Digest Access
- * Authentication </i> (available at http://www.ietf.org/rfc/rfc2617.txt).
- *
- * <p>
- * If the request requires a secure connection and the <code>getScheme</code>
- * method in the request does not return 'https' or some other acceptable
- * secure protocol, then this method should set the status in the response
- * object to Forbidden(403) and return <code>false</code>.
- *
- * <p>
- * When this method returns <code>false</code>, the Http Service will send
- * the response back to the client, thereby completing the request. When
- * this method returns <code>true</code>, the Http Service will proceed with
- * servicing the request.
- *
- * <p>
- * If the specified request has been authenticated, this method must set the
- * {@link #AUTHENTICATION_TYPE} request attribute to the type of
- * authentication used, and the {@link #REMOTE_USER} request attribute to
- * the remote user (request attributes are set using the
- * <code>setAttribute</code> method on the request). If this method does not
- * perform any authentication, it must not set these attributes.
- *
- * <p>
- * If the authenticated user is also authorized to access certain resources,
- * this method must set the {@link #AUTHORIZATION} request attribute to the
- * <code>Authorization</code> object obtained from the
- * <code>org.osgi.service.useradmin.UserAdmin</code> service.
- *
- * <p>
- * The servlet responsible for servicing the specified request determines
- * the authentication type and remote user by calling the
- * <code>getAuthType</code> and <code>getRemoteUser</code> methods,
- * respectively, on the request.
- *
- * @param request the HTTP request
- * @param response the HTTP response
- * @return <code>true</code> if the request should be serviced, <code>false</code>
- * if the request should not be serviced and Http Service will send
- * the response back to the client.
- * @throws java.io.IOException may be thrown by this method. If this
- * occurs, the Http Service will terminate the request and close
- * the socket.
- */
- public boolean handleSecurity(HttpServletRequest request,
- HttpServletResponse response) throws IOException;
-
- /**
- * Maps a resource name to a URL.
- *
- * <p>
- * Called by the Http Service to map a resource name to a URL. For servlet
- * registrations, Http Service will call this method to support the
- * <code>ServletContext</code> methods <code>getResource</code> and
- * <code>getResourceAsStream</code>. For resource registrations, Http Service
- * will call this method to locate the named resource. The context can
- * control from where resources come. For example, the resource can be
- * mapped to a file in the bundle's persistent storage area via
- * <code>bundleContext.getDataFile(name).toURL()</code> or to a resource in
- * the context's bundle via <code>getClass().getResource(name)</code>
- *
- * @param name the name of the requested resource
- * @return URL that Http Service can use to read the resource or
- * <code>null</code> if the resource does not exist.
- */
- public URL getResource(String name);
-
- /**
- * Maps a name to a MIME type.
- *
- * Called by the Http Service to determine the MIME type for the name. For
- * servlet registrations, the Http Service will call this method to support
- * the <code>ServletContext</code> method <code>getMimeType</code>. For
- * resource registrations, the Http Service will call this method to
- * determine the MIME type for the Content-Type header in the response.
- *
- * @param name determine the MIME type for this name.
- * @return MIME type (e.g. text/html) of the name or <code>null</code> to
- * indicate that the Http Service should determine the MIME type
- * itself.
- */
- public String getMimeType(String name);
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/http/HttpService.java b/org.osgi.compendium/src/main/java/org/osgi/service/http/HttpService.java
deleted file mode 100644
index c578a93..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/http/HttpService.java
+++ /dev/null
@@ -1,177 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2000, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.service.http;
-
-import java.util.Dictionary;
-
-import javax.servlet.Servlet;
-import javax.servlet.ServletException;
-
-/**
- * The Http Service allows other bundles in the OSGi environment to dynamically
- * register resources and servlets into the URI namespace of Http Service. A
- * bundle may later unregister its resources or servlets.
- *
- * @version $Revision: 5673 $
- * @see HttpContext
- */
-public interface HttpService {
- /**
- * Registers a servlet into the URI namespace.
- *
- * <p>
- * The alias is the name in the URI namespace of the Http Service at which
- * the registration will be mapped.
- *
- * <p>
- * An alias must begin with slash ('/') and must not end with slash ('/'),
- * with the exception that an alias of the form "/" is used to
- * denote the root alias. See the specification text for details on how HTTP
- * requests are mapped to servlet and resource registrations.
- *
- * <p>
- * The Http Service will call the servlet's <code>init</code> method before
- * returning.
- *
- * <pre>
- * httpService.registerServlet("/myservlet", servlet, initparams, context);
- * </pre>
- *
- * <p>
- * Servlets registered with the same <code>HttpContext</code> object will
- * share the same <code>ServletContext</code>. The Http Service will call the
- * <code>context</code> argument to support the <code>ServletContext</code>
- * methods <code>getResource</code>,<code>getResourceAsStream</code> and
- * <code>getMimeType</code>, and to handle security for requests. If the
- * <code>context</code> argument is <code>null</code>, a default
- * <code>HttpContext</code> object is used (see
- * {@link #createDefaultHttpContext}).
- *
- * @param alias name in the URI namespace at which the servlet is registered
- * @param servlet the servlet object to register
- * @param initparams initialization arguments for the servlet or
- * <code>null</code> if there are none. This argument is used by the
- * servlet's <code>ServletConfig</code> object.
- * @param context the <code>HttpContext</code> object for the registered
- * servlet, or <code>null</code> if a default <code>HttpContext</code> is
- * to be created and used.
- * @throws NamespaceException if the registration fails because the alias
- * is already in use.
- * @throws javax.servlet.ServletException if the servlet's <code>init</code>
- * method throws an exception, or the given servlet object has
- * already been registered at a different alias.
- * @throws java.lang.IllegalArgumentException if any of the arguments are
- * invalid
- */
- public void registerServlet(String alias, Servlet servlet,
- Dictionary initparams, HttpContext context)
- throws ServletException, NamespaceException;
-
- /**
- * Registers resources into the URI namespace.
- *
- * <p>
- * The alias is the name in the URI namespace of the Http Service at which
- * the registration will be mapped. An alias must begin with slash ('/') and
- * must not end with slash ('/'), with the exception that an alias of the
- * form "/" is used to denote the root alias. The name parameter
- * must also not end with slash ('/') with the exception that a name of the
- * form "/" is used to denote the root of the bundle. See the
- * specification text for details on how HTTP requests are mapped to servlet
- * and resource registrations.
- * <p>
- * For example, suppose the resource name /tmp is registered to the alias
- * /files. A request for /files/foo.txt will map to the resource name
- * /tmp/foo.txt.
- *
- * <pre>
- * httpservice.registerResources("/files", "/tmp", context);
- * </pre>
- *
- * The Http Service will call the <code>HttpContext</code> argument to map
- * resource names to URLs and MIME types and to handle security for
- * requests. If the <code>HttpContext</code> argument is <code>null</code>,
- * a default <code>HttpContext</code> is used (see
- * {@link #createDefaultHttpContext}).
- *
- * @param alias name in the URI namespace at which the resources are
- * registered
- * @param name the base name of the resources that will be registered
- * @param context the <code>HttpContext</code> object for the registered
- * resources, or <code>null</code> if a default
- * <code>HttpContext</code> is to be created and used.
- * @throws NamespaceException if the registration fails because the alias is
- * already in use.
- * @throws java.lang.IllegalArgumentException if any of the parameters are
- * invalid
- */
- public void registerResources(String alias, String name,
- HttpContext context) throws NamespaceException;
-
- /**
- * Unregisters a previous registration done by <code>registerServlet</code> or
- * <code>registerResources</code> methods.
- *
- * <p>
- * After this call, the registered alias in the URI name-space will no
- * longer be available. If the registration was for a servlet, the Http
- * Service must call the <code>destroy</code> method of the servlet before
- * returning.
- * <p>
- * If the bundle which performed the registration is stopped or otherwise
- * "unget"s the Http Service without calling {@link #unregister} then Http
- * Service must automatically unregister the registration. However, if the
- * registration was for a servlet, the <code>destroy</code> method of the
- * servlet will not be called in this case since the bundle may be stopped.
- * {@link #unregister} must be explicitly called to cause the
- * <code>destroy</code> method of the servlet to be called. This can be done
- * in the <code>BundleActivator.stop</code> method of the
- * bundle registering the servlet.
- *
- * @param alias name in the URI name-space of the registration to unregister
- * @throws java.lang.IllegalArgumentException if there is no registration
- * for the alias or the calling bundle was not the bundle which
- * registered the alias.
- */
- public void unregister(String alias);
-
- /**
- * Creates a default <code>HttpContext</code> for registering servlets or
- * resources with the HttpService, a new <code>HttpContext</code> object is
- * created each time this method is called.
- *
- * <p>
- * The behavior of the methods on the default <code>HttpContext</code> is
- * defined as follows:
- * <ul>
- * <li><code>getMimeType</code>- Does not define any customized MIME types
- * for the Content-Type header in the response, and always returns
- * <code>null</code>.
- * <li><code>handleSecurity</code>- Performs implementation-defined
- * authentication on the request.
- * <li><code>getResource</code>- Assumes the named resource is in the
- * context bundle; this method calls the context bundle's
- * <code>Bundle.getResource</code> method, and returns the appropriate URL to
- * access the resource. On a Java runtime environment that supports
- * permissions, the Http Service needs to be granted
- * <code>org.osgi.framework.AdminPermission[*,RESOURCE]</code>.
- * </ul>
- *
- * @return a default <code>HttpContext</code> object.
- * @since 1.1
- */
- public HttpContext createDefaultHttpContext();
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/http/NamespaceException.java b/org.osgi.compendium/src/main/java/org/osgi/service/http/NamespaceException.java
deleted file mode 100644
index dce2ba8..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/http/NamespaceException.java
+++ /dev/null
@@ -1,88 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2000, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.service.http;
-
-/**
- * A NamespaceException is thrown to indicate an error with the caller's request
- * to register a servlet or resources into the URI namespace of the Http
- * Service. This exception indicates that the requested alias already is in use.
- *
- * @version $Revision: 6083 $
- */
-public class NamespaceException extends Exception {
- static final long serialVersionUID = 7235606031147877747L;
-
- /**
- * Construct a <code>NamespaceException</code> object with a detail message.
- *
- * @param message the detail message
- */
- public NamespaceException(String message) {
- super(message);
- }
-
- /**
- * Construct a <code>NamespaceException</code> object with a detail message
- * and a nested exception.
- *
- * @param message The detail message.
- * @param cause The nested exception.
- */
- public NamespaceException(String message, Throwable cause) {
- super(message, cause);
- }
-
- /**
- * Returns the nested exception.
- *
- * <p>
- * This method predates the general purpose exception chaining mechanism.
- * The <code>getCause()</code> method is now the preferred means of
- * obtaining this information.
- *
- * @return The result of calling <code>getCause()</code>.
- */
- public Throwable getException() {
- return getCause();
- }
-
- /**
- * Returns the cause of this exception or <code>null</code> if no cause was
- * set.
- *
- * @return The cause of this exception or <code>null</code> if no cause was
- * set.
- * @since 1.2
- */
- public Throwable getCause() {
- return super.getCause();
- }
-
- /**
- * Initializes the cause of this exception to the specified value.
- *
- * @param cause The cause of this exception.
- * @return This exception.
- * @throws IllegalArgumentException If the specified cause is this
- * exception.
- * @throws IllegalStateException If the cause of this exception has already
- * been set.
- * @since 1.2
- */
- public Throwable initCause(Throwable cause) {
- return super.initCause(cause);
- }
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/io/ConnectionFactory.java b/org.osgi.compendium/src/main/java/org/osgi/service/io/ConnectionFactory.java
deleted file mode 100644
index 3939512..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/io/ConnectionFactory.java
+++ /dev/null
@@ -1,60 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2002, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.service.io;
-
-import java.io.IOException;
-
-import javax.microedition.io.Connection;
-
-/**
- * A Connection Factory service is called by the implementation of the Connector
- * Service to create <code>javax.microedition.io.Connection</code> objects which
- * implement the scheme named by <code>IO_SCHEME</code>.
- *
- * When a <code>ConnectorService.open</code> method is called, the implementation
- * of the Connector Service will examine the specified name for a scheme. The
- * Connector Service will then look for a Connection Factory service which is
- * registered with the service property <code>IO_SCHEME</code> which matches the
- * scheme. The {@link #createConnection} method of the selected Connection
- * Factory will then be called to create the actual <code>Connection</code>
- * object.
- *
- * @version $Revision: 7337 $
- */
-public interface ConnectionFactory {
- /**
- * Service property containing the scheme(s) for which this Connection
- * Factory can create <code>Connection</code> objects. This property is of
- * type <code>String[]</code>.
- */
- public static final String IO_SCHEME = "io.scheme";
-
- /**
- * Create a new <code>Connection</code> object for the specified URI.
- *
- * @param name The full URI passed to the <code>ConnectorService.open</code>
- * method
- * @param mode The mode parameter passed to the
- * <code>ConnectorService.open</code> method
- * @param timeouts The timeouts parameter passed to the
- * <code>ConnectorService.open</code> method
- * @return A new <code>javax.microedition.io.Connection</code> object.
- * @throws IOException If a <code>javax.microedition.io.Connection</code>
- * object can not not be created.
- */
- public Connection createConnection(String name, int mode, boolean timeouts)
- throws IOException;
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/io/ConnectorService.java b/org.osgi.compendium/src/main/java/org/osgi/service/io/ConnectorService.java
deleted file mode 100644
index dbfc04a..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/io/ConnectorService.java
+++ /dev/null
@@ -1,165 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2002, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.service.io;
-
-import java.io.*;
-
-import javax.microedition.io.Connection;
-import javax.microedition.io.Connector;
-
-/**
- * The Connector Service should be called to create and open
- * <code>javax.microedition.io.Connection</code> objects.
- *
- * When an <code>open*</code> method is called, the implementation of the
- * Connector Service will examine the specified name for a scheme. The Connector
- * Service will then look for a Connection Factory service which is registered
- * with the service property <code>IO_SCHEME</code> which matches the scheme. The
- * <code>createConnection</code> method of the selected Connection Factory will
- * then be called to create the actual <code>Connection</code> object.
- *
- * <p>
- * If more than one Connection Factory service is registered for a particular
- * scheme, the service with the highest ranking (as specified in its
- * <code>service.ranking</code> property) is called. If there is a tie in ranking,
- * the service with the lowest service ID (as specified in its
- * <code>service.id</code> property), that is the service that was registered
- * first, is called. This is the same algorithm used by
- * <code>BundleContext.getServiceReference</code>.
- *
- * @version $Revision: 5673 $
- */
-public interface ConnectorService {
- /**
- * Read access mode.
- *
- * @see "javax.microedition.io.Connector.READ"
- */
- public static final int READ = Connector.READ;
- /**
- * Write access mode.
- *
- * @see "javax.microedition.io.Connector.WRITE"
- */
- public static final int WRITE = Connector.WRITE;
- /**
- * Read/Write access mode.
- *
- * @see "javax.microedition.io.Connector.READ_WRITE"
- */
- public static final int READ_WRITE = Connector.READ_WRITE;
-
- /**
- * Create and open a <code>Connection</code> object for the specified name.
- *
- * @param name The URI for the connection.
- * @return A new <code>javax.microedition.io.Connection</code> object.
- * @throws IllegalArgumentException If a parameter is invalid.
- * @throws javax.microedition.io.ConnectionNotFoundException If the
- * connection cannot be found.
- * @throws IOException If some other kind of I/O error occurs.
- * @see "javax.microedition.io.Connector.open(String name)"
- */
- public Connection open(String name) throws IOException;
-
- /**
- * Create and open a <code>Connection</code> object for the specified name and
- * access mode.
- *
- * @param name The URI for the connection.
- * @param mode The access mode.
- * @return A new <code>javax.microedition.io.Connection</code> object.
- * @throws IllegalArgumentException If a parameter is invalid.
- * @throws javax.microedition.io.ConnectionNotFoundException If the
- * connection cannot be found.
- * @throws IOException If some other kind of I/O error occurs.
- * @see "javax.microedition.io.Connector.open(String name, int mode)"
- */
- public Connection open(String name, int mode) throws IOException;
-
- /**
- * Create and open a <code>Connection</code> object for the specified name,
- * access mode and timeouts.
- *
- * @param name The URI for the connection.
- * @param mode The access mode.
- * @param timeouts A flag to indicate that the caller wants timeout
- * exceptions.
- * @return A new <code>javax.microedition.io.Connection</code> object.
- * @throws IllegalArgumentException If a parameter is invalid.
- * @throws javax.microedition.io.ConnectionNotFoundException If the
- * connection cannot be found.
- * @throws IOException If some other kind of I/O error occurs.
- * @see "<code>javax.microedition.io.Connector.open</code>"
- */
- public Connection open(String name, int mode, boolean timeouts)
- throws IOException;
-
- /**
- * Create and open an <code>InputStream</code> object for the specified name.
- *
- * @param name The URI for the connection.
- * @return An <code>InputStream</code> object.
- * @throws IllegalArgumentException If a parameter is invalid.
- * @throws javax.microedition.io.ConnectionNotFoundException If the
- * connection cannot be found.
- * @throws IOException If some other kind of I/O error occurs.
- * @see "javax.microedition.io.Connector.openInputStream(String name)"
- */
- public InputStream openInputStream(String name) throws IOException;
-
- /**
- * Create and open a <code>DataInputStream</code> object for the specified
- * name.
- *
- * @param name The URI for the connection.
- * @return A <code>DataInputStream</code> object.
- * @throws IllegalArgumentException If a parameter is invalid.
- * @throws javax.microedition.io.ConnectionNotFoundException If the
- * connection cannot be found.
- * @throws IOException If some other kind of I/O error occurs.
- * @see "javax.microedition.io.Connector.openDataInputStream(String name)"
- */
- public DataInputStream openDataInputStream(String name) throws IOException;
-
- /**
- * Create and open an <code>OutputStream</code> object for the specified name.
- *
- * @param name The URI for the connection.
- * @return An <code>OutputStream</code> object.
- * @throws IllegalArgumentException If a parameter is invalid.
- * @throws javax.microedition.io.ConnectionNotFoundException If the
- * connection cannot be found.
- * @throws IOException If some other kind of I/O error occurs.
- * @see "javax.microedition.io.Connector.openOutputStream(String name)"
- */
- public OutputStream openOutputStream(String name) throws IOException;
-
- /**
- * Create and open a <code>DataOutputStream</code> object for the specified
- * name.
- *
- * @param name The URI for the connection.
- * @return A <code>DataOutputStream</code> object.
- * @throws IllegalArgumentException If a parameter is invalid.
- * @throws javax.microedition.io.ConnectionNotFoundException If the
- * connection cannot be found.
- * @throws IOException If some other kind of I/O error occurs.
- * @see "javax.microedition.io.Connector.openDataOutputStream(String name)"
- */
- public DataOutputStream openDataOutputStream(String name)
- throws IOException;
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/log/LogEntry.java b/org.osgi.compendium/src/main/java/org/osgi/service/log/LogEntry.java
deleted file mode 100644
index 8130cf8..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/log/LogEntry.java
+++ /dev/null
@@ -1,108 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2000, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.service.log;
-
-import org.osgi.framework.Bundle;
-import org.osgi.framework.ServiceReference;
-
-/**
- * Provides methods to access the information contained in an individual Log
- * Service log entry.
- *
- * <p>
- * A <code>LogEntry</code> object may be acquired from the
- * <code>LogReaderService.getLog</code> method or by registering a
- * <code>LogListener</code> object.
- *
- * @ThreadSafe
- * @version $Revision: 5654 $
- * @see LogReaderService#getLog
- * @see LogListener
- */
-public interface LogEntry {
- /**
- * Returns the bundle that created this <code>LogEntry</code> object.
- *
- * @return The bundle that created this <code>LogEntry</code> object;
- * <code>null</code> if no bundle is associated with this
- * <code>LogEntry</code> object.
- */
- public Bundle getBundle();
-
- /**
- * Returns the <code>ServiceReference</code> object for the service associated
- * with this <code>LogEntry</code> object.
- *
- * @return <code>ServiceReference</code> object for the service associated
- * with this <code>LogEntry</code> object; <code>null</code> if no
- * <code>ServiceReference</code> object was provided.
- */
- public ServiceReference getServiceReference();
-
- /**
- * Returns the severity level of this <code>LogEntry</code> object.
- *
- * <p>
- * This is one of the severity levels defined by the <code>LogService</code>
- * interface.
- *
- * @return Severity level of this <code>LogEntry</code> object.
- *
- * @see LogService#LOG_ERROR
- * @see LogService#LOG_WARNING
- * @see LogService#LOG_INFO
- * @see LogService#LOG_DEBUG
- */
- public int getLevel();
-
- /**
- * Returns the human readable message associated with this <code>LogEntry</code>
- * object.
- *
- * @return <code>String</code> containing the message associated with this
- * <code>LogEntry</code> object.
- */
- public String getMessage();
-
- /**
- * Returns the exception object associated with this <code>LogEntry</code>
- * object.
- *
- * <p>
- * In some implementations, the returned exception may not be the original
- * exception. To avoid references to a bundle defined exception class, thus
- * preventing an uninstalled bundle from being garbage collected, the Log
- * Service may return an exception object of an implementation defined
- * Throwable subclass. The returned object will attempt to provide as much
- * information as possible from the original exception object such as the
- * message and stack trace.
- *
- * @return <code>Throwable</code> object of the exception associated with this
- * <code>LogEntry</code>;<code>null</code> if no exception is
- * associated with this <code>LogEntry</code> object.
- */
- public Throwable getException();
-
- /**
- * Returns the value of <code>currentTimeMillis()</code> at the time this
- * <code>LogEntry</code> object was created.
- *
- * @return The system time in milliseconds when this <code>LogEntry</code>
- * object was created.
- * @see "System.currentTimeMillis()"
- */
- public long getTime();
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/log/LogListener.java b/org.osgi.compendium/src/main/java/org/osgi/service/log/LogListener.java
deleted file mode 100644
index de29a56..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/log/LogListener.java
+++ /dev/null
@@ -1,50 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2000, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.service.log;
-
-import java.util.EventListener;
-
-/**
- * Subscribes to <code>LogEntry</code> objects from the <code>LogReaderService</code>.
- *
- * <p>
- * A <code>LogListener</code> object may be registered with the Log Reader Service
- * using the <code>LogReaderService.addLogListener</code> method. After the
- * listener is registered, the <code>logged</code> method will be called for each
- * <code>LogEntry</code> object created. The <code>LogListener</code> object may be
- * unregistered by calling the <code>LogReaderService.removeLogListener</code>
- * method.
- *
- * @ThreadSafe
- * @version $Revision: 5654 $
- * @see LogReaderService
- * @see LogEntry
- * @see LogReaderService#addLogListener(LogListener)
- * @see LogReaderService#removeLogListener(LogListener)
- */
-public interface LogListener extends EventListener {
- /**
- * Listener method called for each LogEntry object created.
- *
- * <p>
- * As with all event listeners, this method should return to its caller as
- * soon as possible.
- *
- * @param entry A <code>LogEntry</code> object containing log information.
- * @see LogEntry
- */
- public void logged(LogEntry entry);
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/log/LogReaderService.java b/org.osgi.compendium/src/main/java/org/osgi/service/log/LogReaderService.java
deleted file mode 100644
index b3753e4..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/log/LogReaderService.java
+++ /dev/null
@@ -1,97 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2000, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.service.log;
-
-import java.util.Enumeration;
-
-/**
- * Provides methods to retrieve <code>LogEntry</code> objects from the log.
- * <p>
- * There are two ways to retrieve <code>LogEntry</code> objects:
- * <ul>
- * <li>The primary way to retrieve <code>LogEntry</code> objects is to register a
- * <code>LogListener</code> object whose <code>LogListener.logged</code> method will
- * be called for each entry added to the log.
- * <li>To retrieve past <code>LogEntry</code> objects, the <code>getLog</code>
- * method can be called which will return an <code>Enumeration</code> of all
- * <code>LogEntry</code> objects in the log.
- *
- * @ThreadSafe
- * @version $Revision: 5654 $
- * @see LogEntry
- * @see LogListener
- * @see LogListener#logged(LogEntry)
- */
-public interface LogReaderService {
- /**
- * Subscribes to <code>LogEntry</code> objects.
- *
- * <p>
- * This method registers a <code>LogListener</code> object with the Log Reader
- * Service. The <code>LogListener.logged(LogEntry)</code> method will be
- * called for each <code>LogEntry</code> object placed into the log.
- *
- * <p>
- * When a bundle which registers a <code>LogListener</code> object is stopped
- * or otherwise releases the Log Reader Service, the Log Reader Service must
- * remove all of the bundle's listeners.
- *
- * <p>
- * If this Log Reader Service's list of listeners already contains a
- * listener <code>l</code> such that <code>(l==listener)</code>, this method
- * does nothing.
- *
- * @param listener A <code>LogListener</code> object to register; the
- * <code>LogListener</code> object is used to receive <code>LogEntry</code>
- * objects.
- * @see LogListener
- * @see LogEntry
- * @see LogListener#logged(LogEntry)
- */
- public void addLogListener(LogListener listener);
-
- /**
- * Unsubscribes to <code>LogEntry</code> objects.
- *
- * <p>
- * This method unregisters a <code>LogListener</code> object from the Log
- * Reader Service.
- *
- * <p>
- * If <code>listener</code> is not contained in this Log Reader Service's list
- * of listeners, this method does nothing.
- *
- * @param listener A <code>LogListener</code> object to unregister.
- * @see LogListener
- */
- public void removeLogListener(LogListener listener);
-
- /**
- * Returns an <code>Enumeration</code> of all <code>LogEntry</code> objects in
- * the log.
- *
- * <p>
- * Each element of the enumeration is a <code>LogEntry</code> object, ordered
- * with the most recent entry first. Whether the enumeration is of all
- * <code>LogEntry</code> objects since the Log Service was started or some
- * recent past is implementation-specific. Also implementation-specific is
- * whether informational and debug <code>LogEntry</code> objects are included
- * in the enumeration.
- * @return An <code>Enumeration</code> of all <code>LogEntry</code> objects in
- * the log.
- */
- public Enumeration getLog();
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/log/LogService.java b/org.osgi.compendium/src/main/java/org/osgi/service/log/LogService.java
deleted file mode 100644
index 1889355..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/log/LogService.java
+++ /dev/null
@@ -1,155 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2000, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.service.log;
-
-import org.osgi.framework.ServiceReference;
-
-/**
- * Provides methods for bundles to write messages to the log.
- *
- * <p>
- * <code>LogService</code> methods are provided to log messages; optionally with a
- * <code>ServiceReference</code> object or an exception.
- *
- * <p>
- * Bundles must log messages in the OSGi environment with a severity level
- * according to the following hierarchy:
- * <ol>
- * <li>{@link #LOG_ERROR}
- * <li>{@link #LOG_WARNING}
- * <li>{@link #LOG_INFO}
- * <li>{@link #LOG_DEBUG}
- * </ol>
- *
- * @ThreadSafe
- * @version $Revision: 5654 $
- */
-public interface LogService {
- /**
- * An error message (Value 1).
- *
- * <p>
- * This log entry indicates the bundle or service may not be functional.
- */
- public static final int LOG_ERROR = 1;
- /**
- * A warning message (Value 2).
- *
- * <p>
- * This log entry indicates a bundle or service is still functioning but may
- * experience problems in the future because of the warning condition.
- */
- public static final int LOG_WARNING = 2;
- /**
- * An informational message (Value 3).
- *
- * <p>
- * This log entry may be the result of any change in the bundle or service
- * and does not indicate a problem.
- */
- public static final int LOG_INFO = 3;
- /**
- * A debugging message (Value 4).
- *
- * <p>
- * This log entry is used for problem determination and may be irrelevant to
- * anyone but the bundle developer.
- */
- public static final int LOG_DEBUG = 4;
-
- /**
- * Logs a message.
- *
- * <p>
- * The <code>ServiceReference</code> field and the <code>Throwable</code> field
- * of the <code>LogEntry</code> object will be set to <code>null</code>.
- *
- * @param level The severity of the message. This should be one of the
- * defined log levels but may be any integer that is interpreted in a
- * user defined way.
- * @param message Human readable string describing the condition or
- * <code>null</code>.
- * @see #LOG_ERROR
- * @see #LOG_WARNING
- * @see #LOG_INFO
- * @see #LOG_DEBUG
- */
- public void log(int level, String message);
-
- /**
- * Logs a message with an exception.
- *
- * <p>
- * The <code>ServiceReference</code> field of the <code>LogEntry</code> object
- * will be set to <code>null</code>.
- *
- * @param level The severity of the message. This should be one of the
- * defined log levels but may be any integer that is interpreted in a
- * user defined way.
- * @param message The human readable string describing the condition or
- * <code>null</code>.
- * @param exception The exception that reflects the condition or
- * <code>null</code>.
- * @see #LOG_ERROR
- * @see #LOG_WARNING
- * @see #LOG_INFO
- * @see #LOG_DEBUG
- */
- public void log(int level, String message, Throwable exception);
-
- /**
- * Logs a message associated with a specific <code>ServiceReference</code>
- * object.
- *
- * <p>
- * The <code>Throwable</code> field of the <code>LogEntry</code> will be set to
- * <code>null</code>.
- *
- * @param sr The <code>ServiceReference</code> object of the service that this
- * message is associated with or <code>null</code>.
- * @param level The severity of the message. This should be one of the
- * defined log levels but may be any integer that is interpreted in a
- * user defined way.
- * @param message Human readable string describing the condition or
- * <code>null</code>.
- * @see #LOG_ERROR
- * @see #LOG_WARNING
- * @see #LOG_INFO
- * @see #LOG_DEBUG
- */
- public void log(ServiceReference sr, int level, String message);
-
- /**
- * Logs a message with an exception associated and a
- * <code>ServiceReference</code> object.
- *
- * @param sr The <code>ServiceReference</code> object of the service that this
- * message is associated with.
- * @param level The severity of the message. This should be one of the
- * defined log levels but may be any integer that is interpreted in a
- * user defined way.
- * @param message Human readable string describing the condition or
- * <code>null</code>.
- * @param exception The exception that reflects the condition or
- * <code>null</code>.
- * @see #LOG_ERROR
- * @see #LOG_WARNING
- * @see #LOG_INFO
- * @see #LOG_DEBUG
- */
- public void log(ServiceReference sr, int level, String message,
- Throwable exception);
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/metatype/AttributeDefinition.java b/org.osgi.compendium/src/main/java/org/osgi/service/metatype/AttributeDefinition.java
deleted file mode 100644
index d427163..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/metatype/AttributeDefinition.java
+++ /dev/null
@@ -1,277 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2001, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.service.metatype;
-
-/**
- * An interface to describe an attribute.
- *
- * <p>
- * An <code>AttributeDefinition</code> object defines a description of the data
- * type of a property/attribute.
- *
- * @version $Revision: 5673 $
- */
-public interface AttributeDefinition {
- /**
- * The <code>STRING</code> (1) type.
- *
- * <p>
- * Attributes of this type should be stored as <code>String</code>,
- * <code>Vector</code> with <code>String</code> or <code>String[]</code> objects,
- * depending on the <code>getCardinality()</code> value.
- */
- public static final int STRING = 1;
- /**
- * The <code>LONG</code> (2) type.
- *
- * Attributes of this type should be stored as <code>Long</code>,
- * <code>Vector</code> with <code>Long</code> or <code>long[]</code> objects,
- * depending on the <code>getCardinality()</code> value.
- */
- public static final int LONG = 2;
- /**
- * The <code>INTEGER</code> (3) type.
- *
- * Attributes of this type should be stored as <code>Integer</code>,
- * <code>Vector</code> with <code>Integer</code> or <code>int[]</code> objects,
- * depending on the <code>getCardinality()</code> value.
- */
- public static final int INTEGER = 3;
- /**
- * The <code>SHORT</code> (4) type.
- *
- * Attributes of this type should be stored as <code>Short</code>,
- * <code>Vector</code> with <code>Short</code> or <code>short[]</code> objects,
- * depending on the <code>getCardinality()</code> value.
- */
- public static final int SHORT = 4;
- /**
- * The <code>CHARACTER</code> (5) type.
- *
- * Attributes of this type should be stored as <code>Character</code>,
- * <code>Vector</code> with <code>Character</code> or <code>char[]</code> objects,
- * depending on the <code>getCardinality()</code> value.
- */
- public static final int CHARACTER = 5;
- /**
- * The <code>BYTE</code> (6) type.
- *
- * Attributes of this type should be stored as <code>Byte</code>,
- * <code>Vector</code> with <code>Byte</code> or <code>byte[]</code> objects,
- * depending on the <code>getCardinality()</code> value.
- */
- public static final int BYTE = 6;
- /**
- * The <code>DOUBLE</code> (7) type.
- *
- * Attributes of this type should be stored as <code>Double</code>,
- * <code>Vector</code> with <code>Double</code> or <code>double[]</code> objects,
- * depending on the <code>getCardinality()</code> value.
- */
- public static final int DOUBLE = 7;
- /**
- * The <code>FLOAT</code> (8) type.
- *
- * Attributes of this type should be stored as <code>Float</code>,
- * <code>Vector</code> with <code>Float</code> or <code>float[]</code> objects,
- * depending on the <code>getCardinality()</code> value.
- */
- public static final int FLOAT = 8;
- /**
- * The <code>BIGINTEGER</code> (9) type.
- *
- * Attributes of this type should be stored as <code>BigInteger</code>,
- * <code>Vector</code> with <code>BigInteger</code> or <code>BigInteger[]</code>
- * objects, depending on the <code>getCardinality()</code> value.
- *
- * @deprecated As of 1.1.
- */
- public static final int BIGINTEGER = 9;
- /**
- * The <code>BIGDECIMAL</code> (10) type.
- *
- * Attributes of this type should be stored as <code>BigDecimal</code>,
- * <code>Vector</code> with <code>BigDecimal</code> or <code>BigDecimal[]</code>
- * objects depending on <code>getCardinality()</code>.
- *
- * @deprecated As of 1.1.
- */
- public static final int BIGDECIMAL = 10;
- /**
- * The <code>BOOLEAN</code> (11) type.
- *
- * Attributes of this type should be stored as <code>Boolean</code>,
- * <code>Vector</code> with <code>Boolean</code> or <code>boolean[]</code> objects
- * depending on <code>getCardinality()</code>.
- */
- public static final int BOOLEAN = 11;
-
- /**
- * Get the name of the attribute. This name may be localized.
- *
- * @return The localized name of the definition.
- */
- public String getName();
-
- /**
- * Unique identity for this attribute.
- *
- * Attributes share a global namespace in the registry. E.g. an attribute
- * <code>cn</code> or <code>commonName</code> must always be a <code>String</code>
- * and the semantics are always a name of some object. They share this
- * aspect with LDAP/X.500 attributes. In these standards the OSI Object
- * Identifier (OID) is used to uniquely identify an attribute. If such an
- * OID exists, (which can be requested at several standard organisations and
- * many companies already have a node in the tree) it can be returned here.
- * Otherwise, a unique id should be returned which can be a Java class name
- * (reverse domain name) or generated with a GUID algorithm. Note that all
- * LDAP defined attributes already have an OID. It is strongly advised to
- * define the attributes from existing LDAP schemes which will give the OID.
- * Many such schemes exist ranging from postal addresses to DHCP parameters.
- *
- * @return The id or oid
- */
- public String getID();
-
- /**
- * Return a description of this attribute.
- *
- * The description may be localized and must describe the semantics of this
- * type and any constraints.
- *
- * @return The localized description of the definition.
- */
- public String getDescription();
-
- /**
- * Return the cardinality of this attribute.
- *
- * The OSGi environment handles multi valued attributes in arrays ([]) or in
- * <code>Vector</code> objects. The return value is defined as follows:
- *
- * <pre>
- *
- * x = Integer.MIN_VALUE no limit, but use Vector
- * x < 0 -x = max occurrences, store in Vector
- * x > 0 x = max occurrences, store in array []
- * x = Integer.MAX_VALUE no limit, but use array []
- * x = 0 1 occurrence required
- *
- * </pre>
- *
- * @return The cardinality of this attribute.
- */
- public int getCardinality();
-
- /**
- * Return the type for this attribute.
- *
- * <p>
- * Defined in the following constants which map to the appropriate Java
- * type. <code>STRING</code>,<code>LONG</code>,<code>INTEGER</code>,
- * <code>CHAR</code>,<code>BYTE</code>,<code>DOUBLE</code>,<code>FLOAT</code>,
- * <code>BOOLEAN</code>.
- *
- * @return The type for this attribute.
- */
- public int getType();
-
- /**
- * Return a list of option values that this attribute can take.
- *
- * <p>
- * If the function returns <code>null</code>, there are no option values
- * available.
- *
- * <p>
- * Each value must be acceptable to validate() (return "") and must be a
- * <code>String</code> object that can be converted to the data type defined
- * by getType() for this attribute.
- *
- * <p>
- * This list must be in the same sequence as <code>getOptionLabels()</code>.
- * I.e. for each index i in <code>getOptionValues</code>, i in
- * <code>getOptionLabels()</code> should be the label.
- *
- * <p>
- * For example, if an attribute can have the value male, female, unknown,
- * this list can return
- * <code>new String[] { "male", "female", "unknown" }</code>.
- *
- * @return A list values
- */
- public String[] getOptionValues();
-
- /**
- * Return a list of labels of option values.
- *
- * <p>
- * The purpose of this method is to allow menus with localized labels. It is
- * associated with <code>getOptionValues</code>. The labels returned here are
- * ordered in the same way as the values in that method.
- *
- * <p>
- * If the function returns <code>null</code>, there are no option labels
- * available.
- * <p>
- * This list must be in the same sequence as the <code>getOptionValues()</code>
- * method. I.e. for each index i in <code>getOptionLabels</code>, i in
- * <code>getOptionValues()</code> should be the associated value.
- *
- * <p>
- * For example, if an attribute can have the value male, female, unknown,
- * this list can return (for dutch)
- * <code>new String[] { "Man", "Vrouw", "Onbekend" }</code>.
- *
- * @return A list values
- */
- public String[] getOptionLabels();
-
- /**
- * Validate an attribute in <code>String</code> form.
- *
- * An attribute might be further constrained in value. This method will
- * attempt to validate the attribute according to these constraints. It can
- * return three different values:
- *
- * <pre>
- * null No validation present
- * "" No problems detected
- * "..." A localized description of why the value is wrong
- * </pre>
- *
- * @param value The value before turning it into the basic data type
- * @return <code>null</code>, "", or another string
- */
- public String validate(String value);
-
- /**
- * Return a default for this attribute.
- *
- * The object must be of the appropriate type as defined by the cardinality
- * and <code>getType()</code>. The return type is a list of <code>String</code>
- * objects that can be converted to the appropriate type. The cardinality of
- * the return array must follow the absolute cardinality of this type. E.g.
- * if the cardinality = 0, the array must contain 1 element. If the
- * cardinality is 1, it must contain 0 or 1 elements. If it is -5, it must
- * contain from 0 to max 5 elements. Note that the special case of a 0
- * cardinality, meaning a single value, does not allow arrays or vectors of
- * 0 elements.
- *
- * @return Return a default value or <code>null</code> if no default exists.
- */
- public String[] getDefaultValue();
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/metatype/MetaTypeInformation.java b/org.osgi.compendium/src/main/java/org/osgi/service/metatype/MetaTypeInformation.java
deleted file mode 100644
index 8b336dc..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/metatype/MetaTypeInformation.java
+++ /dev/null
@@ -1,50 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2005, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.service.metatype;
-
-import org.osgi.framework.Bundle;
-
-/**
- * A MetaType Information object is created by the MetaTypeService to return
- * meta type information for a specific bundle.
- *
- * @version $Revision: 5673 $
- * @since 1.1
- */
-public interface MetaTypeInformation extends MetaTypeProvider {
- /**
- * Return the PIDs (for ManagedServices) for which ObjectClassDefinition
- * information is available.
- *
- * @return Array of PIDs.
- */
- public String[] getPids();
-
- /**
- * Return the Factory PIDs (for ManagedServiceFactories) for which
- * ObjectClassDefinition information is available.
- *
- * @return Array of Factory PIDs.
- */
- public String[] getFactoryPids();
-
- /**
- * Return the bundle for which this object provides meta type information.
- *
- * @return Bundle for which this object provides meta type information.
- */
- public Bundle getBundle();
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/metatype/MetaTypeProvider.java b/org.osgi.compendium/src/main/java/org/osgi/service/metatype/MetaTypeProvider.java
deleted file mode 100644
index b2385b2..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/metatype/MetaTypeProvider.java
+++ /dev/null
@@ -1,55 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2001, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.service.metatype;
-
-/**
- * Provides access to metatypes.
- *
- * @version $Revision: 5673 $
- */
-public interface MetaTypeProvider {
- /**
- * Returns an object class definition for the specified id localized to the
- * specified locale.
- *
- * <p>
- * The locale parameter must be a name that consists of <code>language</code>[
- * "_" <code>country</code>[ "_" <code>variation</code>] ] as is customary in
- * the <code>Locale</code> class. This <code>Locale</code> class is not used
- * because certain profiles do not contain it.
- *
- * @param id The ID of the requested object class. This can be a pid or
- * factory pid returned by getPids or getFactoryPids.
- * @param locale The locale of the definition or <code>null</code> for default
- * locale.
- * @return A <code>ObjectClassDefinition</code> object.
- * @throws IllegalArgumentException If the id or locale arguments are not
- * valid
- */
- public ObjectClassDefinition getObjectClassDefinition(String id, String locale);
-
- /**
- * Return a list of available locales.
- *
- * The results must be names that consists of language [ _ country [ _
- * variation ]] as is customary in the <code>Locale</code> class.
- *
- * @return An array of locale strings or <code>null</code> if there is no
- * locale specific localization can be found.
- *
- */
- public String[] getLocales();
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/metatype/MetaTypeService.java b/org.osgi.compendium/src/main/java/org/osgi/service/metatype/MetaTypeService.java
deleted file mode 100644
index d8f77a3..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/metatype/MetaTypeService.java
+++ /dev/null
@@ -1,51 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2005, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.service.metatype;
-
-import org.osgi.framework.Bundle;
-
-/**
- * The MetaType Service can be used to obtain meta type information for a
- * bundle. The MetaType Service will examine the specified bundle for meta type
- * documents to create the returned <code>MetaTypeInformation</code> object.
- *
- * <p>
- * If the specified bundle does not contain any meta type documents, then a
- * <code>MetaTypeInformation</code> object will be returned that wrappers any
- * <code>ManagedService</code> or <code>ManagedServiceFactory</code>
- * services registered by the specified bundle that implement
- * <code>MetaTypeProvider</code>. Thus the MetaType Service can be used to
- * retrieve meta type information for bundles which contain a meta type
- * documents or which provide their own <code>MetaTypeProvider</code> objects.
- *
- * @version $Revision: 5673 $
- * @since 1.1
- */
-public interface MetaTypeService {
- /**
- * Return the MetaType information for the specified bundle.
- *
- * @param bundle The bundle for which meta type information is requested.
- * @return A MetaTypeInformation object for the specified bundle.
- */
- public MetaTypeInformation getMetaTypeInformation(Bundle bundle);
-
- /**
- * Location of meta type documents. The MetaType Service will process each
- * entry in the meta type documents directory.
- */
- public final static String METATYPE_DOCUMENTS_LOCATION = "OSGI-INF/metatype";
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/metatype/ObjectClassDefinition.java b/org.osgi.compendium/src/main/java/org/osgi/service/metatype/ObjectClassDefinition.java
deleted file mode 100644
index 5c6687e..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/metatype/ObjectClassDefinition.java
+++ /dev/null
@@ -1,119 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2001, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.service.metatype;
-
-import java.io.IOException;
-import java.io.InputStream;
-
-/**
- * Description for the data type information of an objectclass.
- *
- * @version $Revision: 5673 $
- */
-public interface ObjectClassDefinition {
- /**
- * Argument for <code>getAttributeDefinitions(int)</code>.
- * <p>
- * <code>REQUIRED</code> indicates that only the required definitions are
- * returned. The value is 1.
- */
- public static final int REQUIRED = 1;
- /**
- * Argument for <code>getAttributeDefinitions(int)</code>.
- * <p>
- * <code>OPTIONAL</code> indicates that only the optional definitions are
- * returned. The value is 2.
- */
- public static final int OPTIONAL = 2;
- /**
- * Argument for <code>getAttributeDefinitions(int)</code>.
- * <p>
- * <code>ALL</code> indicates that all the definitions are returned. The value
- * is -1.
- */
- public static final int ALL = 0xFFFFFFFF;
-
- /**
- * Return the name of this object class.
- *
- * The name may be localized.
- *
- * @return The name of this object class.
- */
- public String getName();
-
- /**
- * Return the id of this object class.
- *
- * <p>
- * <code>ObjectDefintion</code> objects share a global namespace in the
- * registry. They share this aspect with LDAP/X.500 attributes. In these
- * standards the OSI Object Identifier (OID) is used to uniquely identify
- * object classes. If such an OID exists, (which can be requested at several
- * standard organisations and many companies already have a node in the
- * tree) it can be returned here. Otherwise, a unique id should be returned
- * which can be a java class name (reverse domain name) or generated with a
- * GUID algorithm. Note that all LDAP defined object classes already have an
- * OID associated. It is strongly advised to define the object classes from
- * existing LDAP schemes which will give the OID for free. Many such schemes
- * exist ranging from postal addresses to DHCP parameters.
- *
- * @return The id of this object class.
- */
- public String getID();
-
- /**
- * Return a description of this object class.
- *
- * The description may be localized.
- *
- * @return The description of this object class.
- */
- public String getDescription();
-
- /**
- * Return the attribute definitions for this object class.
- *
- * <p>
- * Return a set of attributes. The filter parameter can distinguish between
- * <code>ALL</code>,<code>REQUIRED</code> or the <code>OPTIONAL</code>
- * attributes.
- *
- * @param filter <code>ALL</code>,<code>REQUIRED</code>,<code>OPTIONAL</code>
- * @return An array of attribute definitions or <code>null</code> if no
- * attributes are selected
- */
- public AttributeDefinition[] getAttributeDefinitions(int filter);
-
- /**
- * Return an <code>InputStream</code> object that can be used to create an
- * icon from.
- *
- * <p>
- * Indicate the size and return an <code>InputStream</code> object containing
- * an icon. The returned icon maybe larger or smaller than the indicated
- * size.
- *
- * <p>
- * The icon may depend on the localization.
- *
- * @param size Requested size of an icon, e.g. a 16x16 pixels icon then size =
- * 16
- * @return An InputStream representing an icon or <code>null</code>
- * @throws IOException If the <code>InputStream</code> cannot be returned.
- */
- public InputStream getIcon(int size) throws IOException;
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/monitor/MonitorAdmin.java b/org.osgi.compendium/src/main/java/org/osgi/service/monitor/MonitorAdmin.java
deleted file mode 100644
index 7551803..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/monitor/MonitorAdmin.java
+++ /dev/null
@@ -1,359 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2004, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.osgi.service.monitor;
-
-/**
- * The <code>MonitorAdmin</code> service is a singleton service that handles
- * <code>StatusVariable</code> query requests and measurement job control
- * requests.
- * <p>
- * Note that an alternative but not recommended way of obtaining
- * <code>StatusVariable</code>s is that applications having the required
- * <code>ServicePermissions</code> can query the list of
- * <code>Monitorable</code> services from the service registry and then query
- * the list of <code>StatusVariable</code> names from the
- * <code>Monitorable</code> services. This way all services which publish
- * <code>StatusVariable</code>s will be returned regardless of whether they do
- * or do not hold the necessary <code>MonitorPermission</code> for publishing
- * <code>StatusVariable</code>s. By using the <code>MonitorAdmin</code> to
- * obtain the <code>StatusVariable</code>s it is guaranteed that only those
- * <code>Monitorable</code> services will be accessed who are authorized to
- * publish <code>StatusVariable</code>s. It is the responsibility of the
- * <code>MonitorAdmin</code> implementation to check the required permissions
- * and show only those variables which pass this check.
- * <p>
- * The events posted by <code>MonitorAdmin</code> contain the following
- * properties:
- * <ul>
- * <li><code>mon.monitorable.pid</code>: The identifier of the
- * <code>Monitorable</code>
- * <li><code>mon.statusvariable.name</code>: The identifier of the
- * <code>StatusVariable</code> within the given <code>Monitorable</code>
- * <li><code>mon.statusvariable.value</code>: The value of the
- * <code>StatusVariable</code>, represented as a <code>String</code>
- * <li><code>mon.listener.id</code>: The identifier of the initiator of the
- * monitoring job (only present if the event was generated due to a monitoring
- * job)
- * </ul>
- * <p>
- * Most of the methods require either a Monitorable ID or a Status Variable path
- * parameter, the latter in [Monitorable_ID]/[StatusVariable_ID] format. These
- * parameters must not be <code>null</code>, and the IDs they contain must
- * conform to their respective definitions in {@link Monitorable} and
- * {@link StatusVariable}. If any of the restrictions are violated, the method
- * must throw an <code>IllegalArgumentException</code>.
- *
- * @version $Revision: 7940 $
- */
-public interface MonitorAdmin {
-
- /**
- * Returns a <code>StatusVariable</code> addressed by its full path.
- * The entity which queries a <code>StatusVariable</code> needs to hold
- * <code>MonitorPermission</code> for the given target with the
- * <code>read</code> action present.
- *
- * @param path the full path of the <code>StatusVariable</code> in
- * [Monitorable_ID]/[StatusVariable_ID] format
- * @return the <code>StatusVariable</code> object
- * @throws java.lang.IllegalArgumentException if <code>path</code> is
- * <code>null</code> or otherwise invalid, or points to a
- * non-existing <code>StatusVariable</code>
- * @throws java.lang.SecurityException if the caller does not hold a
- * <code>MonitorPermission</code> for the
- * <code>StatusVariable</code> specified by <code>path</code>
- * with the <code>read</code> action present
- */
- public StatusVariable getStatusVariable(String path)
- throws IllegalArgumentException, SecurityException;
-
- /**
- * Returns the names of the <code>Monitorable</code> services that are
- * currently registered. The <code>Monitorable</code> instances are not
- * accessible through the <code>MonitorAdmin</code>, so that requests to
- * individual status variables can be filtered with respect to the
- * publishing rights of the <code>Monitorable</code> and the reading
- * rights of the caller.
- * <p>
- * The returned array contains the names in alphabetical order. It cannot be
- * <code>null</code>, an empty array is returned if no
- * <code>Monitorable</code> services are registered.
- *
- * @return the array of <code>Monitorable</code> names
- */
- public String[] getMonitorableNames();
-
- /**
- * Returns the <code>StatusVariable</code> objects published by a
- * <code>Monitorable</code> instance. The <code>StatusVariables</code>
- * will hold the values taken at the time of this method call. Only those
- * status variables are returned where the following two conditions are met:
- * <ul>
- * <li>the specified <code>Monitorable</code> holds a
- * <code>MonitorPermission</code> for the status variable with the
- * <code>publish</code> action present
- * <li>the caller holds a <code>MonitorPermission</code> for the status
- * variable with the <code>read</code> action present
- * </ul>
- * All other status variables are silently ignored, they are omitted from
- * the result.
- * <p>
- * The elements in the returned array are in no particular order. The return
- * value cannot be <code>null</code>, an empty array is returned if no
- * (authorized and readable) Status Variables are provided by the given
- * <code>Monitorable</code>.
- *
- * @param monitorableId the identifier of a <code>Monitorable</code>
- * instance
- * @return a list of <code>StatusVariable</code> objects published
- * by the specified <code>Monitorable</code>
- * @throws java.lang.IllegalArgumentException if <code>monitorableId</code>
- * is <code>null</code> or otherwise invalid, or points to a
- * non-existing <code>Monitorable</code>
- */
- public StatusVariable[] getStatusVariables(String monitorableId)
- throws IllegalArgumentException;
-
- /**
- * Returns the list of <code>StatusVariable</code> names published by a
- * <code>Monitorable</code> instance. Only those status variables are
- * listed where the following two conditions are met:
- * <ul>
- * <li>the specified <code>Monitorable</code> holds a
- * <code>MonitorPermission</code> for the status variable with the
- * <code>publish</code> action present
- * <li>the caller holds a <code>MonitorPermission</code> for
- * the status variable with the <code>read</code> action present
- * </ul>
- * All other status variables are silently ignored, their names are omitted
- * from the list.
- * <p>
- * The returned array does not contain duplicates, and the elements are in
- * alphabetical order. It cannot be <code>null</code>, an empty array is
- * returned if no (authorized and readable) Status Variables are provided
- * by the given <code>Monitorable</code>.
- *
- * @param monitorableId the identifier of a <code>Monitorable</code>
- * instance
- * @return a list of <code>StatusVariable</code> objects names
- * published by the specified <code>Monitorable</code>
- * @throws java.lang.IllegalArgumentException if <code>monitorableId</code>
- * is <code>null</code> or otherwise invalid, or points to a
- * non-existing <code>Monitorable</code>
- */
- public String[] getStatusVariableNames(String monitorableId)
- throws IllegalArgumentException;
-
- /**
- * Switches event sending on or off for the specified
- * <code>StatusVariable</code>s. When the <code>MonitorAdmin</code> is
- * notified about a <code>StatusVariable</code> being updated it sends an
- * event unless this feature is switched off. Note that events within a
- * monitoring job can not be switched off. The event sending state of the
- * <code>StatusVariables</code> must not be persistently stored. When a
- * <code>StatusVariable</code> is registered for the first time in a
- * framework session, its event sending state is set to ON by default.
- * <p>
- * Usage of the "*" wildcard is allowed in the path argument of this method
- * as a convenience feature. The wildcard can be used in either or both path
- * fragments, but only at the end of the fragments. The semantics of the
- * wildcard is that it stands for any matching <code>StatusVariable</code>
- * at the time of the method call, it does not affect the event sending
- * status of <code>StatusVariable</code>s which are not yet registered. As
- * an example, when the <code>switchEvents("MyMonitorable/*", false)</code>
- * method is executed, event sending from all <code>StatusVariables</code>
- * of the MyMonitorable service are switched off. However, if the
- * MyMonitorable service starts to publish a new <code>StatusVariable</code>
- * later, it's event sending status is on by default.
- *
- * @param path the identifier of the <code>StatusVariable</code>(s) in
- * [Monitorable_id]/[StatusVariable_id] format, possibly with the
- * "*" wildcard at the end of either path fragment
- * @param on <code>false</code> if event sending should be switched off,
- * <code>true</code> if it should be switched on for the given path
- * @throws java.lang.SecurityException if the caller does not hold
- * <code>MonitorPermission</code> with the
- * <code>switchevents</code> action or if there is any
- * <code>StatusVariable</code> in the <code>path</code> field for
- * which it is not allowed to switch event sending on or off as per
- * the target field of the permission
- * @throws java.lang.IllegalArgumentException if <code>path</code> is
- * <code>null</code> or otherwise invalid, or points to a
- * non-existing <code>StatusVariable</code>
- */
- public void switchEvents(String path, boolean on)
- throws IllegalArgumentException, SecurityException;
-
- /**
- * Issues a request to reset a given <code>StatusVariable</code>.
- * Depending on the semantics of the <code>StatusVariable</code> this call
- * may or may not succeed: it makes sense to reset a counter to its starting
- * value, but e.g. a <code>StatusVariable</code> of type String might not
- * have a meaningful default value. Note that for numeric
- * <code>StatusVariable</code>s the starting value may not necessarily be
- * 0. Resetting a <code>StatusVariable</code> triggers a monitor event if
- * the <code>StatusVariable</code> supports update notifications.
- * <p>
- * The entity that wants to reset the <code>StatusVariable</code> needs to
- * hold <code>MonitorPermission</code> with the <code>reset</code>
- * action present. The target field of the permission must match the
- * <code>StatusVariable</code> name to be reset.
- *
- * @param path the identifier of the <code>StatusVariable</code> in
- * [Monitorable_id]/[StatusVariable_id] format
- * @return <code>true</code> if the <code>Monitorable</code> could
- * successfully reset the given <code>StatusVariable</code>,
- * <code>false</code> otherwise
- * @throws java.lang.IllegalArgumentException if <code>path</code> is
- * <code>null</code> or otherwise invalid, or points to a
- * non-existing <code>StatusVariable</code>
- * @throws java.lang.SecurityException if the caller does not hold
- * <code>MonitorPermission</code> with the <code>reset</code>
- * action or if the specified <code>StatusVariable</code> is not
- * allowed to be reset as per the target field of the permission
- */
- public boolean resetStatusVariable(String path)
- throws IllegalArgumentException, SecurityException;
-
- /**
- * Returns a human readable description of the given
- * <code>StatusVariable</code>. The <code>null</code> value may be returned
- * if there is no description for the given <code>StatusVariable</code>.
- * <p>
- * The entity that queries a <code>StatusVariable</code> needs to hold
- * <code>MonitorPermission</code> for the given target with the
- * <code>read</code> action present.
- *
- * @param path the full path of the <code>StatusVariable</code> in
- * [Monitorable_ID]/[StatusVariable_ID] format
- * @return the human readable description of this
- * <code>StatusVariable</code> or <code>null</code> if it is not
- * set
- * @throws java.lang.IllegalArgumentException if <code>path</code> is
- * <code>null</code> or otherwise invalid, or points to a
- * non-existing <code>StatusVariable</code>
- * @throws java.lang.SecurityException if the caller does not hold a
- * <code>MonitorPermission</code> for the
- * <code>StatusVariable</code> specified by <code>path</code>
- * with the <code>read</code> action present
- */
- public String getDescription(String path)
- throws IllegalArgumentException, SecurityException;
-
- /**
- * Starts a time based <code>MonitoringJob</code> with the parameters
- * provided. Monitoring events will be sent according to the specified
- * schedule. All specified <code>StatusVariable</code>s must exist when the
- * job is started. The initiator string is used in the
- * <code>mon.listener.id</code> field of all events triggered by the job,
- * to allow filtering the events based on the initiator.
- * <p>
- * The <code>schedule</code> parameter specifies the time in seconds
- * between two measurements, it must be greater than 0. The first
- * measurement will be taken when the timer expires for the first time, not
- * when this method is called.
- * <p>
- * The <code>count</code> parameter defines the number of measurements to be
- * taken, and must either be a positive integer, or 0 if the measurement is
- * to run until explicitly stopped.
- * <p>
- * The entity which initiates a <code>MonitoringJob</code> needs to hold
- * <code>MonitorPermission</code> for all the specified target
- * <code>StatusVariable</code>s with the <code>startjob</code> action
- * present. If the permission's action string specifies a minimal sampling
- * interval then the <code>schedule</code> parameter should be at least as
- * great as the value in the action string.
- *
- * @param initiator the identifier of the entity that initiated the job
- * @param statusVariables the list of <code>StatusVariable</code>s to be
- * monitored, with each <code>StatusVariable</code> name given in
- * [Monitorable_PID]/[StatusVariable_ID] format
- * @param schedule the time in seconds between two measurements
- * @param count the number of measurements to be taken, or 0 for the
- * measurement to run until explicitly stopped
- * @return the successfully started job object, cannot be <code>null</code>
- * @throws java.lang.IllegalArgumentException if the list of
- * <code>StatusVariable</code> names contains an invalid or
- * non-existing <code>StatusVariable</code>; if
- * <code>initiator</code> is <code>null</code> or empty; or if the
- * <code>schedule</code> or <code>count</code> parameters are
- * invalid
- * @throws java.lang.SecurityException if the caller does not hold
- * <code>MonitorPermission</code> for all the specified
- * <code>StatusVariable</code>s, with the <code>startjob</code>
- * action present, or if the permission does not allow starting the
- * job with the given frequency
- */
- public MonitoringJob startScheduledJob(String initiator,
- String[] statusVariables, int schedule, int count)
- throws IllegalArgumentException, SecurityException;
-
- /**
- * Starts a change based <code>MonitoringJob</code> with the parameters
- * provided. Monitoring events will be sent when the
- * <code>StatusVariable</code>s of this job are updated. All specified
- * <code>StatusVariable</code>s must exist when the job is started, and
- * all must support update notifications. The initiator string is used in
- * the <code>mon.listener.id</code> field of all events triggered by the
- * job, to allow filtering the events based on the initiator.
- * <p>
- * The <code>count</code> parameter specifies the number of changes that
- * must happen to a <code>StatusVariable</code> before a new notification is
- * sent, this must be a positive integer.
- * <p>
- * The entity which initiates a <code>MonitoringJob</code> needs to hold
- * <code>MonitorPermission</code> for all the specified target
- * <code>StatusVariable</code>s with the <code>startjob</code> action
- * present.
- *
- * @param initiator the identifier of the entity that initiated the job
- * @param statusVariables the list of <code>StatusVariable</code>s to be
- * monitored, with each <code>StatusVariable</code> name given in
- * [Monitorable_PID]/[StatusVariable_ID] format
- * @param count the number of changes that must happen to a
- * <code>StatusVariable</code> before a new notification is sent
- * @return the successfully started job object, cannot be <code>null</code>
- * @throws java.lang.IllegalArgumentException if the list of
- * <code>StatusVariable</code> names contains an invalid or
- * non-existing <code>StatusVariable</code>, or one that does not
- * support notifications; if the <code>initiator</code> is
- * <code>null</code> or empty; or if <code>count</code> is invalid
- * @throws java.lang.SecurityException if the caller does not hold
- * <code>MonitorPermission</code> for all the specified
- * <code>StatusVariable</code>s, with the <code>startjob</code>
- * action present
- */
- public MonitoringJob startJob(String initiator, String[] statusVariables,
- int count) throws IllegalArgumentException, SecurityException;
-
- /**
- * Returns the list of currently running <code>MonitoringJob</code>s.
- * Jobs are only visible to callers that have the necessary permissions: to
- * receive a Monitoring Job in the returned list, the caller must hold all
- * permissions required for starting the job. This means that if the caller
- * does not have <code>MonitorPermission</code> with the proper
- * <code>startjob</code> action for all the Status Variables monitored by a
- * job, then that job will be silently omitted from the results.
- * <p>
- * The returned array cannot be <code>null</code>, an empty array is
- * returned if there are no running jobs visible to the caller at the time
- * of the call.
- *
- * @return the list of running jobs visible to the caller
- */
- public MonitoringJob[] getRunningJobs();
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/monitor/MonitorListener.java b/org.osgi.compendium/src/main/java/org/osgi/service/monitor/MonitorListener.java
deleted file mode 100644
index 694bcd7..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/monitor/MonitorListener.java
+++ /dev/null
@@ -1,42 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2004, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.osgi.service.monitor;
-
-/**
- * The <code>MonitorListener</code> is used by <code>Monitorable</code> services
- * to send notifications when a <code>StatusVariable</code> value is changed.
- * The <code>MonitorListener</code> should register itself as a service at the
- * OSGi Service Registry. This interface must (only) be implemented by the
- * Monitor Admin component.
- *
- * @version $Revision: 5673 $
- */
-public interface MonitorListener {
- /**
- * Callback for notification of a <code>StatusVariable</code> change.
- *
- * @param monitorableId the identifier of the <code>Monitorable</code>
- * instance reporting the change
- * @param statusVariable the <code>StatusVariable</code> that has changed
- * @throws java.lang.IllegalArgumentException if the specified monitorable
- * ID is invalid (<code>null</code>, empty, or contains illegal
- * characters) or points to a non-existing <code>Monitorable</code>,
- * or if <code>statusVariable</code> is <code>null</code>
- */
- public void updated(String monitorableId, StatusVariable statusVariable)
- throws IllegalArgumentException;
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/monitor/MonitorPermission.java b/org.osgi.compendium/src/main/java/org/osgi/service/monitor/MonitorPermission.java
deleted file mode 100644
index 8bb2fe0..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/monitor/MonitorPermission.java
+++ /dev/null
@@ -1,366 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2005, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.osgi.service.monitor;
-
-import java.io.UnsupportedEncodingException;
-import java.security.Permission;
-import java.util.StringTokenizer;
-
-/**
- * Indicates the callers authority to publish, read or reset
- * <code>StatusVariable</code>s, to switch event sending on or off or to start
- * monitoring jobs. The target of the permission is the identifier of the
- * <code>StatusVariable</code>, the action can be <code>read</code>,
- * <code>publish</code>, <code>reset</code>, <code>startjob</code>,
- * <code>switchevents</code>, or the combination of these separated by commas.
- * Action names are interpreted case-insensitively, but the canonical action
- * string returned by {@link #getActions} uses the forms defined by the action
- * constants.
- * <p>
- * If the wildcard <code>*</code> appears in the actions field, all legal
- * monitoring commands are allowed on the designated target(s) by the owner of
- * the permission.
- *
- * @version $Revision: 7941 $
- */
-public class MonitorPermission extends Permission {
-
- /**
- *
- */
- private static final long serialVersionUID = -9084425194463274314L;
-
- /**
- * Holders of <code>MonitorPermission</code> with the <code>read</code>
- * action present are allowed to read the value of the
- * <code>StatusVariable</code>s specified in the permission's target field.
- */
- public static final String READ = "read";
-
- /**
- * Holders of <code>MonitorPermission</code> with the <code>reset</code>
- * action present are allowed to reset the value of the
- * <code>StatusVariable</code>s specified in the permission's target field.
- */
- public static final String RESET = "reset";
-
- /**
- * Holders of <code>MonitorPermission</code> with the <code>publish</code>
- * action present are <code>Monitorable</code> services that are allowed
- * to publish the <code>StatusVariable</code>s specified in the
- * permission's target field. Note, that this permission cannot be enforced
- * when a <code>Monitorable</code> registers to the framework, because the
- * Service Registry does not know about this permission. Instead, any
- * <code>StatusVariable</code>s published by a <code>Monitorable</code>
- * without the corresponding <code>publish</code> permission are silently
- * ignored by <code>MonitorAdmin</code>, and are therefore invisible to the
- * users of the monitoring service.
- */
- public static final String PUBLISH = "publish";
-
- /**
- * Holders of <code>MonitorPermission</code> with the <code>startjob</code>
- * action present are allowed to initiate monitoring jobs involving the
- * <code>StatusVariable</code>s specified in the permission's target field.
- * <p>
- * A minimal sampling interval can be optionally defined in the following
- * form: <code>startjob:n</code>. This allows the holder of the permission
- * to initiate time based jobs with a measurement interval of at least
- * <code>n</code> seconds. If <code>n</code> is not specified or 0 then the
- * holder of this permission is allowed to start monitoring jobs specifying
- * any frequency.
- */
- public static final String STARTJOB = "startjob";
-
- /**
- * Holders of <code>MonitorPermission</code> with the
- * <code>switchevents</code> action present are allowed to switch event
- * sending on or off for the value of the <code>StatusVariable</code>s
- * specified in the permission's target field.
- */
- public static final String SWITCHEVENTS = "switchevents";
-
- private static final int READ_FLAG = 0x1;
- private static final int RESET_FLAG = 0x2;
- private static final int PUBLISH_FLAG = 0x4;
- private static final int STARTJOB_FLAG = 0x8;
- private static final int SWITCHEVENTS_FLAG = 0x10;
-
- private static final int ALL_FLAGS = READ_FLAG | RESET_FLAG |
- PUBLISH_FLAG | STARTJOB_FLAG | SWITCHEVENTS_FLAG;
-
- private String monId;
- private String varId;
- private boolean prefixMonId;
- private boolean prefixVarId;
- private int mask;
- private int minJobInterval;
-
- /**
- * Create a <code>MonitorPermission</code> object, specifying the target
- * and actions.
- * <p>
- * The <code>statusVariable</code> parameter is the target of the
- * permission, defining one or more status variable names to which the
- * specified actions apply. Multiple status variable names can be selected
- * by using the wildcard <code>*</code> in the target string. The wildcard
- * is allowed in both fragments, but only at the end of the fragments.
- * <p>
- * For example, the following targets are valid:
- * <code>com.mycomp.myapp/queue_length</code>,
- * <code>com.mycomp.myapp/*</code>, <code>com.mycomp.*/*</code>,
- * <code>*/*</code>, <code>*/queue_length</code>,
- * <code>*/queue*</code>.
- * <p>
- * The following targets are invalid:
- * <code>*.myapp/queue_length</code>, <code>com.*.myapp/*</code>,
- * <code>*</code>.
- * <p>
- * The <code>actions</code> parameter specifies the allowed action(s):
- * <code>read</code>, <code>publish</code>, <code>startjob</code>,
- * <code>reset</code>, <code>switchevents</code>, or the combination of
- * these separated by commas. String constants are defined in this class for
- * each valid action. Passing <code>"*"</code> as the action
- * string is equivalent to listing all actions.
- *
- * @param statusVariable the identifier of the <code>StatusVariable</code>
- * in [Monitorable_id]/[StatusVariable_id] format
- * @param actions the list of allowed actions separated by commas, or
- * <code>*</code> for all actions
- * @throws java.lang.IllegalArgumentException if either parameter is
- * <code>null</code>, or invalid with regard to the constraints
- * defined above and in the documentation of the used actions
- */
- public MonitorPermission(String statusVariable, String actions)
- throws IllegalArgumentException {
- super(statusVariable);
-
- if(statusVariable == null)
- throw new IllegalArgumentException(
- "Invalid StatusVariable path 'null'.");
-
- if(actions == null)
- throw new IllegalArgumentException(
- "Invalid actions string 'null'.");
-
- int sep = statusVariable.indexOf('/');
- int len = statusVariable.length();
-
- if (sep == -1)
- throw new IllegalArgumentException(
- "Invalid StatusVariable path: should contain '/' separator.");
- if (sep == 0 || sep == statusVariable.length() - 1)
- throw new IllegalArgumentException(
- "Invalid StatusVariable path: empty monitorable ID or StatusVariable name.");
-
- prefixMonId = statusVariable.charAt(sep - 1) == '*';
- prefixVarId = statusVariable.charAt(len - 1) == '*';
-
- monId = statusVariable.substring(0, prefixMonId ? sep - 1 : sep);
- varId = statusVariable.substring(sep + 1, prefixVarId ? len - 1 : len);
-
- checkId(monId, "Monitorable ID part of the target");
- checkId(varId, "Status Variable ID part of the target");
-
- minJobInterval = 0;
-
- if(actions.equals("*"))
- mask = ALL_FLAGS;
- else {
- mask = 0;
- StringTokenizer st = new StringTokenizer(actions, ",");
- while (st.hasMoreTokens()) {
- String action = st.nextToken().trim();
- if (action.equalsIgnoreCase(READ)) {
- addToMask(READ_FLAG, READ);
- } else if (action.equalsIgnoreCase(RESET)) {
- addToMask(RESET_FLAG, RESET);
- } else if (action.equalsIgnoreCase(PUBLISH)) {
- addToMask(PUBLISH_FLAG, PUBLISH);
- } else if (action.equalsIgnoreCase(SWITCHEVENTS)) {
- addToMask(SWITCHEVENTS_FLAG, SWITCHEVENTS);
- } else if (action.toLowerCase().startsWith(STARTJOB)) {
- minJobInterval = 0;
-
- int slen = STARTJOB.length();
- if (action.length() != slen) {
- if (action.charAt(slen) != ':')
- throw new IllegalArgumentException(
- "Invalid action '" + action + "'.");
-
- try {
- minJobInterval = Integer.parseInt(action
- .substring(slen + 1));
- } catch (NumberFormatException e) {
- throw new IllegalArgumentException(
- "Invalid parameter in startjob action '"
- + action + "'.");
- }
- }
- addToMask(STARTJOB_FLAG, STARTJOB);
- } else
- throw new IllegalArgumentException("Invalid action '" +
- action + "'");
- }
- }
- }
-
- private void addToMask(int action, String actionString) {
- if((mask & action) != 0)
- throw new IllegalArgumentException("Invalid action string: " +
- actionString + " appears multiple times.");
-
- mask |= action;
- }
-
- private void checkId(String id, String idName)
- throws IllegalArgumentException {
-
- byte[] nameBytes;
- try {
- nameBytes = id.getBytes("UTF-8");
- } catch (UnsupportedEncodingException e) {
- // never happens, "UTF-8" must always be supported
- throw new IllegalStateException(e.getMessage());
- }
- if(nameBytes.length > StatusVariable.MAX_ID_LENGTH)
- throw new IllegalArgumentException(idName + " is too long (over " +
- StatusVariable.MAX_ID_LENGTH + " bytes in UTF-8 encoding).");
-
-
- if (id.equals(".") || id.equals(".."))
- throw new IllegalArgumentException(idName + " is invalid.");
-
- char[] chars = id.toCharArray();
- for (int i = 0; i < chars.length; i++)
- if (StatusVariable.SYMBOLIC_NAME_CHARACTERS.indexOf(chars[i]) == -1)
- throw new IllegalArgumentException(idName +
- " contains invalid characters.");
- }
-
- /**
- * Create an integer hash of the object. The hash codes of
- * <code>MonitorPermission</code>s <code>p1</code> and <code>p2</code> are
- * the same if <code>p1.equals(p2)</code>.
- *
- * @return the hash of the object
- */
- public int hashCode() {
- return new Integer(mask).hashCode()
- ^ new Integer(minJobInterval).hashCode() ^ monId.hashCode()
- ^ new Boolean(prefixMonId).hashCode()
- ^ varId.hashCode()
- ^ new Boolean(prefixVarId).hashCode();
- }
-
- /**
- * Determines the equality of two <code>MonitorPermission</code> objects.
- * Two <code>MonitorPermission</code> objects are equal if their target
- * strings are equal and the same set of actions are listed in their action
- * strings.
- *
- * @param o the object being compared for equality with this object
- * @return <code>true</code> if the two permissions are equal
- */
- public boolean equals(Object o) {
- if (!(o instanceof MonitorPermission))
- return false;
-
- MonitorPermission other = (MonitorPermission) o;
-
- return mask == other.mask && minJobInterval == other.minJobInterval
- && monId.equals(other.monId)
- && prefixMonId == other.prefixMonId
- && varId.equals(other.varId)
- && prefixVarId == other.prefixVarId;
- }
-
- /**
- * Get the action string associated with this permission. The actions are
- * returned in the following order: <code>read</code>, <code>reset</code>,
- * <code>publish</code>, <code>startjob</code>, <code>switchevents</code>.
- *
- * @return the allowed actions separated by commas, cannot be
- * <code>null</code>
- */
- public String getActions() {
- StringBuffer sb = new StringBuffer();
-
- appendAction(sb, READ_FLAG, READ);
- appendAction(sb, RESET_FLAG, RESET);
- appendAction(sb, PUBLISH_FLAG, PUBLISH);
- appendAction(sb, STARTJOB_FLAG, STARTJOB);
- appendAction(sb, SWITCHEVENTS_FLAG, SWITCHEVENTS);
-
- return sb.toString();
- }
-
- private void appendAction(StringBuffer sb, int flag, String actionName) {
- if ((mask & flag) != 0) {
- if(sb.length() != 0)
- sb.append(',');
- sb.append(actionName);
-
- if(flag == STARTJOB_FLAG && minJobInterval != 0)
- sb.append(':').append(minJobInterval);
- }
- }
-
- /**
- * Determines if the specified permission is implied by this permission.
- * <p>
- * This method returns <code>false</code> if and only if at least one of the
- * following conditions are fulfilled for the specified permission:
- * <ul>
- * <li>it is not a <code>MonitorPermission</code>
- * <li>it has a broader set of actions allowed than this one
- * <li>it allows initiating time based monitoring jobs with a lower minimal
- * sampling interval
- * <li>the target set of <code>Monitorable</code>s is not the same nor a
- * subset of the target set of <code>Monitorable</code>s of this permission
- * <li>the target set of <code>StatusVariable</code>s is not the same
- * nor a subset of the target set of <code>StatusVariable</code>s of this
- * permission
- * </ul>
- *
- * @param p the permission to be checked
- * @return <code>true</code> if the given permission is implied by this
- * permission
- */
- public boolean implies(Permission p) {
- if (!(p instanceof MonitorPermission))
- return false;
-
- MonitorPermission other = (MonitorPermission) p;
-
- if ((mask & other.mask) != other.mask)
- return false;
-
- if ((other.mask & STARTJOB_FLAG) != 0
- && minJobInterval > other.minJobInterval)
- return false;
-
- return implies(monId, prefixMonId, other.monId, other.prefixMonId)
- && implies(varId, prefixVarId, other.varId, other.prefixVarId);
- }
-
- private boolean implies(String id, boolean prefix, String oid,
- boolean oprefix) {
-
- return prefix ? oid.startsWith(id) : !oprefix && id.equals(oid);
- }
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/monitor/Monitorable.java b/org.osgi.compendium/src/main/java/org/osgi/service/monitor/Monitorable.java
deleted file mode 100644
index c9d8760..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/monitor/Monitorable.java
+++ /dev/null
@@ -1,140 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2004, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.osgi.service.monitor;
-
-/**
- * A <code>Monitorable</code> can provide information about itself in the form
- * of <code>StatusVariables</code>. Instances of this interface should register
- * themselves at the OSGi Service Registry. The <code>MonitorAdmin</code>
- * listens to the registration of <code>Monitorable</code> services, and makes
- * the information they provide available also through the Device Management
- * Tree (DMT) for remote access.
- * <p>
- * The monitorable service is identified by its PID string which must be a non-
- * <code>null</code>, non-empty string that conforms to the "symbolic-name"
- * definition in the OSGi core specification. This means that only the
- * characters [-_.a-zA-Z0-9] may be used. The length of the PID must not exceed
- * 20 characters.
- * <p>
- * A <code>Monitorable</code> may optionally support sending notifications when
- * the status of its <code>StatusVariables</code> change. Support for change
- * notifications can be defined per <code>StatusVariable</code>.
- * <p>
- * Publishing <code>StatusVariables</code> requires the presence of the
- * <code>MonitorPermission</code> with the <code>publish</code> action string.
- * This permission, however, is not checked during registration of the
- * <code>Monitorable</code> service. Instead, the <code>MonitorAdmin</code>
- * implementation must make sure that when a <code>StatusVariable</code> is
- * queried, it is shown only if the <code>Monitorable</code> is authorized to
- * publish the given <code>StatusVariable</code>.
- *
- * @version $Revision: 7940 $
- */
-public interface Monitorable {
- /**
- * Returns the list of <code>StatusVariable</code> identifiers published
- * by this <code>Monitorable</code>. A <code>StatusVariable</code> name
- * is unique within the scope of a <code>Monitorable</code>. The array
- * contains the elements in no particular order. The returned value must not
- * be <code>null</code>.
- *
- * @return the <code>StatusVariable<code> identifiers published by this
- * object, or an empty array if none are published
- */
- public String[] getStatusVariableNames();
-
- /**
- * Returns the <code>StatusVariable</code> object addressed by its
- * identifier. The <code>StatusVariable</code> will hold the value taken
- * at the time of this method call.
- * <p>
- * The given identifier does not contain the Monitorable PID, i.e. it
- * specifies the name and not the path of the Status Variable.
- *
- * @param id the identifier of the <code>StatusVariable</code>, cannot be
- * <code>null</code>
- * @return the <code>StatusVariable</code> object
- * @throws java.lang.IllegalArgumentException if <code>id</code> points to a
- * non-existing <code>StatusVariable</code>
- */
- public StatusVariable getStatusVariable(String id)
- throws IllegalArgumentException;
-
- /**
- * Tells whether the <code>StatusVariable</code> provider is able to send
- * instant notifications when the given <code>StatusVariable</code>
- * changes. If the <code>Monitorable</code> supports sending change
- * updates it must notify the <code>MonitorListener</code> when the value
- * of the <code>StatusVariable</code> changes. The
- * <code>Monitorable</code> finds the <code>MonitorListener</code>
- * service through the Service Registry.
- * <p>
- * The given identifier does not contain the Monitorable PID, i.e. it
- * specifies the name and not the path of the Status Variable.
- *
- * @param id the identifier of the <code>StatusVariable</code>, cannot be
- * <code>null</code>
- * @return <code>true</code> if the <code>Monitorable</code> can send
- * notification when the given <code>StatusVariable</code>
- * changes, <code>false</code> otherwise
- * @throws java.lang.IllegalArgumentException if <code>id</code> points to a
- * non-existing <code>StatusVariable</code>
- */
- public boolean notifiesOnChange(String id) throws IllegalArgumentException;
-
- /**
- * Issues a request to reset a given <code>StatusVariable</code>.
- * Depending on the semantics of the actual Status Variable this call may or
- * may not succeed: it makes sense to reset a counter to its starting value,
- * but for example a <code>StatusVariable</code> of type <code>String</code>
- * might not have a meaningful default value. Note that for numeric
- * <code>StatusVariables</code> the starting value may not necessarily be
- * 0. Resetting a <code>StatusVariable</code> must trigger a monitor event.
- * <p>
- * The given identifier does not contain the Monitorable PID, i.e. it
- * specifies the name and not the path of the Status Variable.
- *
- * @param id the identifier of the <code>StatusVariable</code>, cannot be
- * <code>null</code>
- * @return <code>true</code> if the <code>Monitorable</code> could
- * successfully reset the given <code>StatusVariable</code>,
- * <code>false</code> otherwise
- * @throws java.lang.IllegalArgumentException if <code>id</code> points to a
- * non-existing <code>StatusVariable</code>
- */
- public boolean resetStatusVariable(String id)
- throws IllegalArgumentException;
-
- /**
- * Returns a human readable description of a <code>StatusVariable</code>.
- * This can be used by management systems on their GUI. The
- * <code>null</code> return value is allowed if there is no description for
- * the specified Status Variable.
- * <p>
- * The given identifier does not contain the Monitorable PID, i.e. it
- * specifies the name and not the path of the Status Variable.
- *
- * @param id the identifier of the <code>StatusVariable</code>, cannot be
- * <code>null</code>
- * @return the human readable description of this
- * <code>StatusVariable</code> or <code>null</code> if it is not
- * set
- * @throws java.lang.IllegalArgumentException if <code>id</code> points to a
- * non-existing <code>StatusVariable</code>
- */
- public String getDescription(String id) throws IllegalArgumentException;
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/monitor/MonitoringJob.java b/org.osgi.compendium/src/main/java/org/osgi/service/monitor/MonitoringJob.java
deleted file mode 100644
index 2ee7f9c..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/monitor/MonitoringJob.java
+++ /dev/null
@@ -1,125 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2004, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.osgi.service.monitor;
-
-/**
- * A Monitoring Job is a request for scheduled or event based notifications on
- * update of a set of <code>StatusVariable</code>s. The job is a data structure
- * that holds a non-empty list of <code>StatusVariable</code> names, an
- * identification of the initiator of the job, and the sampling parameters.
- * There are two kinds of monitoring jobs: time based and change based. Time
- * based jobs take samples of all <code>StatusVariable</code>s with a specified
- * frequency. The number of samples to be taken before the job finishes may be
- * specified. Change based jobs are only interested in the changes of the
- * monitored <code>StatusVariable</code>s. In this case, the number of changes
- * that must take place between two notifications can be specified.
- * <p>
- * The job can be started on the <code>MonitorAdmin</code> interface. Running
- * the job (querying the <code>StatusVariable</code>s, listening to changes, and
- * sending out notifications on updates) is the task of the
- * <code>MonitorAdmin</code> implementation.
- * <p>
- * Whether a monitoring job keeps track dynamically of the
- * <code>StatusVariable</code>s it monitors is not specified. This means that if
- * we monitor a <code>StatusVariable</code> of a <code>Monitorable</code>
- * service which disappears and later reappears then it is implementation
- * specific whether we still receive updates of the <code>StatusVariable</code>
- * changes or not.
- *
- * @version $Revision: 7940 $
- */
-public interface MonitoringJob {
- /**
- * Stops a Monitoring Job. Note that a time based job can also stop
- * automatically if the specified number of samples have been taken.
- */
- public void stop();
-
- /**
- * Returns the identifier of the principal who initiated the job. This is
- * set at the time when
- * {@link MonitorAdmin#startJob MonitorAdmin.startJob()} method is called.
- * This string holds the ServerID if the operation was initiated from a
- * remote manager, or an arbitrary ID of the initiator entity in the local
- * case (used for addressing notification events).
- *
- * @return the ID of the initiator, cannot be <code>null</code>
- */
- public String getInitiator();
-
- /**
- * Returns the list of <code>StatusVariable</code> names that are the
- * targets of this measurement job. For time based jobs, the
- * <code>MonitorAdmin</code> will iterate through this list and query all
- * <code>StatusVariable</code>s when its timer set by the job's frequency
- * rate expires.
- *
- * @return the target list of the measurement job in
- * [Monitorable_ID]/[StatusVariable_ID] format, cannot be
- * <code>null</code>
- */
- public String[] getStatusVariableNames();
-
- /**
- * Returns the delay (in seconds) between two samples. If this call returns
- * N (greater than 0) then the <code>MonitorAdmin</code> queries each
- * <code>StatusVariable</code> that belongs to this job every N seconds.
- * The value 0 means that the job is not scheduled but event based: in this
- * case instant notification on changes is requested (at every n-th change of
- * the value, as specified by the report count parameter).
- *
- * @return the delay (in seconds) between samples, or 0 for change based
- * jobs
- */
- public int getSchedule();
-
- /**
- * Returns the number of times <code>MonitorAdmin</code> will query the
- * <code>StatusVariable</code>s (for time based jobs), or the number of
- * changes of a <code>StatusVariable</code> between notifications (for
- * change based jobs). Time based jobs with non-zero report count will take
- * <code>getReportCount()</code>*<code>getSchedule()</code> time to
- * finish. Time based jobs with 0 report count and change based jobs do not
- * stop automatically, but all jobs can be stopped with the {@link #stop}
- * method.
- *
- * @return the number of measurements to be taken, or the number of changes
- * between notifications
- */
- public int getReportCount();
-
- /**
- * Returns whether the job was started locally or remotely. Jobs started by
- * the clients of this API are always local, remote jobs can only be started
- * using the Device Management Tree.
- *
- * @return <code>true</code> if the job was started from the local device,
- * <code>false</code> if the job was initiated from a management
- * server through the device management tree
- */
- public boolean isLocal();
-
- /**
- * Returns whether the job is running. A job is running until it is
- * explicitly stopped, or, in case of time based jobs with a finite report
- * count, until the given number of measurements have been made.
- *
- * @return <code>true</code> if the job is still running, <code>false</code>
- * if it has finished
- */
- public boolean isRunning();
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/monitor/StatusVariable.java b/org.osgi.compendium/src/main/java/org/osgi/service/monitor/StatusVariable.java
deleted file mode 100644
index 927e7ec..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/monitor/StatusVariable.java
+++ /dev/null
@@ -1,433 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2004, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.osgi.service.monitor;
-
-import java.io.UnsupportedEncodingException;
-import java.util.Date;
-
-/**
- * A <code>StatusVariable</code> object represents the value of a status
- * variable taken with a certain collection method at a certain point of time.
- * The type of the <code>StatusVariable</code> can be <code>int</code>,
- * <code>float</code>, <code>boolean</code> or <code>String</code>.
- * <p>
- * A <code>StatusVariable</code> is identified by an ID string that is unique
- * within the scope of a <code>Monitorable</code>. The ID must be a non-
- * <code>null</code>, non-empty string that conforms to the "symbolic-name"
- * definition in the OSGi core specification. This means that only the
- * characters [-_.a-zA-Z0-9] may be used. The length of the ID must not exceed
- * 32 bytes when UTF-8 encoded.
- *
- * @version $Revision: 5673 $
- */
-public final class StatusVariable {
- //----- Public constants -----//
- /**
- * Constant for identifying <code>int</code> data type.
- */
- public static final int TYPE_INTEGER = 0;
-
- /**
- * Constant for identifying <code>float</code> data type.
- */
- public static final int TYPE_FLOAT = 1;
-
- /**
- * Constant for identifying <code>String</code> data type.
- */
- public static final int TYPE_STRING = 2;
-
- /**
- * Constant for identifying <code>boolean</code> data type.
- */
- public static final int TYPE_BOOLEAN = 3;
-
- /**
- * Constant for identifying 'Cumulative Counter' data collection method.
- */
- public static final int CM_CC = 0;
-
- /**
- * Constant for identifying 'Discrete Event Registration' data collection
- * method.
- */
- public static final int CM_DER = 1;
-
- /**
- * Constant for identifying 'Gauge' data collection method.
- */
- public static final int CM_GAUGE = 2;
-
- /**
- * Constant for identifying 'Status Inspection' data collection method.
- */
- public static final int CM_SI = 3;
-
- //----- Package private constants -----//
-
- static final String SYMBOLIC_NAME_CHARACTERS =
- "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ" + "0123456789" +
- "-_."; // a subset of the characters allowed in DMT URIs
-
- static final int MAX_ID_LENGTH = 32;
-
- //----- Private fields -----//
- private String id;
- private Date timeStamp;
- private int cm;
- private int type;
-
- private int intData;
- private float floatData;
- private String stringData;
- private boolean booleanData;
-
-
- //----- Constructors -----//
- /**
- * Constructor for a <code>StatusVariable</code> of <code>int</code>
- * type.
- *
- * @param id the identifier of the <code>StatusVariable</code>
- * @param cm the collection method, one of the <code>CM_</code> constants
- * @param data the <code>int</code> value of the
- * <code>StatusVariable</code>
- * @throws java.lang.IllegalArgumentException if the given <code>id</code>
- * is not a valid <code>StatusVariable</code> name, or if
- * <code>cm</code> is not one of the collection method constants
- * @throws java.lang.NullPointerException if the <code>id</code>
- * parameter is <code>null</code>
- */
- public StatusVariable(String id, int cm, int data) {
- setCommon(id, cm);
- type = TYPE_INTEGER;
- intData = data;
- }
-
- /**
- * Constructor for a <code>StatusVariable</code> of <code>float</code>
- * type.
- *
- * @param id the identifier of the <code>StatusVariable</code>
- * @param cm the collection method, one of the <code>CM_</code> constants
- * @param data the <code>float</code> value of the
- * <code>StatusVariable</code>
- * @throws java.lang.IllegalArgumentException if the given <code>id</code>
- * is not a valid <code>StatusVariable</code> name, or if
- * <code>cm</code> is not one of the collection method constants
- * @throws java.lang.NullPointerException if the <code>id</code> parameter
- * is <code>null</code>
- */
- public StatusVariable(String id, int cm, float data) {
- setCommon(id, cm);
- type = TYPE_FLOAT;
- floatData = data;
- }
-
- /**
- * Constructor for a <code>StatusVariable</code> of <code>boolean</code>
- * type.
- *
- * @param id the identifier of the <code>StatusVariable</code>
- * @param cm the collection method, one of the <code>CM_</code> constants
- * @param data the <code>boolean</code> value of the
- * <code>StatusVariable</code>
- * @throws java.lang.IllegalArgumentException if the given <code>id</code>
- * is not a valid <code>StatusVariable</code> name, or if
- * <code>cm</code> is not one of the collection method constants
- * @throws java.lang.NullPointerException if the <code>id</code> parameter
- * is <code>null</code>
- */
- public StatusVariable(String id, int cm, boolean data) {
- setCommon(id, cm);
- type = TYPE_BOOLEAN;
- booleanData = data;
- }
-
- /**
- * Constructor for a <code>StatusVariable</code> of <code>String</code>
- * type.
- *
- * @param id the identifier of the <code>StatusVariable</code>
- * @param cm the collection method, one of the <code>CM_</code> constants
- * @param data the <code>String</code> value of the
- * <code>StatusVariable</code>, can be <code>null</code>
- * @throws java.lang.IllegalArgumentException if the given <code>id</code>
- * is not a valid <code>StatusVariable</code> name, or if
- * <code>cm</code> is not one of the collection method constants
- * @throws java.lang.NullPointerException if the <code>id</code> parameter
- * is <code>null</code>
- */
- public StatusVariable(String id, int cm, String data) {
- setCommon(id, cm);
- type = TYPE_STRING;
- stringData = data;
- }
-
-
- // ----- Public methods -----//
- /**
- * Returns the ID of this <code>StatusVariable</code>. The ID is unique
- * within the scope of a <code>Monitorable</code>.
- *
- * @return the ID of this <code>StatusVariable</code>
- */
- public String getID() {
- return id;
- }
-
- /**
- * Returns information on the data type of this <code>StatusVariable</code>.
- *
- * @return one of the <code>TYPE_</code> constants indicating the type of
- * this <code>StatusVariable</code>
- */
- public int getType() {
- return type;
- }
-
- /**
- * Returns the timestamp associated with the <code>StatusVariable</code>.
- * The timestamp is stored when the <code>StatusVariable</code> instance is
- * created, generally during the {@link Monitorable#getStatusVariable}
- * method call.
- *
- * @return the time when the <code>StatusVariable</code> value was
- * queried, cannot be <code>null</code>
- *
- */
- public Date getTimeStamp() {
- return timeStamp;
- }
-
- /**
- * Returns the <code>StatusVariable</code> value if its type is
- * <code>String</code>.
- *
- * @return the <code>StatusVariable</code> value as a <code>String</code>
- * @throws java.lang.IllegalStateException if the type of the
- * <code>StatusVariable</code> is not <code>String</code>
- */
- public String getString() throws IllegalStateException {
- if (type != TYPE_STRING)
- throw new IllegalStateException(
- "This StatusVariable does not contain a String value.");
- return stringData;
- }
-
- /**
- * Returns the <code>StatusVariable</code> value if its type is
- * <code>int</code>.
- *
- * @return the <code>StatusVariable</code> value as an <code>int</code>
- * @throws java.lang.IllegalStateException if the type of this
- * <code>StatusVariable</code> is not <code>int</code>
- */
- public int getInteger() throws IllegalStateException {
- if (type != TYPE_INTEGER)
- throw new IllegalStateException(
- "This StatusVariable does not contain an integer value.");
- return intData;
- }
-
- /**
- * Returns the <code>StatusVariable</code> value if its type is
- * <code>float</code>.
- *
- * @return the <code>StatusVariable</code> value as a <code>float</code>
- * @throws java.lang.IllegalStateException if the type of this
- * <code>StatusVariable</code> is not <code>float</code>
- */
- public float getFloat() throws IllegalStateException {
- if (type != TYPE_FLOAT)
- throw new IllegalStateException(
- "This StatusVariable does not contain a float value.");
- return floatData;
- }
-
- /**
- * Returns the <code>StatusVariable</code> value if its type is
- * <code>boolean</code>.
- *
- * @return the <code>StatusVariable</code> value as a <code>boolean</code>
- * @throws java.lang.IllegalStateException if the type of this
- * <code>StatusVariable</code> is not <code>boolean</code>
- */
- public boolean getBoolean() throws IllegalStateException {
- if (type != TYPE_BOOLEAN)
- throw new IllegalStateException(
- "This StatusVariable does not contain a boolean value.");
- return booleanData;
- }
-
- /**
- * Returns the collection method of this <code>StatusVariable</code>. See
- * section 3.3 b) in [ETSI TS 132 403]
- *
- * @return one of the <code>CM_</code> constants
- */
- public int getCollectionMethod() {
- return cm;
- }
-
- /**
- * Compares the specified object with this <code>StatusVariable</code>.
- * Two <code>StatusVariable</code> objects are considered equal if their
- * full path, collection method and type are identical, and the data
- * (selected by their type) is equal.
- *
- * @param obj the object to compare with this <code>StatusVariable</code>
- * @return <code>true</code> if the argument represents the same
- * <code>StatusVariable</code> as this object
- */
- public boolean equals(Object obj) {
- if (!(obj instanceof StatusVariable))
- return false;
-
- StatusVariable other = (StatusVariable) obj;
-
- if (!equals(id, other.id) || cm != other.cm || type != other.type)
- return false;
-
- switch (type) {
- case TYPE_INTEGER: return intData == other.intData;
- case TYPE_FLOAT: return floatData == other.floatData;
- case TYPE_STRING: return equals(stringData, other.stringData);
- case TYPE_BOOLEAN: return booleanData == other.booleanData;
- }
-
- return false; // never reached
- }
-
- /**
- * Returns the hash code value for this <code>StatusVariable</code>. The
- * hash code is calculated based on the full path, collection method and
- * value of the <code>StatusVariable</code>.
- *
- * @return the hash code of this object
- */
- public int hashCode() {
- int hash = hashCode(id) ^ cm;
-
- switch (type) {
- case TYPE_INTEGER: return hash ^ intData;
- case TYPE_FLOAT: return hash ^ hashCode(new Float(floatData));
- case TYPE_BOOLEAN: return hash ^ hashCode(new Boolean(booleanData));
- case TYPE_STRING: return hash ^ hashCode(stringData);
- }
-
- return 0; // never reached
- }
-
- // String representation: StatusVariable(path, cm, time, type, value)
- /**
- * Returns a <code>String</code> representation of this
- * <code>StatusVariable</code>. The returned <code>String</code>
- * contains the full path, collection method, timestamp, type and value
- * parameters of the <code>StatusVariable</code> in the following format:
- * <pre>StatusVariable(<path>, <cm>, <timestamp>, <type>, <value>)</pre>
- * The collection method identifiers used in the string representation are
- * "CC", "DER", "GAUGE" and "SI" (without the quotes). The format of the
- * timestamp is defined by the <code>Date.toString</code> method, while the
- * type is identified by one of the strings "INTEGER", "FLOAT", "STRING" and
- * "BOOLEAN". The final field contains the string representation of the
- * value of the status variable.
- *
- * @return the <code>String</code> representation of this
- * <code>StatusVariable</code>
- */
- public String toString() {
- String cmName = null;
- switch (cm) {
- case CM_CC: cmName = "CC"; break;
- case CM_DER: cmName = "DER"; break;
- case CM_GAUGE: cmName = "GAUGE"; break;
- case CM_SI: cmName = "SI"; break;
- }
-
- String beg = "StatusVariable(" + id + ", " + cmName + ", "
- + timeStamp + ", ";
-
- switch (type) {
- case TYPE_INTEGER: return beg + "INTEGER, " + intData + ")";
- case TYPE_FLOAT: return beg + "FLOAT, " + floatData + ")";
- case TYPE_STRING: return beg + "STRING, " + stringData + ")";
- case TYPE_BOOLEAN: return beg + "BOOLEAN, " + booleanData + ")";
- }
-
- return null; // never reached
- }
-
- //----- Private methods -----//
-
- private void setCommon(String id, int cm)
- throws IllegalArgumentException, NullPointerException {
- checkId(id, "StatusVariable ID");
-
- if (cm != CM_CC && cm != CM_DER && cm != CM_GAUGE && cm != CM_SI)
- throw new IllegalArgumentException(
- "Unknown data collection method constant '" + cm + "'.");
-
- this.id = id;
- this.cm = cm;
- timeStamp = new Date();
- }
-
-
- private boolean equals(Object o1, Object o2) {
- return o1 == null ? o2 == null : o1.equals(o2);
- }
-
- private int hashCode(Object o) {
- return o == null ? 0 : o.hashCode();
- }
-
- private static void checkId(String id, String idName)
- throws IllegalArgumentException, NullPointerException {
- if (id == null)
- throw new NullPointerException(idName + " is null.");
- if(id.length() == 0)
- throw new IllegalArgumentException(idName + " is empty.");
-
- byte[] nameBytes;
- try {
- nameBytes = id.getBytes("UTF-8");
- } catch (UnsupportedEncodingException e) {
- // never happens, "UTF-8" must always be supported
- throw new IllegalStateException(e.getMessage());
- }
- if(nameBytes.length > MAX_ID_LENGTH)
- throw new IllegalArgumentException(idName + " is too long " +
- "(over " + MAX_ID_LENGTH + " bytes in UTF-8 encoding).");
-
- if(id.equals(".") || id.equals(".."))
- throw new IllegalArgumentException(idName + " is invalid.");
-
- if(!containsValidChars(id))
- throw new IllegalArgumentException(idName +
- " contains invalid characters.");
- }
-
- private static boolean containsValidChars(String name) {
- char[] chars = name.toCharArray();
- for(int i = 0; i < chars.length; i++)
- if(SYMBOLIC_NAME_CHARACTERS.indexOf(chars[i]) == -1)
- return false;
-
- return true;
- }
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/prefs/BackingStoreException.java b/org.osgi.compendium/src/main/java/org/osgi/service/prefs/BackingStoreException.java
deleted file mode 100644
index 0f15919..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/prefs/BackingStoreException.java
+++ /dev/null
@@ -1,75 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2001, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.service.prefs;
-
-/**
- * Thrown to indicate that a preferences operation could not complete because of
- * a failure in the backing store, or a failure to contact the backing store.
- *
- * @version $Revision: 6083 $
- */
-public class BackingStoreException extends Exception {
- static final long serialVersionUID = -1415637364122829574L;
-
- /**
- * Constructs a <code>BackingStoreException</code> with the specified detail
- * message.
- *
- * @param message The detail message.
- */
- public BackingStoreException(String message) {
- super(message);
- }
-
- /**
- * Constructs a <code>BackingStoreException</code> with the specified detail
- * message.
- *
- * @param message The detail message.
- * @param cause The cause of the exception. May be <code>null</code>.
- * @since 1.1
- */
- public BackingStoreException(String message, Throwable cause) {
- super(message, cause);
- }
-
- /**
- * Returns the cause of this exception or <code>null</code> if no cause was
- * set.
- *
- * @return The cause of this exception or <code>null</code> if no cause was
- * set.
- * @since 1.1
- */
- public Throwable getCause() {
- return super.getCause();
- }
-
- /**
- * Initializes the cause of this exception to the specified value.
- *
- * @param cause The cause of this exception.
- * @return This exception.
- * @throws IllegalArgumentException If the specified cause is this
- * exception.
- * @throws IllegalStateException If the cause of this exception has already
- * been set.
- * @since 1.1
- */
- public Throwable initCause(Throwable cause) {
- return super.initCause(cause);
- }
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/prefs/Preferences.java b/org.osgi.compendium/src/main/java/org/osgi/service/prefs/Preferences.java
deleted file mode 100644
index 8ffad3f..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/prefs/Preferences.java
+++ /dev/null
@@ -1,700 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2001, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.service.prefs;
-
-/**
- * A node in a hierarchical collection of preference data.
- *
- * <p>
- * This interface allows applications to store and retrieve user and system
- * preference data. This data is stored persistently in an
- * implementation-dependent backing store. Typical implementations include flat
- * files, OS-specific registries, directory servers and SQL databases.
- *
- * <p>
- * For each bundle, there is a separate tree of nodes for each user, and one for
- * system preferences. The precise description of "user" and "system" will vary
- * from one bundle to another. Typical information stored in the user preference
- * tree might include font choice, and color choice for a bundle which interacts
- * with the user via a servlet. Typical information stored in the system
- * preference tree might include installation data, or things like high score
- * information for a game program.
- *
- * <p>
- * Nodes in a preference tree are named in a similar fashion to directories in a
- * hierarchical file system. Every node in a preference tree has a <i>node name
- * </i> (which is not necessarily unique), a unique <i>absolute path name </i>,
- * and a path name <i>relative </i> to each ancestor including itself.
- *
- * <p>
- * The root node has a node name of the empty <code>String</code> object ("").
- * Every other node has an arbitrary node name, specified at the time it is
- * created. The only restrictions on this name are that it cannot be the empty
- * string, and it cannot contain the slash character ('/').
- *
- * <p>
- * The root node has an absolute path name of <code>"/"</code>. Children of the
- * root node have absolute path names of <code>"/" + </code> <i><node name>
- * </i>. All other nodes have absolute path names of <i><parent's absolute
- * path name> </i> <code> + "/" + </code> <i><node name> </i>. Note that
- * all absolute path names begin with the slash character.
- *
- * <p>
- * A node <i>n </i>'s path name relative to its ancestor <i>a </i> is simply the
- * string that must be appended to <i>a </i>'s absolute path name in order to
- * form <i>n </i>'s absolute path name, with the initial slash character (if
- * present) removed. Note that:
- * <ul>
- * <li>No relative path names begin with the slash character.
- * <li>Every node's path name relative to itself is the empty string.
- * <li>Every node's path name relative to its parent is its node name (except
- * for the root node, which does not have a parent).
- * <li>Every node's path name relative to the root is its absolute path name
- * with the initial slash character removed.
- * </ul>
- *
- * <p>
- * Note finally that:
- * <ul>
- * <li>No path name contains multiple consecutive slash characters.
- * <li>No path name with the exception of the root's absolute path name end in
- * the slash character.
- * <li>Any string that conforms to these two rules is a valid path name.
- * </ul>
- *
- * <p>
- * Each <code>Preference</code> node has zero or more properties associated with
- * it, where a property consists of a name and a value. The bundle writer is
- * free to choose any appropriate names for properties. Their values can be of
- * type <code>String</code>,<code>long</code>,<code>int</code>,<code>boolean</code>,
- * <code>byte[]</code>,<code>float</code>, or <code>double</code> but they can
- * always be accessed as if they were <code>String</code> objects.
- *
- * <p>
- * All node name and property name comparisons are case-sensitive.
- *
- * <p>
- * All of the methods that modify preference data are permitted to operate
- * asynchronously; they may return immediately, and changes will eventually
- * propagate to the persistent backing store, with an implementation-dependent
- * delay. The <code>flush</code> method may be used to synchronously force updates
- * to the backing store.
- *
- * <p>
- * Implementations must automatically attempt to flush to the backing store any
- * pending updates for a bundle's preferences when the bundle is stopped or
- * otherwise ungets the Preferences Service.
- *
- * <p>
- * The methods in this class may be invoked concurrently by multiple threads in
- * a single Java Virtual Machine (JVM) without the need for external
- * synchronization, and the results will be equivalent to some serial execution.
- * If this class is used concurrently <i>by multiple JVMs </i> that store their
- * preference data in the same backing store, the data store will not be
- * corrupted, but no other guarantees are made concerning the consistency of the
- * preference data.
- *
- *
- * @version $Revision: 5673 $
- */
-public interface Preferences {
- /**
- * Associates the specified value with the specified key in this node.
- *
- * @param key key with which the specified value is to be associated.
- * @param value value to be associated with the specified key.
- * @throws NullPointerException if <code>key</code> or <code>value</code> is
- * <code>null</code>.
- * @throws IllegalStateException if this node (or an ancestor) has been
- * removed with the {@link #removeNode()} method.
- */
- public void put(String key, String value);
-
- /**
- * Returns the value associated with the specified <code>key</code> in this
- * node. Returns the specified default if there is no value associated with
- * the <code>key</code>, or the backing store is inaccessible.
- *
- * @param key key whose associated value is to be returned.
- * @param def the value to be returned in the event that this node has no
- * value associated with <code>key</code> or the backing store is
- * inaccessible.
- * @return the value associated with <code>key</code>, or <code>def</code> if
- * no value is associated with <code>key</code>.
- * @throws IllegalStateException if this node (or an ancestor) has been
- * removed with the {@link #removeNode()} method.
- * @throws NullPointerException if <code>key</code> is <code>null</code>. (A
- * <code>null</code> default <i>is </i> permitted.)
- */
- public String get(String key, String def);
-
- /**
- * Removes the value associated with the specified <code>key</code> in this
- * node, if any.
- *
- * @param key key whose mapping is to be removed from this node.
- * @see #get(String,String)
- * @throws IllegalStateException if this node (or an ancestor) has been
- * removed with the {@link #removeNode()} method.
- */
- public void remove(String key);
-
- /**
- * Removes all of the properties (key-value associations) in this node. This
- * call has no effect on any descendants of this node.
- *
- * @throws BackingStoreException if this operation cannot be completed due
- * to a failure in the backing store, or inability to communicate
- * with it.
- * @throws IllegalStateException if this node (or an ancestor) has been
- * removed with the {@link #removeNode()} method.
- * @see #remove(String)
- */
- public void clear() throws BackingStoreException;
-
- /**
- * Associates a <code>String</code> object representing the specified
- * <code>int</code> value with the specified <code>key</code> in this node. The
- * associated string is the one that would be returned if the <code>int</code>
- * value were passed to <code>Integer.toString(int)</code>. This method is
- * intended for use in conjunction with {@link #getInt} method.
- *
- * <p>
- * Implementor's note: it is <i>not </i> necessary that the property value
- * be represented by a <code>String</code> object in the backing store. If the
- * backing store supports integer values, it is not unreasonable to use
- * them. This implementation detail is not visible through the
- * <code>Preferences</code> API, which allows the value to be read as an
- * <code>int</code> (with <code>getInt</code> or a <code>String</code> (with
- * <code>get</code>) type.
- *
- * @param key key with which the string form of value is to be associated.
- * @param value <code>value</code> whose string form is to be associated with
- * <code>key</code>.
- * @throws NullPointerException if <code>key</code> is <code>null</code>.
- * @throws IllegalStateException if this node (or an ancestor) has been
- * removed with the {@link #removeNode()} method.
- * @see #getInt(String,int)
- */
- public void putInt(String key, int value);
-
- /**
- * Returns the <code>int</code> value represented by the <code>String</code>
- * object associated with the specified <code>key</code> in this node. The
- * <code>String</code> object is converted to an <code>int</code> as by
- * <code>Integer.parseInt(String)</code>. Returns the specified default if
- * there is no value associated with the <code>key</code>, the backing store
- * is inaccessible, or if <code>Integer.parseInt(String)</code> would throw a
- * <code>NumberFormatException</code> if the associated <code>value</code> were
- * passed. This method is intended for use in conjunction with the
- * {@link #putInt} method.
- *
- * @param key key whose associated value is to be returned as an
- * <code>int</code>.
- * @param def the value to be returned in the event that this node has no
- * value associated with <code>key</code> or the associated value
- * cannot be interpreted as an <code>int</code> or the backing store is
- * inaccessible.
- * @return the <code>int</code> value represented by the <code>String</code>
- * object associated with <code>key</code> in this node, or
- * <code>def</code> if the associated value does not exist or cannot
- * be interpreted as an <code>int</code> type.
- * @throws NullPointerException if <code>key</code> is <code>null</code>.
- * @throws IllegalStateException if this node (or an ancestor) has been
- * removed with the {@link #removeNode()} method.
- * @see #putInt(String,int)
- * @see #get(String,String)
- */
- public int getInt(String key, int def);
-
- /**
- * Associates a <code>String</code> object representing the specified
- * <code>long</code> value with the specified <code>key</code> in this node. The
- * associated <code>String</code> object is the one that would be returned if
- * the <code>long</code> value were passed to <code>Long.toString(long)</code>.
- * This method is intended for use in conjunction with the {@link #getLong}
- * method.
- *
- * <p>
- * Implementor's note: it is <i>not </i> necessary that the <code>value</code>
- * be represented by a <code>String</code> type in the backing store. If the
- * backing store supports <code>long</code> values, it is not unreasonable to
- * use them. This implementation detail is not visible through the <code>
- * Preferences</code> API, which allows the value to be read as a
- * <code>long</code> (with <code>getLong</code> or a <code>String</code> (with
- * <code>get</code>) type.
- *
- * @param key <code>key</code> with which the string form of <code>value</code>
- * is to be associated.
- * @param value <code>value</code> whose string form is to be associated with
- * <code>key</code>.
- * @throws NullPointerException if <code>key</code> is <code>null</code>.
- * @throws IllegalStateException if this node (or an ancestor) has been
- * removed with the {@link #removeNode()} method.
- * @see #getLong(String,long)
- */
- public void putLong(String key, long value);
-
- /**
- * Returns the <code>long</code> value represented by the <code>String</code>
- * object associated with the specified <code>key</code> in this node. The
- * <code>String</code> object is converted to a <code>long</code> as by
- * <code>Long.parseLong(String)</code>. Returns the specified default if
- * there is no value associated with the <code>key</code>, the backing store
- * is inaccessible, or if <code>Long.parseLong(String)</code> would throw a
- * <code>NumberFormatException</code> if the associated <code>value</code> were
- * passed. This method is intended for use in conjunction with the
- * {@link #putLong} method.
- *
- * @param key <code>key</code> whose associated value is to be returned as a
- * <code>long</code> value.
- * @param def the value to be returned in the event that this node has no
- * value associated with <code>key</code> or the associated value
- * cannot be interpreted as a <code>long</code> type or the backing
- * store is inaccessible.
- * @return the <code>long</code> value represented by the <code>String</code>
- * object associated with <code>key</code> in this node, or
- * <code>def</code> if the associated value does not exist or cannot
- * be interpreted as a <code>long</code> type.
- * @throws NullPointerException if <code>key</code> is <code>null</code>.
- * @throws IllegalStateException if this node (or an ancestor) has been
- * removed with the {@link #removeNode()} method.
- * @see #putLong(String,long)
- * @see #get(String,String)
- */
- public long getLong(String key, long def);
-
- /**
- * Associates a <code>String</code> object representing the specified
- * <code>boolean</code> value with the specified key in this node. The
- * associated string is "true" if the value is <code>true</code>, and "false"
- * if it is <code>false</code>. This method is intended for use in
- * conjunction with the {@link #getBoolean} method.
- *
- * <p>
- * Implementor's note: it is <i>not </i> necessary that the value be
- * represented by a string in the backing store. If the backing store
- * supports <code>boolean</code> values, it is not unreasonable to use them.
- * This implementation detail is not visible through the <code>Preferences
- * </code> API, which allows the value to be read as a <code>boolean</code>
- * (with <code>getBoolean</code>) or a <code>String</code> (with <code>get</code>)
- * type.
- *
- * @param key <code>key</code> with which the string form of value is to be
- * associated.
- * @param value value whose string form is to be associated with
- * <code>key</code>.
- * @throws NullPointerException if <code>key</code> is <code>null</code>.
- * @throws IllegalStateException if this node (or an ancestor) has been
- * removed with the {@link #removeNode()} method.
- * @see #getBoolean(String,boolean)
- * @see #get(String,String)
- */
- public void putBoolean(String key, boolean value);
-
- /**
- * Returns the <code>boolean</code> value represented by the <code>String</code>
- * object associated with the specified <code>key</code> in this node. Valid
- * strings are "true", which represents <code>true</code>, and "false", which
- * represents <code>false</code>. Case is ignored, so, for example, "TRUE"
- * and "False" are also valid. This method is intended for use in
- * conjunction with the {@link #putBoolean} method.
- *
- * <p>
- * Returns the specified default if there is no value associated with the
- * <code>key</code>, the backing store is inaccessible, or if the associated
- * value is something other than "true" or "false", ignoring case.
- *
- * @param key <code>key</code> whose associated value is to be returned as a
- * <code>boolean</code>.
- * @param def the value to be returned in the event that this node has no
- * value associated with <code>key</code> or the associated value
- * cannot be interpreted as a <code>boolean</code> or the backing store
- * is inaccessible.
- * @return the <code>boolean</code> value represented by the <code>String</code>
- * object associated with <code>key</code> in this node, or
- * <code>null</code> if the associated value does not exist or cannot
- * be interpreted as a <code>boolean</code>.
- * @throws NullPointerException if <code>key</code> is <code>null</code>.
- * @throws IllegalStateException if this node (or an ancestor) has been
- * removed with the {@link #removeNode()} method.
- * @see #get(String,String)
- * @see #putBoolean(String,boolean)
- */
- public boolean getBoolean(String key, boolean def);
-
- /**
- * Associates a <code>String</code> object representing the specified
- * <code>float</code> value with the specified <code>key</code> in this node.
- * The associated <code>String</code> object is the one that would be returned
- * if the <code>float</code> value were passed to
- * <code>Float.toString(float)</code>. This method is intended for use in
- * conjunction with the {@link #getFloat} method.
- *
- * <p>
- * Implementor's note: it is <i>not </i> necessary that the value be
- * represented by a string in the backing store. If the backing store
- * supports <code>float</code> values, it is not unreasonable to use them.
- * This implementation detail is not visible through the <code>Preferences
- * </code> API, which allows the value to be read as a <code>float</code> (with
- * <code>getFloat</code>) or a <code>String</code> (with <code>get</code>) type.
- *
- * @param key <code>key</code> with which the string form of value is to be
- * associated.
- * @param value value whose string form is to be associated with
- * <code>key</code>.
- * @throws NullPointerException if <code>key</code> is <code>null</code>.
- * @throws IllegalStateException if this node (or an ancestor) has been
- * removed with the {@link #removeNode()} method.
- * @see #getFloat(String,float)
- */
- public void putFloat(String key, float value);
-
- /**
- * Returns the float <code>value</code> represented by the <code>String</code>
- * object associated with the specified <code>key</code> in this node. The
- * <code>String</code> object is converted to a <code>float</code> value as by
- * <code>Float.parseFloat(String)</code>. Returns the specified default if
- * there is no value associated with the <code>key</code>, the backing store
- * is inaccessible, or if <code>Float.parseFloat(String)</code> would throw a
- * <code>NumberFormatException</code> if the associated value were passed.
- * This method is intended for use in conjunction with the {@link #putFloat}
- * method.
- *
- * @param key <code>key</code> whose associated value is to be returned as a
- * <code>float</code> value.
- * @param def the value to be returned in the event that this node has no
- * value associated with <code>key</code> or the associated value
- * cannot be interpreted as a <code>float</code> type or the backing
- * store is inaccessible.
- * @return the <code>float</code> value represented by the string associated
- * with <code>key</code> in this node, or <code>def</code> if the
- * associated value does not exist or cannot be interpreted as a
- * <code>float</code> type.
- * @throws IllegalStateException if this node (or an ancestor) has been
- * removed with the {@link #removeNode()} method.
- * @throws NullPointerException if <code>key</code> is <code>null</code>.
- * @see #putFloat(String,float)
- * @see #get(String,String)
- */
- public float getFloat(String key, float def);
-
- /**
- * Associates a <code>String</code> object representing the specified
- * <code>double</code> value with the specified <code>key</code> in this node.
- * The associated <code>String</code> object is the one that would be returned
- * if the <code>double</code> value were passed to
- * <code>Double.toString(double)</code>. This method is intended for use in
- * conjunction with the {@link #getDouble} method
- *
- * <p>
- * Implementor's note: it is <i>not </i> necessary that the value be
- * represented by a string in the backing store. If the backing store
- * supports <code>double</code> values, it is not unreasonable to use them.
- * This implementation detail is not visible through the <code>Preferences
- * </code> API, which allows the value to be read as a <code>double</code> (with
- * <code>getDouble</code>) or a <code>String</code> (with <code>get</code>)
- * type.
- *
- * @param key <code>key</code> with which the string form of value is to be
- * associated.
- * @param value value whose string form is to be associated with
- * <code>key</code>.
- * @throws NullPointerException if <code>key</code> is <code>null</code>.
- * @throws IllegalStateException if this node (or an ancestor) has been
- * removed with the {@link #removeNode()} method.
- * @see #getDouble(String,double)
- */
- public void putDouble(String key, double value);
-
- /**
- * Returns the <code>double</code> value represented by the <code>String</code>
- * object associated with the specified <code>key</code> in this node. The
- * <code>String</code> object is converted to a <code>double</code> value as by
- * <code>Double.parseDouble(String)</code>. Returns the specified default if
- * there is no value associated with the <code>key</code>, the backing store
- * is inaccessible, or if <code>Double.parseDouble(String)</code> would throw
- * a <code>NumberFormatException</code> if the associated value were passed.
- * This method is intended for use in conjunction with the
- * {@link #putDouble} method.
- *
- * @param key <code>key</code> whose associated value is to be returned as a
- * <code>double</code> value.
- * @param def the value to be returned in the event that this node has no
- * value associated with <code>key</code> or the associated value
- * cannot be interpreted as a <code>double</code> type or the backing
- * store is inaccessible.
- * @return the <code>double</code> value represented by the <code>String</code>
- * object associated with <code>key</code> in this node, or
- * <code>def</code> if the associated value does not exist or cannot
- * be interpreted as a <code>double</code> type.
- * @throws IllegalStateException if this node (or an ancestor) has been
- * removed with the the {@link #removeNode()} method.
- * @throws NullPointerException if <code>key</code> is <code>null</code>.
- * @see #putDouble(String,double)
- * @see #get(String,String)
- */
- public double getDouble(String key, double def);
-
- /**
- * Associates a <code>String</code> object representing the specified
- * <code>byte[]</code> with the specified <code>key</code> in this node. The
- * associated <code>String</code> object the <i>Base64 </i> encoding of the
- * <code>byte[]</code>, as defined in <a
- * href="http://www.ietf.org/rfc/rfc2045.txt">RFC 2045 </a>, Section 6.8,
- * with one minor change: the string will consist solely of characters from
- * the <i>Base64 Alphabet </i>; it will not contain any newline characters.
- * This method is intended for use in conjunction with the
- * {@link #getByteArray} method.
- *
- * <p>
- * Implementor's note: it is <i>not </i> necessary that the value be
- * represented by a <code>String</code> type in the backing store. If the
- * backing store supports <code>byte[]</code> values, it is not unreasonable
- * to use them. This implementation detail is not visible through the <code>
- * Preferences</code> API, which allows the value to be read as an a
- * <code>byte[]</code> object (with <code>getByteArray</code>) or a
- * <code>String</code> object (with <code>get</code>).
- *
- * @param key <code>key</code> with which the string form of <code>value</code>
- * is to be associated.
- * @param value <code>value</code> whose string form is to be associated with
- * <code>key</code>.
- * @throws NullPointerException if <code>key</code> or <code>value</code> is
- * <code>null</code>.
- * @throws IllegalStateException if this node (or an ancestor) has been
- * removed with the {@link #removeNode()} method.
- * @see #getByteArray(String,byte[])
- * @see #get(String,String)
- */
- public void putByteArray(String key, byte[] value);
-
- /**
- * Returns the <code>byte[]</code> value represented by the <code>String</code>
- * object associated with the specified <code>key</code> in this node. Valid
- * <code>String</code> objects are <i>Base64 </i> encoded binary data, as
- * defined in <a href="http://www.ietf.org/rfc/rfc2045.txt">RFC 2045 </a>,
- * Section 6.8, with one minor change: the string must consist solely of
- * characters from the <i>Base64 Alphabet </i>; no newline characters or
- * extraneous characters are permitted. This method is intended for use in
- * conjunction with the {@link #putByteArray} method.
- *
- * <p>
- * Returns the specified default if there is no value associated with the
- * <code>key</code>, the backing store is inaccessible, or if the associated
- * value is not a valid Base64 encoded byte array (as defined above).
- *
- * @param key <code>key</code> whose associated value is to be returned as a
- * <code>byte[]</code> object.
- * @param def the value to be returned in the event that this node has no
- * value associated with <code>key</code> or the associated value
- * cannot be interpreted as a <code>byte[]</code> type, or the backing
- * store is inaccessible.
- * @return the <code>byte[]</code> value represented by the <code>String</code>
- * object associated with <code>key</code> in this node, or
- * <code>def</code> if the associated value does not exist or cannot
- * be interpreted as a <code>byte[]</code>.
- * @throws NullPointerException if <code>key</code> is <code>null</code>. (A
- * <code>null</code> value for <code>def</code> <i>is </i> permitted.)
- * @throws IllegalStateException if this node (or an ancestor) has been
- * removed with the {@link #removeNode()} method.
- * @see #get(String,String)
- * @see #putByteArray(String,byte[])
- */
- public byte[] getByteArray(String key, byte[] def);
-
- /**
- * Returns all of the keys that have an associated value in this node. (The
- * returned array will be of size zero if this node has no preferences and
- * not <code>null</code>!)
- *
- * @return an array of the keys that have an associated value in this node.
- * @throws BackingStoreException if this operation cannot be completed due
- * to a failure in the backing store, or inability to communicate
- * with it.
- * @throws IllegalStateException if this node (or an ancestor) has been
- * removed with the {@link #removeNode()} method.
- */
- public String[] keys() throws BackingStoreException;
-
- /**
- * Returns the names of the children of this node. (The returned array will
- * be of size zero if this node has no children and not <code>null</code>!)
- *
- * @return the names of the children of this node.
- * @throws BackingStoreException if this operation cannot be completed due
- * to a failure in the backing store, or inability to communicate
- * with it.
- * @throws IllegalStateException if this node (or an ancestor) has been
- * removed with the {@link #removeNode()} method.
- */
- public String[] childrenNames() throws BackingStoreException;
-
- /**
- * Returns the parent of this node, or <code>null</code> if this is the root.
- *
- * @return the parent of this node.
- * @throws IllegalStateException if this node (or an ancestor) has been
- * removed with the {@link #removeNode()} method.
- */
- public Preferences parent();
-
- /**
- * Returns a named <code>Preferences</code> object (node), creating it and any
- * of its ancestors if they do not already exist. Accepts a relative or
- * absolute pathname. Absolute pathnames (which begin with <code>'/'</code>)
- * are interpreted relative to the root of this node. Relative pathnames
- * (which begin with any character other than <code>'/'</code>) are
- * interpreted relative to this node itself. The empty string (<code>""</code>)
- * is a valid relative pathname, referring to this node itself.
- *
- * <p>
- * If the returned node did not exist prior to this call, this node and any
- * ancestors that were created by this call are not guaranteed to become
- * persistent until the <code>flush</code> method is called on the returned
- * node (or one of its descendants).
- *
- * @param pathName the path name of the <code>Preferences</code> object to
- * return.
- * @return the specified <code>Preferences</code> object.
- * @throws IllegalArgumentException if the path name is invalid.
- * @throws IllegalStateException if this node (or an ancestor) has been
- * removed with the {@link #removeNode()} method.
- * @throws NullPointerException if path name is <code>null</code>.
- * @see #flush()
- */
- public Preferences node(String pathName);
-
- /**
- * Returns true if the named node exists. Accepts a relative or absolute
- * pathname. Absolute pathnames (which begin with <code>'/'</code>) are
- * interpreted relative to the root of this node. Relative pathnames (which
- * begin with any character other than <code>'/'</code>) are interpreted
- * relative to this node itself. The pathname <code>""</code> is valid, and
- * refers to this node itself.
- *
- * <p>
- * If this node (or an ancestor) has already been removed with the
- * {@link #removeNode()} method, it <i>is </i> legal to invoke this method,
- * but only with the pathname <code>""</code>; the invocation will return
- * <code>false</code>. Thus, the idiom <code>p.nodeExists("")</code> may be
- * used to test whether <code>p</code> has been removed.
- *
- * @param pathName the path name of the node whose existence is to be
- * checked.
- * @return true if the specified node exists.
- * @throws BackingStoreException if this operation cannot be completed due
- * to a failure in the backing store, or inability to communicate
- * with it.
- * @throws IllegalStateException if this node (or an ancestor) has been
- * removed with the {@link #removeNode()} method and
- * <code>pathname</code> is not the empty string (<code>""</code>).
- * @throws IllegalArgumentException if the path name is invalid (i.e., it
- * contains multiple consecutive slash characters, or ends with a
- * slash character and is more than one character long).
- */
- public boolean nodeExists(String pathName)
- throws BackingStoreException;
-
- /**
- * Removes this node and all of its descendants, invalidating any properties
- * contained in the removed nodes. Once a node has been removed, attempting
- * any method other than <code>name()</code>,<code>absolutePath()</code> or
- * <code>nodeExists("")</code> on the corresponding <code>Preferences</code>
- * instance will fail with an <code>IllegalStateException</code>. (The
- * methods defined on <code>Object</code> can still be invoked on a node after
- * it has been removed; they will not throw <code>IllegalStateException</code>.)
- *
- * <p>
- * The removal is not guaranteed to be persistent until the <code>flush</code>
- * method is called on the parent of this node.
- *
- * @throws IllegalStateException if this node (or an ancestor) has already
- * been removed with the {@link #removeNode()} method.
- * @throws BackingStoreException if this operation cannot be completed due
- * to a failure in the backing store, or inability to communicate
- * with it.
- * @see #flush()
- */
- public void removeNode() throws BackingStoreException;
-
- /**
- * Returns this node's name, relative to its parent.
- *
- * @return this node's name, relative to its parent.
- */
- public String name();
-
- /**
- * Returns this node's absolute path name. Note that:
- * <ul>
- * <li>Root node - The path name of the root node is <code>"/"</code>.
- * <li>Slash at end - Path names other than that of the root node may not
- * end in slash (<code>'/'</code>).
- * <li>Unusual names -<code>"."</code> and <code>".."</code> have <i>no </i>
- * special significance in path names.
- * <li>Illegal names - The only illegal path names are those that contain
- * multiple consecutive slashes, or that end in slash and are not the root.
- * </ul>
- *
- * @return this node's absolute path name.
- */
- public String absolutePath();
-
- /**
- * Forces any changes in the contents of this node and its descendants to
- * the persistent store.
- *
- * <p>
- * Once this method returns successfully, it is safe to assume that all
- * changes made in the subtree rooted at this node prior to the method
- * invocation have become permanent.
- *
- * <p>
- * Implementations are free to flush changes into the persistent store at
- * any time. They do not need to wait for this method to be called.
- *
- * <p>
- * When a flush occurs on a newly created node, it is made persistent, as
- * are any ancestors (and descendants) that have yet to be made persistent.
- * Note however that any properties value changes in ancestors are <i>not
- * </i> guaranteed to be made persistent.
- *
- * @throws BackingStoreException if this operation cannot be completed due
- * to a failure in the backing store, or inability to communicate
- * with it.
- * @throws IllegalStateException if this node (or an ancestor) has been
- * removed with the {@link #removeNode()} method.
- * @see #sync()
- */
- public void flush() throws BackingStoreException;
-
- /**
- * Ensures that future reads from this node and its descendants reflect any
- * changes that were committed to the persistent store (from any VM) prior
- * to the <code>sync</code> invocation. As a side-effect, forces any changes
- * in the contents of this node and its descendants to the persistent store,
- * as if the <code>flush</code> method had been invoked on this node.
- *
- * @throws BackingStoreException if this operation cannot be completed due
- * to a failure in the backing store, or inability to communicate
- * with it.
- * @throws IllegalStateException if this node (or an ancestor) has been
- * removed with the {@link #removeNode()} method.
- * @see #flush()
- */
- public void sync() throws BackingStoreException;
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/prefs/PreferencesService.java b/org.osgi.compendium/src/main/java/org/osgi/service/prefs/PreferencesService.java
deleted file mode 100644
index a9d99a4..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/prefs/PreferencesService.java
+++ /dev/null
@@ -1,54 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2001, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.service.prefs;
-
-/**
- * The Preferences Service.
- *
- * <p>
- * Each bundle using this service has its own set of preference trees: one for
- * system preferences, and one for each user.
- *
- * <p>
- * A <code>PreferencesService</code> object is specific to the bundle which
- * obtained it from the service registry. If a bundle wishes to allow another
- * bundle to access its preferences, it should pass its
- * <code>PreferencesService</code> object to that bundle.
- *
- */
-public interface PreferencesService {
- /**
- * Returns the root system node for the calling bundle.
- *
- * @return The root system node for the calling bundle.
- */
- public Preferences getSystemPreferences();
-
- /**
- * Returns the root node for the specified user and the calling bundle.
- *
- * @param name The user for which to return the preference root node.
- * @return The root node for the specified user and the calling bundle.
- */
- public Preferences getUserPreferences(String name);
-
- /**
- * Returns the names of users for which node trees exist.
- *
- * @return The names of users for which node trees exist.
- */
- public String[] getUsers();
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/provisioning/ProvisioningService.java b/org.osgi.compendium/src/main/java/org/osgi/service/provisioning/ProvisioningService.java
deleted file mode 100644
index 5ca31a5..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/provisioning/ProvisioningService.java
+++ /dev/null
@@ -1,213 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2002, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.service.provisioning;
-
-import java.io.IOException;
-import java.util.Dictionary;
-import java.util.zip.ZipInputStream;
-
-/**
- * Service for managing the initial provisioning information.
- * <p>
- * Initial provisioning of an OSGi device is a multi step process that
- * culminates with the installation and execution of the initial management
- * agent. At each step of the process, information is collected for the next
- * step. Multiple bundles may be involved and this service provides a means for
- * these bundles to exchange information. It also provides a means for the
- * initial Management Bundle to get its initial configuration information.
- * <p>
- * The provisioning information is collected in a <code>Dictionary</code>
- * object, called the Provisioning Dictionary. Any bundle that can access the
- * service can get a reference to this object and read and update provisioning
- * information. The key of the dictionary is a <code>String</code> object and
- * the value is a <code>String</code> or <code>byte[]</code> object. The
- * single exception is the PROVISIONING_UPDATE_COUNT value which is an Integer.
- * The <code>provisioning</code> prefix is reserved for keys defined by OSGi,
- * other key names may be used for implementation dependent provisioning
- * systems.
- * <p>
- * Any changes to the provisioning information will be reflected immediately in
- * all the dictionary objects obtained from the Provisioning Service.
- * <p>
- * Because of the specific application of the Provisioning Service, there should
- * be only one Provisioning Service registered. This restriction will not be
- * enforced by the Framework. Gateway operators or manufactures should ensure
- * that a Provisioning Service bundle is not installed on a device that already
- * has a bundle providing the Provisioning Service.
- * <p>
- * The provisioning information has the potential to contain sensitive
- * information. Also, the ability to modify provisioning information can have
- * drastic consequences. Thus, only trusted bundles should be allowed to
- * register and get the Provisioning Service. The <code>ServicePermission</code>
- * is used to limit the bundles that can gain access to the Provisioning
- * Service. There is no check of <code>Permission</code> objects to read or
- * modify the provisioning information, so care must be taken not to leak the
- * Provisioning Dictionary received from <code>getInformation</code> method.
- *
- * @version $Revision: 7347 $
- */
-public interface ProvisioningService {
- /**
- * The key to the provisioning information that uniquely identifies the
- * Service Platform. The value must be of type <code>String</code>.
- */
- public final static String PROVISIONING_SPID = "provisioning.spid";
-
- /**
- * The key to the provisioning information that contains the location of the
- * provision data provider. The value must be of type <code>String</code>.
- */
- public final static String PROVISIONING_REFERENCE = "provisioning.reference";
-
- /**
- * The key to the provisioning information that contains the initial
- * configuration information of the initial Management Agent. The value will
- * be of type <code>byte[]</code>.
- */
- public final static String PROVISIONING_AGENT_CONFIG = "provisioning.agent.config";
-
- /**
- * The key to the provisioning information that contains the update count of
- * the info data. Each set of changes to the provisioning information must
- * end with this value being incremented. The value must be of type
- * <code>Integer</code>. This key/value pair is also reflected in the
- * properties of the ProvisioningService in the service registry.
- */
- public final static String PROVISIONING_UPDATE_COUNT = "provisioning.update.count";
-
- /**
- * The key to the provisioning information that contains the location of the
- * bundle to start with <code>AllPermission</code>. The bundle must have
- * be previously installed for this entry to have any effect.
- */
- public final static String PROVISIONING_START_BUNDLE = "provisioning.start.bundle";
-
- /**
- * The key to the provisioning information that contains the root X509
- * certificate used to establish trust with operator when using HTTPS.
- */
- public final static String PROVISIONING_ROOTX509 = "provisioning.rootx509";
-
- /**
- * The key to the provisioning information that contains the shared secret
- * used in conjunction with the RSH protocol.
- */
- public final static String PROVISIONING_RSH_SECRET = "provisioning.rsh.secret";
-
- /**
- * MIME type to be stored in the extra field of a <code>ZipEntry</code>
- * object for String data.
- */
- public final static String MIME_STRING = "text/plain;charset=utf-8";
-
- /**
- * MIME type to be stored stored in the extra field of a
- * <code>ZipEntry</code> object for <code>byte[]</code> data.
- */
- public final static String MIME_BYTE_ARRAY = "application/octet-stream";
-
- /**
- * MIME type to be stored in the extra field of a <code>ZipEntry</code>
- * object for an installable bundle file. Zip entries of this type will be
- * installed in the framework, but not started. The entry will also not be
- * put into the information dictionary.
- */
- public final static String MIME_BUNDLE = "application/vnd.osgi.bundle";
-
- /**
- * Alternative MIME type to be stored in the extra field of a
- * <code>ZipEntry</code> object for an installable bundle file. Zip entries
- * of this type will be installed in the framework, but not started. The
- * entry will also not be put into the information dictionary. This
- * alternative entry is only for backward compatibility, new applications
- * are recommended to use <code>MIME_BUNDLE</code>, which is an official
- * IANA MIME type.
- *
- * @since 1.2
- */
- public final static String MIME_BUNDLE_ALT = "application/x-osgi-bundle";
-
- /**
- * MIME type to be stored in the extra field of a ZipEntry for a String that
- * represents a URL for a bundle. Zip entries of this type will be used to
- * install (but not start) a bundle from the URL. The entry will not be put
- * into the information dictionary.
- */
- public final static String MIME_BUNDLE_URL = "text/x-osgi-bundle-url";
-
- /**
- * Name of the header that specifies the type information for the ZIP file
- * entries.
- *
- * @since 1.2
- */
- public final static String INITIALPROVISIONING_ENTRIES = "InitialProvisioning-Entries";
-
- /**
- * Returns a reference to the Provisioning Dictionary. Any change operations
- * (put and remove) to the dictionary will cause an
- * <code>UnsupportedOperationException</code> to be thrown. Changes must
- * be done using the <code>setInformation</code> and
- * <code>addInformation</code> methods of this service.
- *
- * @return A reference to the Provisioning Dictionary.
- */
- public Dictionary getInformation();
-
- /**
- * Replaces the Provisioning Information dictionary with the key/value pairs
- * contained in <code>info</code>. Any key/value pairs not in
- * <code>info</code> will be removed from the Provisioning Information
- * dictionary. This method causes the <code>PROVISIONING_UPDATE_COUNT</code>
- * to be incremented.
- *
- * @param info the new set of Provisioning Information key/value pairs. Any
- * keys are values that are of an invalid type will be silently
- * ignored.
- */
- public void setInformation(Dictionary info);
-
- /**
- * Adds the key/value pairs contained in <code>info</code> to the
- * Provisioning Information dictionary. This method causes the
- * <code>PROVISIONING_UPDATE_COUNT</code> to be incremented.
- *
- * @param info the set of Provisioning Information key/value pairs to add to
- * the Provisioning Information dictionary. Any keys are values that
- * are of an invalid type will be silently ignored.
- */
- public void addInformation(Dictionary info);
-
- /**
- * Processes the <code>ZipInputStream</code> and extracts information to
- * add to the Provisioning Information dictionary, as well as,
- * install/update and start bundles. This method causes the
- * <code>PROVISIONING_UPDATE_COUNT</code> to be incremented.
- *
- * @param zis the <code>ZipInputStream</code> that will be used to add
- * key/value pairs to the Provisioning Information dictionary and
- * install and start bundles. If a <code>ZipEntry</code> does not
- * have an <code>Extra</code> field that corresponds to one of the
- * four defined MIME types (<code>MIME_STRING</code>,
- * <code>MIME_BYTE_ARRAY</code>,<code>MIME_BUNDLE</code>, and
- * <code>MIME_BUNDLE_URL</code>) in will be silently ignored.
- * @throws IOException if an error occurs while processing the
- * ZipInputStream. No additions will be made to the Provisioning
- * Information dictionary and no bundles must be started or
- * installed.
- */
- public void addInformation(ZipInputStream zis) throws IOException;
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/upnp/UPnPAction.java b/org.osgi.compendium/src/main/java/org/osgi/service/upnp/UPnPAction.java
deleted file mode 100644
index 742673f..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/upnp/UPnPAction.java
+++ /dev/null
@@ -1,120 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2002, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.service.upnp;
-
-import java.util.Dictionary;
-
-/**
- * A UPnP action.
- *
- * Each UPnP service contains zero or more actions. Each action may have zero or
- * more UPnP state variables as arguments.
- *
- * @version $Revision: 5673 $
- */
-public interface UPnPAction {
- /**
- * Returns the action name.
- *
- * The action name corresponds to the <code>name</code> field in the
- * <code>actionList</code> of the service description.
- * <ul>
- * <li>For standard actions defined by a UPnP Forum working committee,
- * action names must not begin with <code>X_ </code> nor <code> A_</code>.</li>
- * <li>For non-standard actions specified by a UPnP vendor and added to a
- * standard service, action names must begin with <code>X_</code>.</li>
- * </ul>
- *
- * @return Name of action, must not contain a hyphen character or a hash
- * character
- */
- String getName();
-
- /**
- * Returns the name of the designated return argument.
- * <p>
- * One of the output arguments can be flagged as a designated return
- * argument.
- *
- * @return The name of the designated return argument or <code>null</code> if
- * none is marked.
- */
- String getReturnArgumentName();
-
- /**
- * Lists all input arguments for this action.
- * <p>
- * Each action may have zero or more input arguments.
- *
- * @return Array of input argument names or <code>null</code> if no input
- * arguments.
- *
- * @see UPnPStateVariable
- */
- String[] getInputArgumentNames();
-
- /**
- * List all output arguments for this action.
- *
- * @return Array of output argument names or <code>null</code> if there are no
- * output arguments.
- *
- * @see UPnPStateVariable
- */
- String[] getOutputArgumentNames();
-
- /**
- * Finds the state variable associated with an argument name.
- *
- * Helps to resolve the association of state variables with argument names
- * in UPnP actions.
- *
- * @param argumentName The name of the UPnP action argument.
- * @return State variable associated with the named argument or
- * <code>null</code> if there is no such argument.
- *
- * @see UPnPStateVariable
- */
- UPnPStateVariable getStateVariable(String argumentName);
-
- /**
- * Invokes the action.
- *
- * The input and output arguments are both passed as <code>Dictionary</code>
- * objects. Each entry in the <code>Dictionary</code> object has a
- * <code>String</code> object as key representing the argument name and the
- * value is the argument itself. The class of an argument value must be
- * assignable from the class of the associated UPnP state variable.
- *
- * The input argument <code>Dictionary</code> object must contain exactly
- * those arguments listed by <code>getInputArguments</code> method. The output
- * argument <code>Dictionary</code> object will contain exactly those
- * arguments listed by <code>getOutputArguments</code> method.
- *
- * @param args A <code>Dictionary</code> of arguments. Must contain the correct set and
- * type of arguments for this action. May be <code>null</code> if no
- * input arguments exist.
- *
- * @return A <code>Dictionary</code> with the output arguments.
- * <code>null</code> if the action has no output arguments.
- *
- * @throws UPnPException A UPnP error has occured.
- * @throws Exception The execution fails for some reason.
- *
- * @see UPnPStateVariable
- */
- Dictionary invoke(Dictionary args) throws Exception;
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/upnp/UPnPDevice.java b/org.osgi.compendium/src/main/java/org/osgi/service/upnp/UPnPDevice.java
deleted file mode 100644
index 24ce178..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/upnp/UPnPDevice.java
+++ /dev/null
@@ -1,280 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2002, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.service.upnp;
-
-import java.util.Dictionary;
-
-/**
- * Represents a UPnP device.
- *
- * For each UPnP root and embedded device, an object is registered with the
- * framework under the <code>UPnPDevice</code> interface.
- * <p>
- * The relationship between a root device and its embedded devices can be
- * deduced using the <code>UPnPDevice.CHILDREN_UDN</code> and
- * <code>UPnPDevice.PARENT_UDN</code> service registration properties.
- * <p>
- * The values of the UPnP property names are defined by the UPnP Forum.
- * <p>
- * All values of the UPnP properties are obtained from the device using the
- * device's default locale.
- * <p>
- * If an application wants to query for a set of localized property values, it
- * has to use the method <code>UPnPDevice.getDescriptions(String locale)</code>.
- *
- * @version $Revision: 5673 $
- */
-public interface UPnPDevice {
- /*
- * Constants for the UPnP device match scale.
- */
- /**
- * Constant for the UPnP device match scale, indicating a generic match for
- * the device. Value is 1.
- */
- int MATCH_GENERIC = 1;
- /**
- * Constant for the UPnP device match scale, indicating a match with the
- * device type. Value is 3.
- */
- int MATCH_TYPE = 3;
- /**
- * Constant for the UPnP device match scale, indicating a match with the
- * device model. Value is 7.
- */
- int MATCH_MANUFACTURER_MODEL = 7;
- /**
- * Constant for the UPnP device match scale, indicating a match with the
- * device revision. Value is 15.
- */
- int MATCH_MANUFACTURER_MODEL_REVISION = 15;
- /**
- * Constant for the UPnP device match scale, indicating a match with the
- * device revision and the serial number. Value is 31.
- */
- int MATCH_MANUFACTURER_MODEL_REVISION_SERIAL = 31;
- /**
- * Constant for the value of the service property <code>DEVICE_CATEGORY</code>
- * used for all UPnP devices. Value is "UPnP".
- *
- * @see "<code>org.osgi.service.device.Constants.DEVICE_CATEGORY</code>"
- */
- String DEVICE_CATEGORY = "UPnP";
- /**
- * The <code>UPnP.export</code> service property is a hint that marks a device
- * to be picked up and exported by the UPnP Service. Imported devices do not
- * have this property set. The registered property requires no value.
- * <p>
- * The UPNP_EXPORT string is "UPnP.export".
- */
- String UPNP_EXPORT = "UPnP.export";
- /**
- * Property key for the Unique Device Name (UDN) property. It is the unique
- * identifier of an instance of a <code>UPnPDevice</code>. The value of the
- * property is a <code>String</code> object of the Device UDN. Value of the
- * key is "UPnP.device.UDN". This property must be set.
- */
- String UDN = "UPnP.device.UDN";
- /**
- * Property key for the Unique Device ID property. This property is an alias
- * to <code>UPnPDevice.UDN</code>. It is merely provided for reasons of
- * symmetry with the <code>UPnPService.ID</code> property. The value of the
- * property is a <code>String</code> object of the Device UDN. The value of
- * the key is "UPnP.device.UDN".
- */
- String ID = UDN;
- /**
- * Property key for the UPnP Device Type property. Some standard property
- * values are defined by the Universal Plug and Play Forum. The type string
- * also includes a version number as defined in the UPnP specification. This
- * property must be set.
- * <p>
- * For standard devices defined by a UPnP Forum working committee, this must
- * consist of the following components in the given order separated by
- * colons:
- * <ul>
- * <li><code>urn</code></li>
- * <li>schemas-upnp-org</li>
- * <li><code>device</code></li>
- * <li>a device type suffix</li>
- * <li>an integer device version</li>
- * </ul>
- * For non-standard devices specified by UPnP vendors following components
- * must be specified in the given order separated by colons:
- * <ul>
- * <li><code>urn</code></li>
- * <li>an ICANN domain name owned by the vendor</li>
- * <li><code>device</code></li>
- * <li>a device type suffix</li>
- * <li>an integer device version</li>
- * </ul>
- * <p>
- * To allow for backward compatibility the UPnP driver must automatically
- * generate additional Device Type property entries for smaller versions
- * than the current one. If for example a device announces its type as
- * version 3, then properties for versions 2 and 1 must be automatically
- * generated.
- * <p>
- * In the case of exporting a UPnPDevice, the highest available version must
- * be announced on the network.
- * <p>
- * Syntax Example: <code>urn:schemas-upnp-org:device:deviceType:v</code>
- * <p>
- * The value is "UPnP.device.type".
- */
- String TYPE = "UPnP.device.type";
- /**
- * Mandatory property key for the device manufacturer's property. The
- * property value holds a String representation of the device manufacturer's
- * name. Value is "UPnP.device.manufacturer".
- */
- String MANUFACTURER = "UPnP.device.manufacturer";
- /**
- * Mandatory property key for the device model name. The property value
- * holds a <code>String</code> object giving more information about the device
- * model. Value is "UPnP.device.modelName".
- */
- String MODEL_NAME = "UPnP.device.modelName";
- /**
- * Mandatory property key for a short user friendly version of the device
- * name. The property value holds a <code>String</code> object with the user
- * friendly name of the device. Value is "UPnP.device.friendlyName".
- */
- String FRIENDLY_NAME = "UPnP.device.friendlyName";
- /**
- * Optional property key for a URL to the device manufacturers Web site. The
- * value of the property is a <code>String</code> object representing the URL.
- * Value is "UPnP.device.manufacturerURL".
- */
- String MANUFACTURER_URL = "UPnP.device.manufacturerURL";
- /**
- * Optional (but recommended) property key for a <code>String</code> object
- * with a long description of the device for the end user. The value is
- * "UPnP.device.modelDescription".
- */
- String MODEL_DESCRIPTION = "UPnP.device.modelDescription";
- /**
- * Optional (but recommended) property key for a <code>String</code> class
- * typed property holding the model number of the device. Value is
- * "UPnP.device.modelNumber".
- */
- String MODEL_NUMBER = "UPnP.device.modelNumber";
- /**
- * Optional property key for a <code>String</code> typed property holding a
- * string representing the URL to the Web site for this model. Value is
- * "UPnP.device.modelURL".
- */
- String MODEL_URL = "UPnP.device.modelURL";
- /**
- * Optional (but recommended) property key for a <code>String</code> typed
- * property holding the serial number of the device. Value is
- * "UPnP.device.serialNumber".
- */
- String SERIAL_NUMBER = "UPnP.device.serialNumber";
- /**
- * Optional property key for a <code>String</code> typed property holding the
- * Universal Product Code (UPC) of the device. Value is "UPnP.device.UPC".
- */
- String UPC = "UPnP.device.UPC";
- /**
- * Optional (but recommended) property key for a <code>String</code> typed
- * property holding a string representing the URL to a device representation
- * Web page. Value is "UPnP.presentationURL".
- */
- String PRESENTATION_URL = "UPnP.presentationURL";
- /**
- * The property key that must be set for all embedded devices. It contains
- * the UDN of the parent device. The property is not set for root devices.
- * The value is "UPnP.device.parentUDN".
- */
- String PARENT_UDN = "UPnP.device.parentUDN";
- /**
- * The property key that must be set for all devices containing other
- * embedded devices.
- * <p>
- * The value is an array of UDNs for each of the device's children (
- * <code>String[]</code>). The array contains UDNs for the immediate
- * descendants only.
- * </p>
- * <p>
- * If an embedded device in turn contains embedded devices, the latter are
- * not included in the array.
- * </p>
- * The UPnP Specification does not encourage more than two levels of
- * nesting.
- * <p>
- * The property is not set if the device does not contain embedded devices.
- * <p>
- * The property is of type <code>String[]</code>. Value is
- * "UPnP.device.childrenUDN"
- */
- String CHILDREN_UDN = "UPnP.device.childrenUDN";
-
- /**
- * Locates a specific service by its service id.
- *
- * @param serviceId The service id
- * @return The requested service or null if not found.
- */
- UPnPService getService(String serviceId);
-
- /**
- * Lists all services provided by this device.
- *
- * @return Array of services or <code>null</code> if no services are
- * available.
- */
- UPnPService[] getServices();
-
- /**
- * Lists all icons for this device in a given locale.
- *
- * The UPnP specification allows a device to present different icons based
- * on the client's locale.
- *
- * @param locale A language tag as defined by RFC 1766 and maintained by ISO
- * 639. Examples include "<code>de</code>", "<code>en</code>" or "
- * <code>en-US</code>". The default locale of the device is specified
- * by passing a <code>null</code> argument.
- *
- * @return Array of icons or null if no icons are available.
- */
- UPnPIcon[] getIcons(String locale);
-
- /**
- * Get a set of localized UPnP properties.
- *
- * The UPnP specification allows a device to present different device
- * properties based on the client's locale. The properties used to register
- * the UPnPDevice service in the OSGi registry are based on the device's
- * default locale. To obtain a localized set of the properties, an
- * application can use this method.
- * <p>
- * Not all properties might be available in all locales. This method does
- * <b>not </b> substitute missing properties with their default locale
- * versions.
- * <p>
- *
- * @param locale A language tag as defined by RFC 1766 and maintained by ISO
- * 639. Examples include "<code>de</code>", "<code>en</code>" or "
- * <code>en-US</code>". The default locale of the device is specified
- * by passing a <code>null</code> argument.
- * @return Dictionary mapping property name Strings to property value
- * Strings
- *
- */
- Dictionary getDescriptions(String locale);
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/upnp/UPnPEventListener.java b/org.osgi.compendium/src/main/java/org/osgi/service/upnp/UPnPEventListener.java
deleted file mode 100644
index 80d4455..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/upnp/UPnPEventListener.java
+++ /dev/null
@@ -1,85 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2002, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.service.upnp;
-
-import java.util.Dictionary;
-
-/**
- * UPnP Events are mapped and delivered to applications according to the OSGi
- * whiteboard model. An application that wishes to be notified of events
- * generated by a particular UPnP Device registers a service extending this
- * interface.
- * <p>
- * The notification call from the UPnP Service to any
- * <code>UPnPEventListener</code> object must be done asynchronous with respect
- * to the originator (in a separate thread).
- * <p>
- * Upon registration of the UPnP Event Listener service with the Framework, the
- * service is notified for each variable which it listens for with an initial
- * event containing the current value of the variable. Subsequent notifications
- * only happen on changes of the value of the variable.
- * <p>
- * A UPnP Event Listener service filter the events it receives. This event set
- * is limited using a standard framework filter expression which is specified
- * when the listener service is registered.
- * <p>
- * The filter is specified in a property named "upnp.filter" and has as a value
- * an object of type <code>org.osgi.framework.Filter</code>.
- * <p>
- * When the Filter is evaluated, the folowing keywords are recognized as defined
- * as literal constants in the <code>UPnPDevice</code> class.
- * <p>
- * The valid subset of properties for the registration of UPnP Event Listener
- * services are:
- * <ul>
- * <li><code>UPnPDevice.TYPE</code>-- Which type of device to listen for events.
- * </li>
- * <li><code>UPnPDevice.ID</code>-- The ID of a specific device to listen for
- * events.</li>
- * <li><code>UPnPService.TYPE</code>-- The type of a specific service to listen
- * for events.</li>
- * <li><code>UPnPService.ID</code>-- The ID of a specific service to listen for
- * events.</li>
- * </ul>
- *
- * @version $Revision: 5673 $
- */
-public interface UPnPEventListener {
- /**
- * Key for a service property having a value that is an object of type
- * <code>org.osgi.framework.Filter</code> and that is used to limit received
- * events.
- */
- static final String UPNP_FILTER = "upnp.filter";
-
- /**
- * Callback method that is invoked for received events.
- *
- * The events are collected in a <code>Dictionary</code> object. Each entry
- * has a <code>String</code> key representing the event name (= state variable
- * name) and the new value of the state variable. The class of the value
- * object must match the class specified by the UPnP State Variable
- * associated with the event. This method must be called asynchronously
- *
- * @param deviceId ID of the device sending the events
- * @param serviceId ID of the service sending the events
- * @param events <code>Dictionary</code> object containing the new values for
- * the state variables that have changed.
- *
- *
- */
- void notifyUPnPEvent(String deviceId, String serviceId, Dictionary events);
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/upnp/UPnPException.java b/org.osgi.compendium/src/main/java/org/osgi/service/upnp/UPnPException.java
deleted file mode 100644
index 172c995..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/upnp/UPnPException.java
+++ /dev/null
@@ -1,81 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2005, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.service.upnp;
-
-/**
- * There are several defined error situations describing UPnP problems while a
- * control point invokes actions to UPnPDevices.
- *
- * @since 1.1
- * @version $Revision: 5673 $
- */
-public class UPnPException extends Exception {
- static final long serialVersionUID = -262013318122195146L;
-
- /**
- * No Action found by that name at this service.
- */
- public final static int INVALID_ACTION = 401;
-
- /**
- * Not enough arguments, too many arguments with a specific name, or one of
- * more of the arguments are of the wrong type.
- */
- public final static int INVALID_ARGS = 402;
-
- /**
- * The different end-points are no longer in synchronization.
- */
- public final static int INVALID_SEQUENCE_NUMBER = 403;
-
- /**
- * Refers to a non existing variable.
- */
- public final static int INVALID_VARIABLE = 404;
-
- /**
- * The invoked action failed during execution.
- */
- public final static int DEVICE_INTERNAL_ERROR = 501;
-
- /**
- * Key for an error information that is an int type variable and that is
- * used to identify occured errors.
- */
- private final int errorCode;
-
- /**
- * This constructor creates a UPnPException on the specified error code and
- * error description.
- *
- * @param errorCode errorCode which defined UPnP Device Architecture V1.0.
- * @param errordesc errorDescription which explain the type of propblem.
- */
- public UPnPException(int errorCode, String errordesc) {
- super(errordesc);
- this.errorCode = errorCode;
- }
-
- /**
- * Returns the UPnPError Code occured by UPnPDevices during invocation.
- *
- * @return The UPnPErrorCode defined by a UPnP Forum working committee or
- * specified by a UPnP vendor.
- */
- public int getUPnPError_Code() {
- return errorCode;
- }
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/upnp/UPnPIcon.java b/org.osgi.compendium/src/main/java/org/osgi/service/upnp/UPnPIcon.java
deleted file mode 100644
index 8b99be9..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/upnp/UPnPIcon.java
+++ /dev/null
@@ -1,99 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2002, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.service.upnp;
-
-import java.io.IOException;
-import java.io.InputStream;
-
-/**
- * A UPnP icon representation.
- *
- * Each UPnP device can contain zero or more icons.
- *
- * @version $Revision: 5673 $
- */
-public interface UPnPIcon {
- /**
- * Returns the MIME type of the icon.
- *
- * This method returns the format in which the icon graphics, read from the
- * <code>InputStream</code> object obtained by the <code>getInputStream()</code>
- * method, is encoded.
- * <p>
- * The format of the returned string is in accordance to RFC2046. A list of
- * valid MIME types is maintained by the <a
- * href="http://www.iana.org/assignments/media-types/">IANA</a>.
- * <p>
- * Typical values returned include: "image/jpeg" or "image/gif"
- *
- * @return The MIME type of the encoded icon.
- */
- String getMimeType();
-
- /**
- * Returns the width of the icon in pixels.
- *
- * If the actual width of the icon is unknown, -1 is returned.
- *
- * @return The width in pixels, or -1 if unknown.
- */
- int getWidth();
-
- /**
- * Returns the height of the icon in pixels.
- *
- * If the actual height of the icon is unknown, -1 is returned.
- *
- * @return The height in pixels, or -1 if unknown.
- */
- int getHeight();
-
- /**
- * Returns the size of the icon in bytes.
- *
- * This method returns the number of bytes of the icon available to read
- * from the <code>InputStream</code> object obtained by the
- * <code>getInputStream()</code> method. If the actual size can not be
- * determined, -1 is returned.
- *
- * @return The icon size in bytes, or -1 if the size is unknown.
- */
- int getSize();
-
- /**
- * Returns the color depth of the icon in bits.
- *
- * @return The color depth in bits. If the actual color depth of the icon is
- * unknown, -1 is returned.
- */
- int getDepth();
-
- /**
- * Returns an <code>InputStream</code> object for the icon data.
- *
- * The <code>InputStream</code> object provides a way for a client to read the
- * actual icon graphics data. The number of bytes available from this
- * <code>InputStream</code> object can be determined via the
- * <code>getSize()</code> method. The format of the data encoded can be
- * determined by the MIME type availble via the <code>getMimeType()</code>
- * method.
- *
- * @return An InputStream to read the icon graphics data from.
- * @throws IOException If the <code>InputStream</code> cannot be returned.
- * @see UPnPIcon#getMimeType()
- */
- InputStream getInputStream() throws IOException;
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/upnp/UPnPLocalStateVariable.java b/org.osgi.compendium/src/main/java/org/osgi/service/upnp/UPnPLocalStateVariable.java
deleted file mode 100644
index 241fb8a..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/upnp/UPnPLocalStateVariable.java
+++ /dev/null
@@ -1,44 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2005, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-/**
- * To keep the current values getting from subscribed UPnPDevices.
- *
- * The actual values of the UPnPStateVaraible are passed as Java object type.
- *
- * @since 1.1
- **/
-package org.osgi.service.upnp;
-
-/**
- * A local UPnP state variable which allows the value of the state variable to
- * be queried.
- *
- * @since 1.1
- *
- * @version $Revision: 5673 $
- */
-public interface UPnPLocalStateVariable extends UPnPStateVariable {
- /**
- * This method will keep the current values of UPnPStateVariables of a
- * UPnPDevice whenever UPnPStateVariable's value is changed , this method
- * must be called.
- *
- * @return <code>Object</code> current value of UPnPStateVariable. if the
- * current value is initialized with the default value defined UPnP
- * service description.
- */
- public Object getCurrentValue();
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/upnp/UPnPService.java b/org.osgi.compendium/src/main/java/org/osgi/service/upnp/UPnPService.java
deleted file mode 100644
index 64b5894..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/upnp/UPnPService.java
+++ /dev/null
@@ -1,173 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2002, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.service.upnp;
-
-/**
- * A representation of a UPnP Service.
- *
- * Each UPnP device contains zero or more services. The UPnP description for a
- * service defines actions, their arguments, and event characteristics.
- *
- * @version $Revision: 5673 $
- */
-public interface UPnPService {
- /**
- * Property key for the optional service type uri.
- *
- * The service type property is used when registering UPnP Device services
- * and UPnP Event Listener services. The property contains a <code>String</code>
- * array (<code>String[]</code>) of service types. A UPnP Device service can
- * thus announce what types of services it contains. A UPnP Event Listener
- * service can announce for what type of UPnP services it wants
- * notifications. The service version is encoded in the type string as
- * specified in the UPnP specification. A <code>null</code> value is a
- * wildcard, matching <b>all </b> service types. Value is
- * "UPnP.service.type".
- *
- * @see UPnPService#getType()
- */
- String TYPE = "UPnP.service.type";
- /**
- * Property key for the optional service id.
- *
- * The service id property is used when registering UPnP Device services or
- * UPnP Event Listener services. The value of the property contains a
- * <code>String</code> array (<code>String[]</code>) of service ids. A UPnP
- * Device service can thus announce what service ids it contains. A UPnP
- * Event Listener service can announce for what UPnP service ids it wants
- * notifications. A service id does <b>not </b> have to be universally
- * unique. It must be unique only within a device. A <code>null</code> value
- * is a wildcard, matching <b>all </b> services. The value is
- * "UPnP.service.id".
- */
- String ID = "UPnP.service.id";
-
- /**
- * Returns the <code>serviceId</code> field in the UPnP service description.
- *
- *
- * <p>
- * For standard services defined by a UPnP Forum working committee, the
- * serviceId must contain the following components in the indicated order:
- * <ul>
- * <li><code>urn:upnp-org:serviceId:</code></li>
- * <li>service ID suffix</li>
- * </ul>
- * Example: <code>urn:upnp-org:serviceId:serviceID</code>.
- *
- * <p>
- * Note that <code>upnp-org</code> is used instead of
- * <code>schemas-upnp-org</code> in this example because an XML schema is not
- * defined for each serviceId.
- * </p>
- *
- * <p>
- * For non-standard services specified by UPnP vendors, the serviceId must
- * contain the following components in the indicated order:
- * <ul>
- * <li><code>urn:</code></li>
- * <li>ICANN domain name owned by the vendor</li>
- * <li><code>:serviceId:</code></li>
- * <li>service ID suffix</li>
- * </ul>
- * Example: <code>urn:domain-name:serviceId:serviceID</code>.
- *
- * @return The service ID suffix defined by a UPnP Forum working committee
- * or specified by a UPnP vendor. Must be <= 64 characters.
- * Single URI.
- */
- String getId();
-
- /**
- * Returns the <code>serviceType</code> field in the UPnP service description.
- *
- * <p>
- * For standard services defined by a UPnP Forum working committee, the
- * serviceType must contain the following components in the indicated order:
- * <ul>
- * <li><code>urn:schemas-upnp-org:service:</code></li>
- * <li>service type suffix:</li>
- * <li>integer service version</li>
- * </ul>
- * Example: <code>urn:schemas-upnp-org:service:serviceType:v</code>.
- *
- * <p>
- * For non-standard services specified by UPnP vendors, the
- * <code>serviceType</code> must contain the following components in the
- * indicated order:
- * <ul>
- * <li><code>urn:</code></li>
- * <li>ICANN domain name owned by the vendor</li>
- * <li><code>:service:</code></li>
- * <li>service type suffix:</li>
- * <li>integer service version</li>
- * </ul>
- * Example: <code>urn:domain-name:service:serviceType:v</code>.
- *
- * @return The service type suffix defined by a UPnP Forum working committee
- * or specified by a UPnP vendor. Must be <= 64 characters, not
- * including the version suffix and separating colon. Single URI.
- */
- String getType();
-
- /**
- * Returns the version suffix encoded in the <code>serviceType</code> field in
- * the UPnP service description.
- *
- * @return The integer service version defined by a UPnP Forum working
- * committee or specified by a UPnP vendor.
- */
- String getVersion();
-
- /**
- * Locates a specific action by name.
- *
- * Looks up an action by its name.
- *
- * @param name Name of action. Must not contain hyphen or hash characters.
- * Should be < 32 characters.
- *
- * @return The requested action or <code>null</code> if no action is found.
- */
- UPnPAction getAction(String name);
-
- /**
- * Lists all actions provided by this service.
- *
- * @return Array of actions (<code>UPnPAction[]</code> )or <code>null</code> if
- * no actions are defined for this service.
- */
- UPnPAction[] getActions();
-
- /**
- * Lists all <code>UPnPStateVariable</code> objects provided by this service.
- *
- * @return Array of state variables or <code>null</code> if none are defined
- * for this service.
- */
- UPnPStateVariable[] getStateVariables();
-
- /**
- * Gets a <code>UPnPStateVariable</code> objects provided by this service by
- * name
- *
- * @param name Name of the State Variable
- *
- * @return State variable or <code>null</code> if no such state variable
- * exists for this service.
- */
- UPnPStateVariable getStateVariable(String name);
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/upnp/UPnPStateVariable.java b/org.osgi.compendium/src/main/java/org/osgi/service/upnp/UPnPStateVariable.java
deleted file mode 100644
index 27b7241..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/upnp/UPnPStateVariable.java
+++ /dev/null
@@ -1,342 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2002, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.service.upnp;
-
-/**
- * The meta-information of a UPnP state variable as declared in the device's
- * service state table (SST).
- * <p>
- * Method calls to interact with a device (e.g.
- * <code>UPnPAction.invoke(...);</code>) use this class to encapsulate meta
- * information about the input and output arguments.
- * <p>
- * The actual values of the arguments are passed as Java objects. The mapping of
- * types from UPnP data types to Java data types is described with the field
- * definitions.
- *
- * @version $Revision: 5673 $
- */
-public interface UPnPStateVariable {
- /**
- * Unsigned 1 <code>Byte</code> int.
- * <p>
- * Mapped to an <code>Integer</code> object.
- */
- static final String TYPE_UI1 = "ui1";
- /**
- * Unsigned 2 Byte int.
- * <p>
- * Mapped to <code>Integer</code> object.
- */
- static final String TYPE_UI2 = "ui2";
- /**
- * Unsigned 4 Byte int.
- * <p>
- * Mapped to <code>Long</code> object.
- */
- static final String TYPE_UI4 = "ui4";
- /**
- * 1 Byte int.
- * <p>
- * Mapped to <code>Integer</code> object.
- */
- static final String TYPE_I1 = "i1";
- /**
- * 2 Byte int.
- * <p>
- * Mapped to <code>Integer</code> object.
- */
- static final String TYPE_I2 = "i2";
- /**
- * 4 Byte int.
- * <p>
- * Must be between -2147483648 and 2147483647
- * <p>
- * Mapped to <code>Integer</code> object.
- */
- static final String TYPE_I4 = "i4";
- /**
- * Integer number.
- * <p>
- * Mapped to <code>Integer</code> object.
- */
- static final String TYPE_INT = "int";
- /**
- * 4 Byte float.
- * <p>
- * Same format as float. Must be between 3.40282347E+38 to 1.17549435E-38.
- * <p>
- * Mapped to <code>Float</code> object.
- */
- static final String TYPE_R4 = "r4";
- /**
- * 8 Byte float.
- * <p>
- * Same format as float. Must be between -1.79769313486232E308 and
- * -4.94065645841247E-324 for negative values, and between
- * 4.94065645841247E-324 and 1.79769313486232E308 for positive values, i.e.,
- * IEEE 64-bit (8-Byte) double.
- * <p>
- * Mapped to <code>Double</code> object.
- */
- static final String TYPE_R8 = "r8";
- /**
- * Same as r8.
- * <p>
- * Mapped to <code>Double</code> object.
- */
- static final String TYPE_NUMBER = "number";
- /**
- * Same as r8 but no more than 14 digits to the left of the decimal point
- * and no more than 4 to the right.
- * <p>
- * Mapped to <code>Double</code> object.
- */
- static final String TYPE_FIXED_14_4 = "fixed.14.4";
- /**
- * Floating-point number.
- * <p>
- * Mantissa (left of the decimal) and/or exponent may have a leading sign.
- * Mantissa and/or exponent may have leading zeros. Decimal character in
- * mantissa is a period, i.e., whole digits in mantissa separated from
- * fractional digits by period. Mantissa separated from exponent by E. (No
- * currency symbol.) (No grouping of digits in the mantissa, e.g., no
- * commas.)
- * <p>
- * Mapped to <code>Float</code> object.
- */
- static final String TYPE_FLOAT = "float";
- /**
- * Unicode string.
- * <p>
- * One character long.
- * <p>
- * Mapped to <code>Character</code> object.
- */
- static final String TYPE_CHAR = "char";
- /**
- * Unicode string.
- * <p>
- * No limit on length.
- * <p>
- * Mapped to <code>String</code> object.
- */
- static final String TYPE_STRING = "string";
- /**
- * A calendar date.
- * <p>
- * Date in a subset of ISO 8601 format without time data.
- * <p>
- * See <a
- * href="http://www.w3.org/TR/xmlschema-2/#date">http://www.w3.org/TR/xmlschema-2/#date
- * </a>.
- * <p>
- * Mapped to <code>java.util.Date</code> object. Always 00:00 hours.
- */
- static final String TYPE_DATE = "date";
- /**
- * A specific instant of time.
- * <p>
- * Date in ISO 8601 format with optional time but no time zone.
- * <p>
- * See <a
- * href="http://www.w3.org/TR/xmlschema-2/#dateTime">http://www.w3.org/TR/xmlschema-2/#dateTime
- * </a>.
- * <p>
- * Mapped to <code>java.util.Date</code> object using default time zone.
- */
- static final String TYPE_DATETIME = "dateTime";
- /**
- * A specific instant of time.
- * <p>
- * Date in ISO 8601 format with optional time and optional time zone.
- * <p>
- * See <a
- * href="http://www.w3.org/TR/xmlschema-2/#dateTime">http://www.w3.org/TR/xmlschema-2/#dateTime
- * </a>.
- * <p>
- * Mapped to <code>java.util.Date</code> object adjusted to default time zone.
- */
- static final String TYPE_DATETIME_TZ = "dateTime.tz";
- /**
- * An instant of time that recurs every day.
- * <p>
- * Time in a subset of ISO 8601 format with no date and no time zone.
- * <p>
- * See <a
- * href="http://www.w3.org/TR/xmlschema-2/#dateTime">http://www.w3.org/TR/xmlschema-2/#time
- * </a>.
- * <p>
- * Mapped to <code>Long</code>. Converted to milliseconds since midnight.
- */
- static final String TYPE_TIME = "time";
- /**
- * An instant of time that recurs every day.
- * <p>
- * Time in a subset of ISO 8601 format with optional time zone but no date.
- * <p>
- * See <a
- * href="http://www.w3.org/TR/xmlschema-2/#dateTime">http://www.w3.org/TR/xmlschema-2/#time
- * </a>.
- * <p>
- * Mapped to <code>Long</code> object. Converted to milliseconds since
- * midnight and adjusted to default time zone, wrapping at 0 and
- * 24*60*60*1000.
- */
- static final String TYPE_TIME_TZ = "time.tz";
- /**
- * True or false.
- * <p>
- * Mapped to <code>Boolean</code> object.
- */
- static final String TYPE_BOOLEAN = "boolean";
- /**
- * MIME-style Base64 encoded binary BLOB.
- * <p>
- * Takes 3 Bytes, splits them into 4 parts, and maps each 6 bit piece to an
- * octet. (3 octets are encoded as 4.) No limit on size.
- * <p>
- * Mapped to <code>byte[]</code> object. The Java byte array will hold the
- * decoded content of the BLOB.
- */
- static final String TYPE_BIN_BASE64 = "bin.base64";
- /**
- * Hexadecimal digits representing octets.
- * <p>
- * Treats each nibble as a hex digit and encodes as a separate Byte. (1
- * octet is encoded as 2.) No limit on size.
- * <p>
- * Mapped to <code>byte[]</code> object. The Java byte array will hold the
- * decoded content of the BLOB.
- */
- static final String TYPE_BIN_HEX = "bin.hex";
- /**
- * Universal Resource Identifier.
- * <p>
- * Mapped to <code>String</code> object.
- */
- static final String TYPE_URI = "uri";
- /**
- * Universally Unique ID.
- * <p>
- * Hexadecimal digits representing octets. Optional embedded hyphens are
- * ignored.
- * <p>
- * Mapped to <code>String</code> object.
- */
- static final String TYPE_UUID = "uuid";
-
- /**
- * Returns the variable name.
- *
- * <ul>
- * <li>All standard variables defined by a UPnP Forum working committee
- * must not begin with <code>X_</code> nor <code>A_</code>.</li>
- * <li>All non-standard variables specified by a UPnP vendor and added to a
- * standard service must begin with <code>X_</code>.</li>
- * </ul>
- *
- * @return Name of state variable. Must not contain a hyphen character nor a
- * hash character. Should be < 32 characters.
- */
- String getName();
-
- /**
- * Returns the Java class associated with the UPnP data type of this state
- * variable.
- * <P>
- * Mapping between the UPnP data types and Java classes is performed
- * according to the schema mentioned above.
- *
- * <pre>
- *
- * Integer ui1, ui2, i1, i2, i4, int
- * Long ui4, time, time.tz
- * Float r4, float
- * Double r8, number, fixed.14.4
- * Character char
- * String string, uri, uuid
- * Date date, dateTime, dateTime.tz
- * Boolean boolean
- * byte[] bin.base64, bin.hex
- *
- * </pre>
- *
- * @return A class object corresponding to the Java type of this argument.
- */
- Class getJavaDataType();
-
- /**
- * Returns the UPnP type of this state variable. Valid types are defined as
- * constants.
- *
- * @return The UPnP data type of this state variable, as defined in above
- * constants.
- */
- String getUPnPDataType();
-
- /**
- * Returns the default value, if defined.
- *
- * @return The default value or <code>null</code> if not defined. The type of
- * the returned object can be determined by <code>getJavaDataType</code>.
- */
- Object getDefaultValue();
-
- /**
- * Returns the allowed values, if defined. Allowed values can be defined
- * only for String types.
- *
- * @return The allowed values or <code>null</code> if not defined. Should be
- * less than 32 characters.
- */
- String[] getAllowedValues();
-
- /**
- * Returns the minimum value, if defined. Minimum values can only be defined
- * for numeric types.
- *
- * @return The minimum value or <code>null</code> if not defined.
- */
- Number getMinimum();
-
- /**
- * Returns the maximum value, if defined. Maximum values can only be defined
- * for numeric types.
- *
- * @return The maximum value or <code>null</code> if not defined.
- */
- Number getMaximum();
-
- /**
- * Returns the size of an increment operation, if defined. Step sizes can be
- * defined only for numeric types.
- *
- * @return The increment size or null if not defined.
- */
- Number getStep();
-
- /**
- * Tells if this StateVariable can be used as an event source.
- *
- * If the StateVariable is eventable, an event listener service can be
- * registered to be notified when changes to the variable appear.
- *
- * @return <code>true</code> if the <code>StateVariable</code> generates events,
- * <code>false</code> otherwise.
- */
- boolean sendsEvents();
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/useradmin/Authorization.java b/org.osgi.compendium/src/main/java/org/osgi/service/useradmin/Authorization.java
deleted file mode 100644
index 94289f7..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/useradmin/Authorization.java
+++ /dev/null
@@ -1,102 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2001, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.service.useradmin;
-
-/**
- * The <code>Authorization</code> interface encapsulates an authorization context
- * on which bundles can base authorization decisions, where appropriate.
- * <p>
- * Bundles associate the privilege to access restricted resources or operations
- * with roles. Before granting access to a restricted resource or operation, a
- * bundle will check if the <code>Authorization</code> object passed to it possess
- * the required role, by calling its <code>hasRole</code> method.
- * <p>
- * Authorization contexts are instantiated by calling the
- * {@link UserAdmin#getAuthorization} method.
- *
- * <p>
- * <i>Trusting Authorization objects </i>
- * <p>
- * There are no restrictions regarding the creation of <code>Authorization</code>
- * objects. Hence, a service must only accept <code>Authorization</code> objects
- * from bundles that has been authorized to use the service using code based (or
- * Java 2) permissions.
- *
- * <p>
- * In some cases it is useful to use <code>ServicePermission</code> to do the code
- * based access control. A service basing user access control on
- * <code>Authorization</code> objects passed to it, will then require that a
- * calling bundle has the <code>ServicePermission</code> to get the service in
- * question. This is the most convenient way. The OSGi environment will do the
- * code based permission check when the calling bundle attempts to get the
- * service from the service registry.
- * <p>
- * Example: A servlet using a service on a user's behalf. The bundle with the
- * servlet must be given the <code>ServicePermission</code> to get the Http
- * Service.
- * <p>
- * However, in some cases the code based permission checks need to be more
- * fine-grained. A service might allow all bundles to get it, but require
- * certain code based permissions for some of its methods.
- * <p>
- * Example: A servlet using a service on a user's behalf, where some service
- * functionality is open to anyone, and some is restricted by code based
- * permissions. When a restricted method is called (e.g., one handing over an
- * <code>Authorization</code> object), the service explicitly checks that the
- * calling bundle has permission to make the call.
- *
- * @version $Revision: 5673 $
- */
-public interface Authorization {
- /**
- * Gets the name of the {@link User} that this <code>Authorization</code>
- * context was created for.
- *
- * @return The name of the {@link User} object that this
- * <code>Authorization</code> context was created for, or
- * <code>null</code> if no user was specified when this
- * <code>Authorization</code> context was created.
- */
- public String getName();
-
- /**
- * Checks if the role with the specified name is implied by this
- * <code>Authorization</code> context.
- * <p>
- *
- * Bundles must define globally unique role names that are associated with
- * the privilege of accessing restricted resources or operations. Operators
- * will grant users access to these resources, by creating a {@link Group}
- * object for each role and adding {@link User} objects to it.
- *
- * @param name The name of the role to check for.
- *
- * @return <code>true</code> if this <code>Authorization</code> context implies
- * the specified role, otherwise <code>false</code>.
- */
- public boolean hasRole(String name);
-
- /**
- * Gets the names of all roles implied by this <code>Authorization</code>
- * context.
- *
- * @return The names of all roles implied by this
- * <code>Authorization</code> context, or <code>null</code> if no roles
- * are in the context. The predefined role <code>user.anyone</code>
- * will not be included in this list.
- */
- public String[] getRoles();
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/useradmin/Group.java b/org.osgi.compendium/src/main/java/org/osgi/service/useradmin/Group.java
deleted file mode 100644
index 4016a43..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/useradmin/Group.java
+++ /dev/null
@@ -1,158 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2001, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.service.useradmin;
-
-/**
- * A named grouping of roles (<code>Role</code> objects).
- * <p>
- * Whether or not a given <code>Authorization</code> context implies a
- * <code>Group</code> object depends on the members of that <code>Group</code>
- * object.
- * <p>
- * A <code>Group</code> object can have two kinds of members: <i>basic </i> and
- * <i>required </i>. A <code>Group</code> object is implied by an
- * <code>Authorization</code> context if all of its required members are implied
- * and at least one of its basic members is implied.
- * <p>
- * A <code>Group</code> object must contain at least one basic member in order to
- * be implied. In other words, a <code>Group</code> object without any basic
- * member roles is never implied by any <code>Authorization</code> context.
- * <p>
- * A <code>User</code> object always implies itself.
- * <p>
- * No loop detection is performed when adding members to <code>Group</code>
- * objects, which means that it is possible to create circular implications.
- * Loop detection is instead done when roles are checked. The semantics is that
- * if a role depends on itself (i.e., there is an implication loop), the role is
- * not implied.
- * <p>
- * The rule that a <code>Group</code> object must have at least one basic member
- * to be implied is motivated by the following example:
- *
- * <pre>
- *
- * group foo
- * required members: marketing
- * basic members: alice, bob
- *
- * </pre>
- *
- * Privileged operations that require membership in "foo" can be performed only
- * by "alice" and "bob", who are in marketing.
- * <p>
- * If "alice" and "bob" ever transfer to a different department, anybody in
- * marketing will be able to assume the "foo" role, which certainly must be
- * prevented. Requiring that "foo" (or any <code>Group</code> object for that
- * matter) must have at least one basic member accomplishes that.
- * <p>
- * However, this would make it impossible for a <code>Group</code> object to be
- * implied by just its required members. An example where this implication might
- * be useful is the following declaration: "Any citizen who is an adult is
- * allowed to vote." An intuitive configuration of "voter" would be:
- *
- * <pre>
- *
- * group voter
- * required members: citizen, adult
- * basic members:
- *
- * </pre>
- *
- * However, according to the above rule, the "voter" role could never be assumed
- * by anybody, since it lacks any basic members. In order to address this issue
- * a predefined role named "user.anyone" can be specified, which is always
- * implied. The desired implication of the "voter" group can then be achieved by
- * specifying "user.anyone" as its basic member, as follows:
- *
- * <pre>
- *
- * group voter
- * required members: citizen, adult
- * basic members: user.anyone
- *
- * </pre>
- *
- * @version $Revision: 5673 $
- */
-public interface Group extends User {
- /**
- * Adds the specified <code>Role</code> object as a basic member to this
- * <code>Group</code> object.
- *
- * @param role The role to add as a basic member.
- *
- * @return <code>true</code> if the given role could be added as a basic
- * member, and <code>false</code> if this <code>Group</code> object
- * already contains a <code>Role</code> object whose name matches that
- * of the specified role.
- *
- * @throws SecurityException If a security manager exists and the caller
- * does not have the <code>UserAdminPermission</code> with name
- * <code>admin</code>.
- */
- public boolean addMember(Role role);
-
- /**
- * Adds the specified <code>Role</code> object as a required member to this
- * <code>Group</code> object.
- *
- * @param role The <code>Role</code> object to add as a required member.
- *
- * @return <code>true</code> if the given <code>Role</code> object could be
- * added as a required member, and <code>false</code> if this
- * <code>Group</code> object already contains a <code>Role</code> object
- * whose name matches that of the specified role.
- *
- * @throws SecurityException If a security manager exists and the caller
- * does not have the <code>UserAdminPermission</code> with name
- * <code>admin</code>.
- */
- public boolean addRequiredMember(Role role);
-
- /**
- * Removes the specified <code>Role</code> object from this <code>Group</code>
- * object.
- *
- * @param role The <code>Role</code> object to remove from this <code>Group</code>
- * object.
- *
- * @return <code>true</code> if the <code>Role</code> object could be removed,
- * otherwise <code>false</code>.
- *
- * @throws SecurityException If a security manager exists and the caller
- * does not have the <code>UserAdminPermission</code> with name
- * <code>admin</code>.
- */
- public boolean removeMember(Role role);
-
- /**
- * Gets the basic members of this <code>Group</code> object.
- *
- * @return The basic members of this <code>Group</code> object, or
- * <code>null</code> if this <code>Group</code> object does not contain
- * any basic members.
- */
- public Role[] getMembers();
-
- /**
- * Gets the required members of this <code>Group</code> object.
- *
- * @return The required members of this <code>Group</code> object, or
- * <code>null</code> if this <code>Group</code> object does not contain
- * any required members.
- */
- public Role[] getRequiredMembers();
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/useradmin/Role.java b/org.osgi.compendium/src/main/java/org/osgi/service/useradmin/Role.java
deleted file mode 100644
index e33d559..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/useradmin/Role.java
+++ /dev/null
@@ -1,117 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2001, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.service.useradmin;
-
-import java.util.Dictionary;
-
-/**
- * The base interface for <code>Role</code> objects managed by the User Admin
- * service.
- *
- * <p>
- * This interface exposes the characteristics shared by all <code>Role</code>
- * classes: a name, a type, and a set of properties.
- * <p>
- * Properties represent public information about the <code>Role</code> object that
- * can be read by anyone. Specific {@link UserAdminPermission} objects are
- * required to change a <code>Role</code> object's properties.
- * <p>
- * <code>Role</code> object properties are <code>Dictionary</code> objects. Changes
- * to these objects are propagated to the User Admin service and made
- * persistent.
- * <p>
- * Every User Admin service contains a set of predefined <code>Role</code> objects
- * that are always present and cannot be removed. All predefined <code>Role</code>
- * objects are of type <code>ROLE</code>. This version of the
- * <code>org.osgi.service.useradmin</code> package defines a single predefined
- * role named "user.anyone", which is inherited by any other role.
- * Other predefined roles may be added in the future. Since
- * "user.anyone" is a <code>Role</code> object that has properties
- * associated with it that can be read and modified. Access to these properties
- * and their use is application specific and is controlled using
- * <code>UserAdminPermission</code> in the same way that properties for other
- * <code>Role</code> objects are.
- *
- * @version $Revision: 5673 $
- */
-public interface Role {
- /**
- * The name of the predefined role, user.anyone, that all users and groups
- * belong to.
- * @since 1.1
- */
- public static final String USER_ANYONE = "user.anyone";
- /**
- * The type of a predefined role.
- *
- * <p>
- * The value of <code>ROLE</code> is 0.
- */
- public static final int ROLE = 0;
- /**
- * The type of a {@link User} role.
- *
- * <p>
- * The value of <code>USER</code> is 1.
- */
- public static final int USER = 1;
- /**
- * The type of a {@link Group} role.
- *
- * <p>
- * The value of <code>GROUP</code> is 2.
- */
- public static final int GROUP = 2;
-
- /**
- * Returns the name of this role.
- *
- * @return The role's name.
- */
- public String getName();
-
- /**
- * Returns the type of this role.
- *
- * @return The role's type.
- */
- public int getType();
-
- /**
- * Returns a <code>Dictionary</code> of the (public) properties of this
- * <code>Role</code> object. Any changes to the returned <code>Dictionary</code>
- * will change the properties of this <code>Role</code> object. This will
- * cause a <code>UserAdminEvent</code> object of type
- * {@link UserAdminEvent#ROLE_CHANGED} to be broadcast to any
- * <code>UserAdminListener</code> objects.
- *
- * <p>
- * Only objects of type <code>String</code> may be used as property keys, and
- * only objects of type <code>String</code> or <code>byte[]</code> may be used
- * as property values. Any other types will cause an exception of type
- * <code>IllegalArgumentException</code> to be raised.
- *
- * <p>
- * In order to add, change, or remove a property in the returned
- * <code>Dictionary</code>, a {@link UserAdminPermission} named after the
- * property name (or a prefix of it) with action <code>changeProperty</code>
- * is required.
- *
- * @return <code>Dictionary</code> containing the properties of this
- * <code>Role</code> object.
- */
- public Dictionary getProperties();
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/useradmin/User.java b/org.osgi.compendium/src/main/java/org/osgi/service/useradmin/User.java
deleted file mode 100644
index b9103fd..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/useradmin/User.java
+++ /dev/null
@@ -1,94 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2001, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.service.useradmin;
-
-import java.util.Dictionary;
-
-/**
- * A <code>User</code> role managed by a User Admin service.
- *
- * <p>
- * In this context, the term "user" is not limited to just human
- * beings. Instead, it refers to any entity that may have any number of
- * credentials associated with it that it may use to authenticate itself.
- * <p>
- * In general, <code>User</code> objects are associated with a specific User Admin
- * service (namely the one that created them), and cannot be used with other
- * User Admin services.
- * <p>
- * A <code>User</code> object may have credentials (and properties, inherited from
- * the {@link Role} class) associated with it. Specific
- * {@link UserAdminPermission} objects are required to read or change a
- * <code>User</code> object's credentials.
- * <p>
- * Credentials are <code>Dictionary</code> objects and have semantics that are
- * similar to the properties in the <code>Role</code> class.
- *
- * @version $Revision: 5673 $
- */
-public interface User extends Role {
- /**
- * Returns a <code>Dictionary</code> of the credentials of this <code>User</code>
- * object. Any changes to the returned <code>Dictionary</code> object will
- * change the credentials of this <code>User</code> object. This will cause a
- * <code>UserAdminEvent</code> object of type
- * {@link UserAdminEvent#ROLE_CHANGED} to be broadcast to any
- * <code>UserAdminListeners</code> objects.
- *
- * <p>
- * Only objects of type <code>String</code> may be used as credential keys,
- * and only objects of type <code>String</code> or of type <code>byte[]</code>
- * may be used as credential values. Any other types will cause an exception
- * of type <code>IllegalArgumentException</code> to be raised.
- *
- * <p>
- * In order to retrieve a credential from the returned <code>Dictionary</code>
- * object, a {@link UserAdminPermission} named after the credential name (or
- * a prefix of it) with action <code>getCredential</code> is required.
- * <p>
- * In order to add or remove a credential from the returned
- * <code>Dictionary</code> object, a {@link UserAdminPermission} named after
- * the credential name (or a prefix of it) with action
- * <code>changeCredential</code> is required.
- *
- * @return <code>Dictionary</code> object containing the credentials of this
- * <code>User</code> object.
- */
- public Dictionary getCredentials();
-
- /**
- * Checks to see if this <code>User</code> object has a credential with the
- * specified <code>key</code> set to the specified <code>value</code>.
- *
- * <p>
- * If the specified credential <code>value</code> is not of type
- * <code>String</code> or <code>byte[]</code>, it is ignored, that is,
- * <code>false</code> is returned (as opposed to an
- * <code>IllegalArgumentException</code> being raised).
- *
- * @param key The credential <code>key</code>.
- * @param value The credential <code>value</code>.
- *
- * @return <code>true</code> if this user has the specified credential;
- * <code>false</code> otherwise.
- *
- * @throws SecurityException If a security manager exists and the caller
- * does not have the <code>UserAdminPermission</code> named after the
- * credential key (or a prefix of it) with action
- * <code>getCredential</code>.
- */
- public boolean hasCredential(String key, Object value);
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/useradmin/UserAdmin.java b/org.osgi.compendium/src/main/java/org/osgi/service/useradmin/UserAdmin.java
deleted file mode 100644
index 2e4b096..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/useradmin/UserAdmin.java
+++ /dev/null
@@ -1,157 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2001, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.service.useradmin;
-
-import org.osgi.framework.InvalidSyntaxException;
-
-/**
- * This interface is used to manage a database of named <code>Role</code> objects,
- * which can be used for authentication and authorization purposes.
- *
- * <p>
- * This version of the User Admin service defines two types of <code>Role</code>
- * objects: "User" and "Group". Each type of role is represented by an
- * <code>int</code> constant and an interface. The range of positive integers is
- * reserved for new types of roles that may be added in the future. When
- * defining proprietary role types, negative constant values must be used.
- *
- * <p>
- * Every role has a name and a type.
- *
- * <p>
- * A {@link User} object can be configured with credentials (e.g., a password)
- * and properties (e.g., a street address, phone number, etc.).
- * <p>
- * A {@link Group} object represents an aggregation of {@link User} and
- * {@link Group} objects. In other words, the members of a <code>Group</code>
- * object are roles themselves.
- * <p>
- * Every User Admin service manages and maintains its own namespace of
- * <code>Role</code> objects, in which each <code>Role</code> object has a unique
- * name.
- *
- * @version $Revision: 5673 $
- */
-public interface UserAdmin {
- /**
- * Creates a <code>Role</code> object with the given name and of the given
- * type.
- *
- * <p>
- * If a <code>Role</code> object was created, a <code>UserAdminEvent</code>
- * object of type {@link UserAdminEvent#ROLE_CREATED} is broadcast to any
- * <code>UserAdminListener</code> object.
- *
- * @param name The <code>name</code> of the <code>Role</code> object to create.
- * @param type The type of the <code>Role</code> object to create. Must be
- * either a {@link Role#USER} type or {@link Role#GROUP} type.
- *
- * @return The newly created <code>Role</code> object, or <code>null</code> if a
- * role with the given name already exists.
- *
- * @throws IllegalArgumentException if <code>type</code> is invalid.
- *
- * @throws SecurityException If a security manager exists and the caller
- * does not have the <code>UserAdminPermission</code> with name
- * <code>admin</code>.
- */
- public Role createRole(String name, int type);
-
- /**
- * Removes the <code>Role</code> object with the given name from this User
- * Admin service and all groups it is a member of.
- *
- * <p>
- * If the <code>Role</code> object was removed, a <code>UserAdminEvent</code>
- * object of type {@link UserAdminEvent#ROLE_REMOVED} is broadcast to any
- * <code>UserAdminListener</code> object.
- *
- * @param name The name of the <code>Role</code> object to remove.
- *
- * @return <code>true</code> If a <code>Role</code> object with the given name
- * is present in this User Admin service and could be removed,
- * otherwise <code>false</code>.
- *
- * @throws SecurityException If a security manager exists and the caller
- * does not have the <code>UserAdminPermission</code> with name
- * <code>admin</code>.
- */
- public boolean removeRole(String name);
-
- /**
- * Gets the <code>Role</code> object with the given <code>name</code> from this
- * User Admin service.
- *
- * @param name The name of the <code>Role</code> object to get.
- *
- * @return The requested <code>Role</code> object, or <code>null</code> if this
- * User Admin service does not have a <code>Role</code> object with
- * the given <code>name</code>.
- */
- public Role getRole(String name);
-
- /**
- * Gets the <code>Role</code> objects managed by this User Admin service that
- * have properties matching the specified LDAP filter criteria. See
- * <code>org.osgi.framework.Filter</code> for a description of the filter
- * syntax. If a <code>null</code> filter is specified, all Role objects
- * managed by this User Admin service are returned.
- *
- * @param filter The filter criteria to match.
- *
- * @return The <code>Role</code> objects managed by this User Admin service
- * whose properties match the specified filter criteria, or all
- * <code>Role</code> objects if a <code>null</code> filter is specified.
- * If no roles match the filter, <code>null</code> will be returned.
- * @throws InvalidSyntaxException If the filter is not well formed.
- *
- */
- public Role[] getRoles(String filter) throws InvalidSyntaxException;
-
- /**
- * Gets the user with the given property <code>key</code>-<code>value</code>
- * pair from the User Admin service database. This is a convenience method
- * for retrieving a <code>User</code> object based on a property for which
- * every <code>User</code> object is supposed to have a unique value (within
- * the scope of this User Admin service), such as for example a X.500
- * distinguished name.
- *
- * @param key The property key to look for.
- * @param value The property value to compare with.
- *
- * @return A matching user, if <em>exactly</em> one is found. If zero or
- * more than one matching users are found, <code>null</code> is
- * returned.
- */
- public User getUser(String key, String value);
-
- /**
- * Creates an <code>Authorization</code> object that encapsulates the
- * specified <code>User</code> object and the <code>Role</code> objects it
- * possesses. The <code>null</code> user is interpreted as the anonymous user.
- * The anonymous user represents a user that has not been authenticated. An
- * <code>Authorization</code> object for an anonymous user will be unnamed,
- * and will only imply groups that user.anyone implies.
- *
- * @param user The <code>User</code> object to create an
- * <code>Authorization</code> object for, or <code>null</code> for the
- * anonymous user.
- *
- * @return the <code>Authorization</code> object for the specified
- * <code>User</code> object.
- */
- public Authorization getAuthorization(User user);
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/useradmin/UserAdminEvent.java b/org.osgi.compendium/src/main/java/org/osgi/service/useradmin/UserAdminEvent.java
deleted file mode 100644
index 88ef8fb..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/useradmin/UserAdminEvent.java
+++ /dev/null
@@ -1,111 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2001, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.service.useradmin;
-
-import org.osgi.framework.ServiceReference;
-
-/**
- * <code>Role</code> change event.
- * <p>
- * <code>UserAdminEvent</code> objects are delivered asynchronously to any
- * <code>UserAdminListener</code> objects when a change occurs in any of the
- * <code>Role</code> objects managed by a User Admin service.
- *
- * <p>
- * A type code is used to identify the event. The following event types are
- * defined: {@link #ROLE_CREATED} type, {@link #ROLE_CHANGED} type, and
- * {@link #ROLE_REMOVED} type. Additional event types may be defined in the
- * future.
- *
- * @see UserAdmin
- * @see UserAdminListener
- *
- * @version $Revision: 5673 $
- */
-public class UserAdminEvent {
- private ServiceReference ref;
- private int type;
- private Role role;
- /**
- * A <code>Role</code> object has been created.
- *
- * <p>
- * The value of <code>ROLE_CREATED</code> is 0x00000001.
- */
- public static final int ROLE_CREATED = 0x00000001;
- /**
- * A <code>Role</code> object has been modified.
- *
- * <p>
- * The value of <code>ROLE_CHANGED</code> is 0x00000002.
- */
- public static final int ROLE_CHANGED = 0x00000002;
- /**
- * A <code>Role</code> object has been removed.
- *
- * <p>
- * The value of <code>ROLE_REMOVED</code> is 0x00000004.
- */
- public static final int ROLE_REMOVED = 0x00000004;
-
- /**
- * Constructs a <code>UserAdminEvent</code> object from the given
- * <code>ServiceReference</code> object, event type, and <code>Role</code>
- * object.
- *
- * @param ref The <code>ServiceReference</code> object of the User Admin
- * service that generated this event.
- * @param type The event type.
- * @param role The <code>Role</code> object on which this event occurred.
- */
- public UserAdminEvent(ServiceReference ref, int type, Role role) {
- this.ref = ref;
- this.type = type;
- this.role = role;
- }
-
- /**
- * Gets the <code>ServiceReference</code> object of the User Admin service
- * that generated this event.
- *
- * @return The User Admin service's <code>ServiceReference</code> object.
- */
- public ServiceReference getServiceReference() {
- return ref;
- }
-
- /**
- * Returns the type of this event.
- *
- * <p>
- * The type values are {@link #ROLE_CREATED} type, {@link #ROLE_CHANGED}
- * type, and {@link #ROLE_REMOVED} type.
- *
- * @return The event type.
- */
- public int getType() {
- return type;
- }
-
- /**
- * Gets the <code>Role</code> object this event was generated for.
- *
- * @return The <code>Role</code> object this event was generated for.
- */
- public Role getRole() {
- return role;
- }
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/useradmin/UserAdminListener.java b/org.osgi.compendium/src/main/java/org/osgi/service/useradmin/UserAdminListener.java
deleted file mode 100644
index a301b92..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/useradmin/UserAdminListener.java
+++ /dev/null
@@ -1,43 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2001, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.service.useradmin;
-
-/**
- * Listener for UserAdminEvents.
- *
- * <p>
- * <code>UserAdminListener</code> objects are registered with the Framework
- * service registry and notified with a <code>UserAdminEvent</code> object when a
- * <code>Role</code> object has been created, removed, or modified.
- * <p>
- * <code>UserAdminListener</code> objects can further inspect the received
- * <code>UserAdminEvent</code> object to determine its type, the <code>Role</code>
- * object it occurred on, and the User Admin service that generated it.
- *
- * @see UserAdmin
- * @see UserAdminEvent
- *
- * @version $Revision: 5673 $
- */
-public interface UserAdminListener {
- /**
- * Receives notification that a <code>Role</code> object has been created,
- * removed, or modified.
- *
- * @param event The <code>UserAdminEvent</code> object.
- */
- public void roleChanged(UserAdminEvent event);
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/useradmin/UserAdminPermission.java b/org.osgi.compendium/src/main/java/org/osgi/service/useradmin/UserAdminPermission.java
deleted file mode 100644
index 52be194..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/useradmin/UserAdminPermission.java
+++ /dev/null
@@ -1,643 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2001, 2009). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.service.useradmin;
-
-import java.io.IOException;
-import java.security.BasicPermission;
-import java.security.Permission;
-import java.security.PermissionCollection;
-import java.util.Enumeration;
-import java.util.Hashtable;
-
-/**
- * Permission to configure and access the {@link Role} objects managed by a User
- * Admin service.
- *
- * <p>
- * This class represents access to the <code>Role</code> objects managed by a
- * User Admin service and their properties and credentials (in the case of
- * {@link User} objects).
- * <p>
- * The permission name is the name (or name prefix) of a property or credential.
- * The naming convention follows the hierarchical property naming convention.
- * Also, an asterisk may appear at the end of the name, following a
- * ".", or by itself, to signify a wildcard match. For example:
- * "org.osgi.security.protocol.*" or "*" is valid, but
- * "*protocol" or "a*b" are not valid.
- *
- * <p>
- * The <code>UserAdminPermission</code> with the reserved name "admin"
- * represents the permission required for creating and removing
- * <code>Role</code> objects in the User Admin service, as well as adding and
- * removing members in a <code>Group</code> object. This
- * <code>UserAdminPermission</code> does not have any actions associated with
- * it.
- *
- * <p>
- * The actions to be granted are passed to the constructor in a string
- * containing a list of one or more comma-separated keywords. The possible
- * keywords are: <code>changeProperty</code>,<code>changeCredential</code>, and
- * <code>getCredential</code>. Their meaning is defined as follows:
- *
- * <pre>
- *
- * action
- * changeProperty Permission to change (i.e., add and remove)
- * Role object properties whose names start with
- * the name argument specified in the constructor.
- * changeCredential Permission to change (i.e., add and remove)
- * User object credentials whose names start
- * with the name argument specified in the constructor.
- * getCredential Permission to retrieve and check for the
- * existence of User object credentials whose names
- * start with the name argument specified in the
- * constructor.
- *
- * </pre>
- *
- * The action string is converted to lowercase before processing.
- *
- * <p>
- * Following is a PermissionInfo style policy entry which grants a user
- * administration bundle a number of <code>UserAdminPermission</code> object:
- *
- * <pre>
- *
- * (org.osgi.service.useradmin.UserAdminPermission "admin")
- * (org.osgi.service.useradmin.UserAdminPermission "com.foo.*" "changeProperty,getCredential,changeCredential")
- * (org.osgi.service.useradmin.UserAdminPermission "user.*", "changeProperty,changeCredential")
- *
- * </pre>
- *
- * The first permission statement grants the bundle the permission to perform
- * any User Admin service operations of type "admin", that is, create and remove
- * roles and configure <code>Group</code> objects.
- *
- * <p>
- * The second permission statement grants the bundle the permission to change
- * any properties as well as get and change any credentials whose names start
- * with <code>com.foo.</code>.
- *
- * <p>
- * The third permission statement grants the bundle the permission to change any
- * properties and credentials whose names start with <code>user.</code>. This
- * means that the bundle is allowed to change, but not retrieve any credentials
- * with the given prefix.
- *
- * <p>
- * The following policy entry empowers the Http Service bundle to perform user
- * authentication:
- *
- * <pre>
- *
- * grant codeBase "${jars}http.jar" {
- * permission org.osgi.service.useradmin.UserAdminPermission
- * "user.password", "getCredential";
- * };
- *
- * </pre>
- *
- * <p>
- * The permission statement grants the Http Service bundle the permission to
- * validate any password credentials (for authentication purposes), but the
- * bundle is not allowed to change any properties or credentials.
- *
- * @ThreadSafe
- * @version $Revision: 6381 $
- */
-public final class UserAdminPermission extends BasicPermission {
- static final long serialVersionUID = -1179971692401603789L;
- /**
- * The permission name "admin".
- */
- public static final String ADMIN = "admin";
- /**
- * The action string "changeProperty".
- */
- public static final String CHANGE_PROPERTY = "changeProperty";
- private static final int ACTION_CHANGE_PROPERTY = 0x1;
- /**
- * The action string "changeCredential".
- */
- public static final String CHANGE_CREDENTIAL = "changeCredential";
- private static final int ACTION_CHANGE_CREDENTIAL = 0x2;
- /**
- * The action string "getCredential".
- */
- public static final String GET_CREDENTIAL = "getCredential";
- private static final int ACTION_GET_CREDENTIAL = 0x4;
- /**
- * All actions
- */
- private static final int ACTION_ALL = ACTION_CHANGE_PROPERTY
- | ACTION_CHANGE_CREDENTIAL
- | ACTION_GET_CREDENTIAL;
- /**
- * No actions.
- */
- static final int ACTION_NONE = 0;
- /**
- * The actions in canonical form.
- *
- * @serial
- */
- private volatile String actions = null;
- /**
- * The actions mask.
- */
- private transient int action_mask;
-
- /**
- * Creates a new <code>UserAdminPermission</code> with the specified name
- * and actions. <code>name</code> is either the reserved string
- * "admin" or the name of a credential or property, and
- * <code>actions</code> contains a comma-separated list of the actions
- * granted on the specified name. Valid actions are
- * <code>changeProperty</code>,<code>changeCredential</code>, and
- * getCredential.
- *
- * @param name the name of this <code>UserAdminPermission</code>
- * @param actions the action string.
- *
- * @throws IllegalArgumentException If <code>name</code> equals
- * "admin" and <code>actions</code> are specified.
- */
- public UserAdminPermission(String name, String actions) {
- this(name, parseActions(actions));
- }
-
- /**
- * Package private constructor used by
- * <code>UserAdminPermissionCollection</code>.
- *
- * @param name class name
- * @param mask action mask
- */
- UserAdminPermission(String name, int mask) {
- super(name);
- setTransients(mask);
- }
-
- /**
- * Called by constructors and when deserialized.
- *
- * @param mask action mask
- */
- private synchronized void setTransients(int mask) {
- if (getName().equals(ADMIN)) {
- if (mask != ACTION_NONE) {
- throw new IllegalArgumentException("Actions specified for "
- + "no-action " + "UserAdminPermission");
- }
- }
- else {
- if ((mask == ACTION_NONE) || ((mask & ACTION_ALL) != mask)) {
- throw new IllegalArgumentException("Invalid action string");
- }
- }
- action_mask = mask;
- }
-
- /**
- * Returns the current action mask.
- * <p>
- * Used by the UserAdminPermissionCollection class.
- *
- * @return Current action mask.
- */
- synchronized int getActionsMask() {
- return action_mask;
- }
-
- /**
- * Parse action string into action mask.
- *
- * @param actions Action string.
- * @return action mask.
- */
- private static int parseActions(String actions) {
- boolean seencomma = false;
- int mask = ACTION_NONE;
- if (actions == null) {
- return mask;
- }
- char[] a = actions.toCharArray();
- int i = a.length - 1;
- if (i < 0)
- return mask;
- while (i != -1) {
- char c;
- // skip whitespace
- while ((i != -1)
- && ((c = a[i]) == ' ' || c == '\r' || c == '\n'
- || c == '\f' || c == '\t'))
- i--;
- // check for the known strings
- int matchlen;
- if (i >= 12 && match_get(a, i - 10) && match_credential(a, i)) {
- matchlen = 13;
- mask |= ACTION_GET_CREDENTIAL;
- }
- else
- if (i >= 13 && match_change(a, i - 8) && match_property(a, i)) {
- matchlen = 14;
- mask |= ACTION_CHANGE_PROPERTY;
- }
- else
- if (i >= 15 && match_change(a, i - 10)
- && match_credential(a, i)) {
- matchlen = 16;
- mask |= ACTION_CHANGE_CREDENTIAL;
- }
- else {
- // parse error
- throw new IllegalArgumentException(
- "invalid permission: " + actions);
- }
- // make sure we didn't just match the tail of a word
- // like "ackbarfimport". Also, skip to the comma.
- seencomma = false;
- while (i >= matchlen && !seencomma) {
- switch (a[i - matchlen]) {
- case ',' :
- seencomma = true;
- /* FALLTHROUGH */
- case ' ' :
- case '\r' :
- case '\n' :
- case '\f' :
- case '\t' :
- break;
- default :
- throw new IllegalArgumentException(
- "invalid permission: " + actions);
- }
- i--;
- }
- // point i at the location of the comma minus one (or -1).
- i -= matchlen;
- }
- if (seencomma) {
- throw new IllegalArgumentException("invalid permission: " + actions);
- }
- return mask;
- }
-
- private static boolean match_change(char[] a, int i) {
- return ((a[i - 5] == 'c' || a[i - 5] == 'C')
- && (a[i - 4] == 'h' || a[i - 4] == 'H')
- && (a[i - 3] == 'a' || a[i - 3] == 'A')
- && (a[i - 2] == 'n' || a[i - 2] == 'N')
- && (a[i - 1] == 'g' || a[i - 1] == 'G') && (a[i - 0] == 'e' || a[i - 0] == 'E'));
- }
-
- private static boolean match_get(char[] a, int i) {
- return ((a[i - 2] == 'g' || a[i - 2] == 'G')
- && (a[i - 1] == 'e' || a[i - 1] == 'E') && (a[i - 0] == 't' || a[i - 0] == 'T'));
- }
-
- private static boolean match_property(char[] a, int i) {
- return ((a[i - 7] == 'p' || a[i - 7] == 'P')
- && (a[i - 6] == 'r' || a[i - 6] == 'R')
- && (a[i - 5] == 'o' || a[i - 5] == 'O')
- && (a[i - 4] == 'p' || a[i - 4] == 'P')
- && (a[i - 3] == 'e' || a[i - 3] == 'E')
- && (a[i - 2] == 'r' || a[i - 2] == 'R')
- && (a[i - 1] == 't' || a[i - 1] == 'T') && (a[i - 0] == 'y' || a[i - 0] == 'Y'));
- }
-
- private static boolean match_credential(char[] a, int i) {
- return ((a[i - 9] == 'c' || a[i - 9] == 'C')
- && (a[i - 8] == 'r' || a[i - 8] == 'R')
- && (a[i - 7] == 'e' || a[i - 7] == 'E')
- && (a[i - 6] == 'd' || a[i - 6] == 'D')
- && (a[i - 5] == 'e' || a[i - 5] == 'E')
- && (a[i - 4] == 'n' || a[i - 4] == 'N')
- && (a[i - 3] == 't' || a[i - 3] == 'T')
- && (a[i - 2] == 'i' || a[i - 2] == 'I')
- && (a[i - 1] == 'a' || a[i - 1] == 'A') && (a[i - 0] == 'l' || a[i - 0] == 'L'));
- }
-
- /**
- * Checks if this <code>UserAdminPermission</code> object
- * "implies" the specified permission.
- * <P>
- * More specifically, this method returns <code>true</code> if:
- * <p>
- * <ul>
- * <li><i>p </i> is an instanceof <code>UserAdminPermission</code>,
- * <li><i>p </i>'s actions are a proper subset of this object's actions, and
- * <li><i>p </i>'s name is implied by this object's name. For example,
- * "java.*" implies "java.home".
- * </ul>
- *
- * @param p the permission to check against.
- *
- * @return <code>true</code> if the specified permission is implied by this
- * object; <code>false</code> otherwise.
- */
- public boolean implies(Permission p) {
- if (p instanceof UserAdminPermission) {
- UserAdminPermission requested = (UserAdminPermission) p;
- int mask = getActionsMask();
- int targetMask = requested.getActionsMask();
- return // Check that the we have the requested action
- ((targetMask & mask) == targetMask) &&
- // If the target action mask is ACTION_NONE, it must be an
- // admin permission, and then we must be that too
- (targetMask != ACTION_NONE || mask == ACTION_NONE) &&
- // Check that name name matches
- super.implies(p);
- }
- return false;
- }
-
- /**
- * Returns the canonical string representation of the actions, separated by
- * comma.
- *
- * @return the canonical string representation of the actions.
- */
- public String getActions() {
- String result = actions;
- if (result == null) {
- StringBuffer sb = new StringBuffer();
- boolean comma = false;
- int mask = getActionsMask();
- if ((mask & ACTION_CHANGE_CREDENTIAL) == ACTION_CHANGE_CREDENTIAL) {
- sb.append(CHANGE_CREDENTIAL);
- comma = true;
- }
- if ((mask & ACTION_CHANGE_PROPERTY) == ACTION_CHANGE_PROPERTY) {
- if (comma)
- sb.append(',');
- sb.append(CHANGE_PROPERTY);
- comma = true;
- }
- if ((mask & ACTION_GET_CREDENTIAL) == ACTION_GET_CREDENTIAL) {
- if (comma)
- sb.append(',');
- sb.append(GET_CREDENTIAL);
- }
- actions = result = sb.toString();
- }
- return result;
- }
-
- /**
- * Returns a new <code>PermissionCollection</code> object for storing
- * <code>UserAdminPermission</code> objects.
- *
- * @return a new <code>PermissionCollection</code> object suitable for
- * storing <code>UserAdminPermission</code> objects.
- */
- public PermissionCollection newPermissionCollection() {
- return new UserAdminPermissionCollection();
- }
-
- /**
- * Checks two <code>UserAdminPermission</code> objects for equality. Checks
- * that <code>obj</code> is a <code>UserAdminPermission</code>, and has the
- * same name and actions as this object.
- *
- * @param obj the object to be compared for equality with this object.
- *
- * @return <code>true</code> if <code>obj</code> is a
- * <code>UserAdminPermission</code> object, and has the same name
- * and actions as this <code>UserAdminPermission</code> object.
- */
- public boolean equals(Object obj) {
- if (obj == this) {
- return true;
- }
- if (!(obj instanceof UserAdminPermission)) {
- return false;
- }
-
- UserAdminPermission uap = (UserAdminPermission) obj;
-
- return (getActionsMask() == uap.getActionsMask())
- && getName().equals(uap.getName());
- }
-
- /**
- * Returns the hash code value for this object.
- *
- * @return A hash code value for this object.
- */
- public int hashCode() {
- int h = 31 * 17 + getName().hashCode();
- h = 31 * h + getActions().hashCode();
- return h;
- }
-
- /**
- * writeObject is called to save the state of this object to a stream. The
- * actions are serialized, and the superclass takes care of the name.
- */
- private synchronized void writeObject(java.io.ObjectOutputStream s)
- throws IOException {
- // Write out the actions. The superclass takes care of the name
- // call getActions to make sure actions field is initialized
- if (actions == null)
- getActions();
- s.defaultWriteObject();
- }
-
- /*
- * Restores this object from a stream (i.e., deserializes it).
- */
- private synchronized void readObject(java.io.ObjectInputStream s)
- throws IOException, ClassNotFoundException {
- // Read in the action, then initialize the rest
- s.defaultReadObject();
- setTransients(parseActions(actions));
- }
-
- /**
- * Returns a string describing this <code>UserAdminPermission</code> object.
- * This string must be in <code>PermissionInfo</code> encoded format.
- *
- * @return The <code>PermissionInfo</code> encoded string for this
- * <code>UserAdminPermission</code> object.
- * @see "<code>org.osgi.service.permissionadmin.PermissionInfo.getEncoded</code>"
- */
- public String toString() {
- StringBuffer sb = new StringBuffer();
- sb.append('(');
- sb.append(getClass().getName());
- sb.append(" \"");
- sb.append(getName());
- String a = getActions();
- if (a.length() > 0) {
- sb.append("\" \"");
- sb.append(a);
- }
- sb.append("\")");
- return sb.toString();
- }
-}
-
-/**
- * A <code>UserAdminPermissionCollection</code> stores a set of
- * <code>UserAdminPermission</code> permissions.
- */
-
-final class UserAdminPermissionCollection extends PermissionCollection {
- static final long serialVersionUID = -7222111885230120581L;
- /**
- * Table of permissions.
- *
- * @serial
- * @GuardedBy this
- */
- private final Hashtable permissions;
- /**
- * Boolean saying if "*" is in the collection.
- *
- * @serial
- * @GuardedBy this
- */
- private boolean all_allowed;
-
- /**
- * Creates an empty <code>UserAdminPermissionCollection</code> object.
- */
- public UserAdminPermissionCollection() {
- permissions = new Hashtable();
- all_allowed = false;
- }
-
- /**
- * Adds the given permission to this
- * <code>UserAdminPermissionCollection</code>. The key for the hash is the
- * name.
- *
- * @param permission the <code>Permission</code> object to add.
- *
- * @throws IllegalArgumentException If the given permission is not a
- * <code>UserAdminPermission</code>
- * @throws SecurityException If this
- * <code>UserAdminPermissionCollection</code> object has been marked
- * readonly
- */
- public void add(Permission permission) {
- if (!(permission instanceof UserAdminPermission))
- throw new IllegalArgumentException("Invalid permission: "
- + permission);
- if (isReadOnly()) {
- throw new SecurityException("Attempt to add a Permission to a "
- + "readonly PermissionCollection");
- }
- final UserAdminPermission uap = (UserAdminPermission) permission;
- final String name = uap.getName();
- synchronized (this) {
- final UserAdminPermission existing = (UserAdminPermission) permissions
- .get(name);
- if (existing != null) {
- int oldMask = existing.getActionsMask();
- int newMask = uap.getActionsMask();
- if (oldMask != newMask) {
- permissions.put(name, new UserAdminPermission(name, oldMask
- | newMask));
- }
- }
- else {
- permissions.put(name, uap);
- }
- if (!all_allowed) {
- if (name.equals("*")) {
- all_allowed = true;
- }
- }
- }
- }
-
- /**
- * Checks to see if this <code>PermissionCollection</code> implies the given
- * permission.
- *
- * @param permission the <code>Permission</code> object to check against
- *
- * @return true if the given permission is implied by this
- * <code>PermissionCollection</code>, false otherwise.
- */
- public boolean implies(Permission permission) {
- if (!(permission instanceof UserAdminPermission)) {
- return false;
- }
- final UserAdminPermission requested = (UserAdminPermission) permission;
- String name = requested.getName();
- final int desired = requested.getActionsMask();
- UserAdminPermission x;
- int effective = 0;
- synchronized (this) {
- // Short circuit if the "*" Permission was added.
- // desired can only be ACTION_NONE when name is "admin".
- if (all_allowed && (desired != UserAdminPermission.ACTION_NONE)) {
- x = (UserAdminPermission) permissions.get("*");
- if (x != null) {
- effective |= x.getActionsMask();
- if ((effective & desired) == desired) {
- return true;
- }
- }
- }
- // strategy:
- // Check for full match first. Then work our way up the
- // name looking for matches on a.b.*
-
- x = (UserAdminPermission) permissions.get(name);
- }
- if (x != null) {
- // we have a direct hit!
- effective |= x.getActionsMask();
- if ((effective & desired) == desired) {
- return true;
- }
- }
- // work our way up the tree...
- int last;
- int offset = name.length() - 1;
- while ((last = name.lastIndexOf(".", offset)) != -1) {
- name = name.substring(0, last + 1) + "*";
- synchronized (this) {
- x = (UserAdminPermission) permissions.get(name);
- }
- if (x != null) {
- effective |= x.getActionsMask();
- if ((effective & desired) == desired) {
- return true;
- }
- }
- offset = last - 1;
- }
- // we don't have to check for "*" as it was already checked
- // at the top (all_allowed), so we just return false
- return false;
- }
-
- /**
- * Returns an enumeration of all the <code>UserAdminPermission</code>
- * objects in the container.
- *
- * @return an enumeration of all the <code>UserAdminPermission</code>
- * objects.
- */
- public Enumeration elements() {
- return permissions.elements();
- }
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/wireadmin/BasicEnvelope.java b/org.osgi.compendium/src/main/java/org/osgi/service/wireadmin/BasicEnvelope.java
deleted file mode 100644
index 49df68a..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/wireadmin/BasicEnvelope.java
+++ /dev/null
@@ -1,64 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2002, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.service.wireadmin;
-
-/**
- * <code>BasicEnvelope</code> is an implementation of the {@link Envelope}
- * interface
- *
- * @version $Revision: 5673 $
- */
-public class BasicEnvelope implements Envelope {
- Object value;
- Object identification;
- String scope;
-
- /**
- * Constructor.
- *
- * @param value Content of this envelope, may be <code>null</code>.
- * @param identification Identifying object for this <code>Envelope</code>
- * object, must not be <code>null</code>
- * @param scope Scope name for this object, must not be <code>null</code>
- * @see Envelope
- */
- public BasicEnvelope(Object value, Object identification, String scope) {
- this.value = value;
- this.identification = identification;
- this.scope = scope;
- }
-
- /**
- * @see org.osgi.service.wireadmin.Envelope#getValue()
- */
- public Object getValue() {
- return value;
- }
-
- /**
- * @see org.osgi.service.wireadmin.Envelope#getIdentification()
- */
- public Object getIdentification() {
- return identification;
- }
-
- /**
- * @see org.osgi.service.wireadmin.Envelope#getScope()
- */
- public String getScope() {
- return scope;
- }
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/wireadmin/Consumer.java b/org.osgi.compendium/src/main/java/org/osgi/service/wireadmin/Consumer.java
deleted file mode 100644
index cef1c1c..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/wireadmin/Consumer.java
+++ /dev/null
@@ -1,101 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2002, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.service.wireadmin;
-
-/**
- * Data Consumer, a service that can receive udpated values from
- * {@link Producer} services.
- *
- * <p>
- * Service objects registered under the <code>Consumer</code> interface are
- * expected to consume values from a Producer service via a <code>Wire</code>
- * object. A Consumer service may poll the Producer service by calling the
- * {@link Wire#poll} method. The Consumer service will also receive an updated
- * value when called at it's {@link #updated} method. The Producer service
- * should have coerced the value to be an instance of one of the types specified
- * by the {@link Wire#getFlavors} method, or one of their subclasses.
- *
- * <p>
- * Consumer service objects must register with a <code>service.pid</code> and a
- * {@link WireConstants#WIREADMIN_CONSUMER_FLAVORS} property. It is recommended
- * that Consumer service objects also register with a
- * <code>service.description</code> property.
- *
- * <p>
- * If an <code>Exception</code> is thrown by any of the <code>Consumer</code>
- * methods, a <code>WireAdminEvent</code> of type
- * {@link WireAdminEvent#CONSUMER_EXCEPTION} is broadcast by the Wire Admin
- * service.
- *
- * <p>
- * Security Considerations - Data consuming bundles will require
- * <code>ServicePermission[Consumer,REGISTER]</code>. In general, only the Wire
- * Admin service bundle should have this permission. Thus only the Wire Admin
- * service may directly call a Consumer service. Care must be taken in the
- * sharing of <code>Wire</code> objects with other bundles.
- * <p>
- * Consumer services must be registered with their scope when they can receive
- * different types of objects from the Producer service. The Consumer service
- * should have <code>WirePermission</code> for each of these scope names.
- *
- * @version $Revision: 5673 $
- */
-public interface Consumer {
- /**
- * Update the value. This Consumer service is called by the <code>Wire</code>
- * object with an updated value from the Producer service.
- *
- * <p>
- * Note: This method may be called by a <code>Wire</code> object prior to this
- * object being notified that it is connected to that <code>Wire</code> object
- * (via the {@link #producersConnected} method).
- * <p>
- * When the Consumer service can receive <code>Envelope</code> objects, it
- * must have registered all scope names together with the service object,
- * and each of those names must be permitted by the bundle's
- * <code>WirePermission</code>. If an <code>Envelope</code> object is delivered
- * with the <code>updated</code> method, then the Consumer service should
- * assume that the security check has been performed.
- *
- * @param wire The <code>Wire</code> object which is delivering the updated
- * value.
- * @param value The updated value. The value should be an instance of one of
- * the types specified by the {@link Wire#getFlavors} method.
- */
- public void updated(Wire wire, Object value);
-
- /**
- * Update the list of <code>Wire</code> objects to which this Consumer service
- * is connected.
- *
- * <p>
- * This method is called when the Consumer service is first registered and
- * subsequently whenever a <code>Wire</code> associated with this Consumer
- * service becomes connected, is modified or becomes disconnected.
- *
- * <p>
- * The Wire Admin service must call this method asynchronously. This implies
- * that implementors of Consumer can be assured that the callback will not
- * take place during registration when they execute the registration in a
- * synchronized method.
- *
- * @param wires An array of the current and complete list of <code>Wire</code>
- * objects to which this Consumer service is connected. May be
- * <code>null</code> if the Consumer service is not currently connected
- * to any <code>Wire</code> objects.
- */
- public void producersConnected(Wire[] wires);
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/wireadmin/Envelope.java b/org.osgi.compendium/src/main/java/org/osgi/service/wireadmin/Envelope.java
deleted file mode 100644
index 5f57638..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/wireadmin/Envelope.java
+++ /dev/null
@@ -1,79 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2002, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.service.wireadmin;
-
-/**
- * Identifies a contained value.
- *
- * An <code>Envelope</code> object combines a status value, an identification
- * object and a scope name. The <code>Envelope</code> object allows the use of
- * standard Java types when a Producer service can produce more than one kind of
- * object. The <code>Envelope</code> object allows the Consumer service to
- * recognize the kind of object that is received. For example, a door lock could
- * be represented by a <code>Boolean</code> object. If the <code>Producer</code>
- * service would send such a <code>Boolean</code> object, then the Consumer
- * service would not know what door the <code>Boolean</code> object represented.
- * The <code>Envelope</code> object contains an identification object so the
- * Consumer service can discriminate between different kinds of values. The
- * identification object may be a simple <code>String</code> object, but it can
- * also be a domain specific object that is mutually agreed by the Producer and
- * the Consumer service. This object can then contain relevant information that
- * makes the identification easier.
- * <p>
- * The scope name of the envelope is used for security. The Wire object must
- * verify that any <code>Envelope</code> object send through the <code>update</code>
- * method or coming from the <code>poll</code> method has a scope name that
- * matches the permissions of both the Producer service and the Consumer service
- * involved. The wireadmin package also contains a class <code>BasicEnvelope</code>
- * that implements the methods of this interface.
- *
- * @see WirePermission
- * @see BasicEnvelope
- *
- * @version $Revision: 5673 $
- */
-public interface Envelope {
- /**
- * Return the value associated with this <code>Envelope</code> object.
- *
- * @return the value of the status item, or <code>null</code> when no item is
- * associated with this object.
- */
- public Object getValue();
-
- /**
- * Return the identification of this <code>Envelope</code> object.
- *
- * An identification may be of any Java type. The type must be mutually
- * agreed between the Consumer and Producer services.
- *
- * @return an object which identifies the status item in the address space
- * of the composite producer, must not be null.
- */
- public Object getIdentification();
-
- /**
- * Return the scope name of this <code>Envelope</code> object.
- *
- * Scope names are used to restrict the communication between the Producer
- * and Consumer services. Only <code>Envelopes</code> objects with a scope
- * name that is permitted for the Producer and the Consumer services must be
- * passed through a <code>Wire</code> object.
- *
- * @return the security scope for the status item, must not be null.
- */
- public String getScope();
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/wireadmin/Producer.java b/org.osgi.compendium/src/main/java/org/osgi/service/wireadmin/Producer.java
deleted file mode 100644
index faf6dfd..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/wireadmin/Producer.java
+++ /dev/null
@@ -1,123 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2002, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.service.wireadmin;
-
-/**
- * Data Producer, a service that can generate values to be used by
- * {@link Consumer} services.
- *
- * <p>
- * Service objects registered under the Producer interface are expected to
- * produce values (internally generated or from external sensors). The value can
- * be of different types. When delivering a value to a <code>Wire</code> object,
- * the Producer service should coerce the value to be an instance of one of the
- * types specified by {@link Wire#getFlavors}. The classes are specified in
- * order of preference.
- *
- * <p>
- * When the data represented by the Producer object changes, this object should
- * send the updated value by calling the <code>update</code> method on each of
- * <code>Wire</code> objects passed in the most recent call to this object's
- * {@link #consumersConnected} method. These <code>Wire</code> objects will pass
- * the value on to the associated <code>Consumer</code> service object.
- *
- * <p>
- * The Producer service may use the information in the <code>Wire</code> object's
- * properties to schedule the delivery of values to the <code>Wire</code> object.
- *
- * <p>
- * Producer service objects must register with a <code>service.pid</code> and a
- * {@link WireConstants#WIREADMIN_PRODUCER_FLAVORS} property. It is recommended
- * that a Producer service object also registers with a
- * <code>service.description</code> property. Producer service objects must
- * register with a {@link WireConstants#WIREADMIN_PRODUCER_FILTERS} property if
- * the Producer service will be performing filtering instead of the
- * <code>Wire</code> object.
- *
- * <p>
- * If an exception is thrown by a Producer object method, a
- * <code>WireAdminEvent</code> of type {@link WireAdminEvent#PRODUCER_EXCEPTION}
- * is broadcast by the Wire Admin service.
- *
- * <p>
- * Security Considerations. Data producing bundles will require
- * <code>ServicePermission[Producer,REGISTER]</code> to register a Producer
- * service. In general, only the Wire Admin service should have
- * <code>ServicePermission[Producer,GET]</code>. Thus only the Wire Admin service
- * may directly call a Producer service. Care must be taken in the sharing of
- * <code>Wire</code> objects with other bundles.
- * <p>
- * Producer services must be registered with scope names when they can send
- * different types of objects (composite) to the Consumer service. The Producer
- * service should have <code>WirePermission</code> for each of these scope names.
- *
- * @version $Revision: 5673 $
- */
-public interface Producer {
- /**
- * Return the current value of this <code>Producer</code> object.
- *
- * <p>
- * This method is called by a <code>Wire</code> object in response to the
- * Consumer service calling the <code>Wire</code> object's <code>poll</code>
- * method. The Producer should coerce the value to be an instance of one of
- * the types specified by {@link Wire#getFlavors}. The types are specified
- * in order of of preference. The returned value should be as new or newer
- * than the last value furnished by this object.
- *
- * <p>
- * Note: This method may be called by a <code>Wire</code> object prior to this
- * object being notified that it is connected to that <code>Wire</code> object
- * (via the {@link #consumersConnected} method).
- * <p>
- * If the Producer service returns an <code>Envelope</code> object that has an
- * unpermitted scope name, then the Wire object must ignore (or remove) the
- * transfer.
- * <p>
- * If the <code>Wire</code> object has a scope set, the return value must be
- * an array of <code>Envelope</code> objects (<code>Envelope[]</code>). The
- * <code>Wire</code> object must have removed any <code>Envelope</code> objects
- * that have a scope name that is not in the Wire object's scope.
- *
- * @param wire The <code>Wire</code> object which is polling this service.
- * @return The current value of the Producer service or <code>null</code> if
- * the value cannot be coerced into a compatible type. Or an array
- * of <code>Envelope</code> objects.
- */
- public Object polled(Wire wire);
-
- /**
- * Update the list of <code>Wire</code> objects to which this
- * <code>Producer</code> object is connected.
- *
- * <p>
- * This method is called when the Producer service is first registered and
- * subsequently whenever a <code>Wire</code> associated with this Producer
- * becomes connected, is modified or becomes disconnected.
- *
- * <p>
- * The Wire Admin service must call this method asynchronously. This implies
- * that implementors of a Producer service can be assured that the callback
- * will not take place during registration when they execute the
- * registration in a synchronized method.
- *
- * @param wires An array of the current and complete list of <code>Wire</code>
- * objects to which this Producer service is connected. May be
- * <code>null</code> if the Producer is not currently connected to any
- * <code>Wire</code> objects.
- */
- public void consumersConnected(Wire[] wires);
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/wireadmin/Wire.java b/org.osgi.compendium/src/main/java/org/osgi/service/wireadmin/Wire.java
deleted file mode 100644
index 9e0c1a9..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/wireadmin/Wire.java
+++ /dev/null
@@ -1,268 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2002, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.service.wireadmin;
-
-import java.util.Dictionary;
-
-/**
- * A connection between a Producer service and a Consumer service.
- *
- * <p>
- * A <code>Wire</code> object connects a Producer service to a Consumer service.
- * Both the Producer and Consumer services are identified by their unique
- * <code>service.pid</code> values. The Producer and Consumer services may
- * communicate with each other via <code>Wire</code> objects that connect them.
- * The Producer service may send updated values to the Consumer service by
- * calling the {@link #update} method. The Consumer service may request an
- * updated value from the Producer service by calling the {@link #poll} method.
- *
- * <p>
- * A Producer service and a Consumer service may be connected through multiple
- * <code>Wire</code> objects.
- *
- * <p>
- * Security Considerations. <code>Wire</code> objects are available to Producer
- * and Consumer services connected to a given <code>Wire</code> object and to
- * bundles which can access the <code>WireAdmin</code> service. A bundle must have
- * <code>ServicePermission[WireAdmin,GET]</code> to get the <code>WireAdmin</code>
- * service to access all <code>Wire</code> objects. A bundle registering a
- * Producer service or a Consumer service must have the appropriate
- * <code>ServicePermission[Consumer|Producer,REGISTER]</code> to register the
- * service and will be passed <code>Wire</code> objects when the service object's
- * <code>consumersConnected</code> or <code>producersConnected</code> method is
- * called.
- *
- * <p>
- * Scope. Each Wire object can have a scope set with the <code>setScope</code>
- * method. This method should be called by a Consumer service when it assumes a
- * Producer service that is composite (supports multiple information items). The
- * names in the scope must be verified by the <code>Wire</code> object before it
- * is used in communication. The semantics of the names depend on the Producer
- * service and must not be interpreted by the Wire Admin service.
- *
- * @version $Revision: 5673 $
- */
-public interface Wire {
- /**
- * Return the state of this <code>Wire</code> object.
- *
- * <p>
- * A connected <code>Wire</code> must always be disconnected before becoming
- * invalid.
- *
- * @return <code>false</code> if this <code>Wire</code> object is invalid
- * because it has been deleted via {@link WireAdmin#deleteWire};
- * <code>true</code> otherwise.
- */
- public boolean isValid();
-
- /**
- * Return the connection state of this <code>Wire</code> object.
- *
- * <p>
- * A <code>Wire</code> is connected after the Wire Admin service receives
- * notification that the Producer service and the Consumer service for this
- * <code>Wire</code> object are both registered. This method will return
- * <code>true</code> prior to notifying the Producer and Consumer services via
- * calls to their respective <code>consumersConnected</code> and
- * <code>producersConnected</code> methods.
- * <p>
- * A <code>WireAdminEvent</code> of type {@link WireAdminEvent#WIRE_CONNECTED}
- * must be broadcast by the Wire Admin service when the <code>Wire</code>
- * becomes connected.
- *
- * <p>
- * A <code>Wire</code> object is disconnected when either the Consumer or
- * Producer service is unregistered or the <code>Wire</code> object is
- * deleted.
- * <p>
- * A <code>WireAdminEvent</code> of type
- * {@link WireAdminEvent#WIRE_DISCONNECTED} must be broadcast by the Wire
- * Admin service when the <code>Wire</code> becomes disconnected.
- *
- * @return <code>true</code> if both the Producer and Consumer for this
- * <code>Wire</code> object are connected to the <code>Wire</code>
- * object; <code>false</code> otherwise.
- */
- public boolean isConnected();
-
- /**
- * Return the list of data types understood by the Consumer service
- * connected to this <code>Wire</code> object. Note that subclasses of the
- * classes in this list are acceptable data types as well.
- *
- * <p>
- * The list is the value of the
- * {@link WireConstants#WIREADMIN_CONSUMER_FLAVORS} service property of the
- * Consumer service object connected to this object. If no such property was
- * registered or the type of the property value is not <code>Class[]</code>,
- * this method must return <code>null</code>.
- *
- * @return An array containing the list of classes understood by the
- * Consumer service or <code>null</code> if the <code>Wire</code> is not
- * connected, or the consumer did not register a
- * {@link WireConstants#WIREADMIN_CONSUMER_FLAVORS} property or the
- * value of the property is not of type <code>Class[]</code>.
- */
- public Class[] getFlavors();
-
- /**
- * Update the value.
- *
- * <p>
- * This methods is called by the Producer service to notify the Consumer
- * service connected to this <code>Wire</code> object of an updated value.
- * <p>
- * If the properties of this <code>Wire</code> object contain a
- * {@link WireConstants#WIREADMIN_FILTER} property, then filtering is
- * performed. If the Producer service connected to this <code>Wire</code>
- * object was registered with the service property
- * {@link WireConstants#WIREADMIN_PRODUCER_FILTERS}, the Producer service
- * will perform the filtering according to the rules specified for the
- * filter. Otherwise, this <code>Wire</code> object will perform the filtering
- * of the value.
- * <p>
- * If no filtering is done, or the filter indicates the updated value should
- * be delivered to the Consumer service, then this <code>Wire</code> object
- * must call the {@link Consumer#updated} method with the updated value. If
- * this <code>Wire</code> object is not connected, then the Consumer service
- * must not be called and the value is ignored.
- * <p>
- * If the value is an <code>Envelope</code> object, and the scope name is not
- * permitted, then the <code>Wire</code> object must ignore this call and not
- * transfer the object to the Consumer service.
- *
- * <p>
- * A <code>WireAdminEvent</code> of type {@link WireAdminEvent#WIRE_TRACE}
- * must be broadcast by the Wire Admin service after the Consumer service
- * has been successfully called.
- *
- * @param value The updated value. The value should be an instance of one of
- * the types returned by {@link #getFlavors}.
- * @see WireConstants#WIREADMIN_FILTER
- */
- public void update(Object value);
-
- /**
- * Poll for an updated value.
- *
- * <p>
- * This methods is normally called by the Consumer service to request an
- * updated value from the Producer service connected to this <code>Wire</code>
- * object. This <code>Wire</code> object will call the {@link Producer#polled}
- * method to obtain an updated value. If this <code>Wire</code> object is not
- * connected, then the Producer service must not be called.
- * <p>
- *
- * If this <code>Wire</code> object has a scope, then this method must return
- * an array of <code>Envelope</code> objects. The objects returned must match
- * the scope of this object. The <code>Wire</code> object must remove all
- * <code>Envelope</code> objects with a scope name that is not in the
- * <code>Wire</code> object's scope. Thus, the list of objects returned must
- * only contain <code>Envelope</code> objects with a permitted scope name. If
- * the array becomes empty, <code>null</code> must be returned.
- *
- * <p>
- * A <code>WireAdminEvent</code> of type {@link WireAdminEvent#WIRE_TRACE}
- * must be broadcast by the Wire Admin service after the Producer service
- * has been successfully called.
- *
- * @return A value whose type should be one of the types returned by
- * {@link #getFlavors},<code>Envelope[]</code>, or <code>null</code>
- * if the <code>Wire</code> object is not connected, the Producer
- * service threw an exception, or the Producer service returned a
- * value which is not an instance of one of the types returned by
- * {@link #getFlavors}.
- */
- public Object poll();
-
- /**
- * Return the last value sent through this <code>Wire</code> object.
- *
- * <p>
- * The returned value is the most recent, valid value passed to the
- * {@link #update} method or returned by the {@link #poll} method of this
- * object. If filtering is performed by this <code>Wire</code> object, this
- * methods returns the last value provided by the Producer service. This
- * value may be an <code>Envelope[]</code> when the Producer service uses
- * scoping. If the return value is an Envelope object (or array), it must be
- * verified that the Consumer service has the proper WirePermission to see
- * it.
- *
- * @return The last value passed though this <code>Wire</code> object or
- * <code>null</code> if no valid values have been passed or the
- * Consumer service has no permission.
- */
- public Object getLastValue();
-
- /**
- * Return the wire properties for this <code>Wire</code> object.
- *
- * @return The properties for this <code>Wire</code> object. The returned
- * <code>Dictionary</code> must be read only.
- */
- public Dictionary getProperties();
-
- /**
- * Return the calculated scope of this <code>Wire</code> object.
- *
- * The purpose of the <code>Wire</code> object's scope is to allow a Producer
- * and/or Consumer service to produce/consume different types over a single
- * <code>Wire</code> object (this was deemed necessary for efficiency
- * reasons). Both the Consumer service and the Producer service must set an
- * array of scope names (their scope) with the service registration property
- * <code>WIREADMIN_PRODUCER_SCOPE</code>, or
- * <code>WIREADMIN_CONSUMER_SCOPE</code> when they can produce multiple types.
- * If a Producer service can produce different types, it should set this
- * property to the array of scope names it can produce, the Consumer service
- * must set the array of scope names it can consume. The scope of a
- * <code>Wire</code> object is defined as the intersection of permitted scope
- * names of the Producer service and Consumer service.
- * <p>
- * If neither the Consumer, or the Producer service registers scope names
- * with its service registration, then the <code>Wire</code> object's scope
- * must be <code>null</code>.
- * <p>
- * The <code>Wire</code> object's scope must not change when a Producer or
- * Consumer services modifies its scope.
- * <p>
- * A scope name is permitted for a Producer service when the registering
- * bundle has <code>WirePermission[name,PRODUCE]</code>, and for a Consumer
- * service when the registering bundle has <code>WirePermission[name,CONSUME]</code>.
- * <p>
- * If either Consumer service or Producer service has not set a
- * <code>WIREADMIN_*_SCOPE</code> property, then the returned value must be
- * <code>null</code>.
- * <p>
- * If the scope is set, the <code>Wire</code> object must enforce the scope
- * names when <code>Envelope</code> objects are used as a parameter to update
- * or returned from the <code>poll</code> method. The <code>Wire</code> object
- * must then remove all <code>Envelope</code> objects with a scope name that
- * is not permitted.
- *
- * @return A list of permitted scope names or null if the Produce or
- * Consumer service has set no scope names.
- */
- public String[] getScope();
-
- /**
- * Return true if the given name is in this <code>Wire</code> object's scope.
- *
- * @param name The scope name
- * @return true if the name is listed in the permitted scope names
- */
- public boolean hasScope(String name);
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/wireadmin/WireAdmin.java b/org.osgi.compendium/src/main/java/org/osgi/service/wireadmin/WireAdmin.java
deleted file mode 100644
index 578ef4f..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/wireadmin/WireAdmin.java
+++ /dev/null
@@ -1,168 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2002, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.service.wireadmin;
-
-import java.util.Dictionary;
-
-import org.osgi.framework.InvalidSyntaxException;
-
-/**
- * Wire Administration service.
- *
- * <p>
- * This service can be used to create <code>Wire</code> objects connecting a
- * Producer service and a Consumer service. <code>Wire</code> objects also have
- * wire properties that may be specified when a <code>Wire</code> object is
- * created. The Producer and Consumer services may use the <code>Wire</code>
- * object's properties to manage or control their interaction. The use of
- * <code>Wire</code> object's properties by a Producer or Consumer services is
- * optional.
- *
- * <p>
- * Security Considerations. A bundle must have
- * <code>ServicePermission[WireAdmin,GET]</code> to get the Wire Admin service to
- * create, modify, find, and delete <code>Wire</code> objects.
- *
- * @version $Revision: 5673 $
- */
-public interface WireAdmin {
- /**
- * Create a new <code>Wire</code> object that connects a Producer service to a
- * Consumer service.
- *
- * The Producer service and Consumer service do not have to be registered
- * when the <code>Wire</code> object is created.
- *
- * <p>
- * The <code>Wire</code> configuration data must be persistently stored. All
- * <code>Wire</code> connections are reestablished when the <code>WireAdmin</code>
- * service is registered. A <code>Wire</code> can be permanently removed by
- * using the {@link #deleteWire} method.
- *
- * <p>
- * The <code>Wire</code> object's properties must have case insensitive
- * <code>String</code> objects as keys (like the Framework). However, the case
- * of the key must be preserved.
- *
- * <p>
- * The <code>WireAdmin</code> service must automatically add the following
- * <code>Wire</code> properties:
- * <ul>
- * <li>{@link WireConstants#WIREADMIN_PID} set to the value of the
- * <code>Wire</code> object's persistent identity (PID). This value is
- * generated by the Wire Admin service when a <code>Wire</code> object is
- * created.</li>
- * <li>{@link WireConstants#WIREADMIN_PRODUCER_PID} set to the value of
- * Producer service's PID.</li>
- * <li>{@link WireConstants#WIREADMIN_CONSUMER_PID} set to the value of
- * Consumer service's PID.</li>
- * </ul>
- * If the <code>properties</code> argument already contains any of these keys,
- * then the supplied values are replaced with the values assigned by the
- * Wire Admin service.
- *
- * <p>
- * The Wire Admin service must broadcast a <code>WireAdminEvent</code> of type
- * {@link WireAdminEvent#WIRE_CREATED} after the new <code>Wire</code> object
- * becomes available from {@link #getWires}.
- *
- * @param producerPID The <code>service.pid</code> of the Producer service to
- * be connected to the <code>Wire</code> object.
- * @param consumerPID The <code>service.pid</code> of the Consumer service to
- * be connected to the <code>Wire</code> object.
- * @param properties The <code>Wire</code> object's properties. This argument
- * may be <code>null</code> if the caller does not wish to define any
- * <code>Wire</code> object's properties.
- * @return The <code>Wire</code> object for this connection.
- *
- * @throws java.lang.IllegalArgumentException If <code>properties</code>
- * contains invalid wire types or case variants of the same key
- * name.
- */
- public Wire createWire(String producerPID, String consumerPID,
- Dictionary properties);
-
- /**
- * Delete a <code>Wire</code> object.
- *
- * <p>
- * The <code>Wire</code> object representing a connection between a Producer
- * service and a Consumer service must be removed. The persistently stored
- * configuration data for the <code>Wire</code> object must destroyed. The
- * <code>Wire</code> object's method {@link Wire#isValid} will return
- * <code>false</code> after it is deleted.
- *
- * <p>
- * The Wire Admin service must broadcast a <code>WireAdminEvent</code> of type
- * {@link WireAdminEvent#WIRE_DELETED} after the <code>Wire</code> object
- * becomes invalid.
- *
- * @param wire The <code>Wire</code> object which is to be deleted.
- */
- public void deleteWire(Wire wire);
-
- /**
- * Update the properties of a <code>Wire</code> object.
- *
- * The persistently stored configuration data for the <code>Wire</code> object
- * is updated with the new properties and then the Consumer and Producer
- * services will be called at the respective
- * {@link Consumer#producersConnected} and
- * {@link Producer#consumersConnected} methods.
- *
- * <p>
- * The Wire Admin service must broadcast a <code>WireAdminEvent</code> of type
- * {@link WireAdminEvent#WIRE_UPDATED} after the updated properties are
- * available from the <code>Wire</code> object.
- *
- * @param wire The <code>Wire</code> object which is to be updated.
- * @param properties The new <code>Wire</code> object's properties or
- * <code>null</code> if no properties are required.
- *
- * @throws java.lang.IllegalArgumentException If <code>properties</code>
- * contains invalid wire types or case variants of the same key
- * name.
- */
- public void updateWire(Wire wire, Dictionary properties);
-
- /**
- * Return the <code>Wire</code> objects that match the given <code>filter</code>.
- *
- * <p>
- * The list of available <code>Wire</code> objects is matched against the
- * specified <code>filter</code>.<code>Wire</code> objects which match the
- * <code>filter</code> must be returned. These <code>Wire</code> objects are not
- * necessarily connected. The Wire Admin service should not return invalid
- * <code>Wire</code> objects, but it is possible that a <code>Wire</code> object
- * is deleted after it was placed in the list.
- *
- * <p>
- * The filter matches against the <code>Wire</code> object's properties
- * including {@link WireConstants#WIREADMIN_PRODUCER_PID},
- * {@link WireConstants#WIREADMIN_CONSUMER_PID} and
- * {@link WireConstants#WIREADMIN_PID}.
- *
- * @param filter Filter string to select <code>Wire</code> objects or
- * <code>null</code> to select all <code>Wire</code> objects.
- * @return An array of <code>Wire</code> objects which match the
- * <code>filter</code> or <code>null</code> if no <code>Wire</code>
- * objects match the <code>filter</code>.
- * @throws org.osgi.framework.InvalidSyntaxException If the specified
- * <code>filter</code> has an invalid syntax.
- * @see org.osgi.framework.Filter
- */
- public Wire[] getWires(String filter) throws InvalidSyntaxException;
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/wireadmin/WireAdminEvent.java b/org.osgi.compendium/src/main/java/org/osgi/service/wireadmin/WireAdminEvent.java
deleted file mode 100644
index bba84ef..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/wireadmin/WireAdminEvent.java
+++ /dev/null
@@ -1,266 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2002, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.service.wireadmin;
-
-import org.osgi.framework.ServiceReference;
-
-/**
- * A Wire Admin Event.
- *
- * <p>
- * <code>WireAdminEvent</code> objects are delivered to all registered
- * <code>WireAdminListener</code> service objects which specify an interest in the
- * <code>WireAdminEvent</code> type. Events must be delivered in chronological
- * order with respect to each listener. For example, a <code>WireAdminEvent</code>
- * of type {@link #WIRE_CONNECTED} must be delivered before a
- * <code>WireAdminEvent</code> of type {@link #WIRE_DISCONNECTED} for a particular
- * <code>Wire</code> object.
- *
- * <p>
- * A type code is used to identify the type of event. The following event types
- * are defined:
- * <ul>
- * <li>{@link #WIRE_CREATED}
- * <li>{@link #WIRE_CONNECTED}
- * <li>{@link #WIRE_UPDATED}
- * <li>{@link #WIRE_TRACE}
- * <li>{@link #WIRE_DISCONNECTED}
- * <li>{@link #WIRE_DELETED}
- * <li>{@link #PRODUCER_EXCEPTION}
- * <li>{@link #CONSUMER_EXCEPTION}
- * </ul>
- * Additional event types may be defined in the future.
- *
- * <p>
- * Event type values must be unique and disjoint bit values. Event types must be
- * defined as a bit in a 32 bit integer and can thus be bitwise OR'ed together.
- * <p>
- * Security Considerations. <code>WireAdminEvent</code> objects contain
- * <code>Wire</code> objects. Care must be taken in the sharing of <code>Wire</code>
- * objects with other bundles.
- *
- * @see WireAdminListener
- *
- * @version $Revision: 5673 $
- */
-public class WireAdminEvent {
- /**
- * The WireAdmin service which created this event.
- */
- private ServiceReference reference;
- /**
- * The <code>Wire</code> object associated with this event.
- */
- private Wire wire;
- /**
- * Type of this event.
- *
- * @see #getType
- */
- private int type;
- /**
- * Exception associates with this the event.
- */
- private Throwable throwable;
- /**
- * A Producer service method has thrown an exception.
- *
- * <p>
- * This <code>WireAdminEvent</code> type indicates that a Producer service
- * method has thrown an exception. The {@link WireAdminEvent#getThrowable}
- * method will return the exception that the Producer service method raised.
- *
- * <p>
- * The value of <code>PRODUCER_EXCEPTION</code> is 0x00000001.
- */
- public final static int PRODUCER_EXCEPTION = 0x00000001;
- /**
- * A Consumer service method has thrown an exception.
- *
- * <p>
- * This <code>WireAdminEvent</code> type indicates that a Consumer service
- * method has thrown an exception. The {@link WireAdminEvent#getThrowable}
- * method will return the exception that the Consumer service method raised.
- *
- * <p>
- * The value of <code>CONSUMER_EXCEPTION</code> is 0x00000002.
- */
- public final static int CONSUMER_EXCEPTION = 0x00000002;
- /**
- * A <code>Wire</code> has been created.
- *
- * <p>
- * This <code>WireAdminEvent</code> type that indicates that a new
- * <code>Wire</code> object has been created.
- *
- * An event is broadcast when {@link WireAdmin#createWire} is called. The
- * {@link WireAdminEvent#getWire} method will return the <code>Wire</code>
- * object that has just been created.
- *
- * <p>
- * The value of <code>WIRE_CREATED</code> is 0x00000004.
- */
- public final static int WIRE_CREATED = 0x00000004;
- /**
- * A <code>Wire</code> has been updated.
- *
- * <p>
- * This <code>WireAdminEvent</code> type that indicates that an existing
- * <code>Wire</code> object has been updated with new properties.
- *
- * An event is broadcast when {@link WireAdmin#updateWire} is called with a
- * valid wire. The {@link WireAdminEvent#getWire} method will return the
- * <code>Wire</code> object that has just been updated.
- *
- * <p>
- * The value of <code>WIRE_UPDATED</code> is 0x00000008.
- */
- public final static int WIRE_UPDATED = 0x00000008;
- /**
- * A <code>Wire</code> has been deleted.
- *
- * <p>
- * This <code>WireAdminEvent</code> type that indicates that an existing wire
- * has been deleted.
- *
- * An event is broadcast when {@link WireAdmin#deleteWire} is called with a
- * valid wire. {@link WireAdminEvent#getWire} will return the <code>Wire</code>
- * object that has just been deleted.
- *
- * <p>
- * The value of <code>WIRE_DELETED</code> is 0x00000010.
- */
- public final static int WIRE_DELETED = 0x00000010;
- /**
- * The <code>WireAdminEvent</code> type that indicates that an existing
- * <code>Wire</code> object has become connected.
- *
- * The Consumer object and the Producer object that are associated with the
- * <code>Wire</code> object have both been registered and the <code>Wire</code>
- * object is connected. See {@link Wire#isConnected} for a description of
- * the connected state. This event may come before the
- * <code>producersConnected</code> and <code>consumersConnected</code> method
- * have returned or called to allow synchronous delivery of the events. Both
- * methods can cause other <code>WireAdminEvent</code> s to take place and
- * requiring this event to be send before these methods are returned would
- * mandate asynchronous delivery.
- *
- * <p>
- * The value of <code>WIRE_CONNECTED</code> is 0x00000020.
- */
- public final static int WIRE_CONNECTED = 0x00000020;
- /**
- * The <code>WireAdminEvent</code> type that indicates that an existing
- * <code>Wire</code> object has become disconnected.
- *
- * The Consumer object or/and Producer object is/are unregistered breaking
- * the connection between the two. See {@link Wire#isConnected} for a
- * description of the connected state.
- *
- * <p>
- * The value of <code>WIRE_DISCONNECTED</code> is 0x00000040.
- */
- public final static int WIRE_DISCONNECTED = 0x00000040;
- /**
- * The <code>WireAdminEvent</code> type that indicates that a new value is
- * transferred over the <code>Wire</code> object.
- *
- * This event is sent after the Consumer service has been notified by
- * calling the {@link Consumer#updated} method or the Consumer service
- * requested a new value with the {@link Wire#poll} method. This is an
- * advisory event meaning that when this event is received, another update
- * may already have occurred and this the {@link Wire#getLastValue} method
- * returns a newer value then the value that was communicated for this
- * event.
- *
- * <p>
- * The value of <code>WIRE_TRACE</code> is 0x00000080.
- */
- public final static int WIRE_TRACE = 0x00000080;
-
- /**
- * Constructs a <code>WireAdminEvent</code> object from the given
- * <code>ServiceReference</code> object, event type, <code>Wire</code> object
- * and exception.
- *
- * @param reference The <code>ServiceReference</code> object of the Wire Admin
- * service that created this event.
- * @param type The event type. See {@link #getType}.
- * @param wire The <code>Wire</code> object associated with this event.
- * @param exception An exception associated with this event. This may be
- * <code>null</code> if no exception is associated with this event.
- */
- public WireAdminEvent(ServiceReference reference, int type, Wire wire,
- Throwable exception) {
- this.reference = reference;
- this.wire = wire;
- this.type = type;
- this.throwable = exception;
- }
-
- /**
- * Return the <code>ServiceReference</code> object of the Wire Admin service
- * that created this event.
- *
- * @return The <code>ServiceReference</code> object for the Wire Admin service
- * that created this event.
- */
- public ServiceReference getServiceReference() {
- return reference;
- }
-
- /**
- * Return the <code>Wire</code> object associated with this event.
- *
- * @return The <code>Wire</code> object associated with this event or
- * <code>null</code> when no <code>Wire</code> object is associated with
- * the event.
- */
- public Wire getWire() {
- return wire;
- }
-
- /**
- * Return the type of this event.
- * <p>
- * The type values are:
- * <ul>
- * <li>{@link #WIRE_CREATED}
- * <li>{@link #WIRE_CONNECTED}
- * <li>{@link #WIRE_UPDATED}
- * <li>{@link #WIRE_TRACE}
- * <li>{@link #WIRE_DISCONNECTED}
- * <li>{@link #WIRE_DELETED}
- * <li>{@link #PRODUCER_EXCEPTION}
- * <li>{@link #CONSUMER_EXCEPTION}
- * </ul>
- *
- * @return The type of this event.
- */
- public int getType() {
- return type;
- }
-
- /**
- * Returns the exception associated with the event, if any.
- *
- * @return An exception or <code>null</code> if no exception is associated
- * with this event.
- */
- public Throwable getThrowable() {
- return throwable;
- }
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/wireadmin/WireAdminListener.java b/org.osgi.compendium/src/main/java/org/osgi/service/wireadmin/WireAdminListener.java
deleted file mode 100644
index e741dd9..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/wireadmin/WireAdminListener.java
+++ /dev/null
@@ -1,72 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2002, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.service.wireadmin;
-
-/**
- * Listener for Wire Admin Events.
- *
- * <p>
- * <code>WireAdminListener</code> objects are registered with the Framework
- * service registry and are notified with a <code>WireAdminEvent</code> object
- * when an event is broadcast.
- * <p>
- * <code>WireAdminListener</code> objects can inspect the received
- * <code>WireAdminEvent</code> object to determine its type, the <code>Wire</code>
- * object with which it is associated, and the Wire Admin service that
- * broadcasts the event.
- *
- * <p>
- * <code>WireAdminListener</code> objects must be registered with a service
- * property {@link WireConstants#WIREADMIN_EVENTS} whose value is a bitwise OR
- * of all the event types the listener is interested in receiving.
- * <p>
- * For example:
- *
- * <pre>
- * Integer mask = new Integer(WIRE_TRACE | WIRE_CONNECTED | WIRE_DISCONNECTED);
- * Hashtable ht = new Hashtable();
- * ht.put(WIREADMIN_EVENTS, mask);
- * context.registerService(WireAdminListener.class.getName(), this, ht);
- * </pre>
- *
- * If a <code>WireAdminListener</code> object is registered without a service
- * property {@link WireConstants#WIREADMIN_EVENTS}, then the
- * <code>WireAdminListener</code> will receive no events.
- *
- * <p>
- * Security Considerations. Bundles wishing to monitor <code>WireAdminEvent</code>
- * objects will require <code>ServicePermission[WireAdminListener,REGISTER]</code>
- * to register a <code>WireAdminListener</code> service. Since
- * <code>WireAdminEvent</code> objects contain <code>Wire</code> objects, care must
- * be taken in assigning permission to register a <code>WireAdminListener</code>
- * service.
- *
- * @see WireAdminEvent
- *
- * @version $Revision: 5673 $
- */
-public interface WireAdminListener {
- /**
- * Receives notification of a broadcast <code>WireAdminEvent</code> object.
- *
- * The event object will be of an event type specified in this
- * <code>WireAdminListener</code> service's
- * {@link WireConstants#WIREADMIN_EVENTS} service property.
- *
- * @param event The <code>WireAdminEvent</code> object.
- */
- void wireAdminEvent(WireAdminEvent event);
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/wireadmin/WireConstants.java b/org.osgi.compendium/src/main/java/org/osgi/service/wireadmin/WireConstants.java
deleted file mode 100644
index b616a4f..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/wireadmin/WireConstants.java
+++ /dev/null
@@ -1,225 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2002, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.service.wireadmin;
-
-/**
- * Defines standard names for <code>Wire</code> properties, wire filter
- * attributes, Consumer and Producer service properties.
- *
- * @version $Revision: 5673 $
- */
-public interface WireConstants {
- /**
- * <code>Wire</code> property key (named <code>wireadmin.pid</code>) specifying
- * the persistent identity (PID) of this <code>Wire</code> object.
- *
- * <p>
- * Each <code>Wire</code> object has a PID to allow unique and persistent
- * identification of a specific <code>Wire</code> object. The PID must be
- * generated by the {@link WireAdmin} service when the <code>Wire</code>
- * object is created.
- *
- * <p>
- * This wire property is automatically set by the Wire Admin service. The
- * value of the property must be of type <code>String</code>.
- */
- public final static String WIREADMIN_PID = "wireadmin.pid";
- /**
- * A service registration property for a Producer service that is composite.
- * It contains the names of the composite Consumer services it can
- * inter-operate with. Inter-operability exists when any name in this array
- * matches any name in the array set by the Consumer service. The type of
- * this property must be <code>String[]</code>.
- */
- public final static String WIREADMIN_PRODUCER_COMPOSITE = "wireadmin.producer.composite";
- /**
- * A service registration property for a Consumer service that is composite.
- * It contains the names of the composite Producer services it can cooperate
- * with. Inter-operability exists when any name in this array matches any
- * name in the array set by the Producer service. The type of this property
- * must be <code>String[]</code>.
- */
- public final static String WIREADMIN_CONSUMER_COMPOSITE = "wireadmin.consumer.composite";
- /**
- * Service registration property key (named
- * <code>wireadmin.producer.scope</code>) specifying a list of names that may
- * be used to define the scope of this <code>Wire</code> object. A Producer
- * service should set this service property when it can produce more than
- * one kind of value. This property is only used during registration,
- * modifying the property must not have any effect of the <code>Wire</code>
- * object's scope. Each name in the given list mist have
- * <code>WirePermission[name,PRODUCE]</code> or else is ignored. The type of
- * this service registration property must be <code>String[]</code>.
- *
- * @see Wire#getScope
- * @see #WIREADMIN_CONSUMER_SCOPE
- */
- public final static String WIREADMIN_PRODUCER_SCOPE = "wireadmin.producer.scope";
- /**
- * Service registration property key (named
- * <code>wireadmin.consumer.scope</code>) specifying a list of names that may
- * be used to define the scope of this <code>Wire</code> object. A
- * <code>Consumer</code> service should set this service property when it can
- * produce more than one kind of value. This property is only used during
- * registration, modifying the property must not have any effect of the
- * <code>Wire</code> object's scope. Each name in the given list mist have
- * <code>WirePermission[name,CONSUME]</code> or else is ignored. The type of this
- * service registration property must be <code>String[]</code>.
- *
- * @see Wire#getScope
- * @see #WIREADMIN_PRODUCER_SCOPE
- */
- public final static String WIREADMIN_CONSUMER_SCOPE = "wireadmin.consumer.scope";
- /**
- * Matches all scope names.
- */
- public final static String WIREADMIN_SCOPE_ALL[] = {"*"};
- /**
- * <code>Wire</code> property key (named <code>wireadmin.producer.pid</code>)
- * specifying the <code>service.pid</code> of the associated Producer service.
- *
- * <p>
- * This wire property is automatically set by the WireAdmin service. The
- * value of the property must be of type <code>String</code>.
- */
- public final static String WIREADMIN_PRODUCER_PID = "wireadmin.producer.pid";
- /**
- * <code>Wire</code> property key (named <code>wireadmin.consumer.pid</code>)
- * specifying the <code>service.pid</code> of the associated Consumer service.
- *
- * <p>
- * This wire property is automatically set by the Wire Admin service. The
- * value of the property must be of type <code>String</code>.
- */
- public final static String WIREADMIN_CONSUMER_PID = "wireadmin.consumer.pid";
- /**
- * <code>Wire</code> property key (named <code>wireadmin.filter</code>)
- * specifying a filter used to control the delivery rate of data between the
- * Producer and the Consumer service.
- *
- * <p>
- * This property should contain a filter as described in the <code>Filter</code>
- * class. The filter can be used to specify when an updated value from the
- * Producer service should be delivered to the Consumer service. In many
- * cases the Consumer service does not need to receive the data with the
- * same rate that the Producer service can generate data. This property can
- * be used to control the delivery rate.
- * <p>
- * The filter can use a number of pre-defined attributes that can be used to
- * control the delivery of new data values. If the filter produces a match
- * upon the wire filter attributes, the Consumer service should be notifed
- * of the updated data value.
- * <p>
- * If the Producer service was registered with the
- * {@link #WIREADMIN_PRODUCER_FILTERS} service property indicating that the
- * Producer service will perform the data filtering then the <code>Wire</code>
- * object will not perform data filtering. Otherwise, the <code>Wire</code>
- * object must perform basic filtering. Basic filtering includes supporting
- * the following standard wire filter attributes:
- * <ul>
- * <li>{@link #WIREVALUE_CURRENT}- Current value
- * <li>{@link #WIREVALUE_PREVIOUS}- Previous value
- * <li>{@link #WIREVALUE_DELTA_ABSOLUTE}- Absolute delta
- * <li>{@link #WIREVALUE_DELTA_RELATIVE}- Relative delta
- * <li>{@link #WIREVALUE_ELAPSED}- Elapsed time
- * </ul>
- *
- * @see org.osgi.framework.Filter
- */
- public final static String WIREADMIN_FILTER = "wireadmin.filter";
- /* Wire filter attribute names. */
- /**
- * <code>Wire</code> object's filter attribute (named
- * <code>wirevalue.current</code>) representing the current value.
- */
- public final static String WIREVALUE_CURRENT = "wirevalue.current";
- /**
- * <code>Wire</code> object's filter attribute (named
- * <code>wirevalue.previous</code>) representing the previous value.
- */
- public final static String WIREVALUE_PREVIOUS = "wirevalue.previous";
- /**
- * <code>Wire</code> object's filter attribute (named
- * <code>wirevalue.delta.absolute</code>) representing the absolute delta.
- * The absolute (always positive) difference between the last update and the
- * current value (only when numeric). This attribute must not be used when
- * the values are not numeric.
- */
- public final static String WIREVALUE_DELTA_ABSOLUTE = "wirevalue.delta.absolute";
- /**
- * <code>Wire</code> object's filter attribute (named
- * <code>wirevalue.delta.relative</code>) representing the relative delta.
- * The relative difference is |<code>previous</code>-<code>current</code> |/|
- * <code>current</code>| (only when numeric). This attribute must not be used
- * when the values are not numeric.
- */
- public final static String WIREVALUE_DELTA_RELATIVE = "wirevalue.delta.relative";
- /**
- * <code>Wire</code> object's filter attribute (named
- * <code>wirevalue.elapsed</code>) representing the elapsed time, in ms,
- * between this filter evaluation and the last update of the
- * <code>Consumer</code> service.
- */
- public final static String WIREVALUE_ELAPSED = "wirevalue.elapsed";
- /* Service registration property key names. */
- /**
- * Service Registration property (named <code>wireadmin.producer.filters</code>).
- * A <code>Producer</code> service registered with this property indicates to
- * the Wire Admin service that the Producer service implements at least the
- * filtering as described for the {@link #WIREADMIN_FILTER} property. If the
- * Producer service is not registered with this property, the <code>Wire</code>
- * object must perform the basic filtering as described in
- * {@link #WIREADMIN_FILTER}.
- *
- * <p>
- * The type of the property value is not relevant. Only its presence is
- * relevant.
- */
- public final static String WIREADMIN_PRODUCER_FILTERS = "wireadmin.producer.filters";
- /**
- * Service Registration property (named <code>wireadmin.consumer.flavors</code>)
- * specifying the list of data types understood by this Consumer service.
- *
- * <p>
- * The Consumer service object must be registered with this service
- * property. The list must be in the order of preference with the first type
- * being the most preferred. The value of the property must be of type
- * <code>Class[]</code>.
- */
- public final static String WIREADMIN_CONSUMER_FLAVORS = "wireadmin.consumer.flavors";
- /**
- * Service Registration property (named <code>wireadmin.producer.flavors</code>)
- * specifying the list of data types available from this Producer service.
- *
- * <p>
- * The Producer service object should be registered with this service
- * property.
- *
- * <p>
- * The value of the property must be of type <code>Class[]</code>.
- */
- public final static String WIREADMIN_PRODUCER_FLAVORS = "wireadmin.producer.flavors";
- /**
- * Service Registration property (named <code>wireadmin.events</code>)
- * specifying the <code>WireAdminEvent</code> type of interest to a Wire Admin
- * Listener service. The value of the property is a bitwise OR of all the
- * <code>WireAdminEvent</code> types the Wire Admin Listener service wishes to
- * receive and must be of type <code>Integer</code>.
- *
- * @see WireAdminEvent
- */
- public final static String WIREADMIN_EVENTS = "wireadmin.events";
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/service/wireadmin/WirePermission.java b/org.osgi.compendium/src/main/java/org/osgi/service/wireadmin/WirePermission.java
deleted file mode 100644
index 6073466..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/service/wireadmin/WirePermission.java
+++ /dev/null
@@ -1,485 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2002, 2009). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.service.wireadmin;
-
-import java.io.IOException;
-import java.security.BasicPermission;
-import java.security.Permission;
-import java.security.PermissionCollection;
-import java.util.Enumeration;
-import java.util.Hashtable;
-
-/**
- * Permission for the scope of a <code>Wire</code> object. When a
- * <code>Envelope</code> object is used for communication with the
- * <code>poll</code> or <code>update</code> method, and the scope is set, then
- * the <code>Wire</code> object must verify that the Consumer service has
- * <code>WirePermission[name,CONSUME]</code> and the Producer service has
- * <code>WirePermission[name,PRODUCE]</code> for all names in the scope.
- * <p>
- * The names are compared with the normal rules for permission names. This means
- * that they may end with a "*" to indicate wildcards. E.g. Door.* indicates all
- * scope names starting with the string "Door". The last period is required due
- * to the implementations of the <code>BasicPermission</code> class.
- *
- * @ThreadSafe
- * @version $Revision: 6381 $
- */
-final public class WirePermission extends BasicPermission {
- static final long serialVersionUID = -5583709391516569321L;
- /**
- * The action string for the <code>produce</code> action.
- */
- public static final String PRODUCE = "produce";
- /**
- * The action string for the <code>consume</code> action.
- */
- public static final String CONSUME = "consume";
- private final static int ACTION_PRODUCE = 0x00000001;
- private final static int ACTION_CONSUME = 0x00000002;
- private final static int ACTION_ALL = ACTION_PRODUCE
- | ACTION_CONSUME;
- private final static int ACTION_NONE = 0;
- /**
- * The actions mask.
- */
- private transient int action_mask;
- /**
- * The actions in canonical form.
- *
- * @serial
- */
- private volatile String actions = null;
-
- /**
- * Create a new WirePermission with the given name (may be wildcard) and
- * actions.
- *
- * @param name Wire name.
- * @param actions <code>produce</code>, <code>consume</code> (canonical
- * order).
- */
- public WirePermission(String name, String actions) {
- this(name, parseActions(actions));
- }
-
- /**
- * Package private constructor used by WirePermissionCollection.
- *
- * @param name class name
- * @param mask action mask
- */
- WirePermission(String name, int mask) {
- super(name);
- setTransients(mask);
- }
-
- /**
- * Called by constructors and when deserialized.
- *
- * @param mask action mask
- */
- private synchronized void setTransients(int mask) {
- if ((mask == ACTION_NONE) || ((mask & ACTION_ALL) != mask)) {
- throw new IllegalArgumentException("invalid action string");
- }
- action_mask = mask;
- }
-
- /**
- * Returns the current action mask. Used by the WirePermissionCollection
- * object.
- *
- * @return The actions mask.
- */
- synchronized int getActionsMask() {
- return action_mask;
- }
-
- /**
- * Parse action string into action mask.
- *
- * @param actions Action string.
- * @return action mask.
- */
- private static int parseActions(String actions) {
- boolean seencomma = false;
- int mask = ACTION_NONE;
- if (actions == null) {
- return mask;
- }
- char[] a = actions.toCharArray();
- int i = a.length - 1;
- if (i < 0)
- return mask;
- while (i != -1) {
- char c;
- // skip whitespace
- while ((i != -1)
- && ((c = a[i]) == ' ' || c == '\r' || c == '\n'
- || c == '\f' || c == '\t'))
- i--;
- // check for the known strings
- int matchlen;
- if (i >= 6 && (a[i - 6] == 'p' || a[i - 6] == 'P')
- && (a[i - 5] == 'r' || a[i - 5] == 'R')
- && (a[i - 4] == 'o' || a[i - 4] == 'O')
- && (a[i - 3] == 'd' || a[i - 3] == 'D')
- && (a[i - 2] == 'u' || a[i - 2] == 'U')
- && (a[i - 1] == 'c' || a[i - 1] == 'C')
- && (a[i] == 'e' || a[i] == 'E')) {
- matchlen = 7;
- mask |= ACTION_PRODUCE;
- }
- else
- if (i >= 6 && (a[i - 6] == 'c' || a[i - 6] == 'C')
- && (a[i - 5] == 'o' || a[i - 5] == 'O')
- && (a[i - 4] == 'n' || a[i - 4] == 'N')
- && (a[i - 3] == 's' || a[i - 3] == 'S')
- && (a[i - 2] == 'u' || a[i - 2] == 'U')
- && (a[i - 1] == 'm' || a[i - 1] == 'M')
- && (a[i] == 'e' || a[i] == 'E')) {
- matchlen = 7;
- mask |= ACTION_CONSUME;
- }
- else {
- // parse error
- throw new IllegalArgumentException("invalid permission: "
- + actions);
- }
- // make sure we didn't just match the tail of a word
- // like "ackbarfregister". Also, skip to the comma.
- seencomma = false;
- while (i >= matchlen && !seencomma) {
- switch (a[i - matchlen]) {
- case ',' :
- seencomma = true;
- /* FALLTHROUGH */
- case ' ' :
- case '\r' :
- case '\n' :
- case '\f' :
- case '\t' :
- break;
- default :
- throw new IllegalArgumentException(
- "invalid permission: " + actions);
- }
- i--;
- }
- // point i at the location of the comma minus one (or -1).
- i -= matchlen;
- }
- if (seencomma) {
- throw new IllegalArgumentException("invalid permission: " + actions);
- }
- return mask;
- }
-
- /**
- * Checks if this <code>WirePermission</code> object <code>implies</code>
- * the specified permission.
- * <P>
- * More specifically, this method returns <code>true</code> if:
- * <p>
- * <ul>
- * <li><i>p </i> is an instanceof the <code>WirePermission</code> class,
- * <li><i>p </i>'s actions are a proper subset of this object's actions, and
- * <li><i>p </i>'s name is implied by this object's name. For example,
- * <code>java.*</code> implies <code>java.home</code>.
- * </ul>
- *
- * @param p The permission to check against.
- *
- * @return <code>true</code> if the specified permission is implied by this
- * object; <code>false</code> otherwise.
- */
- public boolean implies(Permission p) {
- if (p instanceof WirePermission) {
- WirePermission requested = (WirePermission) p;
- int requestedMask = requested.getActionsMask();
- return ((getActionsMask() & requestedMask) == requestedMask)
- && super.implies(p);
- }
- return false;
- }
-
- /**
- * Returns the canonical string representation of the actions. Always
- * returns present actions in the following order: <code>produce</code>,
- * <code>consume</code>.
- *
- * @return The canonical string representation of the actions.
- */
- public String getActions() {
- String result = actions;
- if (result == null) {
- StringBuffer sb = new StringBuffer();
- boolean comma = false;
- int mask = getActionsMask();
- if ((mask & ACTION_PRODUCE) == ACTION_PRODUCE) {
- sb.append(PRODUCE);
- comma = true;
- }
- if ((mask & ACTION_CONSUME) == ACTION_CONSUME) {
- if (comma)
- sb.append(',');
- sb.append(CONSUME);
- }
- actions = result = sb.toString();
- }
- return result;
- }
-
- /**
- * Returns a new <code>PermissionCollection</code> object for storing
- * <code>WirePermission</code> objects.
- *
- * @return A new <code>PermissionCollection</code> object suitable for
- * storing <code>WirePermission</code> objects.
- */
- public PermissionCollection newPermissionCollection() {
- return new WirePermissionCollection();
- }
-
- /**
- * Determines the equalty of two <code>WirePermission</code> objects.
- *
- * Checks that specified object has the same name and actions as this
- * <code>WirePermission</code> object.
- *
- * @param obj The object to test for equality.
- * @return true if <code>obj</code> is a <code>WirePermission</code>, and
- * has the same name and actions as this <code>WirePermission</code>
- * object; <code>false</code> otherwise.
- */
- public boolean equals(Object obj) {
- if (obj == this) {
- return true;
- }
- if (!(obj instanceof WirePermission)) {
- return false;
- }
- WirePermission wp = (WirePermission) obj;
- return (getActionsMask() == wp.getActionsMask())
- && getName().equals(wp.getName());
- }
-
- /**
- * Returns the hash code value for this object.
- *
- * @return Hash code value for this object.
- */
- public int hashCode() {
- int h = 31 * 17 + getName().hashCode();
- h = 31 * h + getActions().hashCode();
- return h;
- }
-
- /**
- * Returns a string describing this <code>WirePermission</code>. The
- * convention is to specify the class name, the permission name, and the
- * actions in the following format:
- * '(org.osgi.service.wireadmin.WirePermission "name"
- * "actions")'.
- *
- * @return information about this <code>Permission</code> object.
- */
- public String toString() {
- StringBuffer sb = new StringBuffer();
- sb.append('(');
- sb.append(getClass().getName());
- sb.append(" \"");
- sb.append(getName());
- String a = getActions();
- if (a.length() > 0) {
- sb.append("\" \"");
- sb.append(a);
- }
- sb.append("\")");
- return sb.toString();
- }
-
- /**
- * WriteObject is called to save the state of the ServicePermission to a
- * stream. The actions are serialized, and the superclass takes care of the
- * name.
- */
- private synchronized void writeObject(java.io.ObjectOutputStream s)
- throws IOException {
- // Write out the actions. The superclass takes care of the name
- // call getActions to make sure actions field is initialized
- if (actions == null)
- getActions();
- s.defaultWriteObject();
- }
-
- /**
- * readObject is called to restore the state of the ServicePermission from a
- * stream.
- */
- private synchronized void readObject(java.io.ObjectInputStream s)
- throws IOException, ClassNotFoundException {
- // Read in the action, then initialize the rest
- s.defaultReadObject();
- setTransients(parseActions(actions));
- }
-}
-
-/**
- * A <code>WirePermissionCollection</code> stores a set of
- * <code>WirePermission</code> permissions.
- */
-
-final class WirePermissionCollection extends PermissionCollection {
- static final long serialVersionUID = 2617521094909826016L;
- /**
- * Table of permissions.
- *
- * @GuardedBy this
- * @serial
- */
- private final Hashtable permissions;
- /**
- * Boolean saying if "*" is in the collection.
- *
- * @GuardedBy this
- * @serial
- */
- private boolean all_allowed;
-
- /**
- * Creates an empty WirePermissionCollection object.
- *
- */
- public WirePermissionCollection() {
- permissions = new Hashtable();
- all_allowed = false;
- }
-
- /**
- * Adds a permission to this PermissionCollection.
- *
- * @param permission The Permission object to add.
- *
- * @throws IllegalArgumentException If the permission is not a
- * WirePermission object.
- *
- * @throws SecurityException If this PermissionCollection has been marked
- * read-only.
- */
- public void add(Permission permission) {
- if (!(permission instanceof WirePermission)) {
- throw new IllegalArgumentException("invalid permission: "
- + permission);
- }
- if (isReadOnly()) {
- throw new SecurityException("attempt to add a Permission to a "
- + "readonly PermissionCollection");
- }
- WirePermission wp = (WirePermission) permission;
- String name = wp.getName();
- synchronized (this) {
- WirePermission existing = (WirePermission) permissions.get(name);
- if (existing != null) {
- int oldMask = existing.getActionsMask();
- int newMask = wp.getActionsMask();
- if (oldMask != newMask) {
- permissions.put(name, new WirePermission(name, oldMask
- | newMask));
- }
- }
- else {
- permissions.put(name, wp);
- }
- if (!all_allowed) {
- if (name.equals("*")) {
- all_allowed = true;
- }
- }
- }
- }
-
- /**
- * Determines if a set of permissions implies the permissions expressed in
- * <code>permission</code>.
- *
- * @param permission The Permission object to compare.
- *
- * @return <code>true</code> if <code>permission</code> is a proper subset
- * of a permission in the set; <code>false</code> otherwise.
- */
- public boolean implies(Permission permission) {
- if (!(permission instanceof WirePermission)) {
- return false;
- }
- WirePermission requested = (WirePermission) permission;
- WirePermission x;
- int desired = requested.getActionsMask();
- int effective = 0;
- String name = requested.getName();
- synchronized (this) {
- // short circuit if the "*" Permission was added
- if (all_allowed) {
- x = (WirePermission) permissions.get("*");
- if (x != null) {
- effective |= x.getActionsMask();
- if ((effective & desired) == desired)
- return true;
- }
- }
- // strategy:
- // Check for full match first. Then work our way up the
- // name looking for matches on a.b.*
- x = (WirePermission) permissions.get(name);
- }
- if (x != null) {
- // we have a direct hit!
- effective |= x.getActionsMask();
- if ((effective & desired) == desired) {
- return true;
- }
- }
- // work our way up the tree...
- int last;
- int offset = name.length() - 1;
- while ((last = name.lastIndexOf(".", offset)) != -1) {
- name = name.substring(0, last + 1) + "*";
- synchronized (this) {
- x = (WirePermission) permissions.get(name);
- }
- if (x != null) {
- effective |= x.getActionsMask();
- if ((effective & desired) == desired) {
- return (true);
- }
- }
- offset = last - 1;
- }
- // we don't have to check for "*" as it was already checked
- // at the top (all_allowed), so we just return false
- return false;
- }
-
- /**
- * Returns an enumeration of all the Permission objects in the container.
- *
- * @return Enumeration of all the Permission objects.
- */
- public Enumeration elements() {
- return permissions.elements();
- }
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/util/cdma/ESNCondition.java b/org.osgi.compendium/src/main/java/org/osgi/util/cdma/ESNCondition.java
deleted file mode 100644
index 06bd6f8..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/util/cdma/ESNCondition.java
+++ /dev/null
@@ -1,106 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2007, 2009). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.util.cdma;
-
-import java.security.AccessController;
-import java.security.PrivilegedAction;
-
-import org.osgi.framework.Bundle;
-import org.osgi.service.condpermadmin.Condition;
-import org.osgi.service.condpermadmin.ConditionInfo;
-
-/**
- * Class representing an ESN condition. Instances of this class contain a string
- * value that is matched against the ESN of the device.
- *
- * @ThreadSafe
- * @version $Revision: 6439 $
- */
-public class ESNCondition {
- private static final String ORG_OSGI_UTIL_CDMA_ESN = "org.osgi.util.cdma.esn";
- private static final String ESN;
- private static final int ESN_LENGTH = 8;
-
- static {
- ESN = (String) AccessController.doPrivileged(new PrivilegedAction() {
- public Object run() {
- String esn = System.getProperty(ORG_OSGI_UTIL_CDMA_ESN);
- if (esn == null) {
- return null;
- }
- return esn.toUpperCase();
- }
- });
- }
-
- private ESNCondition() {
- // prevent instances being constructed
- }
-
- /**
- * Creates an ESNCondition object.
- *
- * @param bundle This parameter is ignored, as the ESN number is the
- * property of the mobile device, and thus the same for all bundles.
- * @param conditionInfo Contains the ESN value against which to match the
- * device's ESN. Its {@link ConditionInfo#getArgs()} method should
- * return a String array with one value, the ESN string. The ESN is 8
- * hexadecimal digits (32 bits) without hyphens. Limited pattern
- * matching is allowed: the string is 0 to 7 digits, followed by an
- * asterisk(<code>*</code>).
- * @return A Condition object that indicates whether the specified ESN
- * number matches that of the device. If the number ends with an
- * asterisk ( <code>*</code>), then the beginning of the ESN is
- * compared to the pattern.
- * @throws IllegalArgumentException If the ESN is not a string of 8
- * hexadecimal digits, or 0 to 7 hexadecimal digits with an
- * <code>*</code> at the end.
- */
- public static Condition getCondition(Bundle bundle,
- ConditionInfo conditionInfo) {
- String esn = conditionInfo.getArgs()[0].toUpperCase();
- int length = esn.length();
- if (length > ESN_LENGTH) {
- throw new IllegalArgumentException("ESN too long: " + esn);
- }
- if (esn.endsWith("*")) {
- length--;
- esn = esn.substring(0, length);
- }
- else {
- if (length < ESN_LENGTH) {
- throw new IllegalArgumentException("ESN too short: " + esn);
- }
- }
- for (int i = 0; i < length; i++) {
- char c = esn.charAt(i);
- if (('0' <= c) && (c <= '9')) {
- continue;
- }
- if (('A' <= c) && (c <= 'F')) {
- continue;
- }
- throw new IllegalArgumentException("not a valid ESN: " + esn);
- }
- if (ESN == null) {
- System.err
- .println("The OSGi implementation of org.osgi.util.cdma.ESNCondition needs the system property "
- + ORG_OSGI_UTIL_CDMA_ESN + " set.");
- return Condition.FALSE;
- }
- return ESN.startsWith(esn) ? Condition.TRUE : Condition.FALSE;
- }
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/util/cdma/MEIDCondition.java b/org.osgi.compendium/src/main/java/org/osgi/util/cdma/MEIDCondition.java
deleted file mode 100644
index f5331d0..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/util/cdma/MEIDCondition.java
+++ /dev/null
@@ -1,106 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2007, 2009). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.util.cdma;
-
-import java.security.AccessController;
-import java.security.PrivilegedAction;
-
-import org.osgi.framework.Bundle;
-import org.osgi.service.condpermadmin.Condition;
-import org.osgi.service.condpermadmin.ConditionInfo;
-
-/**
- * Class representing an MEID condition. Instances of this class contain a
- * string value that is matched against the MEID of the device.
- *
- * @ThreadSafe
- * @version $Revision: 6439 $
- */
-public class MEIDCondition {
- private static final String ORG_OSGI_UTIL_CDMA_MEID = "org.osgi.util.cdma.meid";
- private static final String MEID;
- private static final int MEID_LENGTH = 14;
-
- static {
- MEID = (String) AccessController.doPrivileged(new PrivilegedAction() {
- public Object run() {
- String meid = System.getProperty(ORG_OSGI_UTIL_CDMA_MEID);
- if (meid == null) {
- return null;
- }
- return meid.toUpperCase();
- }
- });
- }
-
- private MEIDCondition() {
- // prevent instances being constructed
- }
-
- /**
- * Creates a MEIDCondition object.
- *
- * @param bundle This parameter is ignored, as the MEID number is the
- * property of the mobile device, and thus the same for all bundles.
- * @param conditionInfo Contains the MEID value against which to match the
- * device's MEID. Its {@link ConditionInfo#getArgs()} method should
- * return a String array with one value, the MEID string. The MEID is
- * 14 hexadecimal digits (56 bits) without hyphens. Limited pattern
- * matching is allowed: the string is 0 to 13 digits, followed by an
- * asterisk(<code>*</code>).
- * @return A Condition object that indicates whether the specified MEID
- * number matches that of the device. If the number ends with an
- * asterisk ( <code>*</code>), then the beginning of the MEID is
- * compared to the pattern.
- * @throws IllegalArgumentException If the MEID is not a string of 14
- * hexadecimal digits, or 0 to 13 hexadecimal digits with an
- * <code>*</code> at the end.
- */
- public static Condition getCondition(Bundle bundle,
- ConditionInfo conditionInfo) {
- String meid = conditionInfo.getArgs()[0].toUpperCase();
- int length = meid.length();
- if (length > MEID_LENGTH) {
- throw new IllegalArgumentException("MEID too long: " + meid);
- }
- if (meid.endsWith("*")) {
- length--;
- meid = meid.substring(0, length);
- }
- else {
- if (length < MEID_LENGTH) {
- throw new IllegalArgumentException("MEID too short: " + meid);
- }
- }
- for (int i = 0; i < length; i++) {
- char c = meid.charAt(i);
- if (('0' <= c) && (c <= '9')) {
- continue;
- }
- if (('A' <= c) && (c <= 'F')) {
- continue;
- }
- throw new IllegalArgumentException("not a valid MEID: " + meid);
- }
- if (MEID == null) {
- System.err
- .println("The OSGi implementation of org.osgi.util.cdma.MEIDCondition needs the system property "
- + ORG_OSGI_UTIL_CDMA_MEID + " set.");
- return Condition.FALSE;
- }
- return MEID.startsWith(meid) ? Condition.TRUE : Condition.FALSE;
- }
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/util/gsm/IMEICondition.java b/org.osgi.compendium/src/main/java/org/osgi/util/gsm/IMEICondition.java
deleted file mode 100644
index 79761fa..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/util/gsm/IMEICondition.java
+++ /dev/null
@@ -1,98 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2004, 2009). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.util.gsm;
-
-import java.security.AccessController;
-import java.security.PrivilegedAction;
-
-import org.osgi.framework.Bundle;
-import org.osgi.service.condpermadmin.Condition;
-import org.osgi.service.condpermadmin.ConditionInfo;
-
-/**
- * Class representing an IMEI condition. Instances of this class contain a
- * string value that is matched against the IMEI of the device.
- *
- * @ThreadSafe
- * @version $Revision: 6439 $
- */
-public class IMEICondition {
- private static final String ORG_OSGI_UTIL_GSM_IMEI = "org.osgi.util.gsm.imei";
- private static final String IMEI;
- private static final int IMEI_LENGTH = 15;
-
- static {
- IMEI = (String) AccessController.doPrivileged(new PrivilegedAction() {
- public Object run() {
- return System.getProperty(ORG_OSGI_UTIL_GSM_IMEI);
- }
- });
- }
-
- private IMEICondition() {
- // prevent instances being constructed
- }
-
- /**
- * Creates an IMEI condition object.
- *
- * @param bundle This parameter is ignored, as the IMEI number is a property
- * of the mobile device and thus is the same for all bundles.
- * @param conditionInfo Contains the IMEI value against which to match the
- * device's IMEI. Its {@link ConditionInfo#getArgs()} method should
- * return a String array with one value: the IMEI string. The IMEI is
- * 15 digits without hyphens. Limited pattern matching is allowed:
- * the string is 0 to 14 digits, followed by an asterisk (
- * <code>*</code>).
- * @return A Condition object that indicates whether the specified IMEI
- * number matches that of the device. If the number ends with an
- * asterisk ( <code>*</code>), then the beginning of the IMEI is
- * compared to the pattern.
- * @throws IllegalArgumentException If the IMEI is not a string of 15
- * digits, or 0 to 14 digits with an <code>*</code> at the end.
- */
- public static Condition getCondition(Bundle bundle,
- ConditionInfo conditionInfo) {
- String imei = conditionInfo.getArgs()[0];
- int length = imei.length();
- if (length > IMEI_LENGTH) {
- throw new IllegalArgumentException("IMEI too long: " + imei);
- }
- if (imei.endsWith("*")) {
- length--;
- imei = imei.substring(0, length);
- }
- else {
- if (length < IMEI_LENGTH) {
- throw new IllegalArgumentException("IMEI too short: " + imei);
- }
- }
- for (int i = 0; i < length; i++) {
- char c = imei.charAt(i);
- if (('0' <= c) && (c <= '9')) {
- continue;
- }
- throw new IllegalArgumentException("not a valid IMEI: " + imei);
- }
- if (IMEI == null) {
- System.err
- .println("The OSGi implementation of org.osgi.util.gsm.IMEICondition needs the system property "
- + ORG_OSGI_UTIL_GSM_IMEI + " set.");
- return Condition.FALSE;
- }
- return IMEI.startsWith(imei) ? Condition.TRUE : Condition.FALSE;
- }
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/util/gsm/IMSICondition.java b/org.osgi.compendium/src/main/java/org/osgi/util/gsm/IMSICondition.java
deleted file mode 100644
index d772d7a..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/util/gsm/IMSICondition.java
+++ /dev/null
@@ -1,98 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2004, 2009). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.util.gsm;
-
-import java.security.AccessController;
-import java.security.PrivilegedAction;
-
-import org.osgi.framework.Bundle;
-import org.osgi.service.condpermadmin.Condition;
-import org.osgi.service.condpermadmin.ConditionInfo;
-
-/**
- * Class representing an IMSI condition. Instances of this class contain a
- * string value that is matched against the IMSI of the subscriber.
- *
- * @ThreadSafe
- * @version $Revision: 6439 $
- */
-public class IMSICondition {
- private static final String ORG_OSGI_UTIL_GSM_IMSI = "org.osgi.util.gsm.imsi";
- private static final String IMSI;
- private static final int IMSI_LENGTH = 15;
-
- static {
- IMSI = (String) AccessController.doPrivileged(new PrivilegedAction() {
- public Object run() {
- return System.getProperty(ORG_OSGI_UTIL_GSM_IMSI);
- }
- });
- }
-
- private IMSICondition() {
- // prevent instances being constructed
- }
-
- /**
- * Creates an IMSI condition object.
- *
- * @param bundle This parameter is ignored, as the IMSI number is a property
- * of the mobile subscriber and thus is the same for all bundles.
- * @param conditionInfo Contains the IMSI value against which to match the
- * subscriber's IMSI. Its {@link ConditionInfo#getArgs()} method
- * should return a String array with one value: the IMSI string. The
- * IMSI is 15 digits without hyphens. Limited pattern matching is
- * allowed: the string is 0 to 14 digits, followed by an asterisk (
- * <code>*</code>).
- * @return A Condition object that indicates whether the specified IMSI
- * number matches that of the subscriber. If the number ends with an
- * asterisk (<code>*</code>), then the beginning of the IMSI is
- * compared to the pattern.
- * @throws IllegalArgumentException If the IMSI is not a string of 15
- * digits, or 0 to 14 digits with an <code>*</code> at the end.
- */
- public static Condition getCondition(Bundle bundle,
- ConditionInfo conditionInfo) {
- String imsi = conditionInfo.getArgs()[0];
- int length = imsi.length();
- if (length > IMSI_LENGTH) {
- throw new IllegalArgumentException("IMSI too long: " + imsi);
- }
- if (imsi.endsWith("*")) {
- length--;
- imsi = imsi.substring(0, length);
- }
- else {
- if (length < IMSI_LENGTH) {
- throw new IllegalArgumentException("IMSI too short: " + imsi);
- }
- }
- for (int i = 0; i < length; i++) {
- char c = imsi.charAt(i);
- if (('0' <= c) && (c <= '9')) {
- continue;
- }
- throw new IllegalArgumentException("not a valid IMSI: " + imsi);
- }
- if (IMSI == null) {
- System.err
- .println("The OSGi implementation of org.osgi.util.gsm.IMSICondition needs the system property "
- + ORG_OSGI_UTIL_GSM_IMSI + " set.");
- return Condition.FALSE;
- }
- return IMSI.startsWith(imsi) ? Condition.TRUE : Condition.FALSE;
- }
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/util/measurement/Measurement.java b/org.osgi.compendium/src/main/java/org/osgi/util/measurement/Measurement.java
deleted file mode 100644
index 82779cc..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/util/measurement/Measurement.java
+++ /dev/null
@@ -1,484 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2002, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.util.measurement;
-
-/**
- * Represents a value with an error, a unit and a time-stamp.
- *
- * <p>
- * A <code>Measurement</code> object is used for maintaining the tuple of value,
- * error, unit and time-stamp. The value and error are represented as doubles
- * and the time is measured in milliseconds since midnight, January 1, 1970 UTC.
- *
- * <p>
- * Mathematic methods are provided that correctly calculate taking the error
- * into account. A runtime error will occur when two measurements are used in an
- * incompatible way. E.g., when a speed (m/s) is added to a distance (m). The
- * measurement class will correctly track changes in unit during multiplication
- * and division, always coercing the result to the most simple form. See
- * {@link Unit} for more information on the supported units.
- *
- * <p>
- * Errors in the measurement class are absolute errors. Measurement errors
- * should use the P95 rule. Actual values must fall in the range value +/- error
- * 95% or more of the time.
- *
- * <p>
- * A <code>Measurement</code> object is immutable in order to be easily shared.
- *
- * <p>
- * Note: This class has a natural ordering that is inconsistent with equals. See
- * {@link #compareTo}.
- *
- * @Immutable
- * @version $Revision: 5715 $
- */
-public class Measurement implements Comparable {
- private final double value;
- private final double error;
- private final long time;
- private final Unit unit;
- private transient volatile String name;
- private transient volatile int hashCode;
-
- /**
- * Create a new <code>Measurement</code> object.
- *
- * @param value The value of the <code>Measurement</code>.
- * @param error The error of the <code>Measurement</code>.
- * @param unit The <code>Unit</code> object in which the value is measured. If
- * this argument is <code>null</code>, then the unit will be set to
- * {@link Unit#unity}.
- * @param time The time measured in milliseconds since midnight, January 1,
- * 1970 UTC.
- */
- public Measurement(double value, double error, Unit unit, long time) {
- this.value = value;
- this.error = Math.abs(error);
- this.unit = (unit != null) ? unit : Unit.unity;
- this.time = time;
- }
-
- /**
- * Create a new <code>Measurement</code> object with a time of zero.
- *
- * @param value The value of the <code>Measurement</code>.
- * @param error The error of the <code>Measurement</code>.
- * @param unit The <code>Unit</code> object in which the value is measured. If
- * this argument is <code>null</code>, then the unit will be set to
- * {@link Unit#unity}.
- */
- public Measurement(double value, double error, Unit unit) {
- this(value, error, unit, 0l);
- }
-
- /**
- * Create a new <code>Measurement</code> object with an error of 0.0 and a
- * time of zero.
- *
- * @param value The value of the <code>Measurement</code>.
- * @param unit The <code>Unit</code> in which the value is measured. If this
- * argument is <code>null</code>, then the unit will be set to
- * {@link Unit#unity}.
- */
- public Measurement(double value, Unit unit) {
- this(value, 0.0d, unit, 0l);
- }
-
- /**
- * Create a new <code>Measurement</code> object with an error of 0.0, a unit
- * of {@link Unit#unity} and a time of zero.
- *
- * @param value The value of the <code>Measurement</code>.
- */
- public Measurement(double value) {
- this(value, 0.0d, null, 0l);
- }
-
- /**
- * Returns the value of this <code>Measurement</code> object.
- *
- * @return The value of this <code>Measurement</code> object as a double.
- */
- public final double getValue() {
- return value;
- }
-
- /**
- * Returns the error of this <code>Measurement</code> object. The error is
- * always a positive value.
- *
- * @return The error of this <code>Measurement</code> as a double.
- */
- public final double getError() {
- return error;
- }
-
- /**
- * Returns the <code>Unit</code> object of this <code>Measurement</code> object.
- *
- * @return The <code>Unit</code> object of this <code>Measurement</code> object.
- *
- * @see Unit
- */
- public final Unit getUnit() {
- return unit;
- }
-
- /**
- * Returns the time at which this <code>Measurement</code> object was taken.
- * The time is measured in milliseconds since midnight, January 1, 1970 UTC,
- * or zero when not defined.
- *
- * @return The time at which this <code>Measurement</code> object was taken or
- * zero.
- */
- public final long getTime() {
- return time;
- }
-
- /**
- * Returns a new <code>Measurement</code> object that is the product of this
- * object multiplied by the specified object.
- *
- * @param m The <code>Measurement</code> object that will be multiplied with
- * this object.
- * @return A new <code>Measurement</code> that is the product of this object
- * multiplied by the specified object. The error and unit of the new
- * object are computed. The time of the new object is set to the
- * time of this object.
- * @throws ArithmeticException If the <code>Unit</code> objects of this object
- * and the specified object cannot be multiplied.
- * @see Unit
- */
- public Measurement mul(Measurement m) {
- double mvalue = m.value;
- return new Measurement(value * mvalue, Math.abs(value) * m.error
- + error * Math.abs(mvalue), unit.mul(m.unit), time);
- }
-
- /**
- * Returns a new <code>Measurement</code> object that is the product of this
- * object multiplied by the specified value.
- *
- * @param d The value that will be multiplied with this object.
- * @param u The <code>Unit</code> of the specified value.
- * @return A new <code>Measurement</code> object that is the product of this
- * object multiplied by the specified value. The error and unit of
- * the new object are computed. The time of the new object is set to
- * the time of this object.
- * @throws ArithmeticException If the units of this object and the specified
- * value cannot be multiplied.
- * @see Unit
- */
- public Measurement mul(double d, Unit u) {
- return new Measurement(value * d, error * Math.abs(d), unit.mul(u),
- time);
- }
-
- /**
- * Returns a new <code>Measurement</code> object that is the product of this
- * object multiplied by the specified value.
- *
- * @param d The value that will be multiplied with this object.
- * @return A new <code>Measurement</code> object that is the product of this
- * object multiplied by the specified value. The error of the new
- * object is computed. The unit and time of the new object is set to
- * the unit and time of this object.
- */
- public Measurement mul(double d) {
- return new Measurement(value * d, error * Math.abs(d), unit, time);
- }
-
- /**
- * Returns a new <code>Measurement</code> object that is the quotient of this
- * object divided by the specified object.
- *
- * @param m The <code>Measurement</code> object that will be the divisor of
- * this object.
- * @return A new <code>Measurement</code> object that is the quotient of this
- * object divided by the specified object. The error and unit of the
- * new object are computed. The time of the new object is set to the
- * time of this object.
- * @throws ArithmeticException If the <code>Unit</code> objects of this object
- * and the specified object cannot be divided.
- * @see Unit
- */
- public Measurement div(Measurement m) {
- double mvalue = m.value;
- return new Measurement(value / mvalue,
- (Math.abs(value) * m.error + error * Math.abs(mvalue))
- / (mvalue * mvalue), unit.div(m.unit), time);
- }
-
- /**
- * Returns a new <code>Measurement</code> object that is the quotient of this
- * object divided by the specified value.
- *
- * @param d The value that will be the divisor of this object.
- * @param u The <code>Unit</code> object of the specified value.
- * @return A new <code>Measurement</code> that is the quotient of this object
- * divided by the specified value. The error and unit of the new
- * object are computed. The time of the new object is set to the
- * time of this object.
- * @throws ArithmeticException If the <code>Unit</code> objects of this object
- * and the specified object cannot be divided.
- * @see Unit
- */
- public Measurement div(double d, Unit u) {
- return new Measurement(value / d, error / Math.abs(d), unit.div(u),
- time);
- }
-
- /**
- * Returns a new <code>Measurement</code> object that is the quotient of this
- * object divided by the specified value.
- *
- * @param d The value that will be the divisor of this object.
- * @return A new <code>Measurement</code> object that is the quotient of this
- * object divided by the specified value. The error of the new
- * object is computed. The unit and time of the new object is set to
- * the <code>Unit</code> and time of this object.
- */
- public Measurement div(double d) {
- return new Measurement(value / d, error / Math.abs(d), unit, time);
- }
-
- /**
- * Returns a new <code>Measurement</code> object that is the sum of this
- * object added to the specified object.
- *
- * The error and unit of the new object are computed. The time of the new
- * object is set to the time of this object.
- *
- * @param m The <code>Measurement</code> object that will be added with this
- * object.
- * @return A new <code>Measurement</code> object that is the sum of this and
- * m.
- * @see Unit
- * @throws ArithmeticException If the <code>Unit</code> objects of this object
- * and the specified object cannot be added.
- */
- public Measurement add(Measurement m) {
- return new Measurement(value + m.value, error + m.error, unit
- .add(m.unit), time);
- }
-
- /**
- * Returns a new <code>Measurement</code> object that is the sum of this
- * object added to the specified value.
- *
- * @param d The value that will be added with this object.
- * @param u The <code>Unit</code> object of the specified value.
- * @return A new <code>Measurement</code> object that is the sum of this
- * object added to the specified value. The unit of the new object
- * is computed. The error and time of the new object is set to the
- * error and time of this object.
- * @throws ArithmeticException If the <code>Unit</code> objects of this object
- * and the specified value cannot be added.
- * @see Unit
- */
- public Measurement add(double d, Unit u) {
- return new Measurement(value + d, error, unit.add(u), time);
- }
-
- /**
- * Returns a new <code>Measurement</code> object that is the sum of this
- * object added to the specified value.
- *
- * @param d The value that will be added with this object.
- * @return A new <code>Measurement</code> object that is the sum of this
- * object added to the specified value. The error, unit, and time of
- * the new object is set to the error, <code>Unit</code> and time of
- * this object.
- */
- public Measurement add(double d) {
- return new Measurement(value + d, error, unit, time);
- }
-
- /**
- * Returns a new <code>Measurement</code> object that is the subtraction of
- * the specified object from this object.
- *
- * @param m The <code>Measurement</code> object that will be subtracted from
- * this object.
- * @return A new <code>Measurement</code> object that is the subtraction of
- * the specified object from this object. The error and unit of the
- * new object are computed. The time of the new object is set to the
- * time of this object.
- * @throws ArithmeticException If the <code>Unit</code> objects of this object
- * and the specified object cannot be subtracted.
- * @see Unit
- */
- public Measurement sub(Measurement m) {
- return new Measurement(value - m.value, error + m.error, unit
- .sub(m.unit), time);
- }
-
- /**
- * Returns a new <code>Measurement</code> object that is the subtraction of
- * the specified value from this object.
- *
- * @param d The value that will be subtracted from this object.
- * @param u The <code>Unit</code> object of the specified value.
- * @return A new <code>Measurement</code> object that is the subtraction of
- * the specified value from this object. The unit of the new object
- * is computed. The error and time of the new object is set to the
- * error and time of this object.
- * @throws ArithmeticException If the <code>Unit</code> objects of this object
- * and the specified object cannot be subtracted.
- * @see Unit
- */
- public Measurement sub(double d, Unit u) {
- return new Measurement(value - d, error, unit.sub(u), time);
- }
-
- /**
- * Returns a new <code>Measurement</code> object that is the subtraction of
- * the specified value from this object.
- *
- * @param d The value that will be subtracted from this object.
- * @return A new <code>Measurement</code> object that is the subtraction of
- * the specified value from this object. The error, unit and time of
- * the new object is set to the error, <code>Unit</code> object and
- * time of this object.
- */
- public Measurement sub(double d) {
- return new Measurement(value - d, error, unit, time);
- }
-
- /**
- * Returns a <code>String</code> object representing this <code>Measurement</code>
- * object.
- *
- * @return a <code>String</code> object representing this <code>Measurement</code>
- * object.
- */
- public String toString() {
- String result = name;
- if (result == null) {
- StringBuffer sb = new StringBuffer();
- sb.append(value);
- if (error != 0.0d) {
- sb.append(" +/- ");
- sb.append(error);
- }
- String u = unit.toString();
- if (u.length() > 0) {
- sb.append(" ");
- sb.append(u);
- }
- result = sb.toString();
- name = result;
- }
- return result;
- }
-
- /**
- * Compares this object with the specified object for order. Returns a
- * negative integer, zero, or a positive integer if this object is less
- * than, equal to, or greater than the specified object.
- *
- * <p>
- * Note: This class has a natural ordering that is inconsistent with equals.
- * For this method, another <code>Measurement</code> object is considered
- * equal if there is some <code>x</code> such that
- *
- * <pre>
- * getValue() - getError() <= x <= getValue() + getError()
- * </pre>
- *
- * for both <code>Measurement</code> objects being compared.
- *
- * @param obj The object to be compared.
- * @return A negative integer, zero, or a positive integer if this object is
- * less than, equal to, or greater than the specified object.
- *
- * @throws ClassCastException If the specified object is not of type
- * <code>Measurement</code>.
- * @throws ArithmeticException If the unit of the specified
- * <code>Measurement</code> object is not equal to the <code>Unit</code>
- * object of this object.
- */
- public int compareTo(Object obj) {
- if (this == obj) {
- return 0;
- }
- Measurement that = (Measurement) obj;
- if (!unit.equals(that.unit)) {
- throw new ArithmeticException("Cannot compare " + this + " and "
- + that);
- }
- int result = Double.compare(value, that.value);
- if (result == 0) {
- return 0;
- }
- if (result < 0) {
- if (Double.compare(value + error, that.value - that.error) >= 0) {
- return 0;
- }
- return -1;
- }
- if (Double.compare(value - error, that.value + that.error) <= 0) {
- return 0;
- }
- return 1;
- }
-
- /**
- * Returns a hash code value for this object.
- *
- * @return A hash code value for this object.
- */
- public int hashCode() {
- int h = hashCode;
- if (h == 0) {
- long bits = Double.doubleToLongBits(value);
- h = 31 * 17 + ((int) (bits ^ (bits >>> 32)));
- bits = Double.doubleToLongBits(error);
- h = 31 * h + ((int) (bits ^ (bits >>> 32)));
- h = 31 * h + unit.hashCode();
- hashCode = h;
- }
- return h;
- }
-
- /**
- * Returns whether the specified object is equal to this object. Two
- * <code>Measurement</code> objects are equal if they have same value, error
- * and <code>Unit</code>.
- *
- * <p>
- * Note: This class has a natural ordering that is inconsistent with equals.
- * See {@link #compareTo}.
- *
- * @param obj The object to compare with this object.
- * @return <code>true</code> if this object is equal to the specified object;
- * <code>false</code> otherwise.
- */
- public boolean equals(Object obj) {
- if (this == obj) {
- return true;
- }
- if (!(obj instanceof Measurement)) {
- return false;
- }
- Measurement that = (Measurement) obj;
- return (Double.compare(value, that.value) == 0)
- && (Double.compare(error, that.error) == 0)
- && unit.equals(that.unit);
- }
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/util/measurement/State.java b/org.osgi.compendium/src/main/java/org/osgi/util/measurement/State.java
deleted file mode 100644
index 7fcc469..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/util/measurement/State.java
+++ /dev/null
@@ -1,144 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2002, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.util.measurement;
-
-/**
- * Groups a state name, value and timestamp.
- *
- * <p>
- * The state itself is represented as an integer and the time is measured in
- * milliseconds since midnight, January 1, 1970 UTC.
- *
- * <p>
- * A <code>State</code> object is immutable so that it may be easily shared.
- *
- * @Immutable
- * @version $Revision: 5715 $
- */
-public class State {
- private final int value;
- private final long time;
- private final String name;
-
- /**
- * Create a new <code>State</code> object.
- *
- * @param value The value of the state.
- * @param name The name of the state.
- * @param time The time measured in milliseconds since midnight, January 1,
- * 1970 UTC.
- */
- public State(int value, String name, long time) {
- this.value = value;
- this.name = name;
- this.time = time;
- }
-
- /**
- * Create a new <code>State</code> object with a time of 0.
- *
- * @param value The value of the state.
- * @param name The name of the state.
- */
- public State(int value, String name) {
- this(value, name, 0);
- }
-
- /**
- * Returns the value of this <code>State</code>.
- *
- * @return The value of this <code>State</code> object.
- */
- public final int getValue() {
- return value;
- }
-
- /**
- * Returns the time with which this <code>State</code> was created.
- *
- * @return The time with which this <code>State</code> was created. The time
- * is measured in milliseconds since midnight, January 1, 1970 UTC.
- */
- public final long getTime() {
- return time;
- }
-
- /**
- * Returns the name of this <code>State</code>.
- *
- * @return The name of this <code>State</code> object.
- */
- public final String getName() {
- return name;
- }
-
- /**
- * Returns a <code>String</code> object representing this object.
- *
- * @return a <code>String</code> object representing this object.
- */
- public String toString() {
- StringBuffer sb = new StringBuffer();
- sb.append(value);
- if (name != null) {
- sb.append(" \"");
- sb.append(name);
- sb.append("\"");
- }
- return (sb.toString());
- }
-
- /**
- * Returns a hash code value for this object.
- *
- * @return A hash code value for this object.
- */
- public int hashCode() {
- int hash = 31 * 17 + value;
- if (name != null) {
- hash = 31 * hash + name.hashCode();
- }
- return hash;
- }
-
- /**
- * Return whether the specified object is equal to this object. Two
- * <code>State</code> objects are equal if they have same value and name.
- *
- * @param obj The object to compare with this object.
- * @return <code>true</code> if this object is equal to the specified object;
- * <code>false</code> otherwise.
- */
- public boolean equals(Object obj) {
- if (this == obj) {
- return true;
- }
- if (!(obj instanceof State)) {
- return false;
- }
- State that = (State) obj;
- if (value != that.value) {
- return false;
- }
- if (name == that.name) {
- return true;
- }
- if (name == null) {
- return false;
- }
- return name.equals(that.name);
- }
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/util/measurement/Unit.java b/org.osgi.compendium/src/main/java/org/osgi/util/measurement/Unit.java
deleted file mode 100644
index 5bea0c1..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/util/measurement/Unit.java
+++ /dev/null
@@ -1,521 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2002, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.util.measurement;
-
-import java.util.Hashtable;
-
-/**
- * A unit system for measurements.
- *
- * This class contains definitions of the most common SI units.
- * <p>
- *
- * <p>
- * This class only support exponents for the base SI units in the range -64 to
- * +63. Any operation which produces an exponent outside of this range will
- * result in a <code>Unit</code> object with undefined exponents.
- *
- * @Immutable
- * @version $Revision: 5715 $
- */
-/*
- * This local class maintains the information about units. It can calculate new
- * units when two values are multiplied, divided, added or subtracted. <p> The
- * unit works with the 7 basic SI types + rad + up to 2^6 custom types. For each
- * type, the unit keeps a bit mask with the exponents of the basic types. Eg.
- * m/s is m = 1, s = -1. Multiplying one unit with another means that the bit
- * masks are added, dividing means that the bit masks are subtracted. <p> This
- * class can handle any reasonable combination of SI units. However, it will
- * always try to coerce results back into the basic set. E.g. when you do V*A
- * you should get W and not m2.kg/s3 . Only when the existing types do not match
- * does the unit fallback to the expanded form. <p> This class uses offset
- * arithmetic. This means that the exponents are stored in an long. The special
- * field is used for units that should not be arithmetically divided or
- * multiplied, like longitude and lattitude. These special units can however, be
- * divided and multiplied by the basic 7 constants of the SI, e.g. deg/s.
- */
-public class Unit {
- private final static long UNITY = createType(0, 0, 0, 0, 0, 0, 0,
- 0, 0);
- private final static long ZERO = 0x40L;
- private final static long MASK = 0x7fL;
- private final static int m_SHIFT = 0;
- private final static int s_SHIFT = 7;
- private final static int kg_SHIFT = 14;
- private final static int K_SHIFT = 21;
- private final static int A_SHIFT = 28;
- private final static int mol_SHIFT = 35;
- private final static int cd_SHIFT = 42;
- private final static int rad_SHIFT = 49;
- private final static int x_SHIFT = 56;
- private final static long x_MASK = MASK << x_SHIFT;
- /** No Unit (Unity) */
- public final static Unit unity = new Unit("", UNITY); // Unity
- /* SI Base Units */
- /** The length unit meter (m) */
- public final static Unit m = new Unit("m", createType(0, 0, 0,
- 0, 0, 0, 0, 0, 1)); // Distance
- // meter
- /** The time unit second (s) */
- public final static Unit s = new Unit("s", createType(0, 0, 0,
- 0, 0, 0, 0, 1, 0)); // Time
- // Seconds
- // s
- /** The mass unit kilogram (kg) */
- public final static Unit kg = new Unit("kg", createType(0, 0,
- 0, 0, 0, 0, 1, 0, 0)); // Mass
- // kilogram
- // kg
- /** The temperature unit kelvin (K) */
- public final static Unit K = new Unit("K", createType(0, 0, 0,
- 0, 0, 1, 0, 0, 0)); // Temperature
- // kelvin
- // K
- /** The electric current unit ampere (A) */
- public final static Unit A = new Unit("A", createType(0, 0, 0,
- 0, 1, 0, 0, 0, 0)); // Current
- // ampere
- // A
- /** The amount of substance unit mole (mol) */
- public final static Unit mol = new Unit("mol", createType(0, 0,
- 0, 1, 0, 0, 0, 0, 0)); // Substance
- // mole
- // mol
- /** The luminous intensity unit candela (cd) */
- public final static Unit cd = new Unit("cd", createType(0, 0,
- 1, 0, 0, 0, 0, 0, 0)); // Light
- // candela
- // cd
- /* SI Derived Units */
- /** The speed unit meter per second (m/s) */
- public final static Unit m_s = new Unit("m/s", createType(0, 0,
- 0, 0, 0, 0, 0, -1, 1)); // Speed
- // m/s
- /** The acceleration unit meter per second squared (m/s <sup>2 </sup>) */
- public final static Unit m_s2 = new Unit("m/s2", createType(0, 0,
- 0, 0, 0, 0, 0, -2, 1)); // Acceleration
- // m/s^2
- /** The area unit square meter(m <sup>2 </sup>) */
- public final static Unit m2 = new Unit("m2", createType(0, 0,
- 0, 0, 0, 0, 0, 0, 2)); // Surface
- // m^2
- /** The volume unit cubic meter (m <sup>3 </sup>) */
- public final static Unit m3 = new Unit("m3", createType(0, 0,
- 0, 0, 0, 0, 0, 0, 3)); // Volume
- // m^3
- /**
- * The frequency unit hertz (Hz).
- * <p>
- * hertz is expressed in SI units as 1/s
- */
- public final static Unit Hz = new Unit("Hz", createType(0, 0,
- 0, 0, 0, 0, 0, -1, 0)); // Frequency
- // 1/s
- /**
- * The force unit newton (N).
- * <p>
- * N is expressed in SI units as m·kg/s <sup>2 </sup>
- */
- public final static Unit N = new Unit("N", createType(0, 0, 0,
- 0, 0, 0, 1, -2, 1)); // Force
- // newton
- // (m*kg)/s^2
- /**
- * The pressure unit pascal (Pa).
- * <p>
- * Pa is equal to N/m <sup>2 </sup> or is expressed in SI units as
- * kg/m·s <sup>2 </sup>
- */
- public final static Unit Pa = new Unit("Pa", createType(0, 0,
- 0, 0, 0, 0, 1, -2, -1)); // Pressure
- // pascal
- // kg/(m*s^2)
- /**
- * The energy unit joule (J).
- * <p>
- * joule is equal to N·m or is expressed in SI units as m <sup>2
- * </sup>·kg/s <sup>2
- */
- public final static Unit J = new Unit("J", createType(0, 0, 0,
- 0, 0, 0, 1, -2, 2)); // Energy
- // joule
- // (m^2*kg)/s^2
- /**
- * The power unit watt (W).
- * <p>
- * watt is equal to J/s or is expressed in SI units as m <sup>2
- * </sup>·kg/s <sup>3 </sup>
- */
- public final static Unit W = new Unit("W", createType(0, 0, 0,
- 0, 0, 0, 1, -3, 2)); // Power
- // watt
- // (m^2*kg)/s^3
- /**
- * The electric charge unit coulomb (C).
- * <p>
- * coulomb is expressed in SI units as s·A
- */
- public final static Unit C = new Unit("C", createType(0, 0, 0,
- 0, 1, 0, 0, 1, 0)); // Charge
- // coulumb
- // s*A
- /**
- * The electric potential difference unit volt (V).
- * <p>
- * volt is equal to W/A or is expressed in SI units as m <sup>2
- * </sup>·kg/s <sup>3 </sup>·A
- */
- public final static Unit V = new Unit("V", createType(0, 0, 0,
- 0, -1, 0, 1, -3, 2)); // El.
- // Potent.
- // volt
- // (m^2*kg)/(s^3*A)
- /**
- * The capacitance unit farad (F).
- * <p>
- * farad is equal to C/V or is expressed in SI units as s <sup>4
- * </sup>·A <sup>2 </sup>/m <sup>2 </sup>·kg
- */
- public final static Unit F = new Unit("F", createType(0, 0, 0,
- 0, 2, 0, -1, 4, -2)); // Capacitance
- // farad
- // (s^4*A^2)/(m^2*kg)
- /**
- * The electric resistance unit ohm.
- * <p>
- * ohm is equal to V/A or is expressed in SI units as m <sup>2
- * </sup>·kg/s <sup>3 </sup>·A <sup>2 </sup>
- */
- public final static Unit Ohm = new Unit("Ohm", createType(0, 0,
- 0, 0, -2, 0, 1, -3, 2)); // Resistance
- // ohm
- // (m^2*kg)/(s^3*A^2)
- /**
- * The electric conductance unit siemens (S).
- * <p>
- * siemens is equal to A/V or is expressed in SI units as s <sup>3
- * </sup>·A <sup>2 </sup>/m <sup>2 </sup>·kg
- */
- public final static Unit S = new Unit("S", createType(0, 0, 0,
- 0, 2, 0, -1, 3, -2)); // Conductance
- // siemens
- // (s^3*A^2)/(m^2*kg)
- /**
- * The magnetic flux unit weber (Wb).
- * <p>
- * weber is equal to V·s or is expressed in SI units as m <sup>2
- * </sup>·kg/s <sup>2 </sup>·A
- */
- public final static Unit Wb = new Unit("Wb", createType(0, 0,
- 0, 0, -1, 0, 1, -2, 2)); // Magn.
- // Flux
- // weber
- // (m^2*kg)/(s^2*A)
- /**
- * The magnetic flux density unit tesla (T).
- * <p>
- * tesla is equal to Wb/m <sup>2 </sup> or is expressed in SI units as kg/s
- * <sup>2 </sup>·A
- */
- public final static Unit T = new Unit("T", createType(0, 0, 0,
- 0, -1, 0, 1, -2, 0)); // Magn.
- // Flux
- // Dens.
- // tesla
- // kg/(s^2*A)
- /**
- * The illuminance unit lux (lx).
- * <p>
- * lux is expressed in SI units as cd/m <sup>2 </sup>
- */
- public final static Unit lx = new Unit("lx", createType(0, 0,
- 1, 0, 0, 0, 0, 0, -2)); // Illuminace
- // lux
- // cd/m^2
- /**
- * The absorbed dose unit gray (Gy).
- * <p>
- * Gy is equal to J/kg or is expressed in SI units as m <sup>2 </sup>/s
- * <sup>2 </sup>
- */
- public final static Unit Gy = new Unit("Gy", createType(0, 0,
- 0, 0, 0, 0, 0, -2, 2)); // Absorbed
- // dose
- // gray
- // m^2/s^2
- /**
- * The catalytic activity unit katal (kat).
- * <p>
- * katal is expressed in SI units as mol/s
- */
- public final static Unit kat = new Unit("kat", createType(0, 0,
- 0, 1, 0, 0, 0, -1, 0)); // Catalytic
- // Act.
- // katal
- // mol/s
- /** The angle unit radians (rad) */
- public final static Unit rad = new Unit("rad", createType(0, 1,
- 0, 0, 0, 0, 0, 0, 0)); // Angle
- // radians
- // rad
- /**
- * An array containing all units defined. The first seven items must be m,
- * s, kg, K, A, mol, cd, rad in this order!
- */
- private final static Unit[] allUnits = new Unit[] {m, s, kg, K, A, mol,
- cd, rad, m_s, m_s2, m2, m3, Hz, N, Pa, J, W, C, V, F, Ohm, S, Wb,
- T, lx, Gy, kat, unity };
-
- /* @GuardedBy("this") */
- private static Hashtable base;
- private final String name;
- private final long type;
-
- /**
- * Creates a new <code>Unit</code> instance.
- *
- * @param name the name of the <code>Unit</code>
- * @param type the type of the <code>Unit</code>
- */
- private Unit(String name, long type) {
- if (name == null) {
- name = computeName(type);
- }
- this.name = name;
- this.type = type;
- //System.out.println( name + " " + Long.toHexString( type ) );
- }
-
- /**
- * Create a type field from the base SI unit exponent values.
- *
- */
- private static long createType(int x, int rad, int cd, int mol, int A,
- int K, int kg, int s, int m) {
- return (((ZERO + m) & MASK) << m_SHIFT)
- | (((ZERO + s) & MASK) << s_SHIFT)
- | (((ZERO + kg) & MASK) << kg_SHIFT)
- | (((ZERO + K) & MASK) << K_SHIFT)
- | (((ZERO + A) & MASK) << A_SHIFT)
- | (((ZERO + mol) & MASK) << mol_SHIFT)
- | (((ZERO + cd) & MASK) << cd_SHIFT)
- | (((ZERO + rad) & MASK) << rad_SHIFT)
- | (((long) x) << x_SHIFT);
- }
-
- /**
- * Checks whether this <code>Unit</code> object is equal to the specified
- * <code>Unit</code> object. The <code>Unit</code> objects are considered equal
- * if their exponents are equal.
- *
- * @param obj the <code>Unit</code> object that should be checked for equality
- *
- * @return true if the specified <code>Unit</code> object is equal to this
- * <code>Unit</code> object.
- */
- public boolean equals(Object obj) {
- if (this == obj) {
- return true;
- }
- if (!(obj instanceof Unit)) {
- return false;
- }
- return ((Unit) obj).type == type;
- }
-
- /**
- * Returns the hash code for this object.
- *
- * @return This object's hash code.
- */
- public int hashCode() {
- return 31 * 17 + (int) (type ^ (type >>> 32));
- }
-
- /**
- * Returns a new <code>Unit</code> that is the multiplication of this
- * <code>Unit</code> and the <code>Unit</code> specified
- *
- * @param that the <code>Unit</code> that will be multiplied with this
- * <code>Unit</code>
- *
- * @return a new <code>Unit</code> that is the multiplication of this
- * <code>Unit</code> and the <code>Unit</code> specified
- *
- * @throws RuntimeException if both <code>Unit</code> s are special
- *
- * @see Unit#isSpecial
- */
- Unit mul(Unit that) {
- if (this.isSpecial() && that.isSpecial()) {
- throw new ArithmeticException("Cannot multiply " + this + " with "
- + that);
- }
- return find(this.type - UNITY + that.type);
- }
-
- /**
- * Returns a new <code>Unit</code> that is the division of this <code>Unit</code>
- * and the <code>Unit</code> specified
- *
- * @param that the <code>Unit</code> that this <code>Unit</code> will be divided
- * with
- * @return a new <code>Unit</code> that is the division of this <code>Unit</code>
- * and the <code>Unit</code> specified
- *
- * @throws RuntimeException if both <code>Unit</code> s are special
- *
- * @see Unit#isSpecial
- */
- Unit div(Unit that) {
- if (this.isSpecial() && that.isSpecial()) {
- if (this.type == that.type) {
- return Unit.unity;
- }
- throw new ArithmeticException("Cannot divide " + this + " by "
- + that);
- }
- return find(this.type - that.type + UNITY);
- }
-
- /**
- * Returns a new <code>Unit</code> that is the addition of this <code>Unit</code>
- * and the <code>Unit</code> specified.
- *
- * @param that the <code>Unit</code> that should be added to this
- * <code>Unit</code>
- *
- * @return a new <code>Unit</code> that is the addition of this <code>Unit</code>
- * and the <code>Unit</code> specified.
- *
- * @throws RuntimeException if the two <code>Unit</code> s are not the same
- */
- Unit add(Unit that) {
- if (!this.equals(that)) {
- throw new ArithmeticException("Cannot add " + this + " to " + that);
- }
- return this;
- }
-
- /**
- * Returns a new <code>Unit</code> that is the subtraction between this
- * <code>Unit</code> and the <code>Unit</code> specified.
- *
- * @param that the <code>Unit</code> that will be subtracted from this
- * <code>Unit</code>
- * @return a new <code>Unit</code> that is the subtraction between this
- * <code>Unit</code> and the <code>Unit</code> specified.
- *
- * @throws RuntimeException if the <code>Unit</code> specified is not the same
- * as this <code>Unit</code>
- */
- Unit sub(Unit that) {
- if (!this.equals(that)) {
- throw new ArithmeticException("Cannot subtract " + that + " from "
- + this);
- }
- return this;
- }
-
- /**
- * Finds a <code>Unit</code> based on a type. If the <code>Unit</code> is not
- * found, it will be created and added to the list of all units under a null
- * name.
- *
- * @param type the type of the <code>Unit</code> to find
- *
- * @return the <code>Unit</code>
- */
- static synchronized Unit find(long type) {
- if (base == null) {
- int size = allUnits.length;
- base = new Hashtable(size << 1);
- for (int i = 0; i < size; i++) {
- base.put(allUnits[i], allUnits[i]);
- }
- }
- Unit unit = new Unit(null, type);
- Unit out = (Unit) base.get(unit);
- if (out == null) {
- base.put(unit, unit);
- out = unit;
- }
- return out;
- }
-
- /**
- * Returns a <code>String</code> object representing the <code>Unit</code>
- *
- * @return A <code>String</code> object representing the <code>Unit</code>
- */
- public String toString() {
- return name;
- }
-
- private static String computeName(long type) {
- int m = (int) (((type >> m_SHIFT) & MASK) - ZERO);
- int s = (int) (((type >> s_SHIFT) & MASK) - ZERO);
- int kg = (int) (((type >> kg_SHIFT) & MASK) - ZERO);
- int K = (int) (((type >> K_SHIFT) & MASK) - ZERO);
- int A = (int) (((type >> A_SHIFT) & MASK) - ZERO);
- int mol = (int) (((type >> mol_SHIFT) & MASK) - ZERO);
- int cd = (int) (((type >> cd_SHIFT) & MASK) - ZERO);
- int rad = (int) (((type >> rad_SHIFT) & MASK) - ZERO);
- StringBuffer numerator = new StringBuffer();
- StringBuffer denominator = new StringBuffer();
- addSIname(m, "m", numerator, denominator);
- addSIname(s, "s", numerator, denominator);
- addSIname(kg, "kg", numerator, denominator);
- addSIname(K, "K", numerator, denominator);
- addSIname(A, "A", numerator, denominator);
- addSIname(mol, "mol", numerator, denominator);
- addSIname(cd, "cd", numerator, denominator);
- addSIname(rad, "rad", numerator, denominator);
- if (denominator.length() > 0) {
- if (numerator.length() == 0) {
- numerator.append("1");
- }
- numerator.append("/");
- numerator.append(denominator.toString());
- }
- return numerator.toString();
- }
-
- private static void addSIname(int si, String name, StringBuffer numerator,
- StringBuffer denominator) {
- if (si != 0) {
- StringBuffer sb = (si > 0) ? numerator : denominator;
- if (sb.length() > 0) {
- sb.append("*");
- }
- sb.append(name);
- int power = Math.abs(si);
- if (power > 1) {
- sb.append("^");
- sb.append(power);
- }
- }
- }
-
- /**
- * Checks whether the unit has a special type, i.e. not a SI unit.
- *
- * @return true if the type is special, otherwise false.
- */
- private boolean isSpecial() {
- return (type & x_MASK) != 0;
- }
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/util/mobile/UserPromptCondition.java b/org.osgi.compendium/src/main/java/org/osgi/util/mobile/UserPromptCondition.java
deleted file mode 100644
index 3b40080..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/util/mobile/UserPromptCondition.java
+++ /dev/null
@@ -1,254 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2004, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.util.mobile;
-
-import java.lang.reflect.InvocationTargetException;
-import java.lang.reflect.Method;
-import java.util.Dictionary;
-
-import org.osgi.framework.Bundle;
-import org.osgi.service.condpermadmin.Condition;
-import org.osgi.service.condpermadmin.ConditionInfo;
-
-/**
- * Class representing a user prompt condition. Instances of this class hold two
- * values: a prompt string that is to be displayed to the user and the
- * permission level string according to MIDP2.0 (oneshot, session, blanket).
- *
- */
-public class UserPromptCondition implements Condition {
-
- /*
- * NOTE: An implementor may also choose to replace this class in
- * their distribution with a class that directly interfaces with the
- * policy implementation. This replacement class MUST NOT alter the
- * public/protected signature of this class.
- */
- // this will need to be set by the implementation class
- static Method factory = null;
- Condition realUserPromptCondition;
-
- private final Bundle bundle;
- private final String levels;
- private final String defaultLevel;
- private final String catalogName;
- private final String message;
-
- /**
- * Returns a UserPromptCondition object with the given prompt string and permission
- * level. The user should be given choice as to what level of permission is
- * given. Thus, the lifetime of the permission is controlled by the user.
- *
- * @param bundle the bundle to ask about.
- * @param conditionInfo the conditionInfo containing the construction information. Its
- * {@link ConditionInfo#getArgs()} method should return a String array with 4
- * strings in it:
- * <ol start="0">
- * <li>the possible permission levels. This is a comma-separated list that can contain
- * following strings: ONESHOT SESSION BLANKET. The order is not important. This
- * parameter is case-insensitive.
- * </li>
- * <li>the default permission level, one chosen from the possible permission levels. If
- * it is an empty string, then there is no default. This parameter
- * is case-insensitive.</li>
- * <li>the message catalog base name. It will be loaded by a {@link java.util.ResourceBundle},
- * or equivalent
- * from an exporting OSGi Bundle. Thus, if the catalogName is "com.provider.messages.userprompt",
- * then there should be an OSGi Bundle exporting the "com.provider.messages" package, and inside
- * it files like "userprompt_en_US.properties".</li>
- * <li>textual description of the condition, to be displayed to the user. If
- * it starts with a '%' sign, then the message is looked up from the catalog specified previously.
- * The key is the rest of the string after the '%' sign.</li>
- * </ol>
- * @return The requested UserPromptCondition.
- * @throws IllegalArgumentException if the parameters are malformed.
- * @throws NullPointerException if one of the parameters is <code>null</code>.
- */
- public static Condition getCondition(Bundle bundle,ConditionInfo conditionInfo)
- {
- String[] args = conditionInfo.getArgs();
- if (args==null) throw new NullPointerException("args");
- if (args.length!=4) throw new IllegalArgumentException("args.length=="+args.length+" (should be 4)");
- if (bundle==null) throw new NullPointerException("bundle");
- String levels = args[0];
- String defaultLevel = args[1];
- String catalogName = args[2];
- String message = args[3];
- if (levels==null) throw new NullPointerException("levels");
- if (defaultLevel==null) throw new NullPointerException("defaultLevel");
- if (catalogName==null) throw new NullPointerException("catalogName");
- if (message==null) throw new NullPointerException("message");
-
- if (factory==null) {
- // the bundle implementing the UserPromptCondition has not started yet.
- // Do wrapping magick.
- return new UserPromptCondition(bundle,levels,defaultLevel,catalogName,message);
- } else {
- // there is already a factory, no need to do any wrapping magic
- try {
- return (Condition) factory.invoke(null,new Object[]{bundle,levels,defaultLevel,catalogName,message});
- } catch (IllegalAccessException e) {
- e.printStackTrace();
- } catch (InvocationTargetException e) {
- Throwable original = e.getTargetException();
- if (original instanceof NullPointerException) throw (NullPointerException) original;
- if (original instanceof IllegalArgumentException) throw (IllegalArgumentException) original;
- e.printStackTrace();
- }
- // the factory method is not working, fallback behavior:
- factory = null;
- return new UserPromptCondition(bundle,levels,defaultLevel,catalogName,message);
- }
- }
-
- /**
- * Instances of the UserPromptCondition are simply store the construction parameters
- * until a "real" UserPromptCondition is registered in setFactory(). At that point, it
- * will delegate all calls there.
- * @param unused this parameter is here so that ConditionalPermissionAdmin would not
- * use this as the constructor instead of the getInstance
- * @param bundle
- * @param levels
- * @param defaultLevel
- * @param catalogName
- * @param message
- */
- private UserPromptCondition(Bundle bundle,String levels,String defaultLevel,String catalogName,String message) {
- this.bundle=bundle;
- this.levels=levels;
- this.defaultLevel=defaultLevel;
- this.catalogName=catalogName;
- this.message=message;
- }
-
- /**
- * Check if a factory is registered, and if yes, create userprompt to delegate calls to.
- */
- private void lookForImplementation() {
- if ((realUserPromptCondition==null)&&(factory!=null)) {
- try {
- realUserPromptCondition = (Condition) factory.invoke(null,new Object[]{bundle,levels,defaultLevel,catalogName,message});
- return;
- } catch (IllegalAccessException e) {
- e.printStackTrace();
- } catch (InvocationTargetException e) {
- e.printStackTrace();
- }
- // only if the factory call fails with some invocation exception
- factory = null;
- }
- }
-
- /**
- * Checks if the {@link #isSatisfied()} method needs to prompt the user, thus cannot
- * give results instantly.
- * This depends on the permission level given in
- * {@link UserPromptCondition#getCondition(Bundle, ConditionInfo)}.
- * <ul>
- * <li>ONESHOT - isPostponed always returns true. The user is prompted for question every time.</li>
- * <li>SESSION - isPostponed returns true until the user decides either yes or no for the current session.</li>
- * <li>BLANKET - isPostponed returns true until the user decides either always or never.</li>
- * </ul>
- * Regardless of the session level, the user is always given the option to reject the prompt
- * permanently, as if BLANKET/never was chosen. In this case, the question is not postponed
- * anymore, and {@link #isSatisfied()} returns false.<br/>
- * If the system supports an separately accessible permission management GUI,
- * that may reset the condition
- * to its initial state.
- *
- * @return True, if user interaction is needed.
- */
- public boolean isPostponed() {
- lookForImplementation();
- if (realUserPromptCondition!=null) {
- return realUserPromptCondition.isPostponed();
- } else {
- return true;
- }
- }
-
- /**
- * Checks whether the condition may change during the lifetime of the UserPromptCondition object.
- * This depends on the permission level given in
- * {@link UserPromptCondition#getCondition(Bundle, ConditionInfo)}.
- * <ul>
- * <li>ONESHOT - true</li>
- * <li>SESSION - true, if the application model's session lifetime is
- * shorter than the UserPromptCondition object lifetime</li>
- * <li>BLANKET - false</li>
- * </ul>
- * If the system supports separately accessible permission management GUI,
- * then this function may also return true for SESSION and BLANKET.
- *
- * @return True, if the condition can change.
- */
- public boolean isMutable() {
- lookForImplementation();
- if (realUserPromptCondition!=null) {
- return realUserPromptCondition.isMutable();
- } else {
- // since we don't know what the actual status is, we cannot say
- // "the condition cannot change anymore"
- return true;
- }
- }
-
- /**
- * Displays the prompt string to
- * the user and returns true if the user accepts. Depending on the
- * amount of levels the condition is assigned to, the prompt may have
- * multiple accept buttons and one of them can be selected by default (see
- * default level parameter at {@link UserPromptCondition#getCondition(Bundle, ConditionInfo)}).
- * It must always be possible for the user
- * to stop further prompting of this question, even with ONESHOT and SESSION levels.
- * In case of BLANKET
- * and SESSION levels, it is possible that the user has already answered the question,
- * in this case there will be no prompting, but immediate return with the previous answer.
- *
- * @return True if the user accepts the prompt (or accepts any prompt in
- * case there are multiple permission levels).
- */
- public boolean isSatisfied() {
- lookForImplementation();
- if (realUserPromptCondition!=null) {
- return realUserPromptCondition.isSatisfied();
- } else {
- // paranoid security option
- return false;
- }
- }
-
- /**
- * Checks an array of UserPrompt conditions.
- *
- * @param conds The array containing the UserPrompt conditions to evaluate.
- * @param context Storage area for evaluation. The {@link org.osgi.service.condpermadmin.ConditionalPermissionAdmin}
- * may evaluate a condition several times for one permission check, so this context
- * will be used to store results of ONESHOT questions. This way asking the same question
- * twice in a row can be avoided. If context is null, temporary results will not be stored.
- * @return True, if all conditions are satisfied.
- * @throws NullPointerException if conds is null.
- */
- public boolean isSatisfied(Condition[] conds, Dictionary context) {
- lookForImplementation();
- if (realUserPromptCondition!=null) {
- return realUserPromptCondition.isSatisfied(conds,context);
- } else {
- // paranoid security option
- return false;
- }
- }
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/util/position/Position.java b/org.osgi.compendium/src/main/java/org/osgi/util/position/Position.java
deleted file mode 100644
index 5fe3e0f..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/util/position/Position.java
+++ /dev/null
@@ -1,240 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2002, 2009). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.util.position;
-
-import org.osgi.util.measurement.Measurement;
-import org.osgi.util.measurement.Unit;
-
-/**
- * Position represents a geographic location, based on the WGS84 System (World
- * Geodetic System 1984).
- * <p>
- * The <code>org.osgi.util.measurement.Measurement</code> class is used to
- * represent the values that make up a position.
- * <p>
- * <p>
- * A given position object may lack any of it's components, i.e. the altitude
- * may not be known. Such missing values will be represented by null.
- * <p>
- * Position does not override the implementation of either equals() or
- * hashCode() because it is not clear how missing values should be handled. It
- * is up to the user of a position to determine how best to compare two position
- * objects. A <code>Position</code> object is immutable.
- *
- * @Immutable
- * @version $Revision: 6860 $
- */
-public class Position {
- private final Measurement altitude;
- private final Measurement longitude;
- private final Measurement latitude;
- private final Measurement speed;
- private final Measurement track;
-
- /**
- * Constructs a <code>Position</code> object with the given values.
- *
- * @param lat a <code>Measurement</code> object specifying the latitude in
- * radians, or null
- * @param lon a <code>Measurement</code> object specifying the longitude in
- * radians, or null
- * @param alt a <code>Measurement</code> object specifying the altitude in
- * meters, or null
- * @param speed a <code>Measurement</code> object specifying the speed in
- * meters per second, or null
- * @param track a <code>Measurement</code> object specifying the track in
- * radians, or null
- */
- public Position(Measurement lat, Measurement lon, Measurement alt,
- Measurement speed, Measurement track) {
- if (lat != null) {
- if (!Unit.rad.equals(lat.getUnit())) {
- throw new IllegalArgumentException("Invalid Latitude");
- }
- }
- if (lon != null) {
- if (!Unit.rad.equals(lon.getUnit())) {
- throw new IllegalArgumentException("Invalid Longitude");
- }
- }
- if (alt != null) {
- if (!Unit.m.equals(alt.getUnit())) {
- throw new IllegalArgumentException("Invalid Altitude");
- }
- }
- if (speed != null) {
- if (!Unit.m_s.equals(speed.getUnit())) {
- throw new IllegalArgumentException("Invalid Speed");
- }
- }
- if (track != null) {
- if (!Unit.rad.equals(track.getUnit())) {
- throw new IllegalArgumentException("Invalid Track");
- }
- }
-
- /*
- * Verify the longitude and latitude parameters so they fit the normal
- * coordinate system. A latitude is between -90 (south) and +90 (north).
- * A longitude is between -180 (Western hemisphere) and +180 (eastern
- * hemisphere). This method first normalizes the latitude and longitude
- * between +/- 180. If the |latitude| > 90, then the longitude is added
- * 180 and the latitude is normalized to fit +/-90. (Example are with
- * degrees though radians are used) <br> No normalization takes place
- * when either lon or lat is null.
- */
- normalizeLatLon: {
- if (lat == null || lon == null) {
- break normalizeLatLon;
- }
- double dlat = lat.getValue();
- double dlon = lon.getValue();
- if (dlon >= -LON_RANGE && dlon < LON_RANGE && dlat >= -LAT_RANGE
- && dlat <= LAT_RANGE) {
- break normalizeLatLon;
- }
- dlon = normalize(dlon, LON_RANGE);
- dlat = normalize(dlat, LAT_RANGE * 2.0D); // First over 180 degree
- // Check if we have to move to other side of the earth
- if (dlat > LAT_RANGE || dlat < -LAT_RANGE) {
- dlon = normalize(dlon - LON_RANGE, LON_RANGE);
- dlat = normalize((LAT_RANGE * 2.0D) - dlat, LAT_RANGE);
- }
- lon = new Measurement(dlon, lon.getError(), lon.getUnit(), lon
- .getTime());
- lat = new Measurement(dlat, lat.getError(), lat.getUnit(), lat
- .getTime());
- }
-
- /*
- * Normalize track to be a value such that: 0 <= value < +2PI. This
- * corresponds to 0 deg to +360 deg. 0 is North, 0.5PI is East, PI is
- * South, 1.5PI is West
- */
- normalizeTrack: {
- if (track == null) {
- break normalizeTrack;
- }
- double dtrack = track.getValue();
- if ((0.0D <= dtrack) && (dtrack < TRACK_RANGE)) {
- break normalizeTrack; /* value is already normalized */
- }
- dtrack %= TRACK_RANGE;
- if (dtrack < 0.0D) {
- dtrack += TRACK_RANGE;
- }
- track = new Measurement(dtrack, track.getError(), track.getUnit(),
- track.getTime());
- }
-
- this.latitude = lat;
- this.longitude = lon;
- this.altitude = alt;
- this.speed = speed;
- this.track = track;
- }
-
- /**
- * Returns the altitude of this position in meters.
- *
- * @return a <code>Measurement</code> object in <code>Unit.m</code> representing
- * the altitude in meters above the ellipsoid <code>null</code> if the
- * altitude is not known.
- */
- public Measurement getAltitude() {
- return altitude;
- }
-
- /**
- * Returns the longitude of this position in radians.
- *
- * @return a <code>Measurement</code> object in <code>Unit.rad</code>
- * representing the longitude, or <code>null</code> if the longitude
- * is not known.
- */
- public Measurement getLongitude() {
- return longitude;
- }
-
- /**
- * Returns the latitude of this position in radians.
- *
- * @return a <code>Measurement</code> object in <code>Unit.rad</code>
- * representing the latitude, or <code>null</code> if the latitude is
- * not known..
- */
- public Measurement getLatitude() {
- return latitude;
- }
-
- /**
- * Returns the ground speed of this position in meters per second.
- *
- * @return a <code>Measurement</code> object in <code>Unit.m_s</code>
- * representing the speed, or <code>null</code> if the speed is not
- * known..
- */
- public Measurement getSpeed() {
- return speed;
- }
-
- /**
- * Returns the track of this position in radians as a compass heading. The
- * track is the extrapolation of previous previously measured positions to a
- * future position.
- *
- * @return a <code>Measurement</code> object in <code>Unit.rad</code>
- * representing the track, or <code>null</code> if the track is not
- * known..
- */
- public Measurement getTrack() {
- return track;
- }
-
- private static final double LON_RANGE = Math.PI;
- private static final double LAT_RANGE = Math.PI / 2.0D;
-
- /**
- * This function normalizes the a value according to a range. This is not
- * simple modulo (as I thought when I started), but requires some special
- * handling. For positive numbers we subtract 2*range from the number so
- * that end up between -/+ range. For negative numbers we add this value.
- * For example, if the value is 270 and the range is +/- 180. Then sign=1 so
- * the (int) factor becomes 270+180/360 = 1. This means that 270-360=-90 is
- * the result. (degrees are only used to make it easier to understand, this
- * function is agnostic for radians/degrees). The result will be in
- * [range,range> The algorithm is not very fast, but it handling the
- * [> ranges made it very messy using integer arithmetic, and this is
- * very readable. Note that it is highly unlikely that this method is called
- * in normal situations. Normally input values to position are already
- * normalized because they come from a GPS. And this is much more readable.
- *
- * @param value The value that needs adjusting
- * @param range -range = < value < range
- */
- private static double normalize(double value, double range) {
- double twiceRange = 2.0D * range;
- while (value >= range) {
- value -= twiceRange;
- }
- while (value < -range) {
- value += twiceRange;
- }
- return value;
- }
-
- private static final double TRACK_RANGE = Math.PI * 2.0D;
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/util/tracker/AbstractTracked.java b/org.osgi.compendium/src/main/java/org/osgi/util/tracker/AbstractTracked.java
deleted file mode 100644
index 681148f..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/util/tracker/AbstractTracked.java
+++ /dev/null
@@ -1,449 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2007, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.osgi.util.tracker;
-
-import java.util.ArrayList;
-import java.util.HashMap;
-import java.util.LinkedList;
-import java.util.List;
-import java.util.Map;
-
-/**
- * Abstract class to track items. If a Tracker is reused (closed then reopened),
- * then a new AbstractTracked object is used. This class acts a map of tracked
- * item -> customized object. Subclasses of this class will act as the listener
- * object for the tracker. This class is used to synchronize access to the
- * tracked items. This is not a public class. It is only for use by the
- * implementation of the Tracker class.
- *
- * @ThreadSafe
- * @version $Revision: 5871 $
- * @since 1.4
- */
-abstract class AbstractTracked {
- /* set this to true to compile in debug messages */
- static final boolean DEBUG = false;
-
- /**
- * Map of tracked items to customized objects.
- *
- * @GuardedBy this
- */
- private final Map tracked;
-
- /**
- * Modification count. This field is initialized to zero and incremented by
- * modified.
- *
- * @GuardedBy this
- */
- private int trackingCount;
-
- /**
- * List of items in the process of being added. This is used to deal with
- * nesting of events. Since events may be synchronously delivered, events
- * can be nested. For example, when processing the adding of a service and
- * the customizer causes the service to be unregistered, notification to the
- * nested call to untrack that the service was unregistered can be made to
- * the track method.
- *
- * Since the ArrayList implementation is not synchronized, all access to
- * this list must be protected by the same synchronized object for
- * thread-safety.
- *
- * @GuardedBy this
- */
- private final List adding;
-
- /**
- * true if the tracked object is closed.
- *
- * This field is volatile because it is set by one thread and read by
- * another.
- */
- volatile boolean closed;
-
- /**
- * Initial list of items for the tracker. This is used to correctly process
- * the initial items which could be modified before they are tracked. This
- * is necessary since the initial set of tracked items are not "announced"
- * by events and therefore the event which makes the item untracked could be
- * delivered before we track the item.
- *
- * An item must not be in both the initial and adding lists at the same
- * time. An item must be moved from the initial list to the adding list
- * "atomically" before we begin tracking it.
- *
- * Since the LinkedList implementation is not synchronized, all access to
- * this list must be protected by the same synchronized object for
- * thread-safety.
- *
- * @GuardedBy this
- */
- private final LinkedList initial;
-
- /**
- * AbstractTracked constructor.
- */
- AbstractTracked() {
- tracked = new HashMap();
- trackingCount = 0;
- adding = new ArrayList(6);
- initial = new LinkedList();
- closed = false;
- }
-
- /**
- * Set initial list of items into tracker before events begin to be
- * received.
- *
- * This method must be called from Tracker's open method while synchronized
- * on this object in the same synchronized block as the add listener call.
- *
- * @param list The initial list of items to be tracked. <code>null</code>
- * entries in the list are ignored.
- * @GuardedBy this
- */
- void setInitial(Object[] list) {
- if (list == null) {
- return;
- }
- int size = list.length;
- for (int i = 0; i < size; i++) {
- Object item = list[i];
- if (item == null) {
- continue;
- }
- if (DEBUG) {
- System.out.println("AbstractTracked.setInitial: " + item); //$NON-NLS-1$
- }
- initial.add(item);
- }
- }
-
- /**
- * Track the initial list of items. This is called after events can begin to
- * be received.
- *
- * This method must be called from Tracker's open method while not
- * synchronized on this object after the add listener call.
- *
- */
- void trackInitial() {
- while (true) {
- Object item;
- synchronized (this) {
- if (closed || (initial.size() == 0)) {
- /*
- * if there are no more initial items
- */
- return; /* we are done */
- }
- /*
- * move the first item from the initial list to the adding list
- * within this synchronized block.
- */
- item = initial.removeFirst();
- if (tracked.get(item) != null) {
- /* if we are already tracking this item */
- if (DEBUG) {
- System.out
- .println("AbstractTracked.trackInitial[already tracked]: " + item); //$NON-NLS-1$
- }
- continue; /* skip this item */
- }
- if (adding.contains(item)) {
- /*
- * if this item is already in the process of being added.
- */
- if (DEBUG) {
- System.out
- .println("AbstractTracked.trackInitial[already adding]: " + item); //$NON-NLS-1$
- }
- continue; /* skip this item */
- }
- adding.add(item);
- }
- if (DEBUG) {
- System.out.println("AbstractTracked.trackInitial: " + item); //$NON-NLS-1$
- }
- trackAdding(item, null); /*
- * Begin tracking it. We call trackAdding
- * since we have already put the item in the
- * adding list.
- */
- }
- }
-
- /**
- * Called by the owning Tracker object when it is closed.
- */
- void close() {
- closed = true;
- }
-
- /**
- * Begin to track an item.
- *
- * @param item Item to be tracked.
- * @param related Action related object.
- */
- void track(final Object item, final Object related) {
- final Object object;
- synchronized (this) {
- if (closed) {
- return;
- }
- object = tracked.get(item);
- if (object == null) { /* we are not tracking the item */
- if (adding.contains(item)) {
- /* if this item is already in the process of being added. */
- if (DEBUG) {
- System.out
- .println("AbstractTracked.track[already adding]: " + item); //$NON-NLS-1$
- }
- return;
- }
- adding.add(item); /* mark this item is being added */
- }
- else { /* we are currently tracking this item */
- if (DEBUG) {
- System.out
- .println("AbstractTracked.track[modified]: " + item); //$NON-NLS-1$
- }
- modified(); /* increment modification count */
- }
- }
-
- if (object == null) { /* we are not tracking the item */
- trackAdding(item, related);
- }
- else {
- /* Call customizer outside of synchronized region */
- customizerModified(item, related, object);
- /*
- * If the customizer throws an unchecked exception, it is safe to
- * let it propagate
- */
- }
- }
-
- /**
- * Common logic to add an item to the tracker used by track and
- * trackInitial. The specified item must have been placed in the adding list
- * before calling this method.
- *
- * @param item Item to be tracked.
- * @param related Action related object.
- */
- private void trackAdding(final Object item, final Object related) {
- if (DEBUG) {
- System.out.println("AbstractTracked.trackAdding: " + item); //$NON-NLS-1$
- }
- Object object = null;
- boolean becameUntracked = false;
- /* Call customizer outside of synchronized region */
- try {
- object = customizerAdding(item, related);
- /*
- * If the customizer throws an unchecked exception, it will
- * propagate after the finally
- */
- }
- finally {
- synchronized (this) {
- if (adding.remove(item) && !closed) {
- /*
- * if the item was not untracked during the customizer
- * callback
- */
- if (object != null) {
- tracked.put(item, object);
- modified(); /* increment modification count */
- notifyAll(); /* notify any waiters */
- }
- }
- else {
- becameUntracked = true;
- }
- }
- }
- /*
- * The item became untracked during the customizer callback.
- */
- if (becameUntracked && (object != null)) {
- if (DEBUG) {
- System.out
- .println("AbstractTracked.trackAdding[removed]: " + item); //$NON-NLS-1$
- }
- /* Call customizer outside of synchronized region */
- customizerRemoved(item, related, object);
- /*
- * If the customizer throws an unchecked exception, it is safe to
- * let it propagate
- */
- }
- }
-
- /**
- * Discontinue tracking the item.
- *
- * @param item Item to be untracked.
- * @param related Action related object.
- */
- void untrack(final Object item, final Object related) {
- final Object object;
- synchronized (this) {
- if (initial.remove(item)) { /*
- * if this item is already in the list
- * of initial references to process
- */
- if (DEBUG) {
- System.out
- .println("AbstractTracked.untrack[removed from initial]: " + item); //$NON-NLS-1$
- }
- return; /*
- * we have removed it from the list and it will not be
- * processed
- */
- }
-
- if (adding.remove(item)) { /*
- * if the item is in the process of
- * being added
- */
- if (DEBUG) {
- System.out
- .println("AbstractTracked.untrack[being added]: " + item); //$NON-NLS-1$
- }
- return; /*
- * in case the item is untracked while in the process of
- * adding
- */
- }
- object = tracked.remove(item); /*
- * must remove from tracker before
- * calling customizer callback
- */
- if (object == null) { /* are we actually tracking the item */
- return;
- }
- modified(); /* increment modification count */
- }
- if (DEBUG) {
- System.out.println("AbstractTracked.untrack[removed]: " + item); //$NON-NLS-1$
- }
- /* Call customizer outside of synchronized region */
- customizerRemoved(item, related, object);
- /*
- * If the customizer throws an unchecked exception, it is safe to let it
- * propagate
- */
- }
-
- /**
- * Returns the number of tracked items.
- *
- * @return The number of tracked items.
- *
- * @GuardedBy this
- */
- int size() {
- return tracked.size();
- }
-
- /**
- * Return the customized object for the specified item
- *
- * @param item The item to lookup in the map
- * @return The customized object for the specified item.
- *
- * @GuardedBy this
- */
- Object getCustomizedObject(final Object item) {
- return tracked.get(item);
- }
-
- /**
- * Return the list of tracked items.
- *
- * @param list An array to contain the tracked items.
- * @return The specified list if it is large enough to hold the tracked
- * items or a new array large enough to hold the tracked items.
- * @GuardedBy this
- */
- Object[] getTracked(final Object[] list) {
- return tracked.keySet().toArray(list);
- }
-
- /**
- * Increment the modification count. If this method is overridden, the
- * overriding method MUST call this method to increment the tracking count.
- *
- * @GuardedBy this
- */
- void modified() {
- trackingCount++;
- }
-
- /**
- * Returns the tracking count for this <code>ServiceTracker</code> object.
- *
- * The tracking count is initialized to 0 when this object is opened. Every
- * time an item is added, modified or removed from this object the tracking
- * count is incremented.
- *
- * @GuardedBy this
- * @return The tracking count for this object.
- */
- int getTrackingCount() {
- return trackingCount;
- }
-
- /**
- * Call the specific customizer adding method. This method must not be
- * called while synchronized on this object.
- *
- * @param item Item to be tracked.
- * @param related Action related object.
- * @return Customized object for the tracked item or <code>null</code> if
- * the item is not to be tracked.
- */
- abstract Object customizerAdding(final Object item, final Object related);
-
- /**
- * Call the specific customizer modified method. This method must not be
- * called while synchronized on this object.
- *
- * @param item Tracked item.
- * @param related Action related object.
- * @param object Customized object for the tracked item.
- */
- abstract void customizerModified(final Object item, final Object related,
- final Object object);
-
- /**
- * Call the specific customizer removed method. This method must not be
- * called while synchronized on this object.
- *
- * @param item Tracked item.
- * @param related Action related object.
- * @param object Customized object for the tracked item.
- */
- abstract void customizerRemoved(final Object item, final Object related,
- final Object object);
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/util/tracker/BundleTracker.java b/org.osgi.compendium/src/main/java/org/osgi/util/tracker/BundleTracker.java
deleted file mode 100644
index 8791d98..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/util/tracker/BundleTracker.java
+++ /dev/null
@@ -1,471 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2007, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.osgi.util.tracker;
-
-import org.osgi.framework.Bundle;
-import org.osgi.framework.BundleContext;
-import org.osgi.framework.BundleEvent;
-import org.osgi.framework.SynchronousBundleListener;
-
-/**
- * The <code>BundleTracker</code> class simplifies tracking bundles much like
- * the <code>ServiceTracker</code> simplifies tracking services.
- * <p>
- * A <code>BundleTracker</code> is constructed with state criteria and a
- * <code>BundleTrackerCustomizer</code> object. A <code>BundleTracker</code> can
- * use the <code>BundleTrackerCustomizer</code> to select which bundles are
- * tracked and to create a customized object to be tracked with the bundle. The
- * <code>BundleTracker</code> can then be opened to begin tracking all bundles
- * whose state matches the specified state criteria.
- * <p>
- * The <code>getBundles</code> method can be called to get the
- * <code>Bundle</code> objects of the bundles being tracked. The
- * <code>getObject</code> method can be called to get the customized object for
- * a tracked bundle.
- * <p>
- * The <code>BundleTracker</code> class is thread-safe. It does not call a
- * <code>BundleTrackerCustomizer</code> while holding any locks.
- * <code>BundleTrackerCustomizer</code> implementations must also be
- * thread-safe.
- *
- * @ThreadSafe
- * @version $Revision: 5894 $
- * @since 1.4
- */
-public class BundleTracker implements BundleTrackerCustomizer {
- /* set this to true to compile in debug messages */
- static final boolean DEBUG = false;
-
- /**
- * The Bundle Context used by this <code>BundleTracker</code>.
- */
- protected final BundleContext context;
-
- /**
- * The <code>BundleTrackerCustomizer</code> object for this tracker.
- */
- final BundleTrackerCustomizer customizer;
-
- /**
- * Tracked bundles: <code>Bundle</code> object -> customized Object and
- * <code>BundleListener</code> object
- */
- private volatile Tracked tracked;
-
- /**
- * Accessor method for the current Tracked object. This method is only
- * intended to be used by the unsynchronized methods which do not modify the
- * tracked field.
- *
- * @return The current Tracked object.
- */
- private Tracked tracked() {
- return tracked;
- }
-
- /**
- * State mask for bundles being tracked. This field contains the ORed values
- * of the bundle states being tracked.
- */
- final int mask;
-
- /**
- * Create a <code>BundleTracker</code> for bundles whose state is present in
- * the specified state mask.
- *
- * <p>
- * Bundles whose state is present on the specified state mask will be
- * tracked by this <code>BundleTracker</code>.
- *
- * @param context The <code>BundleContext</code> against which the tracking
- * is done.
- * @param stateMask The bit mask of the <code>OR</code>ing of the bundle
- * states to be tracked.
- * @param customizer The customizer object to call when bundles are added,
- * modified, or removed in this <code>BundleTracker</code>. If
- * customizer is <code>null</code>, then this
- * <code>BundleTracker</code> will be used as the
- * <code>BundleTrackerCustomizer</code> and this
- * <code>BundleTracker</code> will call the
- * <code>BundleTrackerCustomizer</code> methods on itself.
- * @see Bundle#getState()
- */
- public BundleTracker(BundleContext context, int stateMask,
- BundleTrackerCustomizer customizer) {
- this.context = context;
- this.mask = stateMask;
- this.customizer = (customizer == null) ? this : customizer;
- }
-
- /**
- * Open this <code>BundleTracker</code> and begin tracking bundles.
- *
- * <p>
- * Bundle which match the state criteria specified when this
- * <code>BundleTracker</code> was created are now tracked by this
- * <code>BundleTracker</code>.
- *
- * @throws java.lang.IllegalStateException If the <code>BundleContext</code>
- * with which this <code>BundleTracker</code> was created is no
- * longer valid.
- * @throws java.lang.SecurityException If the caller and this class do not
- * have the appropriate
- * <code>AdminPermission[context bundle,LISTENER]</code>, and the
- * Java Runtime Environment supports permissions.
- */
- public void open() {
- final Tracked t;
- synchronized (this) {
- if (tracked != null) {
- return;
- }
- if (DEBUG) {
- System.out.println("BundleTracker.open"); //$NON-NLS-1$
- }
- t = new Tracked();
- synchronized (t) {
- context.addBundleListener(t);
- Bundle[] bundles = context.getBundles();
- if (bundles != null) {
- int length = bundles.length;
- for (int i = 0; i < length; i++) {
- int state = bundles[i].getState();
- if ((state & mask) == 0) {
- /* null out bundles whose states are not interesting */
- bundles[i] = null;
- }
- }
- /* set tracked with the initial bundles */
- t.setInitial(bundles);
- }
- }
- tracked = t;
- }
- /* Call tracked outside of synchronized region */
- t.trackInitial(); /* process the initial references */
- }
-
- /**
- * Close this <code>BundleTracker</code>.
- *
- * <p>
- * This method should be called when this <code>BundleTracker</code> should
- * end the tracking of bundles.
- *
- * <p>
- * This implementation calls {@link #getBundles()} to get the list of
- * tracked bundles to remove.
- */
- public void close() {
- final Bundle[] bundles;
- final Tracked outgoing;
- synchronized (this) {
- outgoing = tracked;
- if (outgoing == null) {
- return;
- }
- if (DEBUG) {
- System.out.println("BundleTracker.close"); //$NON-NLS-1$
- }
- outgoing.close();
- bundles = getBundles();
- tracked = null;
- try {
- context.removeBundleListener(outgoing);
- }
- catch (IllegalStateException e) {
- /* In case the context was stopped. */
- }
- }
- if (bundles != null) {
- for (int i = 0; i < bundles.length; i++) {
- outgoing.untrack(bundles[i], null);
- }
- }
- }
-
- /**
- * Default implementation of the
- * <code>BundleTrackerCustomizer.addingBundle</code> method.
- *
- * <p>
- * This method is only called when this <code>BundleTracker</code> has been
- * constructed with a <code>null BundleTrackerCustomizer</code> argument.
- *
- * <p>
- * This implementation simply returns the specified <code>Bundle</code>.
- *
- * <p>
- * This method can be overridden in a subclass to customize the object to be
- * tracked for the bundle being added.
- *
- * @param bundle The <code>Bundle</code> being added to this
- * <code>BundleTracker</code> object.
- * @param event The bundle event which caused this customizer method to be
- * called or <code>null</code> if there is no bundle event associated
- * with the call to this method.
- * @return The specified bundle.
- * @see BundleTrackerCustomizer#addingBundle(Bundle, BundleEvent)
- */
- public Object addingBundle(Bundle bundle, BundleEvent event) {
- return bundle;
- }
-
- /**
- * Default implementation of the
- * <code>BundleTrackerCustomizer.modifiedBundle</code> method.
- *
- * <p>
- * This method is only called when this <code>BundleTracker</code> has been
- * constructed with a <code>null BundleTrackerCustomizer</code> argument.
- *
- * <p>
- * This implementation does nothing.
- *
- * @param bundle The <code>Bundle</code> whose state has been modified.
- * @param event The bundle event which caused this customizer method to be
- * called or <code>null</code> if there is no bundle event associated
- * with the call to this method.
- * @param object The customized object for the specified Bundle.
- * @see BundleTrackerCustomizer#modifiedBundle(Bundle, BundleEvent, Object)
- */
- public void modifiedBundle(Bundle bundle, BundleEvent event, Object object) {
- /* do nothing */
- }
-
- /**
- * Default implementation of the
- * <code>BundleTrackerCustomizer.removedBundle</code> method.
- *
- * <p>
- * This method is only called when this <code>BundleTracker</code> has been
- * constructed with a <code>null BundleTrackerCustomizer</code> argument.
- *
- * <p>
- * This implementation does nothing.
- *
- * @param bundle The <code>Bundle</code> being removed.
- * @param event The bundle event which caused this customizer method to be
- * called or <code>null</code> if there is no bundle event associated
- * with the call to this method.
- * @param object The customized object for the specified bundle.
- * @see BundleTrackerCustomizer#removedBundle(Bundle, BundleEvent, Object)
- */
- public void removedBundle(Bundle bundle, BundleEvent event, Object object) {
- /* do nothing */
- }
-
- /**
- * Return an array of <code>Bundle</code>s for all bundles being tracked by
- * this <code>BundleTracker</code>.
- *
- * @return An array of <code>Bundle</code>s or <code>null</code> if no
- * bundles are being tracked.
- */
- public Bundle[] getBundles() {
- final Tracked t = tracked();
- if (t == null) { /* if BundleTracker is not open */
- return null;
- }
- synchronized (t) {
- int length = t.size();
- if (length == 0) {
- return null;
- }
- return (Bundle[]) t.getTracked(new Bundle[length]);
- }
- }
-
- /**
- * Returns the customized object for the specified <code>Bundle</code> if
- * the specified bundle is being tracked by this <code>BundleTracker</code>.
- *
- * @param bundle The <code>Bundle</code> being tracked.
- * @return The customized object for the specified <code>Bundle</code> or
- * <code>null</code> if the specified <code>Bundle</code> is not
- * being tracked.
- */
- public Object getObject(Bundle bundle) {
- final Tracked t = tracked();
- if (t == null) { /* if BundleTracker is not open */
- return null;
- }
- synchronized (t) {
- return t.getCustomizedObject(bundle);
- }
- }
-
- /**
- * Remove a bundle from this <code>BundleTracker</code>.
- *
- * The specified bundle will be removed from this <code>BundleTracker</code>
- * . If the specified bundle was being tracked then the
- * <code>BundleTrackerCustomizer.removedBundle</code> method will be called
- * for that bundle.
- *
- * @param bundle The <code>Bundle</code> to be removed.
- */
- public void remove(Bundle bundle) {
- final Tracked t = tracked();
- if (t == null) { /* if BundleTracker is not open */
- return;
- }
- t.untrack(bundle, null);
- }
-
- /**
- * Return the number of bundles being tracked by this
- * <code>BundleTracker</code>.
- *
- * @return The number of bundles being tracked.
- */
- public int size() {
- final Tracked t = tracked();
- if (t == null) { /* if BundleTracker is not open */
- return 0;
- }
- synchronized (t) {
- return t.size();
- }
- }
-
- /**
- * Returns the tracking count for this <code>BundleTracker</code>.
- *
- * The tracking count is initialized to 0 when this
- * <code>BundleTracker</code> is opened. Every time a bundle is added,
- * modified or removed from this <code>BundleTracker</code> the tracking
- * count is incremented.
- *
- * <p>
- * The tracking count can be used to determine if this
- * <code>BundleTracker</code> has added, modified or removed a bundle by
- * comparing a tracking count value previously collected with the current
- * tracking count value. If the value has not changed, then no bundle has
- * been added, modified or removed from this <code>BundleTracker</code>
- * since the previous tracking count was collected.
- *
- * @return The tracking count for this <code>BundleTracker</code> or -1 if
- * this <code>BundleTracker</code> is not open.
- */
- public int getTrackingCount() {
- final Tracked t = tracked();
- if (t == null) { /* if BundleTracker is not open */
- return -1;
- }
- synchronized (t) {
- return t.getTrackingCount();
- }
- }
-
- /**
- * Inner class which subclasses AbstractTracked. This class is the
- * <code>SynchronousBundleListener</code> object for the tracker.
- *
- * @ThreadSafe
- * @since 1.4
- */
- class Tracked extends AbstractTracked implements SynchronousBundleListener {
- /**
- * Tracked constructor.
- */
- Tracked() {
- super();
- }
-
- /**
- * <code>BundleListener</code> method for the <code>BundleTracker</code>
- * class. This method must NOT be synchronized to avoid deadlock
- * potential.
- *
- * @param event <code>BundleEvent</code> object from the framework.
- */
- public void bundleChanged(final BundleEvent event) {
- /*
- * Check if we had a delayed call (which could happen when we
- * close).
- */
- if (closed) {
- return;
- }
- final Bundle bundle = event.getBundle();
- final int state = bundle.getState();
- if (DEBUG) {
- System.out
- .println("BundleTracker.Tracked.bundleChanged[" + state + "]: " + bundle); //$NON-NLS-1$ //$NON-NLS-2$
- }
-
- if ((state & mask) != 0) {
- track(bundle, event);
- /*
- * If the customizer throws an unchecked exception, it is safe
- * to let it propagate
- */
- }
- else {
- untrack(bundle, event);
- /*
- * If the customizer throws an unchecked exception, it is safe
- * to let it propagate
- */
- }
- }
-
- /**
- * Call the specific customizer adding method. This method must not be
- * called while synchronized on this object.
- *
- * @param item Item to be tracked.
- * @param related Action related object.
- * @return Customized object for the tracked item or <code>null</code>
- * if the item is not to be tracked.
- */
- Object customizerAdding(final Object item,
- final Object related) {
- return customizer
- .addingBundle((Bundle) item, (BundleEvent) related);
- }
-
- /**
- * Call the specific customizer modified method. This method must not be
- * called while synchronized on this object.
- *
- * @param item Tracked item.
- * @param related Action related object.
- * @param object Customized object for the tracked item.
- */
- void customizerModified(final Object item,
- final Object related, final Object object) {
- customizer.modifiedBundle((Bundle) item, (BundleEvent) related,
- object);
- }
-
- /**
- * Call the specific customizer removed method. This method must not be
- * called while synchronized on this object.
- *
- * @param item Tracked item.
- * @param related Action related object.
- * @param object Customized object for the tracked item.
- */
- void customizerRemoved(final Object item,
- final Object related, final Object object) {
- customizer.removedBundle((Bundle) item, (BundleEvent) related,
- object);
- }
- }
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/util/tracker/BundleTrackerCustomizer.java b/org.osgi.compendium/src/main/java/org/osgi/util/tracker/BundleTrackerCustomizer.java
deleted file mode 100644
index 100c6b4..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/util/tracker/BundleTrackerCustomizer.java
+++ /dev/null
@@ -1,104 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2007, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.osgi.util.tracker;
-
-import org.osgi.framework.Bundle;
-import org.osgi.framework.BundleEvent;
-
-/**
- * The <code>BundleTrackerCustomizer</code> interface allows a
- * <code>BundleTracker</code> to customize the <code>Bundle</code>s that are
- * tracked. A <code>BundleTrackerCustomizer</code> is called when a bundle is
- * being added to a <code>BundleTracker</code>. The
- * <code>BundleTrackerCustomizer</code> can then return an object for the
- * tracked bundle. A <code>BundleTrackerCustomizer</code> is also called when a
- * tracked bundle is modified or has been removed from a
- * <code>BundleTracker</code>.
- *
- * <p>
- * The methods in this interface may be called as the result of a
- * <code>BundleEvent</code> being received by a <code>BundleTracker</code>.
- * Since <code>BundleEvent</code>s are received synchronously by the
- * <code>BundleTracker</code>, it is highly recommended that implementations of
- * these methods do not alter bundle states while being synchronized on any
- * object.
- *
- * <p>
- * The <code>BundleTracker</code> class is thread-safe. It does not call a
- * <code>BundleTrackerCustomizer</code> while holding any locks.
- * <code>BundleTrackerCustomizer</code> implementations must also be
- * thread-safe.
- *
- * @ThreadSafe
- * @version $Revision: 5874 $
- * @since 1.4
- */
-public interface BundleTrackerCustomizer {
- /**
- * A bundle is being added to the <code>BundleTracker</code>.
- *
- * <p>
- * This method is called before a bundle which matched the search parameters
- * of the <code>BundleTracker</code> is added to the
- * <code>BundleTracker</code>. This method should return the object to be
- * tracked for the specified <code>Bundle</code>. The returned object is
- * stored in the <code>BundleTracker</code> and is available from the
- * {@link BundleTracker#getObject(Bundle) getObject} method.
- *
- * @param bundle The <code>Bundle</code> being added to the
- * <code>BundleTracker</code>.
- * @param event The bundle event which caused this customizer method to be
- * called or <code>null</code> if there is no bundle event associated
- * with the call to this method.
- * @return The object to be tracked for the specified <code>Bundle</code>
- * object or <code>null</code> if the specified <code>Bundle</code>
- * object should not be tracked.
- */
- public Object addingBundle(Bundle bundle, BundleEvent event);
-
- /**
- * A bundle tracked by the <code>BundleTracker</code> has been modified.
- *
- * <p>
- * This method is called when a bundle being tracked by the
- * <code>BundleTracker</code> has had its state modified.
- *
- * @param bundle The <code>Bundle</code> whose state has been modified.
- * @param event The bundle event which caused this customizer method to be
- * called or <code>null</code> if there is no bundle event associated
- * with the call to this method.
- * @param object The tracked object for the specified bundle.
- */
- public void modifiedBundle(Bundle bundle, BundleEvent event,
- Object object);
-
- /**
- * A bundle tracked by the <code>BundleTracker</code> has been removed.
- *
- * <p>
- * This method is called after a bundle is no longer being tracked by the
- * <code>BundleTracker</code>.
- *
- * @param bundle The <code>Bundle</code> that has been removed.
- * @param event The bundle event which caused this customizer method to be
- * called or <code>null</code> if there is no bundle event associated
- * with the call to this method.
- * @param object The tracked object for the specified bundle.
- */
- public void removedBundle(Bundle bundle, BundleEvent event,
- Object object);
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/util/tracker/ServiceTracker.java b/org.osgi.compendium/src/main/java/org/osgi/util/tracker/ServiceTracker.java
deleted file mode 100644
index b4e373b..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/util/tracker/ServiceTracker.java
+++ /dev/null
@@ -1,941 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2000, 2009). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.osgi.util.tracker;
-
-import java.security.AccessController;
-import java.security.PrivilegedAction;
-
-import org.osgi.framework.AllServiceListener;
-import org.osgi.framework.BundleContext;
-import org.osgi.framework.Constants;
-import org.osgi.framework.Filter;
-import org.osgi.framework.InvalidSyntaxException;
-import org.osgi.framework.ServiceEvent;
-import org.osgi.framework.ServiceListener;
-import org.osgi.framework.ServiceReference;
-import org.osgi.framework.Version;
-
-/**
- * The <code>ServiceTracker</code> class simplifies using services from the
- * Framework's service registry.
- * <p>
- * A <code>ServiceTracker</code> object is constructed with search criteria and
- * a <code>ServiceTrackerCustomizer</code> object. A <code>ServiceTracker</code>
- * can use a <code>ServiceTrackerCustomizer</code> to customize the service
- * objects to be tracked. The <code>ServiceTracker</code> can then be opened to
- * begin tracking all services in the Framework's service registry that match
- * the specified search criteria. The <code>ServiceTracker</code> correctly
- * handles all of the details of listening to <code>ServiceEvent</code>s and
- * getting and ungetting services.
- * <p>
- * The <code>getServiceReferences</code> method can be called to get references
- * to the services being tracked. The <code>getService</code> and
- * <code>getServices</code> methods can be called to get the service objects for
- * the tracked service.
- * <p>
- * The <code>ServiceTracker</code> class is thread-safe. It does not call a
- * <code>ServiceTrackerCustomizer</code> while holding any locks.
- * <code>ServiceTrackerCustomizer</code> implementations must also be
- * thread-safe.
- *
- * @ThreadSafe
- * @version $Revision: 6386 $
- */
-public class ServiceTracker implements ServiceTrackerCustomizer {
- /* set this to true to compile in debug messages */
- static final boolean DEBUG = false;
- /**
- * The Bundle Context used by this <code>ServiceTracker</code>.
- */
- protected final BundleContext context;
- /**
- * The Filter used by this <code>ServiceTracker</code> which specifies the
- * search criteria for the services to track.
- *
- * @since 1.1
- */
- protected final Filter filter;
- /**
- * The <code>ServiceTrackerCustomizer</code> for this tracker.
- */
- final ServiceTrackerCustomizer customizer;
- /**
- * Filter string for use when adding the ServiceListener. If this field is
- * set, then certain optimizations can be taken since we don't have a user
- * supplied filter.
- */
- final String listenerFilter;
- /**
- * Class name to be tracked. If this field is set, then we are tracking by
- * class name.
- */
- private final String trackClass;
- /**
- * Reference to be tracked. If this field is set, then we are tracking a
- * single ServiceReference.
- */
- private final ServiceReference trackReference;
- /**
- * Tracked services: <code>ServiceReference</code> -> customized Object and
- * <code>ServiceListener</code> object
- */
- private volatile Tracked tracked;
-
- /**
- * Accessor method for the current Tracked object. This method is only
- * intended to be used by the unsynchronized methods which do not modify the
- * tracked field.
- *
- * @return The current Tracked object.
- */
- private Tracked tracked() {
- return tracked;
- }
-
- /**
- * Cached ServiceReference for getServiceReference.
- *
- * This field is volatile since it is accessed by multiple threads.
- */
- private volatile ServiceReference cachedReference;
- /**
- * Cached service object for getService.
- *
- * This field is volatile since it is accessed by multiple threads.
- */
- private volatile Object cachedService;
-
- /**
- * org.osgi.framework package version which introduced
- * {@link ServiceEvent#MODIFIED_ENDMATCH}
- */
- private static final Version endMatchVersion = new Version(1, 5, 0);
-
- /**
- * Create a <code>ServiceTracker</code> on the specified
- * <code>ServiceReference</code>.
- *
- * <p>
- * The service referenced by the specified <code>ServiceReference</code>
- * will be tracked by this <code>ServiceTracker</code>.
- *
- * @param context The <code>BundleContext</code> against which the tracking
- * is done.
- * @param reference The <code>ServiceReference</code> for the service to be
- * tracked.
- * @param customizer The customizer object to call when services are added,
- * modified, or removed in this <code>ServiceTracker</code>. If
- * customizer is <code>null</code>, then this
- * <code>ServiceTracker</code> will be used as the
- * <code>ServiceTrackerCustomizer</code> and this
- * <code>ServiceTracker</code> will call the
- * <code>ServiceTrackerCustomizer</code> methods on itself.
- */
- public ServiceTracker(final BundleContext context,
- final ServiceReference reference,
- final ServiceTrackerCustomizer customizer) {
- this.context = context;
- this.trackReference = reference;
- this.trackClass = null;
- this.customizer = (customizer == null) ? this : customizer;
- this.listenerFilter = "(" + Constants.SERVICE_ID + "="
- + reference.getProperty(Constants.SERVICE_ID).toString() + ")";
- try {
- this.filter = context.createFilter(listenerFilter);
- }
- catch (InvalidSyntaxException e) {
- /*
- * we could only get this exception if the ServiceReference was
- * invalid
- */
- IllegalArgumentException iae = new IllegalArgumentException(
- "unexpected InvalidSyntaxException: " + e.getMessage());
- iae.initCause(e);
- throw iae;
- }
- }
-
- /**
- * Create a <code>ServiceTracker</code> on the specified class name.
- *
- * <p>
- * Services registered under the specified class name will be tracked by
- * this <code>ServiceTracker</code>.
- *
- * @param context The <code>BundleContext</code> against which the tracking
- * is done.
- * @param clazz The class name of the services to be tracked.
- * @param customizer The customizer object to call when services are added,
- * modified, or removed in this <code>ServiceTracker</code>. If
- * customizer is <code>null</code>, then this
- * <code>ServiceTracker</code> will be used as the
- * <code>ServiceTrackerCustomizer</code> and this
- * <code>ServiceTracker</code> will call the
- * <code>ServiceTrackerCustomizer</code> methods on itself.
- */
- public ServiceTracker(final BundleContext context, final String clazz,
- final ServiceTrackerCustomizer customizer) {
- this.context = context;
- this.trackReference = null;
- this.trackClass = clazz;
- this.customizer = (customizer == null) ? this : customizer;
- // we call clazz.toString to verify clazz is non-null!
- this.listenerFilter = "(" + Constants.OBJECTCLASS + "="
- + clazz.toString() + ")";
- try {
- this.filter = context.createFilter(listenerFilter);
- }
- catch (InvalidSyntaxException e) {
- /*
- * we could only get this exception if the clazz argument was
- * malformed
- */
- IllegalArgumentException iae = new IllegalArgumentException(
- "unexpected InvalidSyntaxException: " + e.getMessage());
- iae.initCause(e);
- throw iae;
- }
- }
-
- /**
- * Create a <code>ServiceTracker</code> on the specified <code>Filter</code>
- * object.
- *
- * <p>
- * Services which match the specified <code>Filter</code> object will be
- * tracked by this <code>ServiceTracker</code>.
- *
- * @param context The <code>BundleContext</code> against which the tracking
- * is done.
- * @param filter The <code>Filter</code> to select the services to be
- * tracked.
- * @param customizer The customizer object to call when services are added,
- * modified, or removed in this <code>ServiceTracker</code>. If
- * customizer is null, then this <code>ServiceTracker</code> will be
- * used as the <code>ServiceTrackerCustomizer</code> and this
- * <code>ServiceTracker</code> will call the
- * <code>ServiceTrackerCustomizer</code> methods on itself.
- * @since 1.1
- */
- public ServiceTracker(final BundleContext context, final Filter filter,
- final ServiceTrackerCustomizer customizer) {
- this.context = context;
- this.trackReference = null;
- this.trackClass = null;
- final Version frameworkVersion = (Version) AccessController
- .doPrivileged(new PrivilegedAction() {
- public Object run() {
- String version = context
- .getProperty(Constants.FRAMEWORK_VERSION);
- return (version == null) ? Version.emptyVersion
- : new Version(version);
- }
- });
- final boolean endMatchSupported = (frameworkVersion
- .compareTo(endMatchVersion) >= 0);
- this.listenerFilter = endMatchSupported ? filter.toString() : null;
- this.filter = filter;
- this.customizer = (customizer == null) ? this : customizer;
- if ((context == null) || (filter == null)) {
- /*
- * we throw a NPE here to be consistent with the other constructors
- */
- throw new NullPointerException();
- }
- }
-
- /**
- * Open this <code>ServiceTracker</code> and begin tracking services.
- *
- * <p>
- * This implementation calls <code>open(false)</code>.
- *
- * @throws java.lang.IllegalStateException If the <code>BundleContext</code>
- * with which this <code>ServiceTracker</code> was created is no
- * longer valid.
- * @see #open(boolean)
- */
- public void open() {
- open(false);
- }
-
- /**
- * Open this <code>ServiceTracker</code> and begin tracking services.
- *
- * <p>
- * Services which match the search criteria specified when this
- * <code>ServiceTracker</code> was created are now tracked by this
- * <code>ServiceTracker</code>.
- *
- * @param trackAllServices If <code>true</code>, then this
- * <code>ServiceTracker</code> will track all matching services
- * regardless of class loader accessibility. If <code>false</code>,
- * then this <code>ServiceTracker</code> will only track matching
- * services which are class loader accessible to the bundle whose
- * <code>BundleContext</code> is used by this
- * <code>ServiceTracker</code>.
- * @throws java.lang.IllegalStateException If the <code>BundleContext</code>
- * with which this <code>ServiceTracker</code> was created is no
- * longer valid.
- * @since 1.3
- */
- public void open(boolean trackAllServices) {
- final Tracked t;
- synchronized (this) {
- if (tracked != null) {
- return;
- }
- if (DEBUG) {
- System.out.println("ServiceTracker.open: " + filter);
- }
- t = trackAllServices ? new AllTracked() : new Tracked();
- synchronized (t) {
- try {
- context.addServiceListener(t, listenerFilter);
- ServiceReference[] references = null;
- if (trackClass != null) {
- references = getInitialReferences(trackAllServices,
- trackClass, null);
- }
- else {
- if (trackReference != null) {
- if (trackReference.getBundle() != null) {
- references = new ServiceReference[] {trackReference};
- }
- }
- else { /* user supplied filter */
- references = getInitialReferences(trackAllServices,
- null,
- (listenerFilter != null) ? listenerFilter
- : filter.toString());
- }
- }
- /* set tracked with the initial references */
- t.setInitial(references);
- }
- catch (InvalidSyntaxException e) {
- throw new RuntimeException(
- "unexpected InvalidSyntaxException: "
- + e.getMessage(), e);
- }
- }
- tracked = t;
- }
- /* Call tracked outside of synchronized region */
- t.trackInitial(); /* process the initial references */
- }
-
- /**
- * Returns the list of initial <code>ServiceReference</code>s that will be
- * tracked by this <code>ServiceTracker</code>.
- *
- * @param trackAllServices If <code>true</code>, use
- * <code>getAllServiceReferences</code>.
- * @param className The class name with which the service was registered, or
- * <code>null</code> for all services.
- * @param filterString The filter criteria or <code>null</code> for all
- * services.
- * @return The list of initial <code>ServiceReference</code>s.
- * @throws InvalidSyntaxException If the specified filterString has an
- * invalid syntax.
- */
- private ServiceReference[] getInitialReferences(boolean trackAllServices,
- String className, String filterString)
- throws InvalidSyntaxException {
- if (trackAllServices) {
- return context.getAllServiceReferences(className, filterString);
- }
- return context.getServiceReferences(className, filterString);
- }
-
- /**
- * Close this <code>ServiceTracker</code>.
- *
- * <p>
- * This method should be called when this <code>ServiceTracker</code> should
- * end the tracking of services.
- *
- * <p>
- * This implementation calls {@link #getServiceReferences()} to get the list
- * of tracked services to remove.
- */
- public void close() {
- final Tracked outgoing;
- final ServiceReference[] references;
- synchronized (this) {
- outgoing = tracked;
- if (outgoing == null) {
- return;
- }
- if (DEBUG) {
- System.out.println("ServiceTracker.close: " + filter);
- }
- outgoing.close();
- references = getServiceReferences();
- tracked = null;
- try {
- context.removeServiceListener(outgoing);
- }
- catch (IllegalStateException e) {
- /* In case the context was stopped. */
- }
- }
- modified(); /* clear the cache */
- synchronized (outgoing) {
- outgoing.notifyAll(); /* wake up any waiters */
- }
- if (references != null) {
- for (int i = 0; i < references.length; i++) {
- outgoing.untrack(references[i], null);
- }
- }
- if (DEBUG) {
- if ((cachedReference == null) && (cachedService == null)) {
- System.out
- .println("ServiceTracker.close[cached cleared]: "
- + filter);
- }
- }
- }
-
- /**
- * Default implementation of the
- * <code>ServiceTrackerCustomizer.addingService</code> method.
- *
- * <p>
- * This method is only called when this <code>ServiceTracker</code> has been
- * constructed with a <code>null ServiceTrackerCustomizer</code> argument.
- *
- * <p>
- * This implementation returns the result of calling <code>getService</code>
- * on the <code>BundleContext</code> with which this
- * <code>ServiceTracker</code> was created passing the specified
- * <code>ServiceReference</code>.
- * <p>
- * This method can be overridden in a subclass to customize the service
- * object to be tracked for the service being added. In that case, take care
- * not to rely on the default implementation of
- * {@link #removedService(ServiceReference, Object) removedService} to unget
- * the service.
- *
- * @param reference The reference to the service being added to this
- * <code>ServiceTracker</code>.
- * @return The service object to be tracked for the service added to this
- * <code>ServiceTracker</code>.
- * @see ServiceTrackerCustomizer#addingService(ServiceReference)
- */
- public Object addingService(ServiceReference reference) {
- return context.getService(reference);
- }
-
- /**
- * Default implementation of the
- * <code>ServiceTrackerCustomizer.modifiedService</code> method.
- *
- * <p>
- * This method is only called when this <code>ServiceTracker</code> has been
- * constructed with a <code>null ServiceTrackerCustomizer</code> argument.
- *
- * <p>
- * This implementation does nothing.
- *
- * @param reference The reference to modified service.
- * @param service The service object for the modified service.
- * @see ServiceTrackerCustomizer#modifiedService(ServiceReference, Object)
- */
- public void modifiedService(ServiceReference reference, Object service) {
- /* do nothing */
- }
-
- /**
- * Default implementation of the
- * <code>ServiceTrackerCustomizer.removedService</code> method.
- *
- * <p>
- * This method is only called when this <code>ServiceTracker</code> has been
- * constructed with a <code>null ServiceTrackerCustomizer</code> argument.
- *
- * <p>
- * This implementation calls <code>ungetService</code>, on the
- * <code>BundleContext</code> with which this <code>ServiceTracker</code>
- * was created, passing the specified <code>ServiceReference</code>.
- * <p>
- * This method can be overridden in a subclass. If the default
- * implementation of {@link #addingService(ServiceReference) addingService}
- * method was used, this method must unget the service.
- *
- * @param reference The reference to removed service.
- * @param service The service object for the removed service.
- * @see ServiceTrackerCustomizer#removedService(ServiceReference, Object)
- */
- public void removedService(ServiceReference reference, Object service) {
- context.ungetService(reference);
- }
-
- /**
- * Wait for at least one service to be tracked by this
- * <code>ServiceTracker</code>. This method will also return when this
- * <code>ServiceTracker</code> is closed.
- *
- * <p>
- * It is strongly recommended that <code>waitForService</code> is not used
- * during the calling of the <code>BundleActivator</code> methods.
- * <code>BundleActivator</code> methods are expected to complete in a short
- * period of time.
- *
- * <p>
- * This implementation calls {@link #getService()} to determine if a service
- * is being tracked.
- *
- * @param timeout The time interval in milliseconds to wait. If zero, the
- * method will wait indefinitely.
- * @return Returns the result of {@link #getService()}.
- * @throws InterruptedException If another thread has interrupted the
- * current thread.
- * @throws IllegalArgumentException If the value of timeout is negative.
- */
- public Object waitForService(long timeout) throws InterruptedException {
- if (timeout < 0) {
- throw new IllegalArgumentException("timeout value is negative");
- }
- Object object = getService();
- while (object == null) {
- final Tracked t = tracked();
- if (t == null) { /* if ServiceTracker is not open */
- return null;
- }
- synchronized (t) {
- if (t.size() == 0) {
- t.wait(timeout);
- }
- }
- object = getService();
- if (timeout > 0) {
- return object;
- }
- }
- return object;
- }
-
- /**
- * Return an array of <code>ServiceReference</code>s for all services being
- * tracked by this <code>ServiceTracker</code>.
- *
- * @return Array of <code>ServiceReference</code>s or <code>null</code> if
- * no services are being tracked.
- */
- public ServiceReference[] getServiceReferences() {
- final Tracked t = tracked();
- if (t == null) { /* if ServiceTracker is not open */
- return null;
- }
- synchronized (t) {
- int length = t.size();
- if (length == 0) {
- return null;
- }
- return (ServiceReference[]) t
- .getTracked(new ServiceReference[length]);
- }
- }
-
- /**
- * Returns a <code>ServiceReference</code> for one of the services being
- * tracked by this <code>ServiceTracker</code>.
- *
- * <p>
- * If multiple services are being tracked, the service with the highest
- * ranking (as specified in its <code>service.ranking</code> property) is
- * returned. If there is a tie in ranking, the service with the lowest
- * service ID (as specified in its <code>service.id</code> property); that
- * is, the service that was registered first is returned. This is the same
- * algorithm used by <code>BundleContext.getServiceReference</code>.
- *
- * <p>
- * This implementation calls {@link #getServiceReferences()} to get the list
- * of references for the tracked services.
- *
- * @return A <code>ServiceReference</code> or <code>null</code> if no
- * services are being tracked.
- * @since 1.1
- */
- public ServiceReference getServiceReference() {
- ServiceReference reference = cachedReference;
- if (reference != null) {
- if (DEBUG) {
- System.out
- .println("ServiceTracker.getServiceReference[cached]: "
- + filter);
- }
- return reference;
- }
- if (DEBUG) {
- System.out.println("ServiceTracker.getServiceReference: " + filter);
- }
- ServiceReference[] references = getServiceReferences();
- int length = (references == null) ? 0 : references.length;
- if (length == 0) { /* if no service is being tracked */
- return null;
- }
- int index = 0;
- if (length > 1) { /* if more than one service, select highest ranking */
- int rankings[] = new int[length];
- int count = 0;
- int maxRanking = Integer.MIN_VALUE;
- for (int i = 0; i < length; i++) {
- Object property = references[i]
- .getProperty(Constants.SERVICE_RANKING);
- int ranking = (property instanceof Integer) ? ((Integer) property)
- .intValue()
- : 0;
- rankings[i] = ranking;
- if (ranking > maxRanking) {
- index = i;
- maxRanking = ranking;
- count = 1;
- }
- else {
- if (ranking == maxRanking) {
- count++;
- }
- }
- }
- if (count > 1) { /* if still more than one service, select lowest id */
- long minId = Long.MAX_VALUE;
- for (int i = 0; i < length; i++) {
- if (rankings[i] == maxRanking) {
- long id = ((Long) (references[i]
- .getProperty(Constants.SERVICE_ID)))
- .longValue();
- if (id < minId) {
- index = i;
- minId = id;
- }
- }
- }
- }
- }
- return cachedReference = references[index];
- }
-
- /**
- * Returns the service object for the specified
- * <code>ServiceReference</code> if the specified referenced service is
- * being tracked by this <code>ServiceTracker</code>.
- *
- * @param reference The reference to the desired service.
- * @return A service object or <code>null</code> if the service referenced
- * by the specified <code>ServiceReference</code> is not being
- * tracked.
- */
- public Object getService(ServiceReference reference) {
- final Tracked t = tracked();
- if (t == null) { /* if ServiceTracker is not open */
- return null;
- }
- synchronized (t) {
- return t.getCustomizedObject(reference);
- }
- }
-
- /**
- * Return an array of service objects for all services being tracked by this
- * <code>ServiceTracker</code>.
- *
- * <p>
- * This implementation calls {@link #getServiceReferences()} to get the list
- * of references for the tracked services and then calls
- * {@link #getService(ServiceReference)} for each reference to get the
- * tracked service object.
- *
- * @return An array of service objects or <code>null</code> if no services
- * are being tracked.
- */
- public Object[] getServices() {
- final Tracked t = tracked();
- if (t == null) { /* if ServiceTracker is not open */
- return null;
- }
- synchronized (t) {
- ServiceReference[] references = getServiceReferences();
- int length = (references == null) ? 0 : references.length;
- if (length == 0) {
- return null;
- }
- Object[] objects = new Object[length];
- for (int i = 0; i < length; i++) {
- objects[i] = getService(references[i]);
- }
- return objects;
- }
- }
-
- /**
- * Returns a service object for one of the services being tracked by this
- * <code>ServiceTracker</code>.
- *
- * <p>
- * If any services are being tracked, this implementation returns the result
- * of calling <code>getService(getServiceReference())</code>.
- *
- * @return A service object or <code>null</code> if no services are being
- * tracked.
- */
- public Object getService() {
- Object service = cachedService;
- if (service != null) {
- if (DEBUG) {
- System.out
- .println("ServiceTracker.getService[cached]: "
- + filter);
- }
- return service;
- }
- if (DEBUG) {
- System.out.println("ServiceTracker.getService: " + filter);
- }
- ServiceReference reference = getServiceReference();
- if (reference == null) {
- return null;
- }
- return cachedService = getService(reference);
- }
-
- /**
- * Remove a service from this <code>ServiceTracker</code>.
- *
- * The specified service will be removed from this
- * <code>ServiceTracker</code>. If the specified service was being tracked
- * then the <code>ServiceTrackerCustomizer.removedService</code> method will
- * be called for that service.
- *
- * @param reference The reference to the service to be removed.
- */
- public void remove(ServiceReference reference) {
- final Tracked t = tracked();
- if (t == null) { /* if ServiceTracker is not open */
- return;
- }
- t.untrack(reference, null);
- }
-
- /**
- * Return the number of services being tracked by this
- * <code>ServiceTracker</code>.
- *
- * @return The number of services being tracked.
- */
- public int size() {
- final Tracked t = tracked();
- if (t == null) { /* if ServiceTracker is not open */
- return 0;
- }
- synchronized (t) {
- return t.size();
- }
- }
-
- /**
- * Returns the tracking count for this <code>ServiceTracker</code>.
- *
- * The tracking count is initialized to 0 when this
- * <code>ServiceTracker</code> is opened. Every time a service is added,
- * modified or removed from this <code>ServiceTracker</code>, the tracking
- * count is incremented.
- *
- * <p>
- * The tracking count can be used to determine if this
- * <code>ServiceTracker</code> has added, modified or removed a service by
- * comparing a tracking count value previously collected with the current
- * tracking count value. If the value has not changed, then no service has
- * been added, modified or removed from this <code>ServiceTracker</code>
- * since the previous tracking count was collected.
- *
- * @since 1.2
- * @return The tracking count for this <code>ServiceTracker</code> or -1 if
- * this <code>ServiceTracker</code> is not open.
- */
- public int getTrackingCount() {
- final Tracked t = tracked();
- if (t == null) { /* if ServiceTracker is not open */
- return -1;
- }
- synchronized (t) {
- return t.getTrackingCount();
- }
- }
-
- /**
- * Called by the Tracked object whenever the set of tracked services is
- * modified. Clears the cache.
- */
- /*
- * This method must not be synchronized since it is called by Tracked while
- * Tracked is synchronized. We don't want synchronization interactions
- * between the listener thread and the user thread.
- */
- void modified() {
- cachedReference = null; /* clear cached value */
- cachedService = null; /* clear cached value */
- if (DEBUG) {
- System.out.println("ServiceTracker.modified: " + filter);
- }
- }
-
- /**
- * Inner class which subclasses AbstractTracked. This class is the
- * <code>ServiceListener</code> object for the tracker.
- *
- * @ThreadSafe
- */
- class Tracked extends AbstractTracked implements ServiceListener {
- /**
- * Tracked constructor.
- */
- Tracked() {
- super();
- }
-
- /**
- * <code>ServiceListener</code> method for the
- * <code>ServiceTracker</code> class. This method must NOT be
- * synchronized to avoid deadlock potential.
- *
- * @param event <code>ServiceEvent</code> object from the framework.
- */
- public void serviceChanged(final ServiceEvent event) {
- /*
- * Check if we had a delayed call (which could happen when we
- * close).
- */
- if (closed) {
- return;
- }
- final ServiceReference reference = event.getServiceReference();
- if (DEBUG) {
- System.out
- .println("ServiceTracker.Tracked.serviceChanged["
- + event.getType() + "]: " + reference);
- }
-
- switch (event.getType()) {
- case ServiceEvent.REGISTERED :
- case ServiceEvent.MODIFIED :
- if (listenerFilter != null) { // service listener added with
- // filter
- track(reference, event);
- /*
- * If the customizer throws an unchecked exception, it
- * is safe to let it propagate
- */
- }
- else { // service listener added without filter
- if (filter.match(reference)) {
- track(reference, event);
- /*
- * If the customizer throws an unchecked exception,
- * it is safe to let it propagate
- */
- }
- else {
- untrack(reference, event);
- /*
- * If the customizer throws an unchecked exception,
- * it is safe to let it propagate
- */
- }
- }
- break;
- case ServiceEvent.MODIFIED_ENDMATCH :
- case ServiceEvent.UNREGISTERING :
- untrack(reference, event);
- /*
- * If the customizer throws an unchecked exception, it is
- * safe to let it propagate
- */
- break;
- }
- }
-
- /**
- * Increment the tracking count and tell the tracker there was a
- * modification.
- *
- * @GuardedBy this
- */
- void modified() {
- super.modified(); /* increment the modification count */
- ServiceTracker.this.modified();
- }
-
- /**
- * Call the specific customizer adding method. This method must not be
- * called while synchronized on this object.
- *
- * @param item Item to be tracked.
- * @param related Action related object.
- * @return Customized object for the tracked item or <code>null</code>
- * if the item is not to be tracked.
- */
- Object customizerAdding(final Object item,
- final Object related) {
- return customizer.addingService((ServiceReference) item);
- }
-
- /**
- * Call the specific customizer modified method. This method must not be
- * called while synchronized on this object.
- *
- * @param item Tracked item.
- * @param related Action related object.
- * @param object Customized object for the tracked item.
- */
- void customizerModified(final Object item,
- final Object related, final Object object) {
- customizer.modifiedService((ServiceReference) item, object);
- }
-
- /**
- * Call the specific customizer removed method. This method must not be
- * called while synchronized on this object.
- *
- * @param item Tracked item.
- * @param related Action related object.
- * @param object Customized object for the tracked item.
- */
- void customizerRemoved(final Object item,
- final Object related, final Object object) {
- customizer.removedService((ServiceReference) item, object);
- }
- }
-
- /**
- * Subclass of Tracked which implements the AllServiceListener interface.
- * This class is used by the ServiceTracker if open is called with true.
- *
- * @since 1.3
- * @ThreadSafe
- */
- class AllTracked extends Tracked implements AllServiceListener {
- /**
- * AllTracked constructor.
- */
- AllTracked() {
- super();
- }
- }
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/util/tracker/ServiceTrackerCustomizer.java b/org.osgi.compendium/src/main/java/org/osgi/util/tracker/ServiceTrackerCustomizer.java
deleted file mode 100644
index 5c270e3..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/util/tracker/ServiceTrackerCustomizer.java
+++ /dev/null
@@ -1,94 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2000, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.osgi.util.tracker;
-
-import org.osgi.framework.ServiceReference;
-
-/**
- * The <code>ServiceTrackerCustomizer</code> interface allows a
- * <code>ServiceTracker</code> to customize the service objects that are
- * tracked. A <code>ServiceTrackerCustomizer</code> is called when a service is
- * being added to a <code>ServiceTracker</code>. The
- * <code>ServiceTrackerCustomizer</code> can then return an object for the
- * tracked service. A <code>ServiceTrackerCustomizer</code> is also called when
- * a tracked service is modified or has been removed from a
- * <code>ServiceTracker</code>.
- *
- * <p>
- * The methods in this interface may be called as the result of a
- * <code>ServiceEvent</code> being received by a <code>ServiceTracker</code>.
- * Since <code>ServiceEvent</code>s are synchronously delivered by the
- * Framework, it is highly recommended that implementations of these methods do
- * not register (<code>BundleContext.registerService</code>), modify (
- * <code>ServiceRegistration.setProperties</code>) or unregister (
- * <code>ServiceRegistration.unregister</code>) a service while being
- * synchronized on any object.
- *
- * <p>
- * The <code>ServiceTracker</code> class is thread-safe. It does not call a
- * <code>ServiceTrackerCustomizer</code> while holding any locks.
- * <code>ServiceTrackerCustomizer</code> implementations must also be
- * thread-safe.
- *
- * @ThreadSafe
- * @version $Revision: 5874 $
- */
-public interface ServiceTrackerCustomizer {
- /**
- * A service is being added to the <code>ServiceTracker</code>.
- *
- * <p>
- * This method is called before a service which matched the search
- * parameters of the <code>ServiceTracker</code> is added to the
- * <code>ServiceTracker</code>. This method should return the service object
- * to be tracked for the specified <code>ServiceReference</code>. The
- * returned service object is stored in the <code>ServiceTracker</code> and
- * is available from the <code>getService</code> and
- * <code>getServices</code> methods.
- *
- * @param reference The reference to the service being added to the
- * <code>ServiceTracker</code>.
- * @return The service object to be tracked for the specified referenced
- * service or <code>null</code> if the specified referenced service
- * should not be tracked.
- */
- public Object addingService(ServiceReference reference);
-
- /**
- * A service tracked by the <code>ServiceTracker</code> has been modified.
- *
- * <p>
- * This method is called when a service being tracked by the
- * <code>ServiceTracker</code> has had it properties modified.
- *
- * @param reference The reference to the service that has been modified.
- * @param service The service object for the specified referenced service.
- */
- public void modifiedService(ServiceReference reference, Object service);
-
- /**
- * A service tracked by the <code>ServiceTracker</code> has been removed.
- *
- * <p>
- * This method is called after a service is no longer being tracked by the
- * <code>ServiceTracker</code>.
- *
- * @param reference The reference to the service that has been removed.
- * @param service The service object for the specified referenced service.
- */
- public void removedService(ServiceReference reference, Object service);
-}
diff --git a/org.osgi.compendium/src/main/java/org/osgi/util/xml/XMLParserActivator.java b/org.osgi.compendium/src/main/java/org/osgi/util/xml/XMLParserActivator.java
deleted file mode 100644
index 963c092..0000000
--- a/org.osgi.compendium/src/main/java/org/osgi/util/xml/XMLParserActivator.java
+++ /dev/null
@@ -1,513 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2002, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.osgi.util.xml;
-
-import java.io.BufferedReader;
-import java.io.IOException;
-import java.io.InputStream;
-import java.io.InputStreamReader;
-import java.net.URL;
-import java.util.ArrayList;
-import java.util.Collections;
-import java.util.Hashtable;
-import java.util.Iterator;
-import java.util.List;
-
-import javax.xml.parsers.DocumentBuilderFactory;
-import javax.xml.parsers.FactoryConfigurationError;
-import javax.xml.parsers.SAXParserFactory;
-
-import org.osgi.framework.Bundle;
-import org.osgi.framework.BundleActivator;
-import org.osgi.framework.BundleContext;
-import org.osgi.framework.Constants;
-import org.osgi.framework.ServiceFactory;
-import org.osgi.framework.ServiceReference;
-import org.osgi.framework.ServiceRegistration;
-
-/**
- * A BundleActivator class that allows any JAXP compliant XML Parser to register
- * itself as an OSGi parser service.
- *
- * Multiple JAXP compliant parsers can concurrently register by using this
- * BundleActivator class. Bundles who wish to use an XML parser can then use the
- * framework's service registry to locate available XML Parsers with the desired
- * characteristics such as validating and namespace-aware.
- *
- * <p>
- * The services that this bundle activator enables a bundle to provide are:
- * <ul>
- * <li><code>javax.xml.parsers.SAXParserFactory</code>({@link #SAXFACTORYNAME})
- * <li><code>javax.xml.parsers.DocumentBuilderFactory</code>(
- * {@link #DOMFACTORYNAME})
- * </ul>
- *
- * <p>
- * The algorithm to find the implementations of the abstract parsers is derived
- * from the JAR file specifications, specifically the Services API.
- * <p>
- * An XMLParserActivator assumes that it can find the class file names of the
- * factory classes in the following files:
- * <ul>
- * <li><code>/META-INF/services/javax.xml.parsers.SAXParserFactory</code> is a
- * file contained in a jar available to the runtime which contains the
- * implementation class name(s) of the SAXParserFactory.
- * <li><code>/META-INF/services/javax.xml.parsers.DocumentBuilderFactory</code>
- * is a file contained in a jar available to the runtime which contains the
- * implementation class name(s) of the <code>DocumentBuilderFactory</code>
- * </ul>
- * <p>
- * If either of the files does not exist, <code>XMLParserActivator</code>
- * assumes that the parser does not support that parser type.
- *
- * <p>
- * <code>XMLParserActivator</code> attempts to instantiate both the
- * <code>SAXParserFactory</code> and the <code>DocumentBuilderFactory</code>. It
- * registers each factory with the framework along with service properties:
- * <ul>
- * <li>{@link #PARSER_VALIDATING}- indicates if this factory supports validating
- * parsers. It's value is a <code>Boolean</code>.
- * <li>{@link #PARSER_NAMESPACEAWARE}- indicates if this factory supports
- * namespace aware parsers It's value is a <code>Boolean</code>.
- * </ul>
- * <p>
- * Individual parser implementations may have additional features, properties,
- * or attributes which could be used to select a parser with a filter. These can
- * be added by extending this class and overriding the
- * <code>setSAXProperties</code> and <code>setDOMProperties</code> methods.
- *
- * @ThreadSafe
- * @version $Revision: 5900 $
- */
-public class XMLParserActivator implements BundleActivator, ServiceFactory {
- /** Context of this bundle */
- private volatile BundleContext context;
- /**
- * Filename containing the SAX Parser Factory Class name. Also used as the
- * basis for the <code>SERVICE_PID<code> registration property.
- */
- public static final String SAXFACTORYNAME = "javax.xml.parsers.SAXParserFactory";
- /**
- * Filename containing the DOM Parser Factory Class name. Also used as the
- * basis for the <code>SERVICE_PID</code> registration property.
- */
- public static final String DOMFACTORYNAME = "javax.xml.parsers.DocumentBuilderFactory";
- /** Path to the factory class name files */
- private static final String PARSERCLASSFILEPATH = "/META-INF/services/";
- /** Fully qualified path name of SAX Parser Factory Class Name file */
- public static final String SAXCLASSFILE = PARSERCLASSFILEPATH
- + SAXFACTORYNAME;
- /** Fully qualified path name of DOM Parser Factory Class Name file */
- public static final String DOMCLASSFILE = PARSERCLASSFILEPATH
- + DOMFACTORYNAME;
- /** SAX Factory Service Description */
- private static final String SAXFACTORYDESCRIPTION = "A JAXP Compliant SAX Parser";
- /** DOM Factory Service Description */
- private static final String DOMFACTORYDESCRIPTION = "A JAXP Compliant DOM Parser";
- /**
- * Service property specifying if factory is configured to support
- * validating parsers. The value is of type <code>Boolean</code>.
- */
- public static final String PARSER_VALIDATING = "parser.validating";
- /**
- * Service property specifying if factory is configured to support namespace
- * aware parsers. The value is of type <code>Boolean</code>.
- */
- public static final String PARSER_NAMESPACEAWARE = "parser.namespaceAware";
- /**
- * Key for parser factory name property - this must be saved in the parsers
- * properties hashtable so that the parser factory can be instantiated from
- * a ServiceReference
- */
- private static final String FACTORYNAMEKEY = "parser.factoryname";
-
- /**
- * Called when this bundle is started so the Framework can perform the
- * bundle-specific activities necessary to start this bundle. This method
- * can be used to register services or to allocate any resources that this
- * bundle needs.
- *
- * <p>
- * This method must complete and return to its caller in a timely manner.
- *
- * <p>
- * This method attempts to register a SAX and DOM parser with the
- * Framework's service registry.
- *
- * @param context The execution context of the bundle being started.
- * @throws java.lang.Exception If this method throws an exception, this
- * bundle is marked as stopped and the Framework will remove this
- * bundle's listeners, unregister all services registered by this
- * bundle, and release all services used by this bundle.
- */
- public void start(BundleContext context) throws Exception {
- this.context = context;
- Bundle parserBundle = context.getBundle();
- // check for sax parsers
- registerSAXParsers(getParserFactoryClassNames(parserBundle
- .getResource(SAXCLASSFILE)));
- // check for dom parsers
- registerDOMParsers(getParserFactoryClassNames(parserBundle
- .getResource(DOMCLASSFILE)));
- }
-
- /**
- * This method has nothing to do as all active service registrations will
- * automatically get unregistered when the bundle stops.
- *
- * @param context The execution context of the bundle being stopped.
- * @throws java.lang.Exception If this method throws an exception, the
- * bundle is still marked as stopped, and the Framework will remove
- * the bundle's listeners, unregister all services registered by the
- * bundle, and release all services used by the bundle.
- */
- public void stop(BundleContext context) throws Exception {
- // framework will automatically unregister the parser services
- }
-
- /**
- * Given the URL for a file, reads and returns the parser class names. There
- * may be multiple classes specified in this file, one per line. There may
- * also be comment lines in the file, which begin with "#".
- *
- * @param parserUrl The URL of the service file containing the parser class
- * names
- * @return A List of strings containing the parser class names.
- * @throws IOException if there is a problem reading the URL input stream
- */
- private List getParserFactoryClassNames(URL parserUrl) throws IOException {
- if (parserUrl == null) {
- return Collections.EMPTY_LIST;
- }
- List v = new ArrayList(1);
- String parserFactoryClassName = null;
- InputStream is = parserUrl.openStream();
- BufferedReader br = new BufferedReader(new InputStreamReader(is));
- while (true) {
- parserFactoryClassName = br.readLine();
- if (parserFactoryClassName == null) {
- break; // end of file reached
- }
- String pfcName = parserFactoryClassName.trim();
- if (pfcName.length() == 0) {
- continue; // blank line
- }
- int commentIdx = pfcName.indexOf("#");
- if (commentIdx == 0) { // comment line
- continue;
- }
- else
- if (commentIdx < 0) { // no comment on this line
- v.add(pfcName);
- }
- else {
- v.add(pfcName.substring(0, commentIdx).trim());
- }
- }
- return v;
- }
-
- /**
- * Register SAX Parser Factory Services with the framework.
- *
- * @param parserFactoryClassNames - a <code>List</code> of
- * <code>String</code> objects containing the names of the parser
- * Factory Classes
- * @throws FactoryConfigurationError if thrown from <code>getFactory</code>
- */
- private void registerSAXParsers(List parserFactoryClassNames)
- throws FactoryConfigurationError {
- Iterator e = parserFactoryClassNames.iterator();
- int index = 0;
- while (e.hasNext()) {
- String parserFactoryClassName = (String) e.next();
- // create a sax parser factory just to get it's default
- // properties. It will never be used since
- // this class will operate as a service factory and give each
- // service requestor it's own SaxParserFactory
- SAXParserFactory factory = (SAXParserFactory) getFactory(parserFactoryClassName);
- Hashtable properties = new Hashtable(7);
- // figure out the default properties of the parser
- setDefaultSAXProperties(factory, properties, index);
- // store the parser factory class name in the properties so that
- // it can be retrieved when getService is called
- // to return a parser factory
- properties.put(FACTORYNAMEKEY, parserFactoryClassName);
- // register the factory as a service
- context.registerService(SAXFACTORYNAME, this, properties);
- index++;
- }
- }
-
- /**
- * <p>
- * Set the SAX Parser Service Properties. By default, the following
- * properties are set:
- * <ul>
- * <li><code>SERVICE_DESCRIPTION</code>
- * <li><code>SERVICE_PID</code>
- * <li><code>PARSER_VALIDATING</code>- instantiates a parser and queries
- * it to find out whether it is validating or not
- * <li><code>PARSER_NAMESPACEAWARE</code>- instantiates a parser and
- * queries it to find out whether it is namespace aware or not
- * <ul>
- *
- * @param factory The <code>SAXParserFactory</code> object
- * @param props <code>Hashtable</code> of service properties.
- */
- private void setDefaultSAXProperties(SAXParserFactory factory,
- Hashtable props, int index) {
- props.put(Constants.SERVICE_DESCRIPTION, SAXFACTORYDESCRIPTION);
- props.put(Constants.SERVICE_PID, SAXFACTORYNAME + "."
- + context.getBundle().getBundleId() + "." + index);
- setSAXProperties(factory, props);
- }
-
- /**
- * <p>
- * Set the customizable SAX Parser Service Properties.
- *
- * <p>
- * This method attempts to instantiate a validating parser and a namespace
- * aware parser to determine if the parser can support those features. The
- * appropriate properties are then set in the specified properties object.
- *
- * <p>
- * This method can be overridden to add additional SAX2 features and
- * properties. If you want to be able to filter searches of the OSGi service
- * registry, this method must put a key, value pair into the properties
- * object for each feature or property. For example,
- *
- * properties.put("http://www.acme.com/features/foo", Boolean.TRUE);
- *
- * @param factory - the SAXParserFactory object
- * @param properties - the properties object for the service
- */
- public void setSAXProperties(SAXParserFactory factory, Hashtable properties) {
- // check if this parser can be configured to validate
- boolean validating = true;
- factory.setValidating(true);
- factory.setNamespaceAware(false);
- try {
- factory.newSAXParser();
- }
- catch (Exception pce_val) {
- validating = false;
- }
- // check if this parser can be configured to be namespaceaware
- boolean namespaceaware = true;
- factory.setValidating(false);
- factory.setNamespaceAware(true);
- try {
- factory.newSAXParser();
- }
- catch (Exception pce_nsa) {
- namespaceaware = false;
- }
- // set the factory values
- factory.setValidating(validating);
- factory.setNamespaceAware(namespaceaware);
- // set the OSGi service properties
- properties.put(PARSER_NAMESPACEAWARE, new Boolean(namespaceaware));
- properties.put(PARSER_VALIDATING, new Boolean(validating));
- }
-
- /**
- * Register DOM Parser Factory Services with the framework.
- *
- * @param parserFactoryClassNames - a <code>List</code> of
- * <code>String</code> objects containing the names of the parser
- * Factory Classes
- * @throws FactoryConfigurationError if thrown from <code>getFactory</code>
- */
- private void registerDOMParsers(List parserFactoryClassNames)
- throws FactoryConfigurationError {
- Iterator e = parserFactoryClassNames.iterator();
- int index = 0;
- while (e.hasNext()) {
- String parserFactoryClassName = (String) e.next();
- // create a dom parser factory just to get it's default
- // properties. It will never be used since
- // this class will operate as a service factory and give each
- // service requestor it's own DocumentBuilderFactory
- DocumentBuilderFactory factory = (DocumentBuilderFactory) getFactory(parserFactoryClassName);
- Hashtable properties = new Hashtable(7);
- // figure out the default properties of the parser
- setDefaultDOMProperties(factory, properties, index);
- // store the parser factory class name in the properties so that
- // it can be retrieved when getService is called
- // to return a parser factory
- properties.put(FACTORYNAMEKEY, parserFactoryClassName);
- // register the factory as a service
- context.registerService(DOMFACTORYNAME, this, properties);
- index++;
- }
- }
-
- /**
- * Set the DOM parser service properties.
- *
- * By default, the following properties are set:
- * <ul>
- * <li><code>SERVICE_DESCRIPTION</code>
- * <li><code>SERVICE_PID</code>
- * <li><code>PARSER_VALIDATING</code>
- * <li><code>PARSER_NAMESPACEAWARE</code>
- * <ul>
- *
- * @param factory The <code>DocumentBuilderFactory</code> object
- * @param props <code>Hashtable</code> of service properties.
- */
- private void setDefaultDOMProperties(DocumentBuilderFactory factory,
- Hashtable props, int index) {
- props.put(Constants.SERVICE_DESCRIPTION, DOMFACTORYDESCRIPTION);
- props.put(Constants.SERVICE_PID, DOMFACTORYNAME + "."
- + context.getBundle().getBundleId() + "." + index);
- setDOMProperties(factory, props);
- }
-
- /**
- * <p>
- * Set the customizable DOM Parser Service Properties.
- *
- * <p>
- * This method attempts to instantiate a validating parser and a namespace
- * aware parser to determine if the parser can support those features. The
- * appropriate properties are then set in the specified props object.
- *
- * <p>
- * This method can be overridden to add additional DOM2 features and
- * properties. If you want to be able to filter searches of the OSGi service
- * registry, this method must put a key, value pair into the properties
- * object for each feature or property. For example,
- *
- * properties.put("http://www.acme.com/features/foo", Boolean.TRUE);
- *
- * @param factory - the DocumentBuilderFactory object
- * @param props - Hashtable of service properties.
- */
- public void setDOMProperties(DocumentBuilderFactory factory, Hashtable props) {
- // check if this parser can be configured to validate
- boolean validating = true;
- factory.setValidating(true);
- factory.setNamespaceAware(false);
- try {
- factory.newDocumentBuilder();
- }
- catch (Exception pce_val) {
- validating = false;
- }
- // check if this parser can be configured to be namespaceaware
- boolean namespaceaware = true;
- factory.setValidating(false);
- factory.setNamespaceAware(true);
- try {
- factory.newDocumentBuilder();
- }
- catch (Exception pce_nsa) {
- namespaceaware = false;
- }
- // set the factory values
- factory.setValidating(validating);
- factory.setNamespaceAware(namespaceaware);
- // set the OSGi service properties
- props.put(PARSER_VALIDATING, new Boolean(validating));
- props.put(PARSER_NAMESPACEAWARE, new Boolean(namespaceaware));
- }
-
- /**
- * Given a parser factory class name, instantiate that class.
- *
- * @param parserFactoryClassName A <code>String</code> object containing
- * the name of the parser factory class
- * @return a parserFactoryClass Object
- * @pre parserFactoryClassName!=null
- */
- private Object getFactory(String parserFactoryClassName)
- throws FactoryConfigurationError {
- try {
- return context.getBundle().loadClass(parserFactoryClassName)
- .newInstance();
- }
- catch (RuntimeException e) {
- throw e;
- }
- catch (Exception e) {
- throw new FactoryConfigurationError(e);
- }
- }
-
- /**
- * Creates a new XML Parser Factory object.
- *
- * <p>
- * A unique XML Parser Factory object is returned for each call to this
- * method.
- *
- * <p>
- * The returned XML Parser Factory object will be configured for validating
- * and namespace aware support as specified in the service properties of the
- * specified ServiceRegistration object.
- *
- * This method can be overridden to configure additional features in the
- * returned XML Parser Factory object.
- *
- * @param bundle The bundle using the service.
- * @param registration The <code>ServiceRegistration</code> object for the
- * service.
- * @return A new, configured XML Parser Factory object or null if a
- * configuration error was encountered
- */
- public Object getService(Bundle bundle, ServiceRegistration registration) {
- ServiceReference sref = registration.getReference();
- String parserFactoryClassName = (String) sref
- .getProperty(FACTORYNAMEKEY);
- // need to set factory properties
- Object factory = getFactory(parserFactoryClassName);
- if (factory instanceof SAXParserFactory) {
- ((SAXParserFactory) factory).setValidating(((Boolean) sref
- .getProperty(PARSER_VALIDATING)).booleanValue());
- ((SAXParserFactory) factory).setNamespaceAware(((Boolean) sref
- .getProperty(PARSER_NAMESPACEAWARE)).booleanValue());
- }
- else {
- if (factory instanceof DocumentBuilderFactory) {
- ((DocumentBuilderFactory) factory)
- .setValidating(((Boolean) sref
- .getProperty(PARSER_VALIDATING)).booleanValue());
- ((DocumentBuilderFactory) factory)
- .setNamespaceAware(((Boolean) sref
- .getProperty(PARSER_NAMESPACEAWARE))
- .booleanValue());
- }
- }
- return factory;
- }
-
- /**
- * Releases a XML Parser Factory object.
- *
- * @param bundle The bundle releasing the service.
- * @param registration The <code>ServiceRegistration</code> object for the
- * service.
- * @param service The XML Parser Factory object returned by a previous call
- * to the <code>getService</code> method.
- */
- public void ungetService(Bundle bundle, ServiceRegistration registration,
- Object service) {
- }
-}
diff --git a/org.osgi.compendium/src/main/resources/about.html b/org.osgi.compendium/src/main/resources/about.html
deleted file mode 100644
index 694d69a..0000000
--- a/org.osgi.compendium/src/main/resources/about.html
+++ /dev/null
@@ -1,38 +0,0 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN">
-<html>
-<head>
-<title>About</title>
-<meta http-equiv=Content-Type content="text/html; charset=UTF-8">
-</head>
-<body lang="EN-US">
-<h2>About This Content</h2>
-
-<h3>Copyright</h3>
-<p>Copyright © OSGi Alliance (2000, 2009). All Rights Reserved.</p>
-
-<p>OSGi Alliance<br/>
-Bishop Ranch 6<br/>
-2400 Camino Ramon, Suite 375<br/>
-San Ramon, CA 94583 USA
-</p>
-
-<h3>License</h3>
-<p>The OSGi Alliance makes available all content in this jar ("Work"). Unless otherwise indicated below, the Work is provided to you under the terms and conditions of the
-Apache License, Version 2.0 (the "License"). A copy of the License is available at <a href="http://www.apache.org/licenses/LICENSE-2.0">http://www.apache.org/licenses/LICENSE-2.0</a>.</p>
-
-<h3>Notices</h3>
-<p>Implementation of certain elements of the Content may be subject to third party
-intellectual property rights, including without limitation, patent rights (such a third party may
-or may not be a member of the OSGi Alliance). The OSGi Alliance and its members are not responsible
-and shall not be held responsible in any manner for identifying or failing to identify any or
-all such third party intellectual property rights.</p>
-
-<p>OSGi™ is a trademark, registered trademark, or service mark
-of The OSGi Alliance in the US and other countries. Java is a trademark,
-registered trademark, or service mark of Sun Microsystems, Inc. in the US
-and other countries. All other trademarks, registered trademarks, or
-service marks used in the Content are the property of their respective
-owners and are hereby recognized.</p>
-
-</body>
-</html>
diff --git a/org.osgi.compendium/src/main/resources/info/dmtree/notification/package.html b/org.osgi.compendium/src/main/resources/info/dmtree/notification/package.html
deleted file mode 100644
index b95e61c..0000000
--- a/org.osgi.compendium/src/main/resources/info/dmtree/notification/package.html
+++ /dev/null
@@ -1,13 +0,0 @@
-<!-- $Revision: 6204 $ -->
-<BODY>
-<p>Device Management Tree Notification Package Version 1.0.
-This package contains the public API of the Notification service. This service
-enables the sending of asynchronous notifications to management servers.
-Permission classes are provided by the <code>info.dmtree.security</code> package.
-<p>Bundles wishing to use this package must list the package
-in the Import-Package header of the bundle's manifest.
-For example:
-<pre>
-Import-Package: info.dmtree.notification;version="[1.0,2.0)"
-</pre>
-</BODY>
diff --git a/org.osgi.compendium/src/main/resources/info/dmtree/notification/packageinfo b/org.osgi.compendium/src/main/resources/info/dmtree/notification/packageinfo
deleted file mode 100644
index 7c8de03..0000000
--- a/org.osgi.compendium/src/main/resources/info/dmtree/notification/packageinfo
+++ /dev/null
@@ -1 +0,0 @@
-version 1.0
diff --git a/org.osgi.compendium/src/main/resources/info/dmtree/notification/spi/package.html b/org.osgi.compendium/src/main/resources/info/dmtree/notification/spi/package.html
deleted file mode 100644
index 7a17cd9..0000000
--- a/org.osgi.compendium/src/main/resources/info/dmtree/notification/spi/package.html
+++ /dev/null
@@ -1,15 +0,0 @@
-<!-- $Revision: 6204 $ -->
-<BODY>
-<p>Device Management Tree Notification SPI Package Version 1.0.
-This package contains the SPI (Service Provider Interface) of the Notification
-service. These interfaces are implemented by Protocol Adapters capable of
-delivering notifications to management servers on a specific protocol. Users of
-the <code>NotificationService</code> interface do not interact directly with this
-package.
-<p>Bundles wishing to use this package must list the package
-in the Import-Package header of the bundle's manifest.
-For example:
-<pre>
-Import-Package: info.dmtree.notification.spi;version="[1.0,2.0)"
-</pre>
-</BODY>
diff --git a/org.osgi.compendium/src/main/resources/info/dmtree/notification/spi/packageinfo b/org.osgi.compendium/src/main/resources/info/dmtree/notification/spi/packageinfo
deleted file mode 100644
index 7c8de03..0000000
--- a/org.osgi.compendium/src/main/resources/info/dmtree/notification/spi/packageinfo
+++ /dev/null
@@ -1 +0,0 @@
-version 1.0
diff --git a/org.osgi.compendium/src/main/resources/info/dmtree/package.html b/org.osgi.compendium/src/main/resources/info/dmtree/package.html
deleted file mode 100644
index 51602f5..0000000
--- a/org.osgi.compendium/src/main/resources/info/dmtree/package.html
+++ /dev/null
@@ -1,16 +0,0 @@
-<!-- $Revision: 6204 $ -->
-<BODY>
-<p>Device Management Tree Package Version 1.0.
-This package contains the public API for the Device Management Tree
-manipulations. Permission classes are provided by the
-<code>info.dmtree.security</code> package, and DMT plugin interfaces can be found in
-the <code>info.dmtree.spi</code> package. Asynchronous notifications to remote
-management servers can be sent using the interfaces in the
-<code>info.dmtree.notification</code> package.
-<p>Bundles wishing to use this package must list the package
-in the Import-Package header of the bundle's manifest.
-For example:
-<pre>
-Import-Package: info.dmtree;version="[1.0,2.0)"
-</pre>
-</BODY>
diff --git a/org.osgi.compendium/src/main/resources/info/dmtree/packageinfo b/org.osgi.compendium/src/main/resources/info/dmtree/packageinfo
deleted file mode 100644
index b3d1f97..0000000
--- a/org.osgi.compendium/src/main/resources/info/dmtree/packageinfo
+++ /dev/null
@@ -1 +0,0 @@
-version 1.0.1
diff --git a/org.osgi.compendium/src/main/resources/info/dmtree/registry/package.html b/org.osgi.compendium/src/main/resources/info/dmtree/registry/package.html
deleted file mode 100644
index b2122ac..0000000
--- a/org.osgi.compendium/src/main/resources/info/dmtree/registry/package.html
+++ /dev/null
@@ -1,15 +0,0 @@
-<!-- $Revision: 6204 $ -->
-<BODY>
-<p>Device Management Tree Registry Package Version 1.0.
-This package contains the factory class providing access to the different
-Device Management services for non-OSGi applications. The
-<code>DmtServiceFactory</code> class contained in this package provides methods
-for retrieving <code>NotificationService</code> and <code>DmtAdmin</code>
-service implementations.
-<p>Bundles wishing to use this package must list the package
-in the Import-Package header of the bundle's manifest.
-For example:
-<pre>
-Import-Package: info.dmtree.registry;version="[1.0,2.0)"
-</pre>
-</BODY>
diff --git a/org.osgi.compendium/src/main/resources/info/dmtree/registry/packageinfo b/org.osgi.compendium/src/main/resources/info/dmtree/registry/packageinfo
deleted file mode 100644
index 7c8de03..0000000
--- a/org.osgi.compendium/src/main/resources/info/dmtree/registry/packageinfo
+++ /dev/null
@@ -1 +0,0 @@
-version 1.0
diff --git a/org.osgi.compendium/src/main/resources/info/dmtree/security/package.html b/org.osgi.compendium/src/main/resources/info/dmtree/security/package.html
deleted file mode 100644
index f5c2fb4..0000000
--- a/org.osgi.compendium/src/main/resources/info/dmtree/security/package.html
+++ /dev/null
@@ -1,12 +0,0 @@
-<!-- $Revision: 6204 $ -->
-<BODY>
-<p>Device Management Tree Security Package Version 1.0.
-This package contains the permission classes used by the Device
-Management API in environments that support the Java 2 security model.
-<p>Bundles wishing to use this package must list the package
-in the Import-Package header of the bundle's manifest.
-For example:
-<pre>
-Import-Package: info.dmtree.security;version="[1.0,2.0)"
-</pre>
-</BODY>
diff --git a/org.osgi.compendium/src/main/resources/info/dmtree/security/packageinfo b/org.osgi.compendium/src/main/resources/info/dmtree/security/packageinfo
deleted file mode 100644
index 7c8de03..0000000
--- a/org.osgi.compendium/src/main/resources/info/dmtree/security/packageinfo
+++ /dev/null
@@ -1 +0,0 @@
-version 1.0
diff --git a/org.osgi.compendium/src/main/resources/info/dmtree/spi/package.html b/org.osgi.compendium/src/main/resources/info/dmtree/spi/package.html
deleted file mode 100644
index 63291f7..0000000
--- a/org.osgi.compendium/src/main/resources/info/dmtree/spi/package.html
+++ /dev/null
@@ -1,13 +0,0 @@
-<!-- $Revision: 6204 $ -->
-<BODY>
-<p>Device Management Tree SPI Package Version 1.0.
-This package contains the interface classes that compose the Device Management
-SPI (Service Provider Interface). These interfaces are implemented by DMT plugins;
-users of the <code>DmtAdmin</code> interface do not interact directly with these.
-<p>Bundles wishing to use this package must list the package
-in the Import-Package header of the bundle's manifest.
-For example:
-<pre>
-Import-Package: info.dmtree.spi;version="[1.0,2.0)"
-</pre>
-</BODY>
diff --git a/org.osgi.compendium/src/main/resources/info/dmtree/spi/packageinfo b/org.osgi.compendium/src/main/resources/info/dmtree/spi/packageinfo
deleted file mode 100644
index 7c8de03..0000000
--- a/org.osgi.compendium/src/main/resources/info/dmtree/spi/packageinfo
+++ /dev/null
@@ -1 +0,0 @@
-version 1.0
diff --git a/org.osgi.compendium/src/main/resources/org/osgi/application/package.html b/org.osgi.compendium/src/main/resources/org/osgi/application/package.html
deleted file mode 100644
index 5230b62..0000000
--- a/org.osgi.compendium/src/main/resources/org/osgi/application/package.html
+++ /dev/null
@@ -1,10 +0,0 @@
-<!-- $Revision: 6204 $ -->
-<BODY>
-<p>Foreign Application Package Version 1.0.
-<p>Bundles wishing to use this package must list the package
-in the Import-Package header of the bundle's manifest.
-For example:
-<pre>
-Import-Package: org.osgi.application; version="[1.0,2.0)"
-</pre>
-</BODY>
diff --git a/org.osgi.compendium/src/main/resources/org/osgi/application/packageinfo b/org.osgi.compendium/src/main/resources/org/osgi/application/packageinfo
deleted file mode 100644
index 7c8de03..0000000
--- a/org.osgi.compendium/src/main/resources/org/osgi/application/packageinfo
+++ /dev/null
@@ -1 +0,0 @@
-version 1.0
diff --git a/org.osgi.compendium/src/main/resources/org/osgi/service/application/package.html b/org.osgi.compendium/src/main/resources/org/osgi/service/application/package.html
deleted file mode 100644
index 18daeb5..0000000
--- a/org.osgi.compendium/src/main/resources/org/osgi/service/application/package.html
+++ /dev/null
@@ -1,11 +0,0 @@
-<!-- $Revision: 6204 $ -->
-<BODY>
-<p>Application Package Version 1.1.
-<p>Bundles wishing to use this package must list the package
-in the Import-Package header of the bundle's manifest.
-For example:
-<pre>
-Import-Package: org.osgi.service.application; version="[1.1,2.0)"
-</pre>
-</BODY>
-
diff --git a/org.osgi.compendium/src/main/resources/org/osgi/service/application/packageinfo b/org.osgi.compendium/src/main/resources/org/osgi/service/application/packageinfo
deleted file mode 100644
index 3987f9c..0000000
--- a/org.osgi.compendium/src/main/resources/org/osgi/service/application/packageinfo
+++ /dev/null
@@ -1 +0,0 @@
-version 1.1
diff --git a/org.osgi.compendium/src/main/resources/org/osgi/service/blueprint/container/package.html b/org.osgi.compendium/src/main/resources/org/osgi/service/blueprint/container/package.html
deleted file mode 100644
index 6b2fc92..0000000
--- a/org.osgi.compendium/src/main/resources/org/osgi/service/blueprint/container/package.html
+++ /dev/null
@@ -1,21 +0,0 @@
-<!-- $Revision: 7556 $ -->
-<BODY>
-<p>Blueprint Container Package Version 1.0.</p>
-<p>Bundles wishing to use this package must list the package
-in the Import-Package header of the bundle's manifest.
-For example:</p>
-<pre>
-Import-Package: org.osgi.service.blueprint.container; version="[1.0,2.0)"
-</pre>
-<p>
- This package defines the primary interface to a Blueprint Container,
- <code>BlueprintContainer</code>. An instance of this type is available
- inside a Blueprint Container as an implicitly defined component with the name
- "blueprintContainer".
-</p>
-<p>
- This package also declares the supporting exception types, listener, and constants for working with a Blueprint
- Container.
-</p>
-</BODY>
-
diff --git a/org.osgi.compendium/src/main/resources/org/osgi/service/blueprint/container/packageinfo b/org.osgi.compendium/src/main/resources/org/osgi/service/blueprint/container/packageinfo
deleted file mode 100644
index 7c8de03..0000000
--- a/org.osgi.compendium/src/main/resources/org/osgi/service/blueprint/container/packageinfo
+++ /dev/null
@@ -1 +0,0 @@
-version 1.0
diff --git a/org.osgi.compendium/src/main/resources/org/osgi/service/blueprint/reflect/package.html b/org.osgi.compendium/src/main/resources/org/osgi/service/blueprint/reflect/package.html
deleted file mode 100644
index 534999d..0000000
--- a/org.osgi.compendium/src/main/resources/org/osgi/service/blueprint/reflect/package.html
+++ /dev/null
@@ -1,14 +0,0 @@
-<!-- $Revision: 7556 $ -->
-<BODY>
-<p>Blueprint Reflection Package Version 1.0.
-<p>Bundles wishing to use this package must list the package
-in the Import-Package header of the bundle's manifest.
-For example:
-<pre>
-Import-Package: org.osgi.service.blueprint.reflect; version="[1.0,2.0)"
-</pre>
-<p> This package provides a reflection-based view of the configuration information for a
- Blueprint Container.
-</p>
-</BODY>
-
diff --git a/org.osgi.compendium/src/main/resources/org/osgi/service/blueprint/reflect/packageinfo b/org.osgi.compendium/src/main/resources/org/osgi/service/blueprint/reflect/packageinfo
deleted file mode 100644
index 7c8de03..0000000
--- a/org.osgi.compendium/src/main/resources/org/osgi/service/blueprint/reflect/packageinfo
+++ /dev/null
@@ -1 +0,0 @@
-version 1.0
diff --git a/org.osgi.compendium/src/main/resources/org/osgi/service/cm/package.html b/org.osgi.compendium/src/main/resources/org/osgi/service/cm/package.html
deleted file mode 100644
index 0234320..0000000
--- a/org.osgi.compendium/src/main/resources/org/osgi/service/cm/package.html
+++ /dev/null
@@ -1,11 +0,0 @@
-<!-- $Revision: 7356 $ -->
-<BODY>
-<p>Configuration Admin Package Version 1.3.
-<p>Bundles wishing to use this package must list the package
-in the Import-Package header of the bundle's manifest.
-For example:
-<pre>
-Import-Package: org.osgi.service.cm; version="[1.3,2.0)"
-</pre>
-</BODY>
-
diff --git a/org.osgi.compendium/src/main/resources/org/osgi/service/cm/packageinfo b/org.osgi.compendium/src/main/resources/org/osgi/service/cm/packageinfo
deleted file mode 100644
index 0117a56..0000000
--- a/org.osgi.compendium/src/main/resources/org/osgi/service/cm/packageinfo
+++ /dev/null
@@ -1 +0,0 @@
-version 1.3
diff --git a/org.osgi.compendium/src/main/resources/org/osgi/service/component/package.html b/org.osgi.compendium/src/main/resources/org/osgi/service/component/package.html
deleted file mode 100644
index 2e7717e..0000000
--- a/org.osgi.compendium/src/main/resources/org/osgi/service/component/package.html
+++ /dev/null
@@ -1,11 +0,0 @@
-<!-- $Revision: 6204 $ -->
-<BODY>
-<p>Service Component Package Version 1.1.
-<p>Bundles wishing to use this package must list the package
-in the Import-Package header of the bundle's manifest.
-For example:
-<pre>
-Import-Package: org.osgi.service.component; version="[1.1,2.0)"
-</pre>
-</BODY>
-
diff --git a/org.osgi.compendium/src/main/resources/org/osgi/service/component/packageinfo b/org.osgi.compendium/src/main/resources/org/osgi/service/component/packageinfo
deleted file mode 100644
index 3987f9c..0000000
--- a/org.osgi.compendium/src/main/resources/org/osgi/service/component/packageinfo
+++ /dev/null
@@ -1 +0,0 @@
-version 1.1
diff --git a/org.osgi.compendium/src/main/resources/org/osgi/service/deploymentadmin/package.html b/org.osgi.compendium/src/main/resources/org/osgi/service/deploymentadmin/package.html
deleted file mode 100644
index 5ba69e3..0000000
--- a/org.osgi.compendium/src/main/resources/org/osgi/service/deploymentadmin/package.html
+++ /dev/null
@@ -1,10 +0,0 @@
-<!-- $Revision: 6204 $ -->
-<BODY>
-<p>Deployment Admin Package Version 1.1.
-<p>Bundles wishing to use this package must list the package
-in the Import-Package header of the bundle's manifest.
-For example:
-<pre>
-Import-Package: org.osgi.service.deploymentadmin; version="[1.1,2.0)"
-</pre>
-</BODY>
diff --git a/org.osgi.compendium/src/main/resources/org/osgi/service/deploymentadmin/packageinfo b/org.osgi.compendium/src/main/resources/org/osgi/service/deploymentadmin/packageinfo
deleted file mode 100644
index 3987f9c..0000000
--- a/org.osgi.compendium/src/main/resources/org/osgi/service/deploymentadmin/packageinfo
+++ /dev/null
@@ -1 +0,0 @@
-version 1.1
diff --git a/org.osgi.compendium/src/main/resources/org/osgi/service/deploymentadmin/spi/package.html b/org.osgi.compendium/src/main/resources/org/osgi/service/deploymentadmin/spi/package.html
deleted file mode 100644
index cfa5e3f..0000000
--- a/org.osgi.compendium/src/main/resources/org/osgi/service/deploymentadmin/spi/package.html
+++ /dev/null
@@ -1,12 +0,0 @@
-<!-- $Revision: 6204 $ -->
-<BODY>
-<p>Deployment Admin SPI Package Version 1.0.
-The SPI is used by Resource Processors.
-<p>Bundles wishing to use this package must list the package
-in the Import-Package header of the bundle's manifest.
-For example:
-<pre>
-Import-Package: org.osgi.service.deploymentadmin.spi; version="[1.0,2.0)"
-</pre>
-</BODY>
-</BODY>
diff --git a/org.osgi.compendium/src/main/resources/org/osgi/service/deploymentadmin/spi/packageinfo b/org.osgi.compendium/src/main/resources/org/osgi/service/deploymentadmin/spi/packageinfo
deleted file mode 100644
index b3d1f97..0000000
--- a/org.osgi.compendium/src/main/resources/org/osgi/service/deploymentadmin/spi/packageinfo
+++ /dev/null
@@ -1 +0,0 @@
-version 1.0.1
diff --git a/org.osgi.compendium/src/main/resources/org/osgi/service/device/package.html b/org.osgi.compendium/src/main/resources/org/osgi/service/device/package.html
deleted file mode 100644
index 7647c20..0000000
--- a/org.osgi.compendium/src/main/resources/org/osgi/service/device/package.html
+++ /dev/null
@@ -1,10 +0,0 @@
-<!-- $Revision: 6204 $ -->
-<BODY>
-<p>Device Access Package Version 1.1.
-<p>Bundles wishing to use this package must list the package
-in the Import-Package header of the bundle's manifest.
-For example:
-<pre>
-Import-Package: org.osgi.service.device; version="[1.1,2.0)"
-</pre>
-</BODY>
diff --git a/org.osgi.compendium/src/main/resources/org/osgi/service/device/packageinfo b/org.osgi.compendium/src/main/resources/org/osgi/service/device/packageinfo
deleted file mode 100644
index 3987f9c..0000000
--- a/org.osgi.compendium/src/main/resources/org/osgi/service/device/packageinfo
+++ /dev/null
@@ -1 +0,0 @@
-version 1.1
diff --git a/org.osgi.compendium/src/main/resources/org/osgi/service/event/package.html b/org.osgi.compendium/src/main/resources/org/osgi/service/event/package.html
deleted file mode 100644
index 0d9d0bf..0000000
--- a/org.osgi.compendium/src/main/resources/org/osgi/service/event/package.html
+++ /dev/null
@@ -1,10 +0,0 @@
-<!-- $Revision: 6204 $ -->
-<BODY>
-<p>Event Admin Package Version 1.2.
-<p>Bundles wishing to use this package must list the package
-in the Import-Package header of the bundle's manifest.
-For example:
-<pre>
-Import-Package: org.osgi.service.event; version="[1.2,2.0)"
-</pre>
-</BODY>
diff --git a/org.osgi.compendium/src/main/resources/org/osgi/service/event/packageinfo b/org.osgi.compendium/src/main/resources/org/osgi/service/event/packageinfo
deleted file mode 100644
index ef7df68..0000000
--- a/org.osgi.compendium/src/main/resources/org/osgi/service/event/packageinfo
+++ /dev/null
@@ -1 +0,0 @@
-version 1.2
diff --git a/org.osgi.compendium/src/main/resources/org/osgi/service/http/package.html b/org.osgi.compendium/src/main/resources/org/osgi/service/http/package.html
deleted file mode 100644
index 21f5fed..0000000
--- a/org.osgi.compendium/src/main/resources/org/osgi/service/http/package.html
+++ /dev/null
@@ -1,10 +0,0 @@
-<!-- $Revision: 6204 $ -->
-<BODY>
-<p>Http Service Package Version 1.2.
-<p>Bundles wishing to use this package must list the package
-in the Import-Package header of the bundle's manifest.
-For example:
-<pre>
-Import-Package: org.osgi.service.http; version="[1.2,2.0)"
-</pre>
-</BODY>
diff --git a/org.osgi.compendium/src/main/resources/org/osgi/service/http/packageinfo b/org.osgi.compendium/src/main/resources/org/osgi/service/http/packageinfo
deleted file mode 100644
index 6ebb891..0000000
--- a/org.osgi.compendium/src/main/resources/org/osgi/service/http/packageinfo
+++ /dev/null
@@ -1 +0,0 @@
-version 1.2.1
diff --git a/org.osgi.compendium/src/main/resources/org/osgi/service/io/package.html b/org.osgi.compendium/src/main/resources/org/osgi/service/io/package.html
deleted file mode 100644
index cecc3c3..0000000
--- a/org.osgi.compendium/src/main/resources/org/osgi/service/io/package.html
+++ /dev/null
@@ -1,10 +0,0 @@
-<!-- $Revision: 6204 $ -->
-<BODY>
-<p>IO Connector Package Version 1.0.
-<p>Bundles wishing to use this package must list the package
-in the Import-Package header of the bundle's manifest.
-For example:
-<pre>
-Import-Package: org.osgi.service.io; version="[1.0,2.0)", javax.microedition.io
-</pre>
-</BODY>
diff --git a/org.osgi.compendium/src/main/resources/org/osgi/service/io/packageinfo b/org.osgi.compendium/src/main/resources/org/osgi/service/io/packageinfo
deleted file mode 100644
index 7c8de03..0000000
--- a/org.osgi.compendium/src/main/resources/org/osgi/service/io/packageinfo
+++ /dev/null
@@ -1 +0,0 @@
-version 1.0
diff --git a/org.osgi.compendium/src/main/resources/org/osgi/service/log/package.html b/org.osgi.compendium/src/main/resources/org/osgi/service/log/package.html
deleted file mode 100644
index 02312bb..0000000
--- a/org.osgi.compendium/src/main/resources/org/osgi/service/log/package.html
+++ /dev/null
@@ -1,11 +0,0 @@
-<!-- $Revision: 6204 $ -->
-<BODY>
-<p>Log Service Package Version 1.3.
-<p>Bundles wishing to use this package must list the package
-in the Import-Package header of the bundle's manifest.
-For example:
-<pre>
-Import-Package: org.osgi.service.log; version="[1.3,2.0)"
-</pre>
-</BODY>
-
diff --git a/org.osgi.compendium/src/main/resources/org/osgi/service/log/packageinfo b/org.osgi.compendium/src/main/resources/org/osgi/service/log/packageinfo
deleted file mode 100644
index 0117a56..0000000
--- a/org.osgi.compendium/src/main/resources/org/osgi/service/log/packageinfo
+++ /dev/null
@@ -1 +0,0 @@
-version 1.3
diff --git a/org.osgi.compendium/src/main/resources/org/osgi/service/metatype/package.html b/org.osgi.compendium/src/main/resources/org/osgi/service/metatype/package.html
deleted file mode 100644
index 0b2b533..0000000
--- a/org.osgi.compendium/src/main/resources/org/osgi/service/metatype/package.html
+++ /dev/null
@@ -1,11 +0,0 @@
-<!-- $Revision: 6204 $ -->
-<BODY>
-<p>Metatype Package Version 1.1.
-<p>Bundles wishing to use this package must list the package
-in the Import-Package header of the bundle's manifest.
-For example:
-<pre>
-Import-Package: org.osgi.service.metatype; version="[1.1,2.0)"
-</pre>
-</BODY>
-
diff --git a/org.osgi.compendium/src/main/resources/org/osgi/service/metatype/packageinfo b/org.osgi.compendium/src/main/resources/org/osgi/service/metatype/packageinfo
deleted file mode 100644
index 3987f9c..0000000
--- a/org.osgi.compendium/src/main/resources/org/osgi/service/metatype/packageinfo
+++ /dev/null
@@ -1 +0,0 @@
-version 1.1
diff --git a/org.osgi.compendium/src/main/resources/org/osgi/service/monitor/package.html b/org.osgi.compendium/src/main/resources/org/osgi/service/monitor/package.html
deleted file mode 100644
index 5350310..0000000
--- a/org.osgi.compendium/src/main/resources/org/osgi/service/monitor/package.html
+++ /dev/null
@@ -1,10 +0,0 @@
-<!-- $Revision: 6204 $ -->
-<BODY>
-<p>Monitor Admin Package Version 1.0.
-<p>Bundles wishing to use this package must list the package
-in the Import-Package header of the bundle's manifest.
-For example:
-<pre>
-Import-Package: org.osgi.service.monitor; version="[1.0,2.0)"
-</pre>
-</BODY>
diff --git a/org.osgi.compendium/src/main/resources/org/osgi/service/monitor/packageinfo b/org.osgi.compendium/src/main/resources/org/osgi/service/monitor/packageinfo
deleted file mode 100644
index 7c8de03..0000000
--- a/org.osgi.compendium/src/main/resources/org/osgi/service/monitor/packageinfo
+++ /dev/null
@@ -1 +0,0 @@
-version 1.0
diff --git a/org.osgi.compendium/src/main/resources/org/osgi/service/prefs/package.html b/org.osgi.compendium/src/main/resources/org/osgi/service/prefs/package.html
deleted file mode 100644
index 9bbffe2..0000000
--- a/org.osgi.compendium/src/main/resources/org/osgi/service/prefs/package.html
+++ /dev/null
@@ -1,11 +0,0 @@
-<!-- $Revision: 6204 $ -->
-<BODY>
-<p>Preferences Service Package Version 1.1.
-<p>Bundles wishing to use this package must list the package
-in the Import-Package header of the bundle's manifest.
-For example:
-<pre>
-Import-Package: org.osgi.service.prefs; version="[1.1,2.0)"
-</pre>
-</BODY>
-
diff --git a/org.osgi.compendium/src/main/resources/org/osgi/service/prefs/packageinfo b/org.osgi.compendium/src/main/resources/org/osgi/service/prefs/packageinfo
deleted file mode 100644
index bb27c60..0000000
--- a/org.osgi.compendium/src/main/resources/org/osgi/service/prefs/packageinfo
+++ /dev/null
@@ -1 +0,0 @@
-version 1.1.1
diff --git a/org.osgi.compendium/src/main/resources/org/osgi/service/provisioning/package.html b/org.osgi.compendium/src/main/resources/org/osgi/service/provisioning/package.html
deleted file mode 100644
index 8c28950..0000000
--- a/org.osgi.compendium/src/main/resources/org/osgi/service/provisioning/package.html
+++ /dev/null
@@ -1,10 +0,0 @@
-<!-- $Revision: 6204 $ -->
-<BODY>
-<p>Provisioning Package Version 1.2.
-<p>Bundles wishing to use this package must list the package
-in the Import-Package header of the bundle's manifest.
-For example:
-<pre>
-Import-Package: org.osgi.service.provisioning; version="[1.2,2.0)"
-</pre>
-</BODY>
diff --git a/org.osgi.compendium/src/main/resources/org/osgi/service/provisioning/packageinfo b/org.osgi.compendium/src/main/resources/org/osgi/service/provisioning/packageinfo
deleted file mode 100644
index ef7df68..0000000
--- a/org.osgi.compendium/src/main/resources/org/osgi/service/provisioning/packageinfo
+++ /dev/null
@@ -1 +0,0 @@
-version 1.2
diff --git a/org.osgi.compendium/src/main/resources/org/osgi/service/upnp/package.html b/org.osgi.compendium/src/main/resources/org/osgi/service/upnp/package.html
deleted file mode 100644
index 5422e04..0000000
--- a/org.osgi.compendium/src/main/resources/org/osgi/service/upnp/package.html
+++ /dev/null
@@ -1,10 +0,0 @@
-<!-- $Revision: 6204 $ -->
-<BODY>
-<p>UPnP Package Version 1.1.
-<p>Bundles wishing to use this package must list the package
-in the Import-Package header of the bundle's manifest.
-For example:
-<pre>
-Import-Package: org.osgi.service.upnp; version="[1.1,2.0)"
-</pre>
-</BODY>
diff --git a/org.osgi.compendium/src/main/resources/org/osgi/service/upnp/packageinfo b/org.osgi.compendium/src/main/resources/org/osgi/service/upnp/packageinfo
deleted file mode 100644
index 3987f9c..0000000
--- a/org.osgi.compendium/src/main/resources/org/osgi/service/upnp/packageinfo
+++ /dev/null
@@ -1 +0,0 @@
-version 1.1
diff --git a/org.osgi.compendium/src/main/resources/org/osgi/service/useradmin/package.html b/org.osgi.compendium/src/main/resources/org/osgi/service/useradmin/package.html
deleted file mode 100644
index c8c223d..0000000
--- a/org.osgi.compendium/src/main/resources/org/osgi/service/useradmin/package.html
+++ /dev/null
@@ -1,10 +0,0 @@
-<!-- $Revision: 6204 $ -->
-<BODY>
-<p>User Admin Package Version 1.1.
-<p>Bundles wishing to use this package must list the package
-in the Import-Package header of the bundle's manifest.
-For example:
-<pre>
-Import-Package: org.osgi.service.useradmin; version="[1.1,2.0)"
-</pre>
-</BODY>
diff --git a/org.osgi.compendium/src/main/resources/org/osgi/service/useradmin/packageinfo b/org.osgi.compendium/src/main/resources/org/osgi/service/useradmin/packageinfo
deleted file mode 100644
index 3987f9c..0000000
--- a/org.osgi.compendium/src/main/resources/org/osgi/service/useradmin/packageinfo
+++ /dev/null
@@ -1 +0,0 @@
-version 1.1
diff --git a/org.osgi.compendium/src/main/resources/org/osgi/service/wireadmin/package.html b/org.osgi.compendium/src/main/resources/org/osgi/service/wireadmin/package.html
deleted file mode 100644
index 36d1d82..0000000
--- a/org.osgi.compendium/src/main/resources/org/osgi/service/wireadmin/package.html
+++ /dev/null
@@ -1,11 +0,0 @@
-<!-- $Revision: 6204 $ -->
-<BODY>
-<p>Wire Admin Package Version 1.0.
-<p>Bundles wishing to use this package must list the package
-in the Import-Package header of the bundle's manifest.
-For example:
-<pre>
-Import-Package: org.osgi.service.wireadmin; version="[1.0,2.0)"
-</pre>
-</BODY>
-
diff --git a/org.osgi.compendium/src/main/resources/org/osgi/service/wireadmin/packageinfo b/org.osgi.compendium/src/main/resources/org/osgi/service/wireadmin/packageinfo
deleted file mode 100644
index 7c8de03..0000000
--- a/org.osgi.compendium/src/main/resources/org/osgi/service/wireadmin/packageinfo
+++ /dev/null
@@ -1 +0,0 @@
-version 1.0
diff --git a/org.osgi.compendium/src/main/resources/org/osgi/util/cdma/package.html b/org.osgi.compendium/src/main/resources/org/osgi/util/cdma/package.html
deleted file mode 100644
index eaa0953..0000000
--- a/org.osgi.compendium/src/main/resources/org/osgi/util/cdma/package.html
+++ /dev/null
@@ -1,10 +0,0 @@
-<!-- $Revision: 6204 $ -->
-<BODY>
-<p>CDMA Conditions Package Version 1.0.
-<p>Bundles wishing to use this package must list the package
-in the Import-Package header of the bundle's manifest.
-For example:
-<pre>
-Import-Package: org.osgi.util.cdma; version="[1.0,2.0)"
-</pre>
-</BODY>
diff --git a/org.osgi.compendium/src/main/resources/org/osgi/util/cdma/packageinfo b/org.osgi.compendium/src/main/resources/org/osgi/util/cdma/packageinfo
deleted file mode 100644
index a4f1546..0000000
--- a/org.osgi.compendium/src/main/resources/org/osgi/util/cdma/packageinfo
+++ /dev/null
@@ -1 +0,0 @@
-version 1.0
\ No newline at end of file
diff --git a/org.osgi.compendium/src/main/resources/org/osgi/util/gsm/package.html b/org.osgi.compendium/src/main/resources/org/osgi/util/gsm/package.html
deleted file mode 100644
index 2b6bd0e..0000000
--- a/org.osgi.compendium/src/main/resources/org/osgi/util/gsm/package.html
+++ /dev/null
@@ -1,10 +0,0 @@
-<!-- $Revision: 6204 $ -->
-<BODY>
-<p>Mobile GSM Conditions Package Version 1.0.
-<p>Bundles wishing to use this package must list the package
-in the Import-Package header of the bundle's manifest.
-For example:
-<pre>
-Import-Package: org.osgi.util.gsm; version="[1.0,2.0)"
-</pre>
-</BODY>
diff --git a/org.osgi.compendium/src/main/resources/org/osgi/util/gsm/packageinfo b/org.osgi.compendium/src/main/resources/org/osgi/util/gsm/packageinfo
deleted file mode 100644
index c266447..0000000
--- a/org.osgi.compendium/src/main/resources/org/osgi/util/gsm/packageinfo
+++ /dev/null
@@ -1 +0,0 @@
-version 1.0.1
\ No newline at end of file
diff --git a/org.osgi.compendium/src/main/resources/org/osgi/util/measurement/package.html b/org.osgi.compendium/src/main/resources/org/osgi/util/measurement/package.html
deleted file mode 100644
index 2eb3a8c..0000000
--- a/org.osgi.compendium/src/main/resources/org/osgi/util/measurement/package.html
+++ /dev/null
@@ -1,10 +0,0 @@
-<!-- $Revision: 6204 $ -->
-<BODY>
-<p>Measurement Package Version 1.0.
-<p>Bundles wishing to use this package must list the package
-in the Import-Package header of the bundle's manifest.
-For example:
-<pre>
-Import-Package: org.osgi.util.measurement; version="[1.0,2.0)"
-</pre>
-</BODY>
diff --git a/org.osgi.compendium/src/main/resources/org/osgi/util/measurement/packageinfo b/org.osgi.compendium/src/main/resources/org/osgi/util/measurement/packageinfo
deleted file mode 100644
index c266447..0000000
--- a/org.osgi.compendium/src/main/resources/org/osgi/util/measurement/packageinfo
+++ /dev/null
@@ -1 +0,0 @@
-version 1.0.1
\ No newline at end of file
diff --git a/org.osgi.compendium/src/main/resources/org/osgi/util/mobile/package.html b/org.osgi.compendium/src/main/resources/org/osgi/util/mobile/package.html
deleted file mode 100644
index 5590197..0000000
--- a/org.osgi.compendium/src/main/resources/org/osgi/util/mobile/package.html
+++ /dev/null
@@ -1,10 +0,0 @@
-<!-- $Revision: 6204 $ -->
-<BODY>
-<p>Mobile Conditions Package Version 1.0.
-<p>Bundles wishing to use this package must list the package
-in the Import-Package header of the bundle's manifest.
-For example:
-<pre>
-Import-Package: org.osgi.util.mobile; version="[1.0,2.0)"
-</pre>
-</BODY>
diff --git a/org.osgi.compendium/src/main/resources/org/osgi/util/mobile/packageinfo b/org.osgi.compendium/src/main/resources/org/osgi/util/mobile/packageinfo
deleted file mode 100644
index a4f1546..0000000
--- a/org.osgi.compendium/src/main/resources/org/osgi/util/mobile/packageinfo
+++ /dev/null
@@ -1 +0,0 @@
-version 1.0
\ No newline at end of file
diff --git a/org.osgi.compendium/src/main/resources/org/osgi/util/position/package.html b/org.osgi.compendium/src/main/resources/org/osgi/util/position/package.html
deleted file mode 100644
index d0d745f..0000000
--- a/org.osgi.compendium/src/main/resources/org/osgi/util/position/package.html
+++ /dev/null
@@ -1,10 +0,0 @@
-<!-- $Revision: 6204 $ -->
-<BODY>
-<p>Position Package Version 1.0.
-<p>Bundles wishing to use this package must list the package
-in the Import-Package header of the bundle's manifest.
-For example:
-<pre>
-Import-Package: org.osgi.util.position; version="[1.0,2.0)"
-</pre>
-</BODY>
diff --git a/org.osgi.compendium/src/main/resources/org/osgi/util/position/packageinfo b/org.osgi.compendium/src/main/resources/org/osgi/util/position/packageinfo
deleted file mode 100644
index c266447..0000000
--- a/org.osgi.compendium/src/main/resources/org/osgi/util/position/packageinfo
+++ /dev/null
@@ -1 +0,0 @@
-version 1.0.1
\ No newline at end of file
diff --git a/org.osgi.compendium/src/main/resources/org/osgi/util/tracker/package.html b/org.osgi.compendium/src/main/resources/org/osgi/util/tracker/package.html
deleted file mode 100644
index c29c891..0000000
--- a/org.osgi.compendium/src/main/resources/org/osgi/util/tracker/package.html
+++ /dev/null
@@ -1,10 +0,0 @@
-<!-- $Revision: 6204 $ -->
-<BODY>
-<p>Tracker Package Version 1.4.
-<p>Bundles wishing to use this package must list the package
-in the Import-Package header of the bundle's manifest.
-For example:
-<pre>
-Import-Package: org.osgi.util.tracker; version="[1.4,2.0)"
-</pre>
-</BODY>
diff --git a/org.osgi.compendium/src/main/resources/org/osgi/util/tracker/packageinfo b/org.osgi.compendium/src/main/resources/org/osgi/util/tracker/packageinfo
deleted file mode 100644
index cc13f19..0000000
--- a/org.osgi.compendium/src/main/resources/org/osgi/util/tracker/packageinfo
+++ /dev/null
@@ -1 +0,0 @@
-version 1.4
diff --git a/org.osgi.compendium/src/main/resources/org/osgi/util/xml/package.html b/org.osgi.compendium/src/main/resources/org/osgi/util/xml/package.html
deleted file mode 100644
index e153322..0000000
--- a/org.osgi.compendium/src/main/resources/org/osgi/util/xml/package.html
+++ /dev/null
@@ -1,10 +0,0 @@
-<!-- $Revision: 6204 $ -->
-<BODY>
-<p>XML Parser Package Version 1.0.
-<p>Bundles wishing to use this package must list the package
-in the Import-Package header of the bundle's manifest.
-For example:
-<pre>
-Import-Package: org.osgi.util.xml; version="[1.0,2.0)"
-</pre>
-</BODY>
diff --git a/org.osgi.compendium/src/main/resources/org/osgi/util/xml/packageinfo b/org.osgi.compendium/src/main/resources/org/osgi/util/xml/packageinfo
deleted file mode 100644
index c266447..0000000
--- a/org.osgi.compendium/src/main/resources/org/osgi/util/xml/packageinfo
+++ /dev/null
@@ -1 +0,0 @@
-version 1.0.1
\ No newline at end of file
diff --git a/org.osgi.compendium/src/main/resources/xmlns/app/v1.0.0/app.xsd b/org.osgi.compendium/src/main/resources/xmlns/app/v1.0.0/app.xsd
deleted file mode 100644
index 8253c8d..0000000
--- a/org.osgi.compendium/src/main/resources/xmlns/app/v1.0.0/app.xsd
+++ /dev/null
@@ -1,77 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!--
-/*
- * $Revision: 5673 $
- *
- * Copyright (c) OSGi Alliance (2005, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
--->
-<xs:schema
- xmlns="http://www.osgi.org/xmlns/app/v1.0.0"
- xmlns:app="http://www.osgi.org/xmlns/app/v1.0.0"
- xmlns:xs="http://www.w3.org/2001/XMLSchema"
- targetNamespace="http://www.osgi.org/xmlns/app/v1.0.0"
- elementFormDefault="qualified"
- attributeFormDefault="unqualified"
- version="1.0.0">
-
- <xs:element name="descriptor" type="app:descriptorType">
- <xs:annotation>
- <xs:documentation>descriptor element encloses the application descriptors provided in a document</xs:documentation>
- </xs:annotation>
- </xs:element>
-
- <xs:complexType name="descriptorType">
- <xs:sequence>
- <xs:element name="application" type="app:applicationType" minOccurs="1" maxOccurs="unbounded"/>
- </xs:sequence>
- </xs:complexType>
-
- <xs:complexType name="applicationType">
- <xs:annotation>
- <xs:documentation>describes the service dependencies of an application</xs:documentation>
- </xs:annotation>
- <xs:sequence>
- <xs:element name="reference" minOccurs="0" maxOccurs="unbounded" type="referenceType"/>
- </xs:sequence>
- <xs:attribute name="class" type="xs:string"/>
- </xs:complexType>
-
- <xs:complexType name="referenceType">
- <xs:attribute name="name" type="xs:NMTOKEN" use="required"/>
- <xs:attribute name="interface" type="xs:string" use="required"/>
- <xs:attribute name="cardinality" default="1..1" use="optional" type="cardinalityType"/>
- <xs:attribute name="policy" use="optional" default="static" type="policyType"/>
- <xs:attribute name="target" type="xs:string" use="optional"/>
- </xs:complexType>
-
- <xs:simpleType name="cardinalityType">
- <xs:restriction base="xs:string">
- <xs:enumeration value="0..1"/>
- <xs:enumeration value="0..n"/>
- <xs:enumeration value="1..1"/>
- <xs:enumeration value="1..n"/>
- </xs:restriction>
- </xs:simpleType>
-
- <xs:simpleType name="policyType">
- <xs:restriction base="xs:string">
- <xs:enumeration value="static"/>
- <xs:enumeration value="dynamic"/>
- </xs:restriction>
- </xs:simpleType>
-
-
-</xs:schema>
diff --git a/org.osgi.compendium/src/main/resources/xmlns/app/v1.1.0/app.xsd b/org.osgi.compendium/src/main/resources/xmlns/app/v1.1.0/app.xsd
deleted file mode 100644
index 75b4b23..0000000
--- a/org.osgi.compendium/src/main/resources/xmlns/app/v1.1.0/app.xsd
+++ /dev/null
@@ -1,105 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!--
- /*
- * $Revision: 5655 $
- *
- * Copyright (c) OSGi Alliance (2005, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
--->
-<schema xmlns="http://www.w3.org/2001/XMLSchema"
- xmlns:app="http://www.osgi.org/xmlns/app/v1.1.0"
- targetNamespace="http://www.osgi.org/xmlns/app/v1.1.0"
- version="1.1.0">
-
- <element name="descriptor" type="app:Tdescriptor">
- <annotation>
- <documentation xml:lang="en">
- descriptor element encloses the application descriptors
- provided in a document
- </documentation>
- </annotation>
- </element>
-
- <complexType name="Tdescriptor">
- <sequence>
- <element name="application" type="app:Tapplication"
- minOccurs="1" maxOccurs="unbounded" />
- <!-- It is non-deterministic, per W3C XML Schema 1.0: http://www.w3.org/TR/xmlschema-1/#cos-nonambig
- to use namespace="##any" below. -->
- <any namespace="##other" processContents="lax" minOccurs="0"
- maxOccurs="unbounded" />
- </sequence>
- <anyAttribute />
- </complexType>
-
- <complexType name="Tapplication">
- <annotation>
- <documentation xml:lang="en">
- describes the service dependencies of an application
- </documentation>
- </annotation>
- <sequence>
- <element name="reference" minOccurs="0"
- maxOccurs="unbounded" type="app:Treference" />
- <!-- It is non-deterministic, per W3C XML Schema 1.0: http://www.w3.org/TR/xmlschema-1/#cos-nonambig
- to use namespace="##any" below. -->
- <any namespace="##other" processContents="lax" minOccurs="0"
- maxOccurs="unbounded" />
- </sequence>
- <attribute name="class" type="string" />
- <anyAttribute />
- </complexType>
-
- <complexType name="Treference">
- <sequence>
- <any namespace="##any" processContents="lax" minOccurs="0"
- maxOccurs="unbounded" />
- </sequence>
- <attribute name="name" type="NMTOKEN" use="required" />
- <attribute name="interface" type="string" use="required" />
- <attribute name="cardinality" default="1..1" use="optional"
- type="app:Tcardinality" />
- <attribute name="policy" use="optional" default="static"
- type="app:Tpolicy" />
- <attribute name="target" type="string" use="optional" />
- <anyAttribute />
- </complexType>
-
- <simpleType name="Tcardinality">
- <restriction base="string">
- <enumeration value="0..1" />
- <enumeration value="0..n" />
- <enumeration value="1..1" />
- <enumeration value="1..n" />
- </restriction>
- </simpleType>
-
- <simpleType name="Tpolicy">
- <restriction base="string">
- <enumeration value="static" />
- <enumeration value="dynamic" />
- </restriction>
- </simpleType>
-
- <attribute name="must-understand" type="boolean">
- <annotation>
- <documentation xml:lang="en">
- This attribute should be used by extensions to documents
- to require that the document consumer understand the
- extension.
- </documentation>
- </annotation>
- </attribute>
-</schema>
diff --git a/org.osgi.compendium/src/main/resources/xmlns/blueprint/v1.0.0/blueprint.xsd b/org.osgi.compendium/src/main/resources/xmlns/blueprint/v1.0.0/blueprint.xsd
deleted file mode 100644
index bb90506..0000000
--- a/org.osgi.compendium/src/main/resources/xmlns/blueprint/v1.0.0/blueprint.xsd
+++ /dev/null
@@ -1,1233 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" standalone="no"?>
-<!--
- /*
- * $Revision: 7773 $
- *
- * Copyright (c) OSGi Alliance (2008, 2009). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
- -->
-<xsd:schema xmlns="http://www.osgi.org/xmlns/blueprint/v1.0.0"
- xmlns:xsd="http://www.w3.org/2001/XMLSchema" targetNamespace="http://www.osgi.org/xmlns/blueprint/v1.0.0"
- elementFormDefault="qualified" attributeFormDefault="unqualified"
- version="1.0.0">
-
- <xsd:annotation>
- <xsd:documentation>
- <![CDATA[
- This is the XML Schema for the OSGi Blueprint service 1.0.0
- development descriptor. Blueprint configuration files
- using this schema must indicate the schema using the
- blueprint/v1.0.0 namespace. For example,
-
- <blueprint xmlns="http://www.osgi.org/xmlns/blueprint/v1.0.0">
-
- if used as a qualified namespace, "bp" is the recommended
- namespace prefix.
- ]]>
- </xsd:documentation>
- </xsd:annotation>
-
- <!-- Schema elements for core component declarations -->
-
- <xsd:complexType name="Tcomponent" abstract="true">
- <xsd:annotation>
- <xsd:documentation>
- <![CDATA[
- The Tcomponent type is the base type for top-level
- Blueprint components. The <bean> <reference>, <service>,
- and <reference-list> elements are all derived from
- the Tcomponent type. This type defines an id attribute
- that is used create references between different components.
- Component elements can also be inlined within other component
- definitions. The id attribute is not valid when inlined.
- ]]>
- </xsd:documentation>
- </xsd:annotation>
-
- <xsd:attribute name="id" type="xsd:ID" />
-
- <xsd:attribute name="activation" type="Tactivation">
- <xsd:annotation>
- <xsd:documentation>
- <![CDATA[
- The activation attribute for this component. This can either
- be "eager" or "lazy". If not specified, it
- defaults to default-activation attribute of the enclosing
- <blueprint> element.
- ]]>
- </xsd:documentation>
- </xsd:annotation>
- </xsd:attribute>
-
- <xsd:attribute name="depends-on" type="TdependsOn">
- <xsd:annotation>
- <xsd:documentation>
- <![CDATA[
- depends-on identifies (by id) other components that this component
- depends on. The component only be activated after the
- depends-on components are successfully activated. Also, if there
- are <reference> or <reference-list> elements with unstatisfied
- manadatory references, then the depends-on relationship will also
- be used to determine whether this service is enabled or not.
- ]]>
- </xsd:documentation>
- </xsd:annotation>
- </xsd:attribute>
- </xsd:complexType>
-
- <xsd:element name="blueprint" type="Tblueprint">
- <xsd:annotation>
- <xsd:documentation>
- <![CDATA[
- The <blueprint> element is the root element for a blueprint
- configuration file. A blueprint configuration has two sections.
- The first section (contained within the <type-converters> element)
- identifies components that are used for converting values into
- different target types. The type converters are optional, so
- the file does not need to specify a type converter section.
-
- Following the type converters are the component definitions.
- Components are <bean>, <service>, <reference>, and
- <reference-list> elements that identify the bundle components that will
- be managed by the blueprint service.
- ]]>
- </xsd:documentation>
- </xsd:annotation>
- </xsd:element>
-
- <xsd:complexType name="Tblueprint">
- <xsd:sequence>
- <xsd:element name="description" type="Tdescription"
- minOccurs="0" />
- <xsd:element name="type-converters" type="Ttype-converters"
- minOccurs="0" maxOccurs="1" />
- <!-- top-level components -->
- <xsd:choice minOccurs="0" maxOccurs="unbounded">
- <xsd:element name="service" type="Tservice" />
- <xsd:element name="reference-list" type="Treference-list" />
- <xsd:element name="bean" type="Tbean" />
- <xsd:element name="reference" type="Treference" />
- <xsd:any namespace="##other" processContents="strict" />
- </xsd:choice>
- </xsd:sequence>
-
- <!-- Defaults-->
- <xsd:attribute name="default-activation" default="eager"
- type="Tactivation">
- <xsd:annotation>
- <xsd:documentation>
- <![CDATA[
- Specifies the default activation setting that will be defined
- for components. If not specified, the global default is "eager".
- Individual components may override the default value.
- ]]>
- </xsd:documentation>
- </xsd:annotation>
- </xsd:attribute>
- <xsd:attribute name="default-timeout" type="Ttimeout"
- default="300000">
- <xsd:annotation>
- <xsd:documentation>
- <![CDATA[
- Specifies the default timeout value to be used when operations
- are invoked on unstatisfied service references. If the
- reference does not change to a satisfied state within the timeout
- window, an error is raised on the method invocation. The
- default timeout value is 300000 milliseconds and individual
- <reference> element can override the specified configuration
- default.
- ]]>
- </xsd:documentation>
- </xsd:annotation>
- </xsd:attribute>
- <xsd:attribute name="default-availability" type="Tavailability"
- default="mandatory">
- <xsd:annotation>
- <xsd:documentation>
- <![CDATA[
- Specifies the default availability value to be used for
- <reference>, and <reference-list> components. The
- normal default is "mandatory", and can be changed by individual
- service reference components.
- ]]>
- </xsd:documentation>
- </xsd:annotation>
- </xsd:attribute>
- <xsd:anyAttribute namespace="##other"
- processContents="strict" />
- </xsd:complexType>
-
- <xsd:complexType name="Ttype-converters">
- <xsd:annotation>
- <xsd:documentation>
- <![CDATA[
- The type used for the <type-converters> element. The
- <type-converters> section is a set of <bean>, <ref>, or
- <reference> elements that identify the type converter components.
- ]]>
- </xsd:documentation>
- </xsd:annotation>
- <xsd:choice minOccurs="0" maxOccurs="unbounded">
- <xsd:element name="bean" type="Tbean" />
- <xsd:element name="reference" type="Treference" />
- <xsd:element name="ref" type="Tref" />
- <xsd:any namespace="##other" processContents="strict" />
- </xsd:choice>
- </xsd:complexType>
-
- <!--
- Components that provide a reasonable target for injection used for
- listeners, etc.
- -->
-
- <xsd:group name="GtargetComponent">
- <xsd:annotation>
- <xsd:documentation>
- <![CDATA[
- A target component is one that can be a target for a
- listener, registration-listener or service elements.
- This is used in contexts where the requirement is a single
- provided object that will implement a particular interface.
- The provided object is obtained either from a <ref> element
- or an inlined <bean> or <reference>.
- ]]>
- </xsd:documentation>
- </xsd:annotation>
- <xsd:choice>
- <xsd:element name="bean" type="Tinlined-bean" />
- <xsd:element name="reference" type="Tinlined-reference" />
- <xsd:element name="ref" type="Tref" />
- <xsd:any namespace="##other" processContents="strict" />
- </xsd:choice>
- </xsd:group>
-
- <xsd:group name="GallComponents">
- <xsd:annotation>
- <xsd:documentation>
- <![CDATA[
- An all components is used in contexts where all component element
- types are values. The set of component elements contains
- <bean>, <service>, <reference>, <reference-list> and <ref>.
- ]]>
- </xsd:documentation>
- </xsd:annotation>
- <xsd:choice>
- <xsd:element name="service" type="Tinlined-service" />
- <xsd:element name="reference-list" type="Tinlined-reference-list" />
- <xsd:group ref="GtargetComponent" />
- </xsd:choice>
- </xsd:group>
-
- <xsd:group name="GbeanElements">
- <xsd:annotation>
- <xsd:documentation>
- <![CDATA[
- A bean elements is a reusable definition of the elements allowed on
- a <bean> element.
- ]]>
- </xsd:documentation>
- </xsd:annotation>
- <xsd:sequence>
- <xsd:element name="description" type="Tdescription"
- minOccurs="0" />
- <xsd:choice minOccurs="0" maxOccurs="unbounded">
- <xsd:element name="argument" type="Targument" />
- <xsd:element name="property" type="Tproperty" />
- <xsd:any namespace="##other" processContents="strict" />
- </xsd:choice>
- </xsd:sequence>
- </xsd:group>
-
- <xsd:complexType name="Tbean">
- <xsd:annotation>
- <xsd:documentation>
- <![CDATA[
- The type definition for a <bean> component. The <bean>
- attributes provide the characteristics for how to create a
- bean instance. Constructor arguments and injected properties
- are specified via child <argument> and <property> elements.
- ]]>
- </xsd:documentation>
- </xsd:annotation>
- <xsd:complexContent>
- <xsd:extension base="Tcomponent">
- <xsd:group ref="GbeanElements" />
- <xsd:attribute name="class" type="Tclass" />
- <xsd:attribute name="init-method" type="Tmethod" />
- <xsd:attribute name="destroy-method" type="Tmethod" />
- <xsd:attribute name="factory-method" type="Tmethod" />
- <xsd:attribute name="factory-ref" type="Tidref" />
- <xsd:attribute name="scope" type="Tscope" />
- <xsd:anyAttribute namespace="##other"
- processContents="strict" />
- </xsd:extension>
- </xsd:complexContent>
- </xsd:complexType>
-
- <xsd:complexType name="Tinlined-bean">
- <xsd:annotation>
- <xsd:documentation>
- <![CDATA[
- The Tinlined-bean type is used for inlined (i.e. non top level)
- <bean> elements. Those elements have some restrictions on
- the attributes that can be used to define them.
- ]]>
- </xsd:documentation>
- </xsd:annotation>
- <xsd:complexContent>
- <xsd:restriction base="Tbean">
- <xsd:group ref="GbeanElements" />
- <xsd:attribute name="id" use="prohibited" />
- <xsd:attribute name="depends-on" type="TdependsOn" />
- <xsd:attribute name="activation" use="prohibited"
- fixed="lazy" />
- <xsd:attribute name="class" type="Tclass" />
- <xsd:attribute name="init-method" type="Tmethod" />
- <xsd:attribute name="destroy-method" use="prohibited" />
- <xsd:attribute name="factory-method" type="Tmethod" />
- <xsd:attribute name="factory-ref" type="Tidref" />
- <xsd:attribute name="scope" use="prohibited" />
- <xsd:anyAttribute namespace="##other"
- processContents="strict" />
- </xsd:restriction>
- </xsd:complexContent>
- </xsd:complexType>
-
- <xsd:complexType name="Targument">
- <xsd:annotation>
- <xsd:documentation>
- <![CDATA[
- An argument used to create an object defined by a <bean>
- component. The <argument> elements are the arguments for the
- bean class constructor or passed to the bean factory method.
-
- The type, if specified, is used to disambiguate the constructor
- or method signature. Arguments may also be matched up with
- arguments by explicitly specifying the index position. If the
- index is used, then all <argument> elements for the bean must
- also specify the index.
-
- The value and ref attributes are convenience shortcuts to make
- the <argument> tag easier to code. A fuller set of injected
- values and types can be specified using one of the "value"
- type elements.
- ]]>
- </xsd:documentation>
- </xsd:annotation>
- <xsd:sequence>
- <xsd:element name="description" type="Tdescription"
- minOccurs="0" />
- <xsd:group ref="Gvalue" minOccurs="0" />
- </xsd:sequence>
- <xsd:attribute name="index" type="xsd:nonNegativeInteger" />
- <xsd:attribute name="type" type="Ttype" />
- <xsd:attribute name="ref" type="Tidref" />
- <xsd:attribute name="value" type="TstringValue" />
- </xsd:complexType>
-
- <xsd:complexType name="Tproperty">
- <xsd:annotation>
- <xsd:documentation>
- <![CDATA[
- A property that will be injected into a created <bean>
- component. The <property> elements correspond to named
- JavaBean setting methods for a created bean object.
-
- The value and ref attributes are convenience shortcuts to make
- the <argument> tag easier to code. A fuller set of injected
- values and types can be specified using one of the "value"
- type elements.
- ]]>
- </xsd:documentation>
- </xsd:annotation>
- <xsd:sequence>
- <xsd:element name="description" type="Tdescription"
- minOccurs="0" />
- <xsd:group ref="Gvalue" minOccurs="0" />
- </xsd:sequence>
- <xsd:attribute name="name" type="Tmethod" use="required" />
- <xsd:attribute name="ref" type="Tidref" />
- <xsd:attribute name="value" type="TstringValue" />
- </xsd:complexType>
-
- <xsd:complexType name="Tkey">
- <xsd:annotation>
- <xsd:documentation>
- <![CDATA[
- The Tkey type defines the element types that are permitted
- for Map key situations. These can be any of the "value"
- types other than the <null> element.
- ]]>
- </xsd:documentation>
- </xsd:annotation>
- <xsd:group ref="GnonNullValue" />
- </xsd:complexType>
-
- <!-- reference -->
- <xsd:complexType name="Treference">
- <xsd:annotation>
- <xsd:documentation>
- <![CDATA[
- The Treference type defines the <reference> element. These
- are instances of the TserviceReference type, with the addition
- of a timeout attribute. If the timeout is not specified,
- the default-timeout value is inherited from the encapsulating
- <blueprint> definition.
- ]]>
- </xsd:documentation>
- </xsd:annotation>
- <xsd:complexContent>
- <xsd:extension base="TserviceReference">
- <xsd:sequence>
- <xsd:any namespace="##other" minOccurs="0" maxOccurs="unbounded"
- processContents="strict" />
- </xsd:sequence>
- <xsd:attribute name="timeout" type="Ttimeout" />
- </xsd:extension>
- </xsd:complexContent>
- </xsd:complexType>
-
- <xsd:complexType name="Tinlined-reference">
- <xsd:annotation>
- <xsd:documentation>
- <![CDATA[
- The Tinlined-reference type is used for inlined (i.e. non top level)
- <reference> elements.
- ]]>
- </xsd:documentation>
- </xsd:annotation>
- <xsd:complexContent>
- <xsd:restriction base="Treference">
- <xsd:sequence>
- <xsd:group ref="GserviceReferenceElements" />
- <xsd:any namespace="##other" minOccurs="0" maxOccurs="unbounded"
- processContents="strict" />
- </xsd:sequence>
- <xsd:attribute name="id" use="prohibited" />
- <xsd:attribute name="depends-on" type="TdependsOn" />
- <xsd:attribute name="activation" use="prohibited"
- fixed="lazy" />
- <xsd:attribute name="interface" type="Tclass" />
- <xsd:attribute name="filter" type="xsd:normalizedString" />
- <xsd:attribute name="component-name" type="Tidref" />
- <xsd:attribute name="availability" type="Tavailability" />
- <xsd:attribute name="timeout" type="Ttimeout" />
- <xsd:anyAttribute namespace="##other"
- processContents="strict" />
- </xsd:restriction>
- </xsd:complexContent>
- </xsd:complexType>
-
- <!-- reference-list -->
- <xsd:complexType name="Treference-list">
- <xsd:annotation>
- <xsd:documentation>
- <![CDATA[
- The Treference-list builds in the characteristics of the
- TserviceReference type to define characteristics of the
- <reference-list>. This adds in the characteristics that
- only apply to collections of references (e.g., member-type).
- ]]>
- </xsd:documentation>
- </xsd:annotation>
- <xsd:complexContent>
- <xsd:extension base="TserviceReference">
- <xsd:sequence>
- <xsd:any namespace="##other" minOccurs="0" maxOccurs="unbounded"
- processContents="strict" />
- </xsd:sequence>
- <xsd:attribute name="member-type" type="Tservice-use"
- default="service-object">
- </xsd:attribute>
- </xsd:extension>
- </xsd:complexContent>
- </xsd:complexType>
-
- <xsd:complexType name="Tinlined-reference-list">
- <xsd:annotation>
- <xsd:documentation>
- <![CDATA[
- The Tinlined-reference-list type is used for inlined (i.e. non top level)
- <reference-list> elements.
- ]]>
- </xsd:documentation>
- </xsd:annotation>
- <xsd:complexContent>
- <xsd:restriction base="Treference-list">
- <xsd:sequence>
- <xsd:group ref="GserviceReferenceElements" />
- <xsd:any namespace="##other" minOccurs="0" maxOccurs="unbounded"
- processContents="strict" />
- </xsd:sequence>
- <xsd:attribute name="id" use="prohibited" />
- <xsd:attribute name="depends-on" type="TdependsOn" />
- <xsd:attribute name="activation" use="prohibited"
- fixed="lazy" />
- <xsd:attribute name="interface" type="Tclass" />
- <xsd:attribute name="filter" type="xsd:normalizedString" />
- <xsd:attribute name="component-name" type="Tidref" />
- <xsd:attribute name="availability" type="Tavailability" />
- <xsd:attribute name="member-type" type="Tservice-use"
- default="service-object" />
- <xsd:anyAttribute namespace="##other"
- processContents="strict" />
- </xsd:restriction>
- </xsd:complexContent>
- </xsd:complexType>
-
- <!-- Reference base class -->
- <xsd:complexType name="TserviceReference">
- <xsd:annotation>
- <xsd:documentation>
- <![CDATA[
- TserviceReference is the base element type used for <reference>
- and <reference-list> elements. This type defines all of the
- characteristics common to both sorts of references.
- ]]>
- </xsd:documentation>
- </xsd:annotation>
- <xsd:complexContent>
- <xsd:extension base="Tcomponent">
- <xsd:sequence>
- <xsd:group ref="GserviceReferenceElements" />
- </xsd:sequence>
-
- <xsd:attribute name="interface" type="Tclass">
- <xsd:annotation>
- <xsd:documentation>
- <![CDATA[
- The interface that the OSGi service must implement and that will be
- implemented by the proxy object.
- This attribute is optional.
- ]]>
- </xsd:documentation>
- </xsd:annotation>
- </xsd:attribute>
- <xsd:attribute name="filter" type="xsd:normalizedString">
- <xsd:annotation>
- <xsd:documentation>
- <![CDATA[
- A filter string used to narrow the search for a matching service
- reference.
- ]]>
- </xsd:documentation>
- </xsd:annotation>
- </xsd:attribute>
- <xsd:attribute name="component-name" type="Tidref">
- <xsd:annotation>
- <xsd:documentation>
- <![CDATA[
- An optional specifier that can be used to match a service definition
- to one created by a specific blueprint component.
- ]]>
- </xsd:documentation>
- </xsd:annotation>
- </xsd:attribute>
- <xsd:attribute name="availability" type="Tavailability">
- <xsd:annotation>
- <xsd:documentation>
- <![CDATA[
- Use to control the initial processing of service references at
- blueprint context startup. "mandatory" indicates the context
- should not start unless the service is available within the
- specified context startup period. "optional" indicates availability
- of this service is not a requirement at bundle startup.
-
- NOTE: No default is specified because this can be overridden
- by the default-availability attribute of the <blueprint> element.
- ]]>
- </xsd:documentation>
- </xsd:annotation>
- </xsd:attribute>
- <xsd:anyAttribute namespace="##other"
- processContents="strict" />
- </xsd:extension>
- </xsd:complexContent>
- </xsd:complexType>
-
- <xsd:group name="GserviceReferenceElements">
- <xsd:sequence>
- <xsd:element name="description" type="Tdescription"
- minOccurs="0" />
- <!-- listener -->
- <xsd:element name="reference-listener" type="TreferenceListener"
- minOccurs="0" maxOccurs="unbounded">
- <xsd:annotation>
- <xsd:documentation>
- <![CDATA[
- A definition of a listener that will watch for bind/unbind events
- associated with the service reference. The targetted listener can
- be a <ref> to a <bean> or <reference> element, or an inline
- <bean> or <reference>.
- ]]>
- </xsd:documentation>
- </xsd:annotation>
- </xsd:element>
- </xsd:sequence>
- </xsd:group>
-
- <xsd:complexType name="TreferenceListener">
- <xsd:annotation>
- <xsd:documentation>
- <![CDATA[
- TReferenceListener defines a reference listener that is attached
- to a <reference> or <reference-list> element. The listener
- object can be specified as a <ref> or as an inline <bean> or
- <reference> component. Listener events are mapped to the indicated
- bind or unbind methods.
- ]]>
- </xsd:documentation>
- </xsd:annotation>
- <xsd:sequence>
- <xsd:group ref="GtargetComponent" minOccurs="0" />
- </xsd:sequence>
- <xsd:attribute name="ref" type="Tidref" />
- <xsd:attribute name="bind-method" type="Tmethod" />
- <xsd:attribute name="unbind-method" type="Tmethod" />
- </xsd:complexType>
-
- <xsd:simpleType name="Tactivation">
- <xsd:annotation>
- <xsd:documentation>
- <![CDATA[
- Tactivation defines the activation type for components. This is used in this
- schema by the <blueprint> default-activation attribute and the
- activation attribute.
- ]]>
- </xsd:documentation>
- </xsd:annotation>
- <xsd:restriction base="xsd:NMTOKEN">
- <xsd:enumeration value="eager" />
- <xsd:enumeration value="lazy" />
- </xsd:restriction>
- </xsd:simpleType>
-
- <xsd:simpleType name="Tavailability">
- <xsd:annotation>
- <xsd:documentation>
- <![CDATA[
- Tavailability defines an availability attribute type. This is used in this
- schema by the <blueprint> default-availability attribute and the
- <reference> and <reference-list> availability attribute.
- ]]>
- </xsd:documentation>
- </xsd:annotation>
- <xsd:restriction base="xsd:NMTOKEN">
- <xsd:enumeration value="mandatory" />
- <xsd:enumeration value="optional" />
- </xsd:restriction>
- </xsd:simpleType>
-
- <!-- service -->
-
- <xsd:complexType name="Tservice">
- <xsd:annotation>
- <xsd:documentation>
- <![CDATA[
- Tservice is the type for services exported by this blueprint bundle.
- Services are sourced by either a <ref> to a <bean> component or an
- <inline> bean component.
- ]]>
- </xsd:documentation>
- </xsd:annotation>
- <xsd:complexContent>
- <xsd:extension base="Tcomponent">
- <xsd:sequence>
- <xsd:group ref="GserviceElements" />
- </xsd:sequence>
- <xsd:attribute name="interface" type="Tclass">
- <xsd:annotation>
- <xsd:documentation>
- <![CDATA[
- The interface that this OSGi service will provide.
- ]]>
- </xsd:documentation>
- </xsd:annotation>
- </xsd:attribute>
- <xsd:attribute name="ref" type="Tidref">
- <xsd:annotation>
- <xsd:documentation>
- <![CDATA[
- The ref attribute can be used to specify the component that provides
- the object exported as an OSGi service.
- ]]>
- </xsd:documentation>
- </xsd:annotation>
- </xsd:attribute>
- <xsd:attribute name="auto-export" type="TautoExportModes"
- default="disabled">
- <xsd:annotation>
- <xsd:documentation>
- <![CDATA[
- If set to a value different from "disabled", the Blueprint Container
- will introspect the target to discover the set of interfaces or classes
- that the service will be registered under.
- ]]>
- </xsd:documentation>
- </xsd:annotation>
- </xsd:attribute>
- <xsd:attribute name="ranking" type="xsd:int" default="0">
- <xsd:annotation>
- <xsd:documentation>
- <![CDATA[
- A service ranking value that is added to the service properties
- the service will be published with.
- ]]>
- </xsd:documentation>
- </xsd:annotation>
- </xsd:attribute>
- <xsd:anyAttribute namespace="##other"
- processContents="strict" />
- </xsd:extension>
- </xsd:complexContent>
- </xsd:complexType>
-
- <xsd:complexType name="Tinlined-service">
- <xsd:annotation>
- <xsd:documentation>
- <![CDATA[
- The Tinlined-service type is used for inlined (i.e. non top level)
- <service> elements.
- ]]>
- </xsd:documentation>
- </xsd:annotation>
- <xsd:complexContent>
- <xsd:restriction base="Tservice">
- <xsd:sequence>
- <xsd:group ref="GserviceElements" />
- </xsd:sequence>
- <xsd:attribute name="id" use="prohibited" />
- <xsd:attribute name="depends-on" type="TdependsOn" />
- <xsd:attribute name="activation" use="prohibited"
- fixed="lazy" />
- <xsd:attribute name="interface" type="Tclass" />
- <xsd:attribute name="ref" type="Tidref" />
- <xsd:attribute name="auto-export" type="TautoExportModes"
- default="disabled" />
- <xsd:attribute name="ranking" type="xsd:int" default="0" />
- <xsd:anyAttribute namespace="##other"
- processContents="strict" />
- </xsd:restriction>
- </xsd:complexContent>
- </xsd:complexType>
-
- <xsd:group name="GbaseServiceElements">
- <xsd:sequence>
- <xsd:element name="description" type="Tdescription"
- minOccurs="0" />
- <xsd:element name="interfaces" type="Tinterfaces"
- minOccurs="0">
- <xsd:annotation>
- <xsd:documentation>
- <![CDATA[
- A collection of one or more interface class names this service
- will be registered under. The <service> element also has
- a shortcut interface attribute for the usual case of just
- a single interface being used. This also cannot be used if
- the auto-export attribute is used.
- ]]>
- </xsd:documentation>
- </xsd:annotation>
- </xsd:element>
-
- <xsd:element name="service-properties" type="TserviceProperties"
- minOccurs="0">
- <xsd:annotation>
- <xsd:documentation>
- <![CDATA[
- The service provided when the service is registered. The service
- properties are similar to map elements, but the keys must always
- be strings, and the values are required to be in a narrower range.
- ]]>
- </xsd:documentation>
- </xsd:annotation>
- </xsd:element>
- <xsd:element name="registration-listener" type="TregistrationListener"
- minOccurs="0" maxOccurs="unbounded">
- <xsd:annotation>
- <xsd:documentation>
- <![CDATA[
- A set of 0 or more registration listeners attached to this service
- component. The registration listeners will be notified whenever the
- service is registered or unregistered from the framework service
- registry.
- ]]>
- </xsd:documentation>
- </xsd:annotation>
- </xsd:element>
- </xsd:sequence>
- </xsd:group>
-
- <xsd:group name="GserviceElements">
- <xsd:annotation>
- <xsd:documentation>
- <![CDATA[
- A set of service elements.
- ]]>
- </xsd:documentation>
- </xsd:annotation>
- <xsd:sequence>
- <xsd:group ref="GbaseServiceElements" />
- <xsd:group ref="GtargetComponent" minOccurs="0">
- <xsd:annotation>
- <xsd:documentation>
- <![CDATA[
- A service definition can use any of the target types as an inline element
- as well.
- ]]>
- </xsd:documentation>
- </xsd:annotation>
- </xsd:group>
- </xsd:sequence>
- </xsd:group>
-
- <xsd:complexType name="TregistrationListener">
- <xsd:annotation>
- <xsd:documentation>
- <![CDATA[
- A registration listener definition. The target registration listener
- can be either a <ref> to a <bean> or <service> component, or an inline
- <bean> or <service> component definition. The registration-method and
- unregistration-method attributes define the methods that will be called
- for the respective events.
-
- For the very common case of using a <ref> to a listener component, the
- ref attribute may also be used as a shortcut.
- ]]>
- </xsd:documentation>
- </xsd:annotation>
- <xsd:sequence>
- <xsd:group ref="GtargetComponent" minOccurs="0" />
- </xsd:sequence>
- <xsd:attribute name="ref" type="Tidref" />
- <xsd:attribute name="registration-method" type="Tmethod" />
- <xsd:attribute name="unregistration-method" type="Tmethod" />
- </xsd:complexType>
-
- <!-- Values -->
-
- <xsd:group name="Gvalue">
- <xsd:annotation>
- <xsd:documentation>
- <![CDATA[
- The set of "value" types that can be used in any place a value
- can be specified. This set includes the <ref> and <idref> elements, any of the
- component types (<bean>, <service>, etc.) as inline components, the
- generic <value> element for types sourced from string values, any of the
- collection types (<set>, <list>, <array>, <map>, <props>), and the
- <null> type to inject a null value.
- ]]>
- </xsd:documentation>
- </xsd:annotation>
- <xsd:choice>
- <xsd:group ref="GnonNullValue" />
- <xsd:element name="null" type="Tnull" />
- </xsd:choice>
- </xsd:group>
-
- <xsd:complexType name="Tnull">
- <xsd:annotation>
- <xsd:documentation>
- <![CDATA[
- The definition for a <null> value type.
- ]]>
- </xsd:documentation>
- </xsd:annotation>
- </xsd:complexType>
-
- <xsd:group name="GnonNullValue">
- <xsd:annotation>
- <xsd:documentation>
- <![CDATA[
- The set of "value" types that can be used in any place a non-null value
- can be specified. This set includes the <ref> and <idref> elements, any of the
- component types (<bean>, <service>, etc.) as inline components, the
- generic <value> element for types sourced from string values, and any of the
- collection types (<set>, <list>, <array>, <map>, <props>).
-
- The <null> type is NOT a member of this group.
- ]]>
- </xsd:documentation>
- </xsd:annotation>
- <xsd:choice>
- <xsd:group ref="GallComponents" />
- <xsd:element name="idref" type="Tref" />
- <xsd:element name="value" type="Tvalue" />
- <xsd:element name="list" type="Tcollection" />
- <xsd:element name="set" type="Tcollection" />
- <xsd:element name="map" type="Tmap" />
- <xsd:element name="array" type="Tcollection" />
- <xsd:element name="props" type="Tprops" />
- </xsd:choice>
- </xsd:group>
-
- <xsd:complexType name="Tref">
- <xsd:annotation>
- <xsd:documentation>
- <![CDATA[
- Tref is the type used for <ref> elements. This specifies a required
- component id for the reference component.
- ]]>
- </xsd:documentation>
- </xsd:annotation>
- <xsd:attribute name="component-id" type="Tidref" use="required" />
- </xsd:complexType>
-
- <xsd:complexType name="Tvalue" mixed="true">
- <xsd:annotation>
- <xsd:documentation>
- <![CDATA[
- Tvalue is the type used for <value> elements. The <value> element
- is used for types that can be created from a single string value.
- The string value is the data value for the element. The optional
- type attribute allows a target conversion value to be explicitly
- specified.
- ]]>
- </xsd:documentation>
- </xsd:annotation>
- <xsd:attribute name="type" type="Ttype" />
- </xsd:complexType>
-
- <!-- Collection Values -->
-
- <xsd:complexType name="TtypedCollection">
- <xsd:annotation>
- <xsd:documentation>
- <![CDATA[
- TtypeCollection defines comment attributes shared among different
- collection types that allow a default value type to be specified.
- ]]>
- </xsd:documentation>
- </xsd:annotation>
- <xsd:attribute name="value-type" type="Ttype" />
- </xsd:complexType>
-
- <xsd:complexType name="Tcollection">
- <xsd:annotation>
- <xsd:documentation>
- <![CDATA[
- Tcollection is the base schema type for different ordered collection
- types. This is shared between the <array>, <list>, and <set> elements.
- ]]>
- </xsd:documentation>
- </xsd:annotation>
- <xsd:complexContent>
- <xsd:extension base="TtypedCollection">
- <xsd:group ref="Gvalue" minOccurs="0" maxOccurs="unbounded" />
- </xsd:extension>
- </xsd:complexContent>
- </xsd:complexType>
-
- <xsd:complexType name="Tprops">
- <xsd:annotation>
- <xsd:documentation>
- <![CDATA[
- Tprops is the type used by the <props> value element. The prop elements
- are pairs of string-valued keys and values.
- ]]>
- </xsd:documentation>
- </xsd:annotation>
- <xsd:sequence>
- <xsd:element name="prop" type="Tprop" minOccurs="0"
- maxOccurs="unbounded" />
- </xsd:sequence>
- </xsd:complexType>
-
- <xsd:complexType name="Tprop" mixed="true">
- <xsd:annotation>
- <xsd:documentation>
- <![CDATA[
- Tprop is a single property element for a <props> value type. The property
- value can be specified using either the attribute, or as value data for
- the property element.
- ]]>
- </xsd:documentation>
- </xsd:annotation>
- <xsd:attribute name="key" type="TstringValue" use="required" />
- <xsd:attribute name="value" type="TstringValue" />
- </xsd:complexType>
-
- <!-- 'map' element type -->
- <xsd:complexType name="Tmap">
- <xsd:annotation>
- <xsd:documentation>
- <![CDATA[
- Tmap is the base type used for <map> elements. A map may have a
- default value type specified, so it inherits from the TtypeCollection
- type. A key type can also be specified, and the map members are
- created from the entry elements, which require a key/value pair.
- ]]>
- </xsd:documentation>
- </xsd:annotation>
- <xsd:complexContent>
- <xsd:extension base="TtypedCollection">
- <xsd:sequence>
- <xsd:element name="entry" type="TmapEntry" minOccurs="0"
- maxOccurs="unbounded" />
- </xsd:sequence>
- <xsd:attribute name="key-type" type="Ttype" />
- </xsd:extension>
- </xsd:complexContent>
- </xsd:complexType>
-
- <!-- 'entry' element type -->
- <xsd:complexType name="TmapEntry">
- <xsd:annotation>
- <xsd:documentation>
- <![CDATA[
- TmapEntry is used for <entry> elements nested inside of a <map> element.
- Each <entry> instance defines a key/value pair that will be added to the
- Map. Both the keys and values may be arbitrary types. Keys must not
- be <null> but <null> is permitted for entry values. A default type
- can be specified for both the keys and the values, but individual keys
- or values can override the default.
- ]]>
- </xsd:documentation>
- </xsd:annotation>
- <xsd:sequence>
- <xsd:element name="key" type="Tkey" minOccurs="0" />
- <xsd:group ref="Gvalue" minOccurs="0" />
- </xsd:sequence>
- <xsd:attribute name="key" type="TstringValue" />
- <xsd:attribute name="key-ref" type="Tidref" />
- <xsd:attribute name="value" type="TstringValue" />
- <xsd:attribute name="value-ref" type="Tidref" />
- </xsd:complexType>
-
- <!-- 'service property' element type -->
- <xsd:complexType name="TserviceProperties">
- <xsd:annotation>
- <xsd:documentation>
- <![CDATA[
- TserviceProperty is used for <service-properties> elements.
- The syntax is similar to what is defined for <map>, but keys must be
- string values and there are no type defaults that can be specified.
- created from the entry elements, which require a key/value pair.
- ]]>
- </xsd:documentation>
- </xsd:annotation>
- <xsd:sequence>
- <xsd:element name="entry" type="TservicePropertyEntry"
- minOccurs="0" maxOccurs="unbounded" />
- <xsd:any namespace="##other" processContents="strict"
- minOccurs="0" maxOccurs="unbounded" />
- </xsd:sequence>
- </xsd:complexType>
-
- <!-- 'entry' element type -->
- <xsd:complexType name="TservicePropertyEntry">
- <xsd:annotation>
- <xsd:documentation>
- <![CDATA[
- TservicePropertyEntry is an entry value used for the <service-properties>
- element. This does not allow a child <key> element and there are no
- key-ref or value-ref attributes.
- ]]>
- </xsd:documentation>
- </xsd:annotation>
- <xsd:sequence>
- <xsd:group ref="Gvalue" minOccurs="0" />
- </xsd:sequence>
- <xsd:attribute name="key" type="TstringValue" use="required" />
- <xsd:attribute name="value" type="TstringValue" />
- </xsd:complexType>
-
- <!-- General types -->
-
- <xsd:complexType name="Tdescription" mixed="true">
- <xsd:annotation>
- <xsd:documentation>
- <![CDATA[
- A generic <description> element type to allow documentation to added to the
- blueprint configuration.
- ]]>
- </xsd:documentation>
- </xsd:annotation>
- <xsd:choice minOccurs="0" maxOccurs="unbounded" />
- </xsd:complexType>
-
- <xsd:complexType name="Tinterfaces">
- <xsd:annotation>
- <xsd:documentation>
- <![CDATA[
- The type definition for the <interfaces> element used for <service>
- ]]>
- </xsd:documentation>
- </xsd:annotation>
- <xsd:choice minOccurs="1" maxOccurs="unbounded">
- <xsd:element name="value" type="TinterfaceValue" />
- </xsd:choice>
- </xsd:complexType>
-
- <xsd:simpleType name="TinterfaceValue">
- <xsd:annotation>
- <xsd:documentation>
- <![CDATA[
- TinterfaceValue is used for subelements of the <interfaces> element.
- This is just a <value>xxxxx</value> element where the contained
- value is the name of an interface class.
- ]]>
- </xsd:documentation>
- </xsd:annotation>
- <xsd:restriction base="Tclass" />
- </xsd:simpleType>
-
- <xsd:simpleType name="Tclass">
- <xsd:annotation>
- <xsd:documentation>
- <![CDATA[
- Tclass is a base type that should be used for all attributes that
- refer to java class names.
- ]]>
- </xsd:documentation>
- </xsd:annotation>
- <xsd:restriction base="xsd:NCName" />
- </xsd:simpleType>
-
- <xsd:simpleType name="Ttype">
- <xsd:annotation>
- <xsd:documentation>
- <![CDATA[
- Ttype is a base type that refer to java types such as classes or
- arrays.
- ]]>
- </xsd:documentation>
- </xsd:annotation>
- <xsd:restriction base="xsd:token">
- <xsd:pattern value="[\i-[:]][\c-[:]]*(\[\])*" />
- </xsd:restriction>
- </xsd:simpleType>
-
- <xsd:simpleType name="Tmethod">
- <xsd:annotation>
- <xsd:documentation>
- <![CDATA[
- Tmethod is a base type that should be used for all attributes that
- refer to java method names.
- ]]>
- </xsd:documentation>
- </xsd:annotation>
- <xsd:restriction base="xsd:NCName" />
- </xsd:simpleType>
-
- <!--
- Should be used for all attributes and elements that refer to method
- names
- -->
- <xsd:simpleType name="Tidref">
- <xsd:annotation>
- <xsd:documentation>
- <![CDATA[
- Tidref is a base type that should be used for all attributes that
- refer to component ids.
- ]]>
- </xsd:documentation>
- </xsd:annotation>
- <xsd:restriction base="xsd:NCName" />
- </xsd:simpleType>
-
- <xsd:simpleType name="TstringValue">
- <xsd:annotation>
- <xsd:documentation>
- <![CDATA[
- TstringValue is a base type that should be used for all attributes that
- refer to raw string values
- ]]>
- </xsd:documentation>
- </xsd:annotation>
- <xsd:restriction base="xsd:normalizedString" />
- </xsd:simpleType>
-
- <xsd:simpleType name="TautoExportModes">
- <xsd:annotation>
- <xsd:documentation>
- <![CDATA[
- TautoExportModes is a base type that should be used for export-mode
- attributes.
- ]]>
- </xsd:documentation>
- </xsd:annotation>
- <xsd:restriction base="xsd:NMTOKEN">
- <xsd:enumeration value="disabled" />
- <xsd:enumeration value="interfaces" />
- <xsd:enumeration value="class-hierarchy" />
- <xsd:enumeration value="all-classes" />
- </xsd:restriction>
- </xsd:simpleType>
-
- <xsd:simpleType name="Ttimeout">
- <xsd:annotation>
- <xsd:documentation>
- <![CDATA[
- Ttimeout is a base type that should be used for all attributes that
- specify timeout values
- ]]>
- </xsd:documentation>
- </xsd:annotation>
- <xsd:restriction base="xsd:unsignedLong" />
- </xsd:simpleType>
-
- <xsd:simpleType name="TdependsOn">
- <xsd:annotation>
- <xsd:documentation>
- <![CDATA[
- TdependsOn is a base type that should be used for all attributes that
- specify depends-on relationships
- ]]>
- </xsd:documentation>
- </xsd:annotation>
- <xsd:restriction>
- <xsd:simpleType>
- <xsd:list itemType="Tidref" />
- </xsd:simpleType>
- <xsd:minLength value="1" />
- </xsd:restriction>
- </xsd:simpleType>
-
- <xsd:simpleType name="Tscope">
- <xsd:union>
- <xsd:simpleType>
- <xsd:restriction base="xsd:NMTOKEN">
- <xsd:enumeration value="singleton" />
- <xsd:enumeration value="prototype" />
- </xsd:restriction>
- </xsd:simpleType>
- <xsd:simpleType>
- <xsd:restriction base="xsd:QName">
- <xsd:pattern value=".+:.+" />
- </xsd:restriction>
- </xsd:simpleType>
- </xsd:union>
- </xsd:simpleType>
-
- <xsd:simpleType name="Tservice-use">
- <xsd:annotation>
- <xsd:documentation>
- <![CDATA[
- Indicates the type of object that will be placed within the
- reference collection. "service-object" indicates the
- collection contains blueprint proxies for imported services.
- "service-reference" indicates the collection contains
- ServiceReference objects matching the target service type.
- ]]>
- </xsd:documentation>
- </xsd:annotation>
- <xsd:restriction base="xsd:NMTOKEN">
- <xsd:enumeration value="service-object" />
- <xsd:enumeration value="service-reference" />
- </xsd:restriction>
- </xsd:simpleType>
-
-</xsd:schema>
diff --git a/org.osgi.compendium/src/main/resources/xmlns/metatype/v1.0.0/metatype.xsd b/org.osgi.compendium/src/main/resources/xmlns/metatype/v1.0.0/metatype.xsd
deleted file mode 100644
index 97d70d3..0000000
--- a/org.osgi.compendium/src/main/resources/xmlns/metatype/v1.0.0/metatype.xsd
+++ /dev/null
@@ -1,121 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!--
-/*
- * $Revision: 5673 $
- *
- * Copyright (c) OSGi Alliance (2005, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
--->
-<schema xmlns="http://www.w3.org/2001/XMLSchema"
- targetNamespace="http://www.osgi.org/xmlns/metatype/v1.0.0"
- xmlns:metatype="http://www.osgi.org/xmlns/metatype/v1.0.0">
-
- <complexType name="MetaData">
- <sequence>
- <element name="OCD" type="metatype:OCD" minOccurs="0"
- maxOccurs="unbounded" />
- <element name="Designate" type="metatype:Designate"
- minOccurs="0" maxOccurs="unbounded" />
- </sequence>
- <attribute name="localization" type="string" use="optional" />
- </complexType>
-
- <complexType name="OCD">
- <sequence>
- <element name="AD" type="metatype:AD" minOccurs="1"
- maxOccurs="unbounded" />
- <element name="Icon" type="metatype:Icon" minOccurs="0"
- maxOccurs="1" />
- </sequence>
- <attribute name="name" type="string" use="required" />
- <attribute name="description" type="string" use="optional" />
- <attribute name="id" type="string" use="required" />
- </complexType>
-
- <complexType name="AD">
- <sequence>
- <element name="Option" type="metatype:Option" minOccurs="0"
- maxOccurs="unbounded" />
- </sequence>
- <attribute name="name" type="string" use="optional" />
- <attribute name="description" type="string" use="optional" />
- <attribute name="id" type="string" use="required" />
- <attribute name="type" type="metatype:Scalar" use="required" />
- <attribute name="cardinality" type="int" use="optional"
- default="0" />
- <attribute name="min" type="string" use="optional" />
- <attribute name="max" type="string" use="optional" />
- <attribute name="default" type="string" use="optional" />
- <attribute name="required" type="boolean" use="optional"
- default="true" />
- </complexType>
-
- <complexType name="Object">
- <sequence>
- <element name="Attribute" type="metatype:Attribute"
- minOccurs="0" maxOccurs="unbounded" />
- </sequence>
- <attribute name="ocdref" type="string" use="required" />
- </complexType>
-
- <complexType name="Attribute">
- <sequence>
- <element name="Value" type="string" minOccurs="0"
- maxOccurs="unbounded" />
- </sequence>
- <attribute name="adref" type="string" use="required" />
- <attribute name="content" type="string" use="optional" />
- </complexType>
-
- <complexType name="Designate">
- <sequence>
- <element name="Object" type="metatype:Object" minOccurs="1"
- maxOccurs="1" />
- </sequence>
- <attribute name="pid" type="string" use="required" />
- <attribute name="factoryPid" type="string" use="optional" />
- <attribute name="bundle" type="string" use="optional" />
- <attribute name="optional" type="boolean" default="false"
- use="optional" />
- <attribute name="merge" type="boolean" default="false"
- use="optional" />
- </complexType>
-
- <simpleType name="Scalar">
- <restriction base="string">
- <enumeration value="String" />
- <enumeration value="Long" />
- <enumeration value="Double" />
- <enumeration value="Float" />
- <enumeration value="Integer" />
- <enumeration value="Byte" />
- <enumeration value="Char" />
- <enumeration value="Boolean" />
- <enumeration value="Short" />
- </restriction>
- </simpleType>
-
- <complexType name="Option">
- <attribute name="label" type="string" use="required" />
- <attribute name="value" type="string" use="required" />
- </complexType>
-
- <complexType name="Icon">
- <attribute name="resource" type="string" use="required" />
- <attribute name="size" type="positiveInteger" use="required" />
- </complexType>
-
- <element name="MetaData" type="metatype:MetaData" />
-</schema>
\ No newline at end of file
diff --git a/org.osgi.compendium/src/main/resources/xmlns/metatype/v1.1.0/metatype.xsd b/org.osgi.compendium/src/main/resources/xmlns/metatype/v1.1.0/metatype.xsd
deleted file mode 100644
index 605c69c..0000000
--- a/org.osgi.compendium/src/main/resources/xmlns/metatype/v1.1.0/metatype.xsd
+++ /dev/null
@@ -1,170 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!--
- /*
- * $Revision: 5655 $
- *
- * Copyright (c) OSGi Alliance (2005, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
--->
-<schema xmlns="http://www.w3.org/2001/XMLSchema"
- xmlns:metatype="http://www.osgi.org/xmlns/metatype/v1.1.0"
- targetNamespace="http://www.osgi.org/xmlns/metatype/v1.1.0"
- version="1.1.0">
-
- <element name="MetaData" type="metatype:Tmetadata" />
-
- <complexType name="Tmetadata">
- <sequence>
- <element name="OCD" type="metatype:Tocd" minOccurs="0"
- maxOccurs="unbounded" />
- <element name="Designate" type="metatype:Tdesignate"
- minOccurs="0" maxOccurs="unbounded" />
- <!-- It is non-deterministic, per W3C XML Schema 1.0: http://www.w3.org/TR/xmlschema-1/#cos-nonambig
- to use namespace="##any" below. -->
- <any namespace="##other" processContents="lax" minOccurs="0"
- maxOccurs="unbounded" />
- </sequence>
- <attribute name="localization" type="string" use="optional" />
- <anyAttribute />
- </complexType>
-
- <complexType name="Tocd">
- <sequence>
- <element name="AD" type="metatype:Tad" minOccurs="1"
- maxOccurs="unbounded" />
- <element name="Icon" type="metatype:Ticon" minOccurs="0"
- maxOccurs="1" />
- <!-- It is non-deterministic, per W3C XML Schema 1.0: http://www.w3.org/TR/xmlschema-1/#cos-nonambig
- to use namespace="##any" below. -->
- <any namespace="##other" processContents="lax" minOccurs="0"
- maxOccurs="unbounded" />
- </sequence>
- <attribute name="name" type="string" use="required" />
- <attribute name="description" type="string" use="optional" />
- <attribute name="id" type="string" use="required" />
- <anyAttribute />
- </complexType>
-
- <complexType name="Tad">
- <sequence>
- <element name="Option" type="metatype:Toption" minOccurs="0"
- maxOccurs="unbounded" />
- <!-- It is non-deterministic, per W3C XML Schema 1.0: http://www.w3.org/TR/xmlschema-1/#cos-nonambig
- to use namespace="##any" below. -->
- <any namespace="##other" processContents="lax" minOccurs="0"
- maxOccurs="unbounded" />
- </sequence>
- <attribute name="name" type="string" use="optional" />
- <attribute name="description" type="string" use="optional" />
- <attribute name="id" type="string" use="required" />
- <attribute name="type" type="metatype:Tscalar" use="required" />
- <attribute name="cardinality" type="int" use="optional"
- default="0" />
- <attribute name="min" type="string" use="optional" />
- <attribute name="max" type="string" use="optional" />
- <attribute name="default" type="string" use="optional" />
- <attribute name="required" type="boolean" use="optional"
- default="true" />
- <anyAttribute />
- </complexType>
-
- <complexType name="Tobject">
- <sequence>
- <element name="Attribute" type="metatype:Tattribute"
- minOccurs="0" maxOccurs="unbounded" />
- <!-- It is non-deterministic, per W3C XML Schema 1.0: http://www.w3.org/TR/xmlschema-1/#cos-nonambig
- to use namespace="##any" below. -->
- <any namespace="##other" processContents="lax" minOccurs="0"
- maxOccurs="unbounded" />
- </sequence>
- <attribute name="ocdref" type="string" use="required" />
- <anyAttribute />
- </complexType>
-
- <complexType name="Tattribute">
- <sequence>
- <element name="Value" type="string" minOccurs="0"
- maxOccurs="unbounded" />
- <!-- It is non-deterministic, per W3C XML Schema 1.0: http://www.w3.org/TR/xmlschema-1/#cos-nonambig
- to use namespace="##any" below. -->
- <any namespace="##other" processContents="lax" minOccurs="0"
- maxOccurs="unbounded" />
- </sequence>
- <attribute name="adref" type="string" use="required" />
- <attribute name="content" type="string" use="optional" />
- <anyAttribute />
- </complexType>
-
- <complexType name="Tdesignate">
- <sequence>
- <element name="Object" type="metatype:Tobject" minOccurs="1"
- maxOccurs="1" />
- <any namespace="##any" processContents="lax" minOccurs="0"
- maxOccurs="unbounded" />
- </sequence>
- <attribute name="pid" type="string" use="required" />
- <attribute name="factoryPid" type="string" use="optional" />
- <attribute name="bundle" type="string" use="optional" />
- <attribute name="optional" type="boolean" default="false"
- use="optional" />
- <attribute name="merge" type="boolean" default="false"
- use="optional" />
- <anyAttribute />
- </complexType>
-
- <simpleType name="Tscalar">
- <restriction base="string">
- <enumeration value="String" />
- <enumeration value="Long" />
- <enumeration value="Double" />
- <enumeration value="Float" />
- <enumeration value="Integer" />
- <enumeration value="Byte" />
- <enumeration value="Char" />
- <enumeration value="Boolean" />
- <enumeration value="Short" />
- </restriction>
- </simpleType>
-
- <complexType name="Toption">
- <sequence>
- <any namespace="##any" processContents="lax" minOccurs="0"
- maxOccurs="unbounded" />
- </sequence>
- <attribute name="label" type="string" use="required" />
- <attribute name="value" type="string" use="required" />
- <anyAttribute />
- </complexType>
-
- <complexType name="Ticon">
- <sequence>
- <any namespace="##any" processContents="lax" minOccurs="0"
- maxOccurs="unbounded" />
- </sequence>
- <attribute name="resource" type="string" use="required" />
- <attribute name="size" type="positiveInteger" use="required" />
- <anyAttribute />
- </complexType>
-
- <attribute name="must-understand" type="boolean">
- <annotation>
- <documentation xml:lang="en">
- This attribute should be used by extensions to documents
- to require that the document consumer understand the
- extension.
- </documentation>
- </annotation>
- </attribute>
-</schema>
\ No newline at end of file
diff --git a/org.osgi.compendium/src/main/resources/xmlns/scr/v1.0.0/scr.xsd b/org.osgi.compendium/src/main/resources/xmlns/scr/v1.0.0/scr.xsd
deleted file mode 100644
index 9b1a13a..0000000
--- a/org.osgi.compendium/src/main/resources/xmlns/scr/v1.0.0/scr.xsd
+++ /dev/null
@@ -1,129 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!--
-/*
- * $Revision: 5655 $
- *
- * Copyright (c) OSGi Alliance (2005, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
--->
-<schema xmlns="http://www.w3.org/2001/XMLSchema" targetNamespace="http://www.osgi.org/xmlns/scr/v1.0.0" xmlns:scr="http://www.osgi.org/xmlns/scr/v1.0.0">
- <annotation>
- <documentation xml:lang="en">
-This is the XML Schema for component descriptions used by the Service Component Runtime (SCR).
-Component description documents may be embedded in other XML documents. The SCR will
-process all XML documents listed in the Service-Component manifest header of a bundle.
-XML documents containing component descriptions may contain a single, root component
-element or one or more component elements embedded in a larger document. Use of the
-namespace is optional if the document only contains a root component element. In this
-case, the scr namespace is assumed. Otherwise the namespace must be used.
- </documentation>
- </annotation>
-
- <element name="component" type="scr:Tcomponent"/>
-
- <complexType name="Tcomponent">
- <annotation>
- <documentation xml:lang="en">
- Implementations of SCR must not require component descriptions to specify the subelements
- of the component element in the order as required by the schema. SCR implementations must
- allow other orderings since arbitrary orderings do not affect the meaning of the component
- description. Only the relative ordering of property and properties element have meaning.
- </documentation>
- </annotation>
- <sequence>
- <element name="implementation" type="scr:Timplementation" minOccurs="1" maxOccurs="1"/>
- <choice minOccurs="0" maxOccurs="unbounded">
- <element name="property" type="scr:Tproperty"/>
- <element name="properties" type="scr:Tproperties"/>
- </choice>
- <element name="service" type="scr:Tservice" minOccurs="0" maxOccurs="1"/>
- <element name="reference" type="scr:Treference" minOccurs="0" maxOccurs="unbounded"/>
- </sequence>
- <attribute name="enabled" type="boolean" default="true" use="optional"/>
- <attribute name="name" type="token" use="required"/>
- <attribute name="factory" type="string" use="optional"/>
- <attribute name="immediate" type="boolean" use="optional"/>
- </complexType>
-
- <complexType name="Timplementation">
- <attribute name="class" type="token" use="required"/>
- </complexType>
-
- <complexType name="Tproperty">
- <simpleContent>
- <extension base="string">
- <attribute name="name" type="string" use="required"/>
- <attribute name="value" type="string" use="optional"/>
- <attribute name="type" type="scr:Tjava-types" default="String" use="optional"/>
- </extension>
- </simpleContent>
- </complexType>
-
- <complexType name="Tproperties">
- <attribute name="entry" type="string" use="required"/>
- </complexType>
-
- <complexType name="Tservice">
- <sequence>
- <element name="provide" type="scr:Tprovide" minOccurs="1" maxOccurs="unbounded"/>
- </sequence>
- <attribute name="servicefactory" type="boolean" default="false" use="optional"/>
- </complexType>
-
- <complexType name="Tprovide">
- <attribute name="interface" type="token" use="required"/>
- </complexType>
-
- <complexType name="Treference">
- <attribute name="name" type="NMTOKEN" use="required"/>
- <attribute name="interface" type="token" use="required"/>
- <attribute name="cardinality" type="scr:Tcardinality" default="1..1" use="optional"/>
- <attribute name="policy" type="scr:Tpolicy" default="static" use="optional"/>
- <attribute name="target" type="string" use="optional"/>
- <attribute name="bind" type="token" use="optional"/>
- <attribute name="unbind" type="token" use="optional"/>
- </complexType>
-
- <simpleType name="Tjava-types">
- <restriction base="string">
- <enumeration value="String"/>
- <enumeration value="Long"/>
- <enumeration value="Double"/>
- <enumeration value="Float"/>
- <enumeration value="Integer"/>
- <enumeration value="Byte"/>
- <enumeration value="Character"/>
- <enumeration value="Boolean"/>
- <enumeration value="Short"/>
- </restriction>
- </simpleType>
-
- <simpleType name="Tcardinality">
- <restriction base="string">
- <enumeration value="0..1"/>
- <enumeration value="0..n"/>
- <enumeration value="1..1"/>
- <enumeration value="1..n"/>
- </restriction>
- </simpleType>
-
- <simpleType name="Tpolicy">
- <restriction base="string">
- <enumeration value="static"/>
- <enumeration value="dynamic"/>
- </restriction>
- </simpleType>
-
-</schema>
\ No newline at end of file
diff --git a/org.osgi.compendium/src/main/resources/xmlns/scr/v1.1.0/scr.xsd b/org.osgi.compendium/src/main/resources/xmlns/scr/v1.1.0/scr.xsd
deleted file mode 100644
index 8ada1db..0000000
--- a/org.osgi.compendium/src/main/resources/xmlns/scr/v1.1.0/scr.xsd
+++ /dev/null
@@ -1,216 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
- <!--
- /*
- * $Revision: 7533 $
- *
- * Copyright (c) OSGi Alliance (2005, 2009). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
- -->
-<schema xmlns="http://www.w3.org/2001/XMLSchema"
- xmlns:scr="http://www.osgi.org/xmlns/scr/v1.1.0"
- targetNamespace="http://www.osgi.org/xmlns/scr/v1.1.0"
- elementFormDefault="unqualified"
- attributeFormDefault="unqualified"
- version="1.1.0">
-
- <annotation>
- <documentation xml:lang="en">
- This is the XML Schema for component descriptions used by
- the Service Component Runtime (SCR). Component description
- documents may be embedded in other XML documents. SCR will
- process all XML documents listed in the Service-Component
- manifest header of a bundle. XML documents containing
- component descriptions may contain a single, root component
- element or one or more component elements embedded in a
- larger document. Use of the namespace for component
- descriptions is mandatory. The attributes and subelements
- of a component element are always unqualified.
- </documentation>
- </annotation>
- <element name="component" type="scr:Tcomponent" />
- <complexType name="Tcomponent">
- <sequence>
- <annotation>
- <documentation xml:lang="en">
- Implementations of SCR must not require component
- descriptions to specify the subelements of the component
- element in the order as required by the schema. SCR
- implementations must allow other orderings since
- arbitrary orderings do not affect the meaning of the
- component description. Only the relative ordering of
- property and properties element have meaning.
- </documentation>
- </annotation>
- <choice minOccurs="0" maxOccurs="unbounded">
- <element name="property" type="scr:Tproperty" />
- <element name="properties" type="scr:Tproperties" />
- </choice>
- <element name="service" type="scr:Tservice" minOccurs="0"
- maxOccurs="1" />
- <element name="reference" type="scr:Treference"
- minOccurs="0" maxOccurs="unbounded" />
- <element name="implementation" type="scr:Timplementation"
- minOccurs="1" maxOccurs="1" />
- <any namespace="##any" processContents="lax" minOccurs="0"
- maxOccurs="unbounded" />
- </sequence>
- <attribute name="enabled" type="boolean" default="true"
- use="optional" />
- <attribute name="name" type="token" use="optional">
- <annotation>
- <documentation xml:lang="en">
- The default value of this attribute is the value of
- the class attribute of the nested implementation
- element. If multiple component elements use the same
- value for the class attribute of their nested
- implementation element, then using the default value
- for this attribute will result in duplicate names.
- In this case, this attribute must be specified with
- a unique value.
- </documentation>
- </annotation>
- </attribute>
- <attribute name="factory" type="string" use="optional" />
- <attribute name="immediate" type="boolean" use="optional" />
- <attribute name="configuration-policy"
- type="scr:Tconfiguration-policy" default="optional" use="optional" />
- <attribute name="activate" type="token" use="optional"
- default="activate" />
- <attribute name="deactivate" type="token" use="optional"
- default="deactivate" />
- <attribute name="modified" type="token" use="optional" />
- <anyAttribute />
- </complexType>
- <complexType name="Timplementation">
- <sequence>
- <any namespace="##any" processContents="lax" minOccurs="0"
- maxOccurs="unbounded" />
- </sequence>
- <attribute name="class" type="token" use="required" />
- <anyAttribute />
- </complexType>
- <complexType name="Tproperty">
- <simpleContent>
- <extension base="string">
- <attribute name="name" type="string" use="required" />
- <attribute name="value" type="string" use="optional" />
- <attribute name="type" type="scr:Tjava-types"
- default="String" use="optional" />
- <anyAttribute />
- </extension>
- </simpleContent>
- </complexType>
- <complexType name="Tproperties">
- <sequence>
- <any namespace="##any" processContents="lax" minOccurs="0"
- maxOccurs="unbounded" />
- </sequence>
- <attribute name="entry" type="string" use="required" />
- <anyAttribute />
- </complexType>
- <complexType name="Tservice">
- <sequence>
- <element name="provide" type="scr:Tprovide" minOccurs="1"
- maxOccurs="unbounded" />
- <!-- It is non-deterministic, per W3C XML Schema 1.0:
- http://www.w3.org/TR/xmlschema-1/#cos-nonambig
- to use name space="##any" below. -->
- <any namespace="##other" processContents="lax" minOccurs="0"
- maxOccurs="unbounded" />
- </sequence>
- <attribute name="servicefactory" type="boolean" default="false"
- use="optional" />
- <anyAttribute />
- </complexType>
- <complexType name="Tprovide">
- <sequence>
- <any namespace="##any" processContents="lax" minOccurs="0"
- maxOccurs="unbounded" />
- </sequence>
- <attribute name="interface" type="token" use="required" />
- <anyAttribute />
- </complexType>
- <complexType name="Treference">
- <sequence>
- <any namespace="##any" processContents="lax" minOccurs="0"
- maxOccurs="unbounded" />
- </sequence>
- <attribute name="name" type="token" use="optional">
- <annotation>
- <documentation xml:lang="en">
- The default value of this attribute is the value of
- the interface attribute of this element. If multiple
- instances of this element within a component element
- use the same value for the interface attribute, then
- using the default value for this attribute will result
- in duplicate names. In this case, this attribute
- must be specified with a unique value.
- </documentation>
- </annotation>
- </attribute>
- <attribute name="interface" type="token" use="required" />
- <attribute name="cardinality" type="scr:Tcardinality"
- default="1..1" use="optional" />
- <attribute name="policy" type="scr:Tpolicy" default="static"
- use="optional" />
- <attribute name="target" type="string" use="optional" />
- <attribute name="bind" type="token" use="optional" />
- <attribute name="unbind" type="token" use="optional" />
- <anyAttribute />
- </complexType>
- <simpleType name="Tjava-types">
- <restriction base="string">
- <enumeration value="String" />
- <enumeration value="Long" />
- <enumeration value="Double" />
- <enumeration value="Float" />
- <enumeration value="Integer" />
- <enumeration value="Byte" />
- <enumeration value="Character" />
- <enumeration value="Boolean" />
- <enumeration value="Short" />
- </restriction>
- </simpleType>
- <simpleType name="Tcardinality">
- <restriction base="string">
- <enumeration value="0..1" />
- <enumeration value="0..n" />
- <enumeration value="1..1" />
- <enumeration value="1..n" />
- </restriction>
- </simpleType>
- <simpleType name="Tpolicy">
- <restriction base="string">
- <enumeration value="static" />
- <enumeration value="dynamic" />
- </restriction>
- </simpleType>
- <simpleType name="Tconfiguration-policy">
- <restriction base="string">
- <enumeration value="optional" />
- <enumeration value="require" />
- <enumeration value="ignore" />
- </restriction>
- </simpleType>
- <attribute name="must-understand" type="boolean">
- <annotation>
- <documentation xml:lang="en">
- This attribute should be used by extensions to documents
- to require that the document consumer understand the
- extension. This attribute must be qualified when used.
- </documentation>
- </annotation>
- </attribute>
-</schema>
diff --git a/org.osgi.core/LICENSE b/org.osgi.core/LICENSE
deleted file mode 100644
index d645695..0000000
--- a/org.osgi.core/LICENSE
+++ /dev/null
@@ -1,202 +0,0 @@
-
- Apache License
- Version 2.0, January 2004
- http://www.apache.org/licenses/
-
- TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
-
- 1. Definitions.
-
- "License" shall mean the terms and conditions for use, reproduction,
- and distribution as defined by Sections 1 through 9 of this document.
-
- "Licensor" shall mean the copyright owner or entity authorized by
- the copyright owner that is granting the License.
-
- "Legal Entity" shall mean the union of the acting entity and all
- other entities that control, are controlled by, or are under common
- control with that entity. For the purposes of this definition,
- "control" means (i) the power, direct or indirect, to cause the
- direction or management of such entity, whether by contract or
- otherwise, or (ii) ownership of fifty percent (50%) or more of the
- outstanding shares, or (iii) beneficial ownership of such entity.
-
- "You" (or "Your") shall mean an individual or Legal Entity
- exercising permissions granted by this License.
-
- "Source" form shall mean the preferred form for making modifications,
- including but not limited to software source code, documentation
- source, and configuration files.
-
- "Object" form shall mean any form resulting from mechanical
- transformation or translation of a Source form, including but
- not limited to compiled object code, generated documentation,
- and conversions to other media types.
-
- "Work" shall mean the work of authorship, whether in Source or
- Object form, made available under the License, as indicated by a
- copyright notice that is included in or attached to the work
- (an example is provided in the Appendix below).
-
- "Derivative Works" shall mean any work, whether in Source or Object
- form, that is based on (or derived from) the Work and for which the
- editorial revisions, annotations, elaborations, or other modifications
- represent, as a whole, an original work of authorship. For the purposes
- of this License, Derivative Works shall not include works that remain
- separable from, or merely link (or bind by name) to the interfaces of,
- the Work and Derivative Works thereof.
-
- "Contribution" shall mean any work of authorship, including
- the original version of the Work and any modifications or additions
- to that Work or Derivative Works thereof, that is intentionally
- submitted to Licensor for inclusion in the Work by the copyright owner
- or by an individual or Legal Entity authorized to submit on behalf of
- the copyright owner. For the purposes of this definition, "submitted"
- means any form of electronic, verbal, or written communication sent
- to the Licensor or its representatives, including but not limited to
- communication on electronic mailing lists, source code control systems,
- and issue tracking systems that are managed by, or on behalf of, the
- Licensor for the purpose of discussing and improving the Work, but
- excluding communication that is conspicuously marked or otherwise
- designated in writing by the copyright owner as "Not a Contribution."
-
- "Contributor" shall mean Licensor and any individual or Legal Entity
- on behalf of whom a Contribution has been received by Licensor and
- subsequently incorporated within the Work.
-
- 2. Grant of Copyright License. Subject to the terms and conditions of
- this License, each Contributor hereby grants to You a perpetual,
- worldwide, non-exclusive, no-charge, royalty-free, irrevocable
- copyright license to reproduce, prepare Derivative Works of,
- publicly display, publicly perform, sublicense, and distribute the
- Work and such Derivative Works in Source or Object form.
-
- 3. Grant of Patent License. Subject to the terms and conditions of
- this License, each Contributor hereby grants to You a perpetual,
- worldwide, non-exclusive, no-charge, royalty-free, irrevocable
- (except as stated in this section) patent license to make, have made,
- use, offer to sell, sell, import, and otherwise transfer the Work,
- where such license applies only to those patent claims licensable
- by such Contributor that are necessarily infringed by their
- Contribution(s) alone or by combination of their Contribution(s)
- with the Work to which such Contribution(s) was submitted. If You
- institute patent litigation against any entity (including a
- cross-claim or counterclaim in a lawsuit) alleging that the Work
- or a Contribution incorporated within the Work constitutes direct
- or contributory patent infringement, then any patent licenses
- granted to You under this License for that Work shall terminate
- as of the date such litigation is filed.
-
- 4. Redistribution. You may reproduce and distribute copies of the
- Work or Derivative Works thereof in any medium, with or without
- modifications, and in Source or Object form, provided that You
- meet the following conditions:
-
- (a) You must give any other recipients of the Work or
- Derivative Works a copy of this License; and
-
- (b) You must cause any modified files to carry prominent notices
- stating that You changed the files; and
-
- (c) You must retain, in the Source form of any Derivative Works
- that You distribute, all copyright, patent, trademark, and
- attribution notices from the Source form of the Work,
- excluding those notices that do not pertain to any part of
- the Derivative Works; and
-
- (d) If the Work includes a "NOTICE" text file as part of its
- distribution, then any Derivative Works that You distribute must
- include a readable copy of the attribution notices contained
- within such NOTICE file, excluding those notices that do not
- pertain to any part of the Derivative Works, in at least one
- of the following places: within a NOTICE text file distributed
- as part of the Derivative Works; within the Source form or
- documentation, if provided along with the Derivative Works; or,
- within a display generated by the Derivative Works, if and
- wherever such third-party notices normally appear. The contents
- of the NOTICE file are for informational purposes only and
- do not modify the License. You may add Your own attribution
- notices within Derivative Works that You distribute, alongside
- or as an addendum to the NOTICE text from the Work, provided
- that such additional attribution notices cannot be construed
- as modifying the License.
-
- You may add Your own copyright statement to Your modifications and
- may provide additional or different license terms and conditions
- for use, reproduction, or distribution of Your modifications, or
- for any such Derivative Works as a whole, provided Your use,
- reproduction, and distribution of the Work otherwise complies with
- the conditions stated in this License.
-
- 5. Submission of Contributions. Unless You explicitly state otherwise,
- any Contribution intentionally submitted for inclusion in the Work
- by You to the Licensor shall be under the terms and conditions of
- this License, without any additional terms or conditions.
- Notwithstanding the above, nothing herein shall supersede or modify
- the terms of any separate license agreement you may have executed
- with Licensor regarding such Contributions.
-
- 6. Trademarks. This License does not grant permission to use the trade
- names, trademarks, service marks, or product names of the Licensor,
- except as required for reasonable and customary use in describing the
- origin of the Work and reproducing the content of the NOTICE file.
-
- 7. Disclaimer of Warranty. Unless required by applicable law or
- agreed to in writing, Licensor provides the Work (and each
- Contributor provides its Contributions) on an "AS IS" BASIS,
- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
- implied, including, without limitation, any warranties or conditions
- of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
- PARTICULAR PURPOSE. You are solely responsible for determining the
- appropriateness of using or redistributing the Work and assume any
- risks associated with Your exercise of permissions under this License.
-
- 8. Limitation of Liability. In no event and under no legal theory,
- whether in tort (including negligence), contract, or otherwise,
- unless required by applicable law (such as deliberate and grossly
- negligent acts) or agreed to in writing, shall any Contributor be
- liable to You for damages, including any direct, indirect, special,
- incidental, or consequential damages of any character arising as a
- result of this License or out of the use or inability to use the
- Work (including but not limited to damages for loss of goodwill,
- work stoppage, computer failure or malfunction, or any and all
- other commercial damages or losses), even if such Contributor
- has been advised of the possibility of such damages.
-
- 9. Accepting Warranty or Additional Liability. While redistributing
- the Work or Derivative Works thereof, You may choose to offer,
- and charge a fee for, acceptance of support, warranty, indemnity,
- or other liability obligations and/or rights consistent with this
- License. However, in accepting such obligations, You may act only
- on Your own behalf and on Your sole responsibility, not on behalf
- of any other Contributor, and only if You agree to indemnify,
- defend, and hold each Contributor harmless for any liability
- incurred by, or claims asserted against, such Contributor by reason
- of your accepting any such warranty or additional liability.
-
- END OF TERMS AND CONDITIONS
-
- APPENDIX: How to apply the Apache License to your work.
-
- To apply the Apache License to your work, attach the following
- boilerplate notice, with the fields enclosed by brackets "[]"
- replaced with your own identifying information. (Don't include
- the brackets!) The text should be enclosed in the appropriate
- comment syntax for the file format. We also recommend that a
- file or class name and description of purpose be included on the
- same "printed page" as the copyright notice for easier
- identification within third-party archives.
-
- Copyright [yyyy] [name of copyright owner]
-
- Licensed under the Apache License, Version 2.0 (the "License");
- you may not use this file except in compliance with the License.
- You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
- Unless required by applicable law or agreed to in writing, software
- distributed under the License is distributed on an "AS IS" BASIS,
- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- See the License for the specific language governing permissions and
- limitations under the License.
diff --git a/org.osgi.core/NOTICE b/org.osgi.core/NOTICE
deleted file mode 100644
index d8df7fe..0000000
--- a/org.osgi.core/NOTICE
+++ /dev/null
@@ -1,5 +0,0 @@
-OSGi Core Classes
-Copyright (c) OSGi Alliance (2000, 2009).
-
-This product includes software developed at
-the OSGi Alliance (http://www.osgi.org/).
diff --git a/org.osgi.core/doc/apache-felix-osgi-core.html b/org.osgi.core/doc/apache-felix-osgi-core.html
deleted file mode 100644
index fc17858..0000000
--- a/org.osgi.core/doc/apache-felix-osgi-core.html
+++ /dev/null
@@ -1,38 +0,0 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
-<html><head><title>Apache Felix - Apache Felix OSGi Core</title>
-
-
-
-
- <link rel="stylesheet" href="apache-felix-osgi-core_files/site.css" type="text/css" media="all">
- <meta http-equiv="Content-Type" content="text/html;charset=UTF-8"></head><body>
- <div class="title"><div class="logo"><a href="http://felix.apache.org/site/index.html"><img alt="Apache Felix" src="apache-felix-osgi-core_files/logo.png" border="0"></a></div><div class="header"><a href="http://www.apache.org/"><img alt="Apache" src="apache-felix-osgi-core_files/apache.png" border="0"></a></div></div>
- <div class="menu">
-<ul>
- <li><a href="http://felix.apache.org/site/news.html" title="news">news</a></li>
- <li><a href="http://felix.apache.org/site/license.html" title="license">license</a></li>
- <li><span class="nobr"><a href="http://felix.apache.org/site/downloads.cgi" title="Visit page outside Confluence" rel="nofollow">downloads<sup><img class="rendericon" src="apache-felix-osgi-core_files/linkext7.gif" alt="" align="absmiddle" border="0" height="7" width="7"></sup></a></span></li>
- <li><a href="http://felix.apache.org/site/documentation.html" title="documentation">documentation</a></li>
- <li><a href="http://felix.apache.org/site/mailinglists.html" title="mailinglists">mailing lists</a></li>
- <li><a href="http://felix.apache.org/site/contributing.html" title="Contributing">contributing</a></li>
- <li><span class="nobr"><a href="http://www.apache.org/" title="Visit page outside Confluence" rel="nofollow">asf<sup><img class="rendericon" src="apache-felix-osgi-core_files/linkext7.gif" alt="" align="absmiddle" border="0" height="7" width="7"></sup></a></span></li>
- <li><span class="nobr"><a href="http://www.apache.org/foundation/sponsorship.html" title="Visit page outside Confluence" rel="nofollow">sponsorship<sup><img class="rendericon" src="apache-felix-osgi-core_files/linkext7.gif" alt="" align="absmiddle" border="0" height="7" width="7"></sup></a></span></li>
- <li><span class="nobr"><a href="http://www.apache.org/foundation/thanks.html" title="Visit page outside Confluence" rel="nofollow">sponsors<sup><img class="rendericon" src="apache-felix-osgi-core_files/linkext7.gif" alt="" align="absmiddle" border="0" height="7" width="7"></sup></a></span>
-<!-- ApacheCon Ad -->
-<iframe src="apache-felix-osgi-core_files/button.html" style="border-width: 0pt; float: left;" frameborder="0" height="135" scrolling="no" width="135"></iframe>
-<p style="height: 100px;">
-<!-- ApacheCon Ad -->
-</p></li></ul> </div>
- <div class="main">
-<h1><a name="ApacheFelixOSGiCore-ApacheFelixOSGiCore"></a>Apache Felix OSGi Core</h1>
-
-<p>The Apache Felix OSGi Core sub-project simply repackages the
-standard OSGi core API packages provided by the OSGi Alliance into a
-Maven module. Nearly all OSGi-related projects will have a dependency
-on this module if using Maven or will require this module's JAR file in
-its class path in order to compile against the OSGi core APIs. The
-Felix framework has a compile-time dependency on the OSGi core module,
-but at packaging time it embeds the specific set of required packages
-so there is no longer a dependency on the module at execution time.</p>
- </div>
- </body></html>
diff --git a/org.osgi.core/doc/apache-felix-osgi-core_files/apache-felix-small.png b/org.osgi.core/doc/apache-felix-osgi-core_files/apache-felix-small.png
deleted file mode 100644
index 95bfa5e..0000000
--- a/org.osgi.core/doc/apache-felix-osgi-core_files/apache-felix-small.png
+++ /dev/null
Binary files differ
diff --git a/org.osgi.core/doc/apache-felix-osgi-core_files/apache.png b/org.osgi.core/doc/apache-felix-osgi-core_files/apache.png
deleted file mode 100644
index 5132f65..0000000
--- a/org.osgi.core/doc/apache-felix-osgi-core_files/apache.png
+++ /dev/null
Binary files differ
diff --git a/org.osgi.core/doc/apache-felix-osgi-core_files/button.html b/org.osgi.core/doc/apache-felix-osgi-core_files/button.html
deleted file mode 100644
index d6a5da8..0000000
--- a/org.osgi.core/doc/apache-felix-osgi-core_files/button.html
+++ /dev/null
@@ -1,3 +0,0 @@
-<html><head><!-- ads start --></head><body><a href="http://www.us.apachecon.com/us2008/" target="_blank"><img src="button_data/2008-usa-125x125.png" title="ApacheCon US 2008" border="0" height="125" width="125"></a>
-<!-- ads end -->
-</body></html>
\ No newline at end of file
diff --git a/org.osgi.core/doc/apache-felix-osgi-core_files/button_data/2008-usa-125x125.png b/org.osgi.core/doc/apache-felix-osgi-core_files/button_data/2008-usa-125x125.png
deleted file mode 100644
index 3d6008b..0000000
--- a/org.osgi.core/doc/apache-felix-osgi-core_files/button_data/2008-usa-125x125.png
+++ /dev/null
Binary files differ
diff --git a/org.osgi.core/doc/apache-felix-osgi-core_files/linkext7.gif b/org.osgi.core/doc/apache-felix-osgi-core_files/linkext7.gif
deleted file mode 100644
index f2dd2dc..0000000
--- a/org.osgi.core/doc/apache-felix-osgi-core_files/linkext7.gif
+++ /dev/null
Binary files differ
diff --git a/org.osgi.core/doc/apache-felix-osgi-core_files/logo.png b/org.osgi.core/doc/apache-felix-osgi-core_files/logo.png
deleted file mode 100644
index dccbddc..0000000
--- a/org.osgi.core/doc/apache-felix-osgi-core_files/logo.png
+++ /dev/null
Binary files differ
diff --git a/org.osgi.core/doc/apache-felix-osgi-core_files/site.css b/org.osgi.core/doc/apache-felix-osgi-core_files/site.css
deleted file mode 100644
index 959ab0a..0000000
--- a/org.osgi.core/doc/apache-felix-osgi-core_files/site.css
+++ /dev/null
@@ -1,25 +0,0 @@
-/* @override http://felix.apache.org/site/media.data/site.css */
-
-body { background-color: #ffffff; color: #3b3b3b; font-family: Tahoma, Arial, sans-serif; font-size: 10pt; line-height: 140% }
-h1, h2, h3, h4, h5, h6 { font-weight: normal; color: #000000; line-height: 100%; margin-top: 0px}
-h1 { font-size: 200% }
-h2 { font-size: 175% }
-h3 { font-size: 150% }
-h4 { font-size: 140% }
-h5 { font-size: 130% }
-h6 { font-size: 120% }
-a { color: #1980af }
-a:visited { color: #1980af }
-a:hover { color: #1faae9 }
-.title { position: absolute; left: 1px; right: 1px; top:25px; height: 81px; background: url(http://felix.apache.org/site/media.data/gradient.png) repeat-x; background-position: bottom; }
-.logo { position: absolute; width: 15em; height: 81px; text-align: center; }
-.header { text-align: right; margin-right: 20pt; margin-top: 30pt;}
-.menu { border-top: 10px solid #f9bb00; position: absolute; top: 107px; left: 1px; width: 15em; bottom: 0px; padding: 0px; background-color: #fcfcfc }
-.menu ul { background-color: #fdf5d9; list-style: none; padding-left: 4em; margin-top: 0px; padding-top: 2em; padding-bottom: 2em; margin-left: 0px; color: #4a4a43}
-.menu a { text-decoration: none; color: #4a4a43 }
-.main { position: absolute; border-top: 10px solid #cde0ea; top: 107px; left: 15em; right: 1px; margin-left: 2px; padding-right: 4em; padding-left: 1em; padding-top: 1em;}
-.code { background-color: #eeeeee; border: solid 1px black; padding: 0.5em }
-.code-keyword { color: #880000 }
-.code-quote { color: #008800 }
-.code-object { color: #0000dd }
-.code-java { margin: 0em }
\ No newline at end of file
diff --git a/org.osgi.core/doc/changelog.txt b/org.osgi.core/doc/changelog.txt
deleted file mode 100644
index 28a9a17..0000000
--- a/org.osgi.core/doc/changelog.txt
+++ /dev/null
@@ -1,16 +0,0 @@
-Changes from 1.2.0 to 1.4.0
----------------------------
-
-* [2009-09-01] Update to latest R4.2 API
-
-Changes from 1.0.0 to 1.0.1
----------------------------
-
-* [2008-04-21] Re-release to make bytecode executable on jre 1.3.
-
-Changes from 0.8.0-incubator to 1.0.0
--------------------------------------
-
-* [2007-03-02] Added Bundle.getBundleContext() method, which is part
- of OSGi R4.1; this is an interim fix until we switch to the OSGi R4.1
- API definitions.
diff --git a/org.osgi.core/pom.xml b/org.osgi.core/pom.xml
deleted file mode 100644
index 6ccbf1d..0000000
--- a/org.osgi.core/pom.xml
+++ /dev/null
@@ -1,56 +0,0 @@
-<!--
- Licensed to the Apache Software Foundation (ASF) under one
- or more contributor license agreements. See the NOTICE file
- distributed with this work for additional information
- regarding copyright ownership. The ASF licenses this file
- to you under the Apache License, Version 2.0 (the
- "License"); you may not use this file except in compliance
- with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
- Unless required by applicable law or agreed to in writing,
- software distributed under the License is distributed on an
- "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- KIND, either express or implied. See the License for the
- specific language governing permissions and limitations
- under the License.
--->
-<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
- <parent>
- <groupId>org.apache.felix</groupId>
- <artifactId>felix-parent</artifactId>
- <version>1.2.0</version>
- <relativePath>../pom/pom.xml</relativePath>
- </parent>
- <organization>
- <name>OSGi Alliance</name>
- <url>http://www.osgi.org/</url>
- </organization>
- <modelVersion>4.0.0</modelVersion>
- <name>OSGi R4 Core Bundle</name>
- <description>OSGi Service Platform Release 4 Core Interfaces and Classes.</description>
- <artifactId>org.osgi.core</artifactId>
- <version>1.5.0-SNAPSHOT</version>
- <packaging>bundle</packaging>
- <build>
- <plugins>
- <plugin>
- <groupId>org.apache.felix</groupId>
- <artifactId>maven-bundle-plugin</artifactId>
- <version>1.4.0</version>
- <extensions>true</extensions>
- <configuration>
- <instructions>
- <Bundle-SymbolicName>org.osgi.core</Bundle-SymbolicName>
- <Export-Package>org.osgi.framework, org.osgi.framework.launch, org.osgi.framework.hooks.service, org.osgi.service.condpermadmin, org.osgi.service.packageadmin, org.osgi.service.permissionadmin, org.osgi.service.startlevel, org.osgi.service.url</Export-Package>
- <Import-Package>org.osgi.framework,org.osgi.service.packageadmin,org.osgi.service.startlevel,org.osgi.service.url,!org.osgi.*,*</Import-Package>
- <Bundle-Version>4.1</Bundle-Version>
- <Bundle-Copyright>Copyright (c) OSGi Alliance (2000, 2009). All Rights Reserved.</Bundle-Copyright>
- <Bundle-Category>osgi</Bundle-Category>
- </instructions>
- </configuration>
- </plugin>
- </plugins>
- </build>
-</project>
diff --git a/org.osgi.core/src/main/java/org/osgi/framework/AdminPermission.java b/org.osgi.core/src/main/java/org/osgi/framework/AdminPermission.java
deleted file mode 100644
index 1811791..0000000
--- a/org.osgi.core/src/main/java/org/osgi/framework/AdminPermission.java
+++ /dev/null
@@ -1,1032 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2000, 2009). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.osgi.framework;
-
-import java.io.IOException;
-import java.io.NotSerializableException;
-import java.io.ObjectInputStream;
-import java.io.ObjectOutputStream;
-import java.io.ObjectStreamField;
-import java.security.AccessController;
-import java.security.BasicPermission;
-import java.security.Permission;
-import java.security.PermissionCollection;
-import java.security.PrivilegedAction;
-import java.util.Collection;
-import java.util.Collections;
-import java.util.Dictionary;
-import java.util.Enumeration;
-import java.util.HashMap;
-import java.util.Hashtable;
-import java.util.Iterator;
-import java.util.Map;
-
-/**
- * A bundle's authority to perform specific privileged administrative operations
- * on or to get sensitive information about a bundle. The actions for this
- * permission are:
- *
- * <pre>
- * Action Methods
- * class Bundle.loadClass
- * execute Bundle.start
- * Bundle.stop
- * StartLevel.setBundleStartLevel
- * extensionLifecycle BundleContext.installBundle for extension bundles
- * Bundle.update for extension bundles
- * Bundle.uninstall for extension bundles
- * lifecycle BundleContext.installBundle
- * Bundle.update
- * Bundle.uninstall
- * listener BundleContext.addBundleListener for SynchronousBundleListener
- * BundleContext.removeBundleListener for SynchronousBundleListener
- * metadata Bundle.getHeaders
- * Bundle.getLocation
- * resolve PackageAdmin.refreshPackages
- * PackageAdmin.resolveBundles
- * resource Bundle.getResource
- * Bundle.getResources
- * Bundle.getEntry
- * Bundle.getEntryPaths
- * Bundle.findEntries
- * Bundle resource/entry URL creation
- * startlevel StartLevel.setStartLevel
- * StartLevel.setInitialBundleStartLevel
- * context Bundle.getBundleContext
- * </pre>
- *
- * <p>
- * The special action "*" will represent all actions. The
- * <code>resolve</code> action is implied by the <code>class</code>,
- * <code>execute</code> and <code>resource</code> actions.
- * <p>
- * The name of this permission is a filter expression. The filter gives access
- * to the following attributes:
- * <ul>
- * <li>signer - A Distinguished Name chain used to sign a bundle. Wildcards in a
- * DN are not matched according to the filter string rules, but according to the
- * rules defined for a DN chain.</li>
- * <li>location - The location of a bundle.</li>
- * <li>id - The bundle ID of the designated bundle.</li>
- * <li>name - The symbolic name of a bundle.</li>
- * </ul>
- * Filter attribute names are processed in a case sensitive manner.
- *
- * @ThreadSafe
- * @version $Revision: 7743 $
- */
-
-public final class AdminPermission extends BasicPermission {
- static final long serialVersionUID = 307051004521261705L;
-
- /**
- * The action string <code>class</code>. The <code>class</code> action
- * implies the <code>resolve</code> action.
- *
- * @since 1.3
- */
- public final static String CLASS = "class";
- /**
- * The action string <code>execute</code>. The <code>execute</code> action
- * implies the <code>resolve</code> action.
- *
- * @since 1.3
- */
- public final static String EXECUTE = "execute";
- /**
- * The action string <code>extensionLifecycle</code>.
- *
- * @since 1.3
- */
- public final static String EXTENSIONLIFECYCLE = "extensionLifecycle";
- /**
- * The action string <code>lifecycle</code>.
- *
- * @since 1.3
- */
- public final static String LIFECYCLE = "lifecycle";
- /**
- * The action string <code>listener</code>.
- *
- * @since 1.3
- */
- public final static String LISTENER = "listener";
- /**
- * The action string <code>metadata</code>.
- *
- * @since 1.3
- */
- public final static String METADATA = "metadata";
- /**
- * The action string <code>resolve</code>. The <code>resolve</code> action
- * is implied by the <code>class</code>, <code>execute</code> and
- * <code>resource</code> actions.
- *
- * @since 1.3
- */
- public final static String RESOLVE = "resolve";
- /**
- * The action string <code>resource</code>. The <code>resource</code> action
- * implies the <code>resolve</code> action.
- *
- * @since 1.3
- */
- public final static String RESOURCE = "resource";
- /**
- * The action string <code>startlevel</code>.
- *
- * @since 1.3
- */
- public final static String STARTLEVEL = "startlevel";
-
- /**
- * The action string <code>context</code>.
- *
- * @since 1.4
- */
- public final static String CONTEXT = "context";
-
- private final static int ACTION_CLASS = 0x00000001;
- private final static int ACTION_EXECUTE = 0x00000002;
- private final static int ACTION_LIFECYCLE = 0x00000004;
- private final static int ACTION_LISTENER = 0x00000008;
- private final static int ACTION_METADATA = 0x00000010;
- private final static int ACTION_RESOLVE = 0x00000040;
- private final static int ACTION_RESOURCE = 0x00000080;
- private final static int ACTION_STARTLEVEL = 0x00000100;
- private final static int ACTION_EXTENSIONLIFECYCLE = 0x00000200;
- private final static int ACTION_CONTEXT = 0x00000400;
- private final static int ACTION_ALL = ACTION_CLASS
- | ACTION_EXECUTE
- | ACTION_LIFECYCLE
- | ACTION_LISTENER
- | ACTION_METADATA
- | ACTION_RESOLVE
- | ACTION_RESOURCE
- | ACTION_STARTLEVEL
- | ACTION_EXTENSIONLIFECYCLE
- | ACTION_CONTEXT;
- final static int ACTION_NONE = 0;
-
- /**
- * The actions in canonical form.
- *
- * @serial
- */
- private volatile String actions = null;
-
- /**
- * The actions mask.
- */
- transient int action_mask;
-
- /**
- * If this AdminPermission was constructed with a filter, this holds a
- * Filter matching object used to evaluate the filter in implies.
- */
- transient Filter filter;
-
- /**
- * The bundle governed by this AdminPermission - only used if filter == null
- */
- transient final Bundle bundle;
-
- /**
- * This dictionary holds the properties of the permission, used to match a
- * filter in implies. This is not initialized until necessary, and then
- * cached in this object.
- */
- private transient volatile Dictionary properties;
-
- /**
- * ThreadLocal used to determine if we have recursively called
- * getProperties.
- */
- private static final ThreadLocal recurse = new ThreadLocal();
-
- /**
- * Creates a new <code>AdminPermission</code> object that matches all
- * bundles and has all actions. Equivalent to AdminPermission("*","*");
- */
- public AdminPermission() {
- this(null, ACTION_ALL);
- }
-
- /**
- * Create a new AdminPermission.
- *
- * This constructor must only be used to create a permission that is going
- * to be checked.
- * <p>
- * Examples:
- *
- * <pre>
- * (signer=\*,o=ACME,c=US)
- * (&(signer=\*,o=ACME,c=US)(name=com.acme.*)(location=http://www.acme.com/bundles/*))
- * (id>=1)
- * </pre>
- *
- * <p>
- * When a signer key is used within the filter expression the signer value
- * must escape the special filter chars ('*', '(', ')').
- * <p>
- * Null arguments are equivalent to "*".
- *
- * @param filter A filter expression that can use signer, location, id, and
- * name keys. A value of "*" or <code>null</code> matches
- * all bundle. Filter attribute names are processed in a case
- * sensitive manner.
- * @param actions <code>class</code>, <code>execute</code>,
- * <code>extensionLifecycle</code>, <code>lifecycle</code>,
- * <code>listener</code>, <code>metadata</code>, <code>resolve</code>
- * , <code>resource</code>, <code>startlevel</code> or
- * <code>context</code>. A value of "*" or <code>null</code>
- * indicates all actions.
- * @throws IllegalArgumentException If the filter has an invalid syntax.
- */
- public AdminPermission(String filter, String actions) {
- // arguments will be null if called from a PermissionInfo defined with
- // no args
- this(parseFilter(filter), parseActions(actions));
- }
-
- /**
- * Creates a new requested <code>AdminPermission</code> object to be used by
- * the code that must perform <code>checkPermission</code>.
- * <code>AdminPermission</code> objects created with this constructor cannot
- * be added to an <code>AdminPermission</code> permission collection.
- *
- * @param bundle A bundle.
- * @param actions <code>class</code>, <code>execute</code>,
- * <code>extensionLifecycle</code>, <code>lifecycle</code>,
- * <code>listener</code>, <code>metadata</code>, <code>resolve</code>
- * , <code>resource</code>, <code>startlevel</code>,
- * <code>context</code>. A value of "*" or <code>null</code>
- * indicates all actions.
- * @since 1.3
- */
- public AdminPermission(Bundle bundle, String actions) {
- super(createName(bundle));
- setTransients(null, parseActions(actions));
- this.bundle = bundle;
- }
-
- /**
- * Create a permission name from a Bundle
- *
- * @param bundle Bundle to use to create permission name.
- * @return permission name.
- */
- private static String createName(Bundle bundle) {
- if (bundle == null) {
- throw new IllegalArgumentException("bundle must not be null");
- }
- StringBuffer sb = new StringBuffer("(id=");
- sb.append(bundle.getBundleId());
- sb.append(")");
- return sb.toString();
- }
-
- /**
- * Package private constructor used by AdminPermissionCollection.
- *
- * @param filter name filter or <code>null</code> for wildcard.
- * @param mask action mask
- */
- AdminPermission(Filter filter, int mask) {
- super((filter == null) ? "*" : filter.toString());
- setTransients(filter, mask);
- this.bundle = null;
- }
-
- /**
- * Called by constructors and when deserialized.
- *
- * @param filter Permission's filter or <code>null</code> for wildcard.
- * @param mask action mask
- */
- private void setTransients(Filter filter, int mask) {
- this.filter = filter;
- if ((mask == ACTION_NONE) || ((mask & ACTION_ALL) != mask)) {
- throw new IllegalArgumentException("invalid action string");
- }
- this.action_mask = mask;
- }
-
- /**
- * Parse action string into action mask.
- *
- * @param actions Action string.
- * @return action mask.
- */
- private static int parseActions(String actions) {
- if ((actions == null) || actions.equals("*")) {
- return ACTION_ALL;
- }
-
- boolean seencomma = false;
-
- int mask = ACTION_NONE;
-
- if (actions == null) {
- return mask;
- }
-
- char[] a = actions.toCharArray();
-
- int i = a.length - 1;
- if (i < 0)
- return mask;
-
- while (i != -1) {
- char c;
-
- // skip whitespace
- while ((i != -1)
- && ((c = a[i]) == ' ' || c == '\r' || c == '\n'
- || c == '\f' || c == '\t'))
- i--;
-
- // check for the known strings
- int matchlen;
-
- if (i >= 4 && (a[i - 4] == 'c' || a[i - 4] == 'C')
- && (a[i - 3] == 'l' || a[i - 3] == 'L')
- && (a[i - 2] == 'a' || a[i - 2] == 'A')
- && (a[i - 1] == 's' || a[i - 1] == 'S')
- && (a[i] == 's' || a[i] == 'S')) {
- matchlen = 5;
- mask |= ACTION_CLASS | ACTION_RESOLVE;
-
- }
- else
- if (i >= 6 && (a[i - 6] == 'e' || a[i - 6] == 'E')
- && (a[i - 5] == 'x' || a[i - 5] == 'X')
- && (a[i - 4] == 'e' || a[i - 4] == 'E')
- && (a[i - 3] == 'c' || a[i - 3] == 'C')
- && (a[i - 2] == 'u' || a[i - 2] == 'U')
- && (a[i - 1] == 't' || a[i - 1] == 'T')
- && (a[i] == 'e' || a[i] == 'E')) {
- matchlen = 7;
- mask |= ACTION_EXECUTE | ACTION_RESOLVE;
-
- }
- else
- if (i >= 17 && (a[i - 17] == 'e' || a[i - 17] == 'E')
- && (a[i - 16] == 'x' || a[i - 16] == 'X')
- && (a[i - 15] == 't' || a[i - 15] == 'T')
- && (a[i - 14] == 'e' || a[i - 14] == 'E')
- && (a[i - 13] == 'n' || a[i - 13] == 'N')
- && (a[i - 12] == 's' || a[i - 12] == 'S')
- && (a[i - 11] == 'i' || a[i - 11] == 'I')
- && (a[i - 10] == 'o' || a[i - 10] == 'O')
- && (a[i - 9] == 'n' || a[i - 9] == 'N')
- && (a[i - 8] == 'l' || a[i - 8] == 'L')
- && (a[i - 7] == 'i' || a[i - 7] == 'I')
- && (a[i - 6] == 'f' || a[i - 6] == 'F')
- && (a[i - 5] == 'e' || a[i - 5] == 'E')
- && (a[i - 4] == 'c' || a[i - 4] == 'C')
- && (a[i - 3] == 'y' || a[i - 3] == 'Y')
- && (a[i - 2] == 'c' || a[i - 2] == 'C')
- && (a[i - 1] == 'l' || a[i - 1] == 'L')
- && (a[i] == 'e' || a[i] == 'E')) {
- matchlen = 18;
- mask |= ACTION_EXTENSIONLIFECYCLE;
-
- }
- else
- if (i >= 8 && (a[i - 8] == 'l' || a[i - 8] == 'L')
- && (a[i - 7] == 'i' || a[i - 7] == 'I')
- && (a[i - 6] == 'f' || a[i - 6] == 'F')
- && (a[i - 5] == 'e' || a[i - 5] == 'E')
- && (a[i - 4] == 'c' || a[i - 4] == 'C')
- && (a[i - 3] == 'y' || a[i - 3] == 'Y')
- && (a[i - 2] == 'c' || a[i - 2] == 'C')
- && (a[i - 1] == 'l' || a[i - 1] == 'L')
- && (a[i] == 'e' || a[i] == 'E')) {
- matchlen = 9;
- mask |= ACTION_LIFECYCLE;
-
- }
- else
- if (i >= 7 && (a[i - 7] == 'l' || a[i - 7] == 'L')
- && (a[i - 6] == 'i' || a[i - 6] == 'I')
- && (a[i - 5] == 's' || a[i - 5] == 'S')
- && (a[i - 4] == 't' || a[i - 4] == 'T')
- && (a[i - 3] == 'e' || a[i - 3] == 'E')
- && (a[i - 2] == 'n' || a[i - 2] == 'N')
- && (a[i - 1] == 'e' || a[i - 1] == 'E')
- && (a[i] == 'r' || a[i] == 'R')) {
- matchlen = 8;
- mask |= ACTION_LISTENER;
-
- }
- else
- if (i >= 7
- && (a[i - 7] == 'm' || a[i - 7] == 'M')
- && (a[i - 6] == 'e' || a[i - 6] == 'E')
- && (a[i - 5] == 't' || a[i - 5] == 'T')
- && (a[i - 4] == 'a' || a[i - 4] == 'A')
- && (a[i - 3] == 'd' || a[i - 3] == 'D')
- && (a[i - 2] == 'a' || a[i - 2] == 'A')
- && (a[i - 1] == 't' || a[i - 1] == 'T')
- && (a[i] == 'a' || a[i] == 'A')) {
- matchlen = 8;
- mask |= ACTION_METADATA;
-
- }
- else
- if (i >= 6
- && (a[i - 6] == 'r' || a[i - 6] == 'R')
- && (a[i - 5] == 'e' || a[i - 5] == 'E')
- && (a[i - 4] == 's' || a[i - 4] == 'S')
- && (a[i - 3] == 'o' || a[i - 3] == 'O')
- && (a[i - 2] == 'l' || a[i - 2] == 'L')
- && (a[i - 1] == 'v' || a[i - 1] == 'V')
- && (a[i] == 'e' || a[i] == 'E')) {
- matchlen = 7;
- mask |= ACTION_RESOLVE;
-
- }
- else
- if (i >= 7
- && (a[i - 7] == 'r' || a[i - 7] == 'R')
- && (a[i - 6] == 'e' || a[i - 6] == 'E')
- && (a[i - 5] == 's' || a[i - 5] == 'S')
- && (a[i - 4] == 'o' || a[i - 4] == 'O')
- && (a[i - 3] == 'u' || a[i - 3] == 'U')
- && (a[i - 2] == 'r' || a[i - 2] == 'R')
- && (a[i - 1] == 'c' || a[i - 1] == 'C')
- && (a[i] == 'e' || a[i] == 'E')) {
- matchlen = 8;
- mask |= ACTION_RESOURCE
- | ACTION_RESOLVE;
-
- }
- else
- if (i >= 9
- && (a[i - 9] == 's' || a[i - 9] == 'S')
- && (a[i - 8] == 't' || a[i - 8] == 'T')
- && (a[i - 7] == 'a' || a[i - 7] == 'A')
- && (a[i - 6] == 'r' || a[i - 6] == 'R')
- && (a[i - 5] == 't' || a[i - 5] == 'T')
- && (a[i - 4] == 'l' || a[i - 4] == 'L')
- && (a[i - 3] == 'e' || a[i - 3] == 'E')
- && (a[i - 2] == 'v' || a[i - 2] == 'V')
- && (a[i - 1] == 'e' || a[i - 1] == 'E')
- && (a[i] == 'l' || a[i] == 'L')) {
- matchlen = 10;
- mask |= ACTION_STARTLEVEL;
-
- }
- else
- if (i >= 6
- && (a[i - 6] == 'c' || a[i - 6] == 'C')
- && (a[i - 5] == 'o' || a[i - 5] == 'O')
- && (a[i - 4] == 'n' || a[i - 4] == 'N')
- && (a[i - 3] == 't' || a[i - 3] == 'T')
- && (a[i - 2] == 'e' || a[i - 2] == 'E')
- && (a[i - 1] == 'x' || a[i - 1] == 'X')
- && (a[i] == 't' || a[i] == 'T')) {
- matchlen = 7;
- mask |= ACTION_CONTEXT;
-
- }
- else
- if (i >= 0 &&
-
- (a[i] == '*')) {
- matchlen = 1;
- mask |= ACTION_ALL;
-
- }
- else {
- // parse error
- throw new IllegalArgumentException(
- "invalid permission: "
- + actions);
- }
-
- // make sure we didn't just match the tail of a word
- // like "ackbarfstartlevel". Also, skip to the comma.
- seencomma = false;
- while (i >= matchlen && !seencomma) {
- switch (a[i - matchlen]) {
- case ',' :
- seencomma = true;
- /* FALLTHROUGH */
- case ' ' :
- case '\r' :
- case '\n' :
- case '\f' :
- case '\t' :
- break;
- default :
- throw new IllegalArgumentException(
- "invalid permission: " + actions);
- }
- i--;
- }
-
- // point i at the location of the comma minus one (or -1).
- i -= matchlen;
- }
-
- if (seencomma) {
- throw new IllegalArgumentException("invalid permission: " +
- actions);
- }
-
- return mask;
- }
-
- /**
- * Parse filter string into a Filter object.
- *
- * @param filterString The filter string to parse.
- * @return a Filter for this bundle. If the specified filterString is
- * <code>null</code> or equals "*", then <code>null</code> is
- * returned to indicate a wildcard.
- * @throws IllegalArgumentException If the filter syntax is invalid.
- */
- private static Filter parseFilter(String filterString) {
- if (filterString == null) {
- return null;
- }
- filterString = filterString.trim();
- if (filterString.equals("*")) {
- return null;
- }
-
- try {
- return FrameworkUtil.createFilter(filterString);
- }
- catch (InvalidSyntaxException e) {
- IllegalArgumentException iae = new IllegalArgumentException(
- "invalid filter");
- iae.initCause(e);
- throw iae;
- }
- }
-
- /**
- * Determines if the specified permission is implied by this object. This
- * method throws an exception if the specified permission was not
- * constructed with a bundle.
- *
- * <p>
- * This method returns <code>true</code> if the specified permission is an
- * AdminPermission AND
- * <ul>
- * <li>this object's filter matches the specified permission's bundle ID,
- * bundle symbolic name, bundle location and bundle signer distinguished
- * name chain OR</li>
- * <li>this object's filter is "*"</li>
- * </ul>
- * AND this object's actions include all of the specified permission's
- * actions.
- * <p>
- * Special case: if the specified permission was constructed with "*"
- * filter, then this method returns <code>true</code> if this object's
- * filter is "*" and this object's actions include all of the specified
- * permission's actions
- *
- * @param p The requested permission.
- * @return <code>true</code> if the specified permission is implied by this
- * object; <code>false</code> otherwise.
- */
- public boolean implies(Permission p) {
- if (!(p instanceof AdminPermission)) {
- return false;
- }
- AdminPermission requested = (AdminPermission) p;
- if (bundle != null) {
- return false;
- }
- // if requested permission has a filter, then it is an invalid argument
- if (requested.filter != null) {
- return false;
- }
- return implies0(requested, ACTION_NONE);
- }
-
- /**
- * Internal implies method. Used by the implies and the permission
- * collection implies methods.
- *
- * @param requested The requested AdminPermision which has already be
- * validated as a proper argument. The requested AdminPermission must
- * not have a filter expression.
- * @param effective The effective actions with which to start.
- * @return <code>true</code> if the specified permission is implied by this
- * object; <code>false</code> otherwise.
- */
- boolean implies0(AdminPermission requested, int effective) {
- /* check actions first - much faster */
- effective |= action_mask;
- final int desired = requested.action_mask;
- if ((effective & desired) != desired) {
- return false;
- }
-
- /* Get our filter */
- Filter f = filter;
- if (f == null) {
- // it's "*"
- return true;
- }
- /* is requested a wildcard filter? */
- if (requested.bundle == null) {
- return false;
- }
- Dictionary requestedProperties = requested.getProperties();
- if (requestedProperties == null) {
- /*
- * If the requested properties are null, then we have detected a
- * recursion getting the bundle location. So we return true to
- * permit the bundle location request in the AdminPermission check
- * up the stack to succeed.
- */
- return true;
- }
- return f.matchCase(requestedProperties);
- }
-
- /**
- * Returns the canonical string representation of the
- * <code>AdminPermission</code> actions.
- *
- * <p>
- * Always returns present <code>AdminPermission</code> actions in the
- * following order: <code>class</code>, <code>execute</code>,
- * <code>extensionLifecycle</code>, <code>lifecycle</code>,
- * <code>listener</code>, <code>metadata</code>, <code>resolve</code>,
- * <code>resource</code>, <code>startlevel</code>, <code>context</code>.
- *
- * @return Canonical string representation of the
- * <code>AdminPermission</code> actions.
- */
- public String getActions() {
- String result = actions;
- if (result == null) {
- StringBuffer sb = new StringBuffer();
-
- int mask = action_mask;
- if ((mask & ACTION_CLASS) == ACTION_CLASS) {
- sb.append(CLASS);
- sb.append(',');
- }
-
- if ((mask & ACTION_EXECUTE) == ACTION_EXECUTE) {
- sb.append(EXECUTE);
- sb.append(',');
- }
-
- if ((mask & ACTION_EXTENSIONLIFECYCLE) == ACTION_EXTENSIONLIFECYCLE) {
- sb.append(EXTENSIONLIFECYCLE);
- sb.append(',');
- }
-
- if ((mask & ACTION_LIFECYCLE) == ACTION_LIFECYCLE) {
- sb.append(LIFECYCLE);
- sb.append(',');
- }
-
- if ((mask & ACTION_LISTENER) == ACTION_LISTENER) {
- sb.append(LISTENER);
- sb.append(',');
- }
-
- if ((mask & ACTION_METADATA) == ACTION_METADATA) {
- sb.append(METADATA);
- sb.append(',');
- }
-
- if ((mask & ACTION_RESOLVE) == ACTION_RESOLVE) {
- sb.append(RESOLVE);
- sb.append(',');
- }
-
- if ((mask & ACTION_RESOURCE) == ACTION_RESOURCE) {
- sb.append(RESOURCE);
- sb.append(',');
- }
-
- if ((mask & ACTION_STARTLEVEL) == ACTION_STARTLEVEL) {
- sb.append(STARTLEVEL);
- sb.append(',');
- }
-
- if ((mask & ACTION_CONTEXT) == ACTION_CONTEXT) {
- sb.append(CONTEXT);
- sb.append(',');
- }
-
- // remove trailing comma
- if (sb.length() > 0) {
- sb.setLength(sb.length() - 1);
- }
-
- actions = result = sb.toString();
- }
- return result;
- }
-
- /**
- * Returns a new <code>PermissionCollection</code> object suitable for
- * storing <code>AdminPermission</code>s.
- *
- * @return A new <code>PermissionCollection</code> object.
- */
- public PermissionCollection newPermissionCollection() {
- return new AdminPermissionCollection();
- }
-
- /**
- * Determines the equality of two <code>AdminPermission</code> objects.
- *
- * @param obj The object being compared for equality with this object.
- * @return <code>true</code> if <code>obj</code> is equivalent to this
- * <code>AdminPermission</code>; <code>false</code> otherwise.
- */
- public boolean equals(Object obj) {
- if (obj == this) {
- return true;
- }
-
- if (!(obj instanceof AdminPermission)) {
- return false;
- }
-
- AdminPermission ap = (AdminPermission) obj;
-
- return (action_mask == ap.action_mask)
- && ((bundle == ap.bundle) || ((bundle != null) && bundle
- .equals(ap.bundle)))
- && (filter == null ? ap.filter == null : filter
- .equals(ap.filter));
- }
-
- /**
- * Returns the hash code value for this object.
- *
- * @return Hash code value for this object.
- */
- public int hashCode() {
- int h = 31 * 17 + getName().hashCode();
- h = 31 * h + getActions().hashCode();
- if (bundle != null) {
- h = 31 * h + bundle.hashCode();
- }
- return h;
- }
-
- /**
- * WriteObject is called to save the state of this permission object to a
- * stream. The actions are serialized, and the superclass takes care of the
- * name.
- */
- private synchronized void writeObject(java.io.ObjectOutputStream s)
- throws IOException {
- if (bundle != null) {
- throw new NotSerializableException("cannot serialize");
- }
- // Write out the actions. The superclass takes care of the name
- // call getActions to make sure actions field is initialized
- if (actions == null)
- getActions();
- s.defaultWriteObject();
- }
-
- /**
- * readObject is called to restore the state of this permission from a
- * stream.
- */
- private synchronized void readObject(java.io.ObjectInputStream s)
- throws IOException, ClassNotFoundException {
- // Read in the data, then initialize the transients
- s.defaultReadObject();
- setTransients(parseFilter(getName()), parseActions(actions));
- }
-
- /**
- * Called by <code>implies0</code> on an AdminPermission which was
- * constructed with a Bundle. This method loads a dictionary with the
- * filter-matchable properties of this bundle. The dictionary is cached so
- * this lookup only happens once.
- *
- * This method should only be called on an AdminPermission which was
- * constructed with a bundle
- *
- * @return a dictionary of properties for this bundle
- */
- private Dictionary getProperties() {
- Dictionary result = properties;
- if (result != null) {
- return result;
- }
- /*
- * We may have recursed here due to the Bundle.getLocation call in the
- * doPrivileged below. If this is the case, return null to allow implies
- * to return true.
- */
- final Object mark = recurse.get();
- if (mark == bundle) {
- return null;
- }
- recurse.set(bundle);
- try {
- final Dictionary dict = new Hashtable(4);
- AccessController.doPrivileged(new PrivilegedAction() {
- public Object run() {
- dict.put("id", new Long(bundle.getBundleId()));
- dict.put("location", bundle.getLocation());
- String name = bundle.getSymbolicName();
- if (name != null) {
- dict.put("name", name);
- }
- SignerProperty signer = new SignerProperty(bundle);
- if (signer.isBundleSigned()) {
- dict.put("signer", signer);
- }
- return null;
- }
- });
- return properties = dict;
- }
- finally {
- recurse.set(null);
- }
- }
-}
-
-/**
- * Stores a collection of <code>AdminPermission</code>s.
- */
-final class AdminPermissionCollection extends PermissionCollection {
- private static final long serialVersionUID = 3906372644575328048L;
- /**
- * Collection of permissions.
- *
- * @GuardedBy this
- */
- private transient Map permissions;
-
- /**
- * Boolean saying if "*" is in the collection.
- *
- * @serial
- * @GuardedBy this
- */
- private boolean all_allowed;
-
- /**
- * Create an empty AdminPermissions object.
- *
- */
- public AdminPermissionCollection() {
- permissions = new HashMap();
- }
-
- /**
- * Adds a permission to this permission collection.
- *
- * @param permission The <code>AdminPermission</code> object to add.
- * @throws IllegalArgumentException If the specified permission is not an
- * <code>AdminPermission</code> instance or was constructed with a
- * Bundle object.
- * @throws SecurityException If this <code>AdminPermissionCollection</code>
- * object has been marked read-only.
- */
- public void add(Permission permission) {
- if (!(permission instanceof AdminPermission)) {
- throw new IllegalArgumentException("invalid permission: "
- + permission);
- }
- if (isReadOnly()) {
- throw new SecurityException("attempt to add a Permission to a "
- + "readonly PermissionCollection");
- }
- final AdminPermission ap = (AdminPermission) permission;
- if (ap.bundle != null) {
- throw new IllegalArgumentException("cannot add to collection: "
- + ap);
- }
- final String name = ap.getName();
- synchronized (this) {
- Map pc = permissions;
- AdminPermission existing = (AdminPermission) pc.get(name);
- if (existing != null) {
- int oldMask = existing.action_mask;
- int newMask = ap.action_mask;
-
- if (oldMask != newMask) {
- pc.put(name, new AdminPermission(existing.filter, oldMask
- | newMask));
- }
- }
- else {
- pc.put(name, ap);
- }
- if (!all_allowed) {
- if (name.equals("*")) {
- all_allowed = true;
- }
- }
- }
- }
-
- /**
- * Determines if the specified permissions implies the permissions expressed
- * in <code>permission</code>.
- *
- * @param permission The Permission object to compare with the
- * <code>AdminPermission</code> objects in this collection.
- * @return <code>true</code> if <code>permission</code> is implied by an
- * <code>AdminPermission</code> in this collection,
- * <code>false</code> otherwise.
- */
- public boolean implies(Permission permission) {
- if (!(permission instanceof AdminPermission)) {
- return false;
- }
-
- AdminPermission requested = (AdminPermission) permission;
- // if requested permission has a filter, then it is an invalid argument
- if (requested.filter != null) {
- return false;
- }
- int effective = AdminPermission.ACTION_NONE;
- Collection perms;
- synchronized (this) {
- Map pc = permissions;
- // short circuit if the "*" Permission was added
- if (all_allowed) {
- AdminPermission ap = (AdminPermission) pc.get("*");
- if (ap != null) {
- effective |= ap.action_mask;
- final int desired = requested.action_mask;
- if ((effective & desired) == desired) {
- return true;
- }
- }
- }
- perms = pc.values();
- }
-
- // just iterate one by one
- for (Iterator iter = perms.iterator(); iter.hasNext();) {
- if (((AdminPermission) iter.next()).implies0(requested, effective)) {
- return true;
- }
- }
- return false;
- }
-
- /**
- * Returns an enumeration of all <code>AdminPermission</code> objects in the
- * container.
- *
- * @return Enumeration of all <code>AdminPermission</code> objects.
- */
- public synchronized Enumeration elements() {
- return Collections.enumeration(permissions.values());
- }
-
- /* serialization logic */
- private static final ObjectStreamField[] serialPersistentFields = {
- new ObjectStreamField("permissions", Hashtable.class),
- new ObjectStreamField("all_allowed", Boolean.TYPE) };
-
- private synchronized void writeObject(ObjectOutputStream out)
- throws IOException {
- Hashtable hashtable = new Hashtable(permissions);
- ObjectOutputStream.PutField pfields = out.putFields();
- pfields.put("permissions", hashtable);
- pfields.put("all_allowed", all_allowed);
- out.writeFields();
- }
-
- private synchronized void readObject(java.io.ObjectInputStream in)
- throws IOException,
- ClassNotFoundException {
- ObjectInputStream.GetField gfields = in.readFields();
- Hashtable hashtable = (Hashtable) gfields.get("permissions", null);
- permissions = new HashMap(hashtable);
- all_allowed = gfields.get("all_allowed", false);
- }
-}
diff --git a/org.osgi.core/src/main/java/org/osgi/framework/AllServiceListener.java b/org.osgi.core/src/main/java/org/osgi/framework/AllServiceListener.java
deleted file mode 100644
index 688f51e..0000000
--- a/org.osgi.core/src/main/java/org/osgi/framework/AllServiceListener.java
+++ /dev/null
@@ -1,63 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2005, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.osgi.framework;
-
-/**
- * A <code>ServiceEvent</code> listener that does not filter based upon
- * package wiring. <code>AllServiceListener</code> is a listener interface
- * that may be implemented by a bundle developer. When a
- * <code>ServiceEvent</code> is fired, it is synchronously delivered to an
- * <code>AllServiceListener</code>. The Framework may deliver
- * <code>ServiceEvent</code> objects to an <code>AllServiceListener</code>
- * out of order and may concurrently call and/or reenter an
- * <code>AllServiceListener</code>.
- * <p>
- * An <code>AllServiceListener</code> object is registered with the Framework
- * using the <code>BundleContext.addServiceListener</code> method.
- * <code>AllServiceListener</code> objects are called with a
- * <code>ServiceEvent</code> object when a service is registered, modified, or
- * is in the process of unregistering.
- *
- * <p>
- * <code>ServiceEvent</code> object delivery to
- * <code>AllServiceListener</code> objects is filtered by the filter specified
- * when the listener was registered. If the Java Runtime Environment supports
- * permissions, then additional filtering is done. <code>ServiceEvent</code>
- * objects are only delivered to the listener if the bundle which defines the
- * listener object's class has the appropriate <code>ServicePermission</code>
- * to get the service using at least one of the named classes under which the
- * service was registered.
- *
- * <p>
- * Unlike normal <code>ServiceListener</code> objects,
- * <code>AllServiceListener</code> objects receive all
- * <code>ServiceEvent</code> objects regardless of whether the package source
- * of the listening bundle is equal to the package source of the bundle that
- * registered the service. This means that the listener may not be able to cast
- * the service object to any of its corresponding service interfaces if the
- * service object is retrieved.
- *
- * @see ServiceEvent
- * @see ServicePermission
- * @ThreadSafe
- * @since 1.3
- * @version $Revision: 5673 $
- */
-
-public interface AllServiceListener extends ServiceListener {
- // This is a marker interface
-}
diff --git a/org.osgi.core/src/main/java/org/osgi/framework/Bundle.java b/org.osgi.core/src/main/java/org/osgi/framework/Bundle.java
deleted file mode 100644
index 692bc5e..0000000
--- a/org.osgi.core/src/main/java/org/osgi/framework/Bundle.java
+++ /dev/null
@@ -1,1194 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2000, 2009). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.osgi.framework;
-
-import java.io.IOException;
-import java.io.InputStream;
-import java.net.URL;
-import java.util.Dictionary;
-import java.util.Enumeration;
-import java.util.Map;
-
-/**
- * An installed bundle in the Framework.
- *
- * <p>
- * A <code>Bundle</code> object is the access point to define the lifecycle of
- * an installed bundle. Each bundle installed in the OSGi environment must have
- * an associated <code>Bundle</code> object.
- *
- * <p>
- * A bundle must have a unique identity, a <code>long</code>, chosen by the
- * Framework. This identity must not change during the lifecycle of a bundle,
- * even when the bundle is updated. Uninstalling and then reinstalling the
- * bundle must create a new unique identity.
- *
- * <p>
- * A bundle can be in one of six states:
- * <ul>
- * <li>{@link #UNINSTALLED}
- * <li>{@link #INSTALLED}
- * <li>{@link #RESOLVED}
- * <li>{@link #STARTING}
- * <li>{@link #STOPPING}
- * <li>{@link #ACTIVE}
- * </ul>
- * <p>
- * Values assigned to these states have no specified ordering; they represent
- * bit values that may be ORed together to determine if a bundle is in one of
- * the valid states.
- *
- * <p>
- * A bundle should only execute code when its state is one of
- * <code>STARTING</code>,<code>ACTIVE</code>, or <code>STOPPING</code>.
- * An <code>UNINSTALLED</code> bundle can not be set to another state; it is a
- * zombie and can only be reached because references are kept somewhere.
- *
- * <p>
- * The Framework is the only entity that is allowed to create
- * <code>Bundle</code> objects, and these objects are only valid within the
- * Framework that created them.
- *
- * @ThreadSafe
- * @version $Revision: 6906 $
- */
-public interface Bundle {
- /**
- * The bundle is uninstalled and may not be used.
- *
- * <p>
- * The <code>UNINSTALLED</code> state is only visible after a bundle is
- * uninstalled; the bundle is in an unusable state but references to the
- * <code>Bundle</code> object may still be available and used for
- * introspection.
- * <p>
- * The value of <code>UNINSTALLED</code> is 0x00000001.
- */
- public static final int UNINSTALLED = 0x00000001;
-
- /**
- * The bundle is installed but not yet resolved.
- *
- * <p>
- * A bundle is in the <code>INSTALLED</code> state when it has been
- * installed in the Framework but is not or cannot be resolved.
- * <p>
- * This state is visible if the bundle's code dependencies are not resolved.
- * The Framework may attempt to resolve an <code>INSTALLED</code> bundle's
- * code dependencies and move the bundle to the <code>RESOLVED</code>
- * state.
- * <p>
- * The value of <code>INSTALLED</code> is 0x00000002.
- */
- public static final int INSTALLED = 0x00000002;
-
- /**
- * The bundle is resolved and is able to be started.
- *
- * <p>
- * A bundle is in the <code>RESOLVED</code> state when the Framework has
- * successfully resolved the bundle's code dependencies. These dependencies
- * include:
- * <ul>
- * <li>The bundle's class path from its {@link Constants#BUNDLE_CLASSPATH}
- * Manifest header.
- * <li>The bundle's package dependencies from its
- * {@link Constants#EXPORT_PACKAGE} and {@link Constants#IMPORT_PACKAGE}
- * Manifest headers.
- * <li>The bundle's required bundle dependencies from its
- * {@link Constants#REQUIRE_BUNDLE} Manifest header.
- * <li>A fragment bundle's host dependency from its
- * {@link Constants#FRAGMENT_HOST} Manifest header.
- * </ul>
- * <p>
- * Note that the bundle is not active yet. A bundle must be put in the
- * <code>RESOLVED</code> state before it can be started. The Framework may
- * attempt to resolve a bundle at any time.
- * <p>
- * The value of <code>RESOLVED</code> is 0x00000004.
- */
- public static final int RESOLVED = 0x00000004;
-
- /**
- * The bundle is in the process of starting.
- *
- * <p>
- * A bundle is in the <code>STARTING</code> state when its
- * {@link #start(int) start} method is active. A bundle must be in this
- * state when the bundle's {@link BundleActivator#start} is called. If the
- * <code>BundleActivator.start</code> method completes without exception,
- * then the bundle has successfully started and must move to the
- * <code>ACTIVE</code> state.
- * <p>
- * If the bundle has a
- * {@link Constants#ACTIVATION_LAZY lazy activation policy}, then the
- * bundle may remain in this state for some time until the activation is
- * triggered.
- * <p>
- * The value of <code>STARTING</code> is 0x00000008.
- */
- public static final int STARTING = 0x00000008;
-
- /**
- * The bundle is in the process of stopping.
- *
- * <p>
- * A bundle is in the <code>STOPPING</code> state when its
- * {@link #stop(int) stop} method is active. A bundle must be in this state
- * when the bundle's {@link BundleActivator#stop} method is called. When the
- * <code>BundleActivator.stop</code> method completes the bundle is
- * stopped and must move to the <code>RESOLVED</code> state.
- * <p>
- * The value of <code>STOPPING</code> is 0x00000010.
- */
- public static final int STOPPING = 0x00000010;
-
- /**
- * The bundle is now running.
- *
- * <p>
- * A bundle is in the <code>ACTIVE</code> state when it has been
- * successfully started and activated.
- * <p>
- * The value of <code>ACTIVE</code> is 0x00000020.
- */
- public static final int ACTIVE = 0x00000020;
-
- /**
- * The bundle start operation is transient and the persistent autostart
- * setting of the bundle is not modified.
- *
- * <p>
- * This bit may be set when calling {@link #start(int)} to notify the
- * framework that the autostart setting of the bundle must not be modified.
- * If this bit is not set, then the autostart setting of the bundle is
- * modified.
- *
- * @since 1.4
- * @see #start(int)
- */
- public static final int START_TRANSIENT = 0x00000001;
-
- /**
- * The bundle start operation must activate the bundle according to the
- * bundle's declared
- * {@link Constants#BUNDLE_ACTIVATIONPOLICY activation policy}.
- *
- * <p>
- * This bit may be set when calling {@link #start(int)} to notify the
- * framework that the bundle must be activated using the bundle's declared
- * activation policy.
- *
- * @since 1.4
- * @see Constants#BUNDLE_ACTIVATIONPOLICY
- * @see #start(int)
- */
- public static final int START_ACTIVATION_POLICY = 0x00000002;
-
- /**
- * The bundle stop is transient and the persistent autostart setting of the
- * bundle is not modified.
- *
- * <p>
- * This bit may be set when calling {@link #stop(int)} to notify the
- * framework that the autostart setting of the bundle must not be modified.
- * If this bit is not set, then the autostart setting of the bundle is
- * modified.
- *
- * @since 1.4
- * @see #stop(int)
- */
- public static final int STOP_TRANSIENT = 0x00000001;
-
- /**
- * Request that all certificates used to sign the bundle be returned.
- *
- * @since 1.5
- * @see #getSignerCertificates(int)
- */
- public final static int SIGNERS_ALL = 1;
-
- /**
- * Request that only certificates used to sign the bundle that are trusted
- * by the framework be returned.
- *
- * @since 1.5
- * @see #getSignerCertificates(int)
- */
- public final static int SIGNERS_TRUSTED = 2;
-
- /**
- * Returns this bundle's current state.
- *
- * <p>
- * A bundle can be in only one state at any time.
- *
- * @return An element of <code>UNINSTALLED</code>,<code>INSTALLED</code>,
- * <code>RESOLVED</code>,<code>STARTING</code>,
- * <code>STOPPING</code>,<code>ACTIVE</code>.
- */
- public int getState();
-
- /**
- * Starts this bundle.
- *
- * <p>
- * If this bundle's state is <code>UNINSTALLED</code> then an
- * <code>IllegalStateException</code> is thrown.
- * <p>
- * If the Framework implements the optional Start Level service and the
- * current start level is less than this bundle's start level:
- * <ul>
- * <li>If the {@link #START_TRANSIENT} option is set, then a
- * <code>BundleException</code> is thrown indicating this bundle cannot be
- * started due to the Framework's current start level.
- *
- * <li>Otherwise, the Framework must set this bundle's persistent autostart
- * setting to <em>Started with declared activation</em> if the
- * {@link #START_ACTIVATION_POLICY} option is set or
- * <em>Started with eager activation</em> if not set.
- * </ul>
- * <p>
- * When the Framework's current start level becomes equal to or more than
- * this bundle's start level, this bundle will be started.
- * <p>
- * Otherwise, the following steps are required to start this bundle:
- * <ol>
- * <li>If this bundle is in the process of being activated or deactivated
- * then this method must wait for activation or deactivation to complete
- * before continuing. If this does not occur in a reasonable time, a
- * <code>BundleException</code> is thrown to indicate this bundle was unable
- * to be started.
- *
- * <li>If this bundle's state is <code>ACTIVE</code> then this method
- * returns immediately.
- *
- * <li>If the {@link #START_TRANSIENT} option is not set then set this
- * bundle's autostart setting to <em>Started with declared activation</em>
- * if the {@link #START_ACTIVATION_POLICY} option is set or
- * <em>Started with eager activation</em> if not set. When the Framework is
- * restarted and this bundle's autostart setting is not <em>Stopped</em>,
- * this bundle must be automatically started.
- *
- * <li>If this bundle's state is not <code>RESOLVED</code>, an attempt is
- * made to resolve this bundle. If the Framework cannot resolve this bundle,
- * a <code>BundleException</code> is thrown.
- *
- * <li>If the {@link #START_ACTIVATION_POLICY} option is set and this
- * bundle's declared activation policy is {@link Constants#ACTIVATION_LAZY
- * lazy} then:
- * <ul>
- * <li>If this bundle's state is <code>STARTING</code> then this method
- * returns immediately.
- * <li>This bundle's state is set to <code>STARTING</code>.
- * <li>A bundle event of type {@link BundleEvent#LAZY_ACTIVATION} is fired.
- * <li>This method returns immediately and the remaining steps will be
- * followed when this bundle's activation is later triggered.
- * </ul>
- * <i></i>
- * <li>This bundle's state is set to <code>STARTING</code>.
- *
- * <li>A bundle event of type {@link BundleEvent#STARTING} is fired.
- *
- * <li>The {@link BundleActivator#start} method of this bundle's
- * <code>BundleActivator</code>, if one is specified, is called. If the
- * <code>BundleActivator</code> is invalid or throws an exception then:
- * <ul>
- * <li>This bundle's state is set to <code>STOPPING</code>.
- * <li>A bundle event of type {@link BundleEvent#STOPPING} is fired.
- * <li>Any services registered by this bundle must be unregistered.
- * <li>Any services used by this bundle must be released.
- * <li>Any listeners registered by this bundle must be removed.
- * <li>This bundle's state is set to <code>RESOLVED</code>.
- * <li>A bundle event of type {@link BundleEvent#STOPPED} is fired.
- * <li>A <code>BundleException</code> is then thrown.
- * </ul>
- * <i></i>
- * <li>If this bundle's state is <code>UNINSTALLED</code>, because this
- * bundle was uninstalled while the <code>BundleActivator.start</code>
- * method was running, a <code>BundleException</code> is thrown.
- *
- * <li>This bundle's state is set to <code>ACTIVE</code>.
- *
- * <li>A bundle event of type {@link BundleEvent#STARTED} is fired.
- * </ol>
- *
- * <b>Preconditions </b>
- * <ul>
- * <li><code>getState()</code> in { <code>INSTALLED</code>,
- * <code>RESOLVED</code> } or { <code>INSTALLED</code>,
- * <code>RESOLVED</code>, <code>STARTING</code> } if this bundle has
- * a lazy activation policy.
- * </ul>
- * <b>Postconditions, no exceptions thrown </b>
- * <ul>
- * <li>Bundle autostart setting is modified unless the
- * {@link #START_TRANSIENT} option was set.
- * <li><code>getState()</code> in { <code>ACTIVE</code> }
- * unless the lazy activation policy was used.
- * <li><code>BundleActivator.start()</code> has been called and did not
- * throw an exception unless the lazy activation policy was used.
- * </ul>
- * <b>Postconditions, when an exception is thrown </b>
- * <ul>
- * <li>Depending on when the exception occurred, bundle autostart setting is
- * modified unless the {@link #START_TRANSIENT} option was set.
- * <li><code>getState()</code> not in { <code>STARTING</code>,
- * <code>ACTIVE</code> }.
- * </ul>
- *
- * @param options The options for starting this bundle. See
- * {@link #START_TRANSIENT} and {@link #START_ACTIVATION_POLICY}. The
- * Framework must ignore unrecognized options.
- * @throws BundleException If this bundle could not be started. This could
- * be because a code dependency could not be resolved or the
- * specified <code>BundleActivator</code> could not be loaded or
- * threw an exception or this bundle is a fragment.
- * @throws IllegalStateException If this bundle has been uninstalled or this
- * bundle tries to change its own state.
- * @throws SecurityException If the caller does not have the appropriate
- * <code>AdminPermission[this,EXECUTE]</code>, and the Java Runtime
- * Environment supports permissions.
- * @since 1.4
- */
- public void start(int options) throws BundleException;
-
- /**
- * Starts this bundle with no options.
- *
- * <p>
- * This method performs the same function as calling <code>start(0)</code>.
- *
- * @throws BundleException If this bundle could not be started. This could
- * be because a code dependency could not be resolved or the
- * specified <code>BundleActivator</code> could not be loaded or
- * threw an exception or this bundle is a fragment.
- * @throws IllegalStateException If this bundle has been uninstalled or this
- * bundle tries to change its own state.
- * @throws SecurityException If the caller does not have the appropriate
- * <code>AdminPermission[this,EXECUTE]</code>, and the Java Runtime
- * Environment supports permissions.
- * @see #start(int)
- */
- public void start() throws BundleException;
-
- /**
- * Stops this bundle.
- *
- * <p>
- * The following steps are required to stop a bundle:
- * <ol>
- * <li>If this bundle's state is <code>UNINSTALLED</code> then an
- * <code>IllegalStateException</code> is thrown.
- *
- * <li>If this bundle is in the process of being activated or deactivated
- * then this method must wait for activation or deactivation to complete
- * before continuing. If this does not occur in a reasonable time, a
- * <code>BundleException</code> is thrown to indicate this bundle was unable
- * to be stopped.
- * <li>If the {@link #STOP_TRANSIENT} option is not set then then set this
- * bundle's persistent autostart setting to to <em>Stopped</em>. When the
- * Framework is restarted and this bundle's autostart setting is
- * <em>Stopped</em>, this bundle must not be automatically started.
- *
- * <li>If this bundle's state is not <code>STARTING</code> or
- * <code>ACTIVE</code> then this method returns immediately.
- *
- * <li>This bundle's state is set to <code>STOPPING</code>.
- *
- * <li>A bundle event of type {@link BundleEvent#STOPPING} is fired.
- *
- * <li>If this bundle's state was <code>ACTIVE</code> prior to setting the
- * state to <code>STOPPING</code>, the {@link BundleActivator#stop} method
- * of this bundle's <code>BundleActivator</code>, if one is specified, is
- * called. If that method throws an exception, this method must continue to
- * stop this bundle and a <code>BundleException</code> must be thrown after
- * completion of the remaining steps.
- *
- * <li>Any services registered by this bundle must be unregistered.
- * <li>Any services used by this bundle must be released.
- * <li>Any listeners registered by this bundle must be removed.
- *
- * <li>If this bundle's state is <code>UNINSTALLED</code>, because this
- * bundle was uninstalled while the <code>BundleActivator.stop</code> method
- * was running, a <code>BundleException</code> must be thrown.
- *
- * <li>This bundle's state is set to <code>RESOLVED</code>.
- *
- * <li>A bundle event of type {@link BundleEvent#STOPPED} is fired.
- * </ol>
- *
- * <b>Preconditions </b>
- * <ul>
- * <li><code>getState()</code> in { <code>ACTIVE</code> }.
- * </ul>
- * <b>Postconditions, no exceptions thrown </b>
- * <ul>
- * <li>Bundle autostart setting is modified unless the
- * {@link #STOP_TRANSIENT} option was set.
- * <li><code>getState()</code> not in { <code>ACTIVE</code>,
- * <code>STOPPING</code> }.
- * <li><code>BundleActivator.stop</code> has been called and did not throw
- * an exception.
- * </ul>
- * <b>Postconditions, when an exception is thrown </b>
- * <ul>
- * <li>Bundle autostart setting is modified unless the
- * {@link #STOP_TRANSIENT} option was set.
- * </ul>
- *
- * @param options The options for stoping this bundle. See
- * {@link #STOP_TRANSIENT}. The Framework must ignore unrecognized
- * options.
- * @throws BundleException If this bundle's <code>BundleActivator</code>
- * threw an exception or this bundle is a fragment.
- * @throws IllegalStateException If this bundle has been uninstalled or this
- * bundle tries to change its own state.
- * @throws SecurityException If the caller does not have the appropriate
- * <code>AdminPermission[this,EXECUTE]</code>, and the Java Runtime
- * Environment supports permissions.
- * @since 1.4
- */
- public void stop(int options) throws BundleException;
-
- /**
- * Stops this bundle with no options.
- *
- * <p>
- * This method performs the same function as calling <code>stop(0)</code>.
- *
- * @throws BundleException If this bundle's <code>BundleActivator</code>
- * threw an exception or this bundle is a fragment.
- * @throws IllegalStateException If this bundle has been uninstalled or this
- * bundle tries to change its own state.
- * @throws SecurityException If the caller does not have the appropriate
- * <code>AdminPermission[this,EXECUTE]</code>, and the Java Runtime
- * Environment supports permissions.
- * @see #start(int)
- */
- public void stop() throws BundleException;
-
- /**
- * Updates this bundle from an <code>InputStream</code>.
- *
- * <p>
- * If the specified <code>InputStream</code> is <code>null</code>, the
- * Framework must create the <code>InputStream</code> from which to read the
- * updated bundle by interpreting, in an implementation dependent manner,
- * this bundle's {@link Constants#BUNDLE_UPDATELOCATION
- * Bundle-UpdateLocation} Manifest header, if present, or this bundle's
- * original location.
- *
- * <p>
- * If this bundle's state is <code>ACTIVE</code>, it must be stopped before
- * the update and started after the update successfully completes.
- *
- * <p>
- * If this bundle has exported any packages that are imported by another
- * bundle, these packages must not be updated. Instead, the previous package
- * version must remain exported until the
- * <code>PackageAdmin.refreshPackages</code> method has been has been called
- * or the Framework is relaunched.
- *
- * <p>
- * The following steps are required to update a bundle:
- * <ol>
- * <li>If this bundle's state is <code>UNINSTALLED</code> then an
- * <code>IllegalStateException</code> is thrown.
- *
- * <li>If this bundle's state is <code>ACTIVE</code>, <code>STARTING</code>
- * or <code>STOPPING</code>, this bundle is stopped as described in the
- * <code>Bundle.stop</code> method. If <code>Bundle.stop</code> throws an
- * exception, the exception is rethrown terminating the update.
- *
- * <li>The updated version of this bundle is read from the input stream and
- * installed. If the Framework is unable to install the updated version of
- * this bundle, the original version of this bundle must be restored and a
- * <code>BundleException</code> must be thrown after completion of the
- * remaining steps.
- *
- * <li>This bundle's state is set to <code>INSTALLED</code>.
- *
- * <li>If the updated version of this bundle was successfully installed, a
- * bundle event of type {@link BundleEvent#UPDATED} is fired.
- *
- * <li>If this bundle's state was originally <code>ACTIVE</code>, the
- * updated bundle is started as described in the <code>Bundle.start</code>
- * method. If <code>Bundle.start</code> throws an exception, a Framework
- * event of type {@link FrameworkEvent#ERROR} is fired containing the
- * exception.
- * </ol>
- *
- * <b>Preconditions </b>
- * <ul>
- * <li><code>getState()</code> not in { <code>UNINSTALLED</code>
- * }.
- * </ul>
- * <b>Postconditions, no exceptions thrown </b>
- * <ul>
- * <li><code>getState()</code> in { <code>INSTALLED</code>,
- * <code>RESOLVED</code>, <code>ACTIVE</code> }.
- * <li>This bundle has been updated.
- * </ul>
- * <b>Postconditions, when an exception is thrown </b>
- * <ul>
- * <li><code>getState()</code> in { <code>INSTALLED</code>,
- * <code>RESOLVED</code>, <code>ACTIVE</code> }.
- * <li>Original bundle is still used; no update occurred.
- * </ul>
- *
- * @param input The <code>InputStream</code> from which to read the new
- * bundle or <code>null</code> to indicate the Framework must create
- * the input stream from this bundle's
- * {@link Constants#BUNDLE_UPDATELOCATION Bundle-UpdateLocation}
- * Manifest header, if present, or this bundle's original location.
- * The input stream must always be closed when this method completes,
- * even if an exception is thrown.
- * @throws BundleException If the input stream cannot be read or the update
- * fails.
- * @throws IllegalStateException If this bundle has been uninstalled or this
- * bundle tries to change its own state.
- * @throws SecurityException If the caller does not have the appropriate
- * <code>AdminPermission[this,LIFECYCLE]</code> for both the current
- * bundle and the updated bundle, and the Java Runtime Environment
- * supports permissions.
- * @see #stop()
- * @see #start()
- */
- public void update(InputStream input) throws BundleException;
-
- /**
- * Updates this bundle.
- *
- * <p>
- * This method performs the same function as calling
- * {@link #update(InputStream)} with a <code>null</code> InputStream.
- *
- * @throws BundleException If the update fails.
- * @throws IllegalStateException If this bundle has been uninstalled or this
- * bundle tries to change its own state.
- * @throws SecurityException If the caller does not have the appropriate
- * <code>AdminPermission[this,LIFECYCLE]</code> for both the current
- * bundle and the updated bundle, and the Java Runtime Environment
- * supports permissions.
- * @see #update(InputStream)
- */
- public void update() throws BundleException;
-
- /**
- * Uninstalls this bundle.
- *
- * <p>
- * This method causes the Framework to notify other bundles that this bundle
- * is being uninstalled, and then puts this bundle into the
- * <code>UNINSTALLED</code> state. The Framework must remove any resources
- * related to this bundle that it is able to remove.
- *
- * <p>
- * If this bundle has exported any packages, the Framework must continue to
- * make these packages available to their importing bundles until the
- * <code>PackageAdmin.refreshPackages</code> method has been called or the
- * Framework is relaunched.
- *
- * <p>
- * The following steps are required to uninstall a bundle:
- * <ol>
- * <li>If this bundle's state is <code>UNINSTALLED</code> then an
- * <code>IllegalStateException</code> is thrown.
- *
- * <li>If this bundle's state is <code>ACTIVE</code>, <code>STARTING</code>
- * or <code>STOPPING</code>, this bundle is stopped as described in the
- * <code>Bundle.stop</code> method. If <code>Bundle.stop</code> throws an
- * exception, a Framework event of type {@link FrameworkEvent#ERROR} is
- * fired containing the exception.
- *
- * <li>This bundle's state is set to <code>UNINSTALLED</code>.
- *
- * <li>A bundle event of type {@link BundleEvent#UNINSTALLED} is fired.
- *
- * <li>This bundle and any persistent storage area provided for this bundle
- * by the Framework are removed.
- * </ol>
- *
- * <b>Preconditions </b>
- * <ul>
- * <li><code>getState()</code> not in { <code>UNINSTALLED</code>
- * }.
- * </ul>
- * <b>Postconditions, no exceptions thrown </b>
- * <ul>
- * <li><code>getState()</code> in { <code>UNINSTALLED</code>
- * }.
- * <li>This bundle has been uninstalled.
- * </ul>
- * <b>Postconditions, when an exception is thrown </b>
- * <ul>
- * <li><code>getState()</code> not in { <code>UNINSTALLED</code>
- * }.
- * <li>This Bundle has not been uninstalled.
- * </ul>
- *
- * @throws BundleException If the uninstall failed. This can occur if
- * another thread is attempting to change this bundle's state and
- * does not complete in a timely manner.
- * @throws IllegalStateException If this bundle has been uninstalled or this
- * bundle tries to change its own state.
- * @throws SecurityException If the caller does not have the appropriate
- * <code>AdminPermission[this,LIFECYCLE]</code>, and the Java
- * Runtime Environment supports permissions.
- * @see #stop()
- */
- public void uninstall() throws BundleException;
-
- /**
- * Returns this bundle's Manifest headers and values. This method returns
- * all the Manifest headers and values from the main section of this
- * bundle's Manifest file; that is, all lines prior to the first blank line.
- *
- * <p>
- * Manifest header names are case-insensitive. The methods of the returned
- * <code>Dictionary</code> object must operate on header names in a
- * case-insensitive manner.
- *
- * If a Manifest header value starts with "%", it must be
- * localized according to the default locale. If no localization is found
- * for a header value, the header value without the leading "%" is
- * returned.
- *
- * <p>
- * For example, the following Manifest headers and values are included if
- * they are present in the Manifest file:
- *
- * <pre>
- * Bundle-Name
- * Bundle-Vendor
- * Bundle-Version
- * Bundle-Description
- * Bundle-DocURL
- * Bundle-ContactAddress
- * </pre>
- *
- * <p>
- * This method must continue to return Manifest header information while
- * this bundle is in the <code>UNINSTALLED</code> state.
- *
- * @return A <code>Dictionary</code> object containing this bundle's
- * Manifest headers and values.
- * @throws SecurityException If the caller does not have the
- * appropriate <code>AdminPermission[this,METADATA]</code>, and
- * the Java Runtime Environment supports permissions.
- * @see Constants#BUNDLE_LOCALIZATION
- */
- public Dictionary/* <String,String> */getHeaders();
-
- /**
- * Returns this bundle's unique identifier. This bundle is assigned a unique
- * identifier by the Framework when it was installed in the OSGi
- * environment.
- *
- * <p>
- * A bundle's unique identifier has the following attributes:
- * <ul>
- * <li>Is unique and persistent.
- * <li>Is a <code>long</code>.
- * <li>Its value is not reused for another bundle, even after a bundle is
- * uninstalled.
- * <li>Does not change while a bundle remains installed.
- * <li>Does not change when a bundle is updated.
- * </ul>
- *
- * <p>
- * This method must continue to return this bundle's unique identifier while
- * this bundle is in the <code>UNINSTALLED</code> state.
- *
- * @return The unique identifier of this bundle.
- */
- public long getBundleId();
-
- /**
- * Returns this bundle's location identifier.
- *
- * <p>
- * The location identifier is the location passed to
- * <code>BundleContext.installBundle</code> when a bundle is installed.
- * The location identifier does not change while this bundle remains
- * installed, even if this bundle is updated.
- *
- * <p>
- * This method must continue to return this bundle's location identifier
- * while this bundle is in the <code>UNINSTALLED</code> state.
- *
- * @return The string representation of this bundle's location identifier.
- * @throws SecurityException If the caller does not have the
- * appropriate <code>AdminPermission[this,METADATA]</code>, and
- * the Java Runtime Environment supports permissions.
- */
- public String getLocation();
-
- /**
- * Returns this bundle's <code>ServiceReference</code> list for all
- * services it has registered or <code>null</code> if this bundle has no
- * registered services.
- *
- * <p>
- * If the Java runtime supports permissions, a <code>ServiceReference</code>
- * object to a service is included in the returned list only if the caller
- * has the <code>ServicePermission</code> to get the service using at
- * least one of the named classes the service was registered under.
- *
- * <p>
- * The list is valid at the time of the call to this method, however, as the
- * Framework is a very dynamic environment, services can be modified or
- * unregistered at anytime.
- *
- * @return An array of <code>ServiceReference</code> objects or
- * <code>null</code>.
- * @throws IllegalStateException If this bundle has been
- * uninstalled.
- * @see ServiceRegistration
- * @see ServiceReference
- * @see ServicePermission
- */
- public ServiceReference[] getRegisteredServices();
-
- /**
- * Returns this bundle's <code>ServiceReference</code> list for all
- * services it is using or returns <code>null</code> if this bundle is not
- * using any services. A bundle is considered to be using a service if its
- * use count for that service is greater than zero.
- *
- * <p>
- * If the Java Runtime Environment supports permissions, a
- * <code>ServiceReference</code> object to a service is included in the
- * returned list only if the caller has the <code>ServicePermission</code>
- * to get the service using at least one of the named classes the service
- * was registered under.
- * <p>
- * The list is valid at the time of the call to this method, however, as the
- * Framework is a very dynamic environment, services can be modified or
- * unregistered at anytime.
- *
- * @return An array of <code>ServiceReference</code> objects or
- * <code>null</code>.
- * @throws IllegalStateException If this bundle has been
- * uninstalled.
- * @see ServiceReference
- * @see ServicePermission
- */
- public ServiceReference[] getServicesInUse();
-
- /**
- * Determines if this bundle has the specified permissions.
- *
- * <p>
- * If the Java Runtime Environment does not support permissions, this method
- * always returns <code>true</code>.
- * <p>
- * <code>permission</code> is of type <code>Object</code> to avoid
- * referencing the <code>java.security.Permission</code> class directly.
- * This is to allow the Framework to be implemented in Java environments
- * which do not support permissions.
- *
- * <p>
- * If the Java Runtime Environment does support permissions, this bundle and
- * all its resources including embedded JAR files, belong to the same
- * <code>java.security.ProtectionDomain</code>; that is, they must share
- * the same set of permissions.
- *
- * @param permission The permission to verify.
- * @return <code>true</code> if this bundle has the specified permission
- * or the permissions possessed by this bundle imply the specified
- * permission; <code>false</code> if this bundle does not have the
- * specified permission or <code>permission</code> is not an
- * <code>instanceof</code> <code>java.security.Permission</code>.
- * @throws IllegalStateException If this bundle has been
- * uninstalled.
- */
- public boolean hasPermission(Object permission);
-
- /**
- * Find the specified resource from this bundle's class loader.
- *
- * This bundle's class loader is called to search for the specified
- * resource. If this bundle's state is <code>INSTALLED</code>, this method
- * must attempt to resolve this bundle before attempting to get the
- * specified resource. If this bundle cannot be resolved, then only this
- * bundle must be searched for the specified resource. Imported packages
- * cannot be searched when this bundle has not been resolved. If this bundle
- * is a fragment bundle then <code>null</code> is returned.
- * <p>
- * Note: Jar and zip files are not required to include directory entries.
- * URLs to directory entries will not be returned if the bundle contents do
- * not contain directory entries.
- *
- * @param name The name of the resource. See
- * <code>ClassLoader.getResource</code> for a description of the
- * format of a resource name.
- * @return A URL to the named resource, or <code>null</code> if the resource
- * could not be found or if this bundle is a fragment bundle or if
- * the caller does not have the appropriate
- * <code>AdminPermission[this,RESOURCE]</code>, and the Java Runtime
- * Environment supports permissions.
- * @throws IllegalStateException If this bundle has been uninstalled.
- * @see #getEntry
- * @see #findEntries
- * @since 1.1
- */
- public URL getResource(String name);
-
- /**
- * Returns this bundle's Manifest headers and values localized to the
- * specified locale.
- *
- * <p>
- * This method performs the same function as
- * <code>Bundle.getHeaders()</code> except the manifest header values are
- * localized to the specified locale.
- *
- * <p>
- * If a Manifest header value starts with "%", it must be
- * localized according to the specified locale. If a locale is specified and
- * cannot be found, then the header values must be returned using the
- * default locale. Localizations are searched for in the following order:
- *
- * <pre>
- * bn + "_" + Ls + "_" + Cs + "_" + Vs
- * bn + "_" + Ls + "_" + Cs
- * bn + "_" + Ls
- * bn + "_" + Ld + "_" + Cd + "_" + Vd
- * bn + "_" + Ld + "_" + Cd
- * bn + "_" + Ld
- * bn
- * </pre>
- *
- * Where <code>bn</code> is this bundle's localization basename,
- * <code>Ls</code>, <code>Cs</code> and <code>Vs</code> are the
- * specified locale (language, country, variant) and <code>Ld</code>,
- * <code>Cd</code> and <code>Vd</code> are the default locale (language,
- * country, variant).
- *
- * If <code>null</code> is specified as the locale string, the header
- * values must be localized using the default locale. If the empty string
- * ("") is specified as the locale string, the header values must
- * not be localized and the raw (unlocalized) header values, including any
- * leading "%", must be returned. If no localization is found for
- * a header value, the header value without the leading "%" is
- * returned.
- *
- * <p>
- * This method must continue to return Manifest header information while
- * this bundle is in the <code>UNINSTALLED</code> state, however the
- * header values must only be available in the raw and default locale
- * values.
- *
- * @param locale The locale name into which the header values are to be
- * localized. If the specified locale is <code>null</code> then the
- * locale returned by <code>java.util.Locale.getDefault</code> is
- * used. If the specified locale is the empty string, this method
- * will return the raw (unlocalized) manifest headers including any
- * leading "%".
- * @return A <code>Dictionary</code> object containing this bundle's
- * Manifest headers and values.
- * @throws SecurityException If the caller does not have the
- * appropriate <code>AdminPermission[this,METADATA]</code>, and
- * the Java Runtime Environment supports permissions.
- * @see #getHeaders()
- * @see Constants#BUNDLE_LOCALIZATION
- * @since 1.3
- */
- public Dictionary/* <String,String> */getHeaders(String locale);
-
- /**
- * Returns the symbolic name of this bundle as specified by its
- * <code>Bundle-SymbolicName</code> manifest header. The bundle symbolic
- * name together with a version must identify a unique bundle. The bundle
- * symbolic name should be based on the reverse domain name naming
- * convention like that used for java packages.
- *
- * <p>
- * This method must continue to return this bundle's symbolic name while
- * this bundle is in the <code>UNINSTALLED</code> state.
- *
- * @return The symbolic name of this bundle or <code>null</code> if this
- * bundle does not have a symbolic name.
- * @since 1.3
- */
- public String getSymbolicName();
-
- /**
- * Loads the specified class using this bundle's class loader.
- *
- * <p>
- * If this bundle is a fragment bundle then this method must throw a
- * <code>ClassNotFoundException</code>.
- *
- * <p>
- * If this bundle's state is <code>INSTALLED</code>, this method must
- * attempt to resolve this bundle before attempting to load the class.
- *
- * <p>
- * If this bundle cannot be resolved, a Framework event of type
- * {@link FrameworkEvent#ERROR} is fired containing a
- * <code>BundleException</code> with details of the reason this bundle
- * could not be resolved. This method must then throw a
- * <code>ClassNotFoundException</code>.
- *
- * <p>
- * If this bundle's state is <code>UNINSTALLED</code>, then an
- * <code>IllegalStateException</code> is thrown.
- *
- * @param name The name of the class to load.
- * @return The Class object for the requested class.
- * @throws ClassNotFoundException If no such class can be found or
- * if this bundle is a fragment bundle or if the caller does not
- * have the appropriate <code>AdminPermission[this,CLASS]</code>,
- * and the Java Runtime Environment supports permissions.
- * @throws IllegalStateException If this bundle has been
- * uninstalled.
- * @since 1.3
- */
- public Class loadClass(String name) throws ClassNotFoundException;
-
- /**
- * Find the specified resources from this bundle's class loader.
- *
- * This bundle's class loader is called to search for the specified
- * resources. If this bundle's state is <code>INSTALLED</code>, this method
- * must attempt to resolve this bundle before attempting to get the
- * specified resources. If this bundle cannot be resolved, then only this
- * bundle must be searched for the specified resources. Imported packages
- * cannot be searched when a bundle has not been resolved. If this bundle is
- * a fragment bundle then <code>null</code> is returned.
- * <p>
- * Note: Jar and zip files are not required to include directory entries.
- * URLs to directory entries will not be returned if the bundle contents do
- * not contain directory entries.
- *
- * @param name The name of the resource. See
- * <code>ClassLoader.getResources</code> for a description of the
- * format of a resource name.
- * @return An enumeration of URLs to the named resources, or
- * <code>null</code> if the resource could not be found or if this
- * bundle is a fragment bundle or if the caller does not have the
- * appropriate <code>AdminPermission[this,RESOURCE]</code>, and the
- * Java Runtime Environment supports permissions.
- * @throws IllegalStateException If this bundle has been uninstalled.
- * @throws IOException If there is an I/O error.
- * @since 1.3
- */
- public Enumeration/* <URL> */getResources(String name) throws IOException;
-
- /**
- * Returns an Enumeration of all the paths (<code>String</code> objects)
- * to entries within this bundle whose longest sub-path matches the
- * specified path. This bundle's class loader is not used to search for
- * entries. Only the contents of this bundle are searched.
- * <p>
- * The specified path is always relative to the root of this bundle and may
- * begin with a "/". A path value of "/" indicates the
- * root of this bundle.
- * <p>
- * Returned paths indicating subdirectory paths end with a "/".
- * The returned paths are all relative to the root of this bundle and must
- * not begin with "/".
- * <p>
- * Note: Jar and zip files are not required to include directory entries.
- * Paths to directory entries will not be returned if the bundle contents do
- * not contain directory entries.
- *
- * @param path The path name for which to return entry paths.
- * @return An Enumeration of the entry paths (<code>String</code>
- * objects) or <code>null</code> if no entry could be found or if
- * the caller does not have the appropriate
- * <code>AdminPermission[this,RESOURCE]</code> and the Java
- * Runtime Environment supports permissions.
- * @throws IllegalStateException If this bundle has been
- * uninstalled.
- * @since 1.3
- */
- public Enumeration/* <String> */getEntryPaths(String path);
-
- /**
- * Returns a URL to the entry at the specified path in this bundle. This
- * bundle's class loader is not used to search for the entry. Only the
- * contents of this bundle are searched for the entry.
- * <p>
- * The specified path is always relative to the root of this bundle and may
- * begin with "/". A path value of "/" indicates the
- * root of this bundle.
- * <p>
- * Note: Jar and zip files are not required to include directory entries.
- * URLs to directory entries will not be returned if the bundle contents do
- * not contain directory entries.
- *
- * @param path The path name of the entry.
- * @return A URL to the entry, or <code>null</code> if no entry could be
- * found or if the caller does not have the appropriate
- * <code>AdminPermission[this,RESOURCE]</code> and the Java
- * Runtime Environment supports permissions.
- * @throws IllegalStateException If this bundle has been
- * uninstalled.
- * @since 1.3
- */
- public URL getEntry(String path);
-
- /**
- * Returns the time when this bundle was last modified. A bundle is
- * considered to be modified when it is installed, updated or uninstalled.
- *
- * <p>
- * The time value is the number of milliseconds since January 1, 1970,
- * 00:00:00 GMT.
- *
- * @return The time when this bundle was last modified.
- * @since 1.3
- */
- public long getLastModified();
-
- /**
- * Returns entries in this bundle and its attached fragments. This bundle's
- * class loader is not used to search for entries. Only the contents of this
- * bundle and its attached fragments are searched for the specified entries.
- *
- * If this bundle's state is <code>INSTALLED</code>, this method must
- * attempt to resolve this bundle before attempting to find entries.
- *
- * <p>
- * This method is intended to be used to obtain configuration, setup,
- * localization and other information from this bundle. This method takes
- * into account that the "contents" of this bundle can be extended
- * with fragments. This "bundle space" is not a namespace with
- * unique members; the same entry name can be present multiple times. This
- * method therefore returns an enumeration of URL objects. These URLs can
- * come from different JARs but have the same path name. This method can
- * either return only entries in the specified path or recurse into
- * subdirectories returning entries in the directory tree beginning at the
- * specified path. Fragments can be attached after this bundle is resolved,
- * possibly changing the set of URLs returned by this method. If this bundle
- * is not resolved, only the entries in the JAR file of this bundle are
- * returned.
- * <p>
- * Examples:
- *
- * <pre>
- * // List all XML files in the OSGI-INF directory and below
- * Enumeration e = b.findEntries("OSGI-INF", "*.xml", true);
- *
- * // Find a specific localization file
- * Enumeration e = b
- * .findEntries("OSGI-INF/l10n", "bundle_nl_DU.properties", false);
- * if (e.hasMoreElements())
- * return (URL) e.nextElement();
- * </pre>
- *
- * <p>
- * Note: Jar and zip files are not required to include directory entries.
- * URLs to directory entries will not be returned if the bundle contents do
- * not contain directory entries.
- *
- * @param path The path name in which to look. The path is always relative
- * to the root of this bundle and may begin with "/". A
- * path value of "/" indicates the root of this bundle.
- * @param filePattern The file name pattern for selecting entries in the
- * specified path. The pattern is only matched against the last
- * element of the entry path. If the entry is a directory then the
- * trailing "/" is not used for pattern matching. Substring
- * matching is supported, as specified in the Filter specification,
- * using the wildcard character ("*"). If null is
- * specified, this is equivalent to "*" and matches all
- * files.
- * @param recurse If <code>true</code>, recurse into subdirectories.
- * Otherwise only return entries from the specified path.
- * @return An enumeration of URL objects for each matching entry, or
- * <code>null</code> if an entry could not be found or if the caller
- * does not have the appropriate
- * <code>AdminPermission[this,RESOURCE]</code>, and the Java Runtime
- * Environment supports permissions. The URLs are sorted such that
- * entries from this bundle are returned first followed by the
- * entries from attached fragments in ascending bundle id order. If
- * this bundle is a fragment, then only matching entries in this
- * fragment are returned.
- * @throws IllegalStateException If this bundle has been uninstalled.
- * @since 1.3
- */
- public Enumeration/* <URL> */findEntries(String path, String filePattern,
- boolean recurse);
-
- /**
- * Returns this bundle's {@link BundleContext}. The returned
- * <code>BundleContext</code> can be used by the caller to act on behalf
- * of this bundle.
- *
- * <p>
- * If this bundle is not in the {@link #STARTING}, {@link #ACTIVE}, or
- * {@link #STOPPING} states or this bundle is a fragment bundle, then this
- * bundle has no valid <code>BundleContext</code>. This method will
- * return <code>null</code> if this bundle has no valid
- * <code>BundleContext</code>.
- *
- * @return A <code>BundleContext</code> for this bundle or
- * <code>null</code> if this bundle has no valid
- * <code>BundleContext</code>.
- * @throws SecurityException If the caller does not have the
- * appropriate <code>AdminPermission[this,CONTEXT]</code>, and
- * the Java Runtime Environment supports permissions.
- * @since 1.4
- */
- public BundleContext getBundleContext();
-
- /**
- * Return the certificates for the signers of this bundle and the
- * certificate chains for those signers.
- *
- * @param signersType If {@link #SIGNERS_ALL} is specified, then information
- * on all signers of this bundle is returned. If
- * {@link #SIGNERS_TRUSTED} is specified, then only information on
- * the signers of this bundle trusted by the framework is returned.
- * @return The <code>X509Certificate</code>s for the signers of this bundle
- * and the <code>X509Certificate</code> chains for those signers.
- * The keys of the <code>Map</code> are the
- * <code>X509Certificate</code>s of the signers of this bundle. The
- * value for a key is a <code>List</code> containing the
- * <code>X509Certificate</code> chain for the signer. The first item
- * in the <code>List</code> is the signer's
- * <code>X509Certificate</code> which is then followed by the rest
- * of the <code>X509Certificate</code> chain. The returned
- * <code>Map</code> will be empty if there are no signers. The
- * returned <code>Map</code> is the property of the caller who is
- * free to modify it.
- * @throws IllegalArgumentException If the specified
- * <code>signersType</code> is not {@link #SIGNERS_ALL} or
- * {@link #SIGNERS_TRUSTED}.
- * @since 1.5
- */
- public Map/* <X509Certificate, List<X509Certificate>> */getSignerCertificates(
- int signersType);
-
- /**
- * Returns the version of this bundle as specified by its
- * <code>Bundle-Version</code> manifest header. If this bundle does not have a
- * specified version then {@link Version#emptyVersion} is returned.
- *
- * <p>
- * This method must continue to return this bundle's version while
- * this bundle is in the <code>UNINSTALLED</code> state.
- *
- * @return The version of this bundle.
- * @since 1.5
- */
- public Version getVersion();
-}
diff --git a/org.osgi.core/src/main/java/org/osgi/framework/BundleActivator.java b/org.osgi.core/src/main/java/org/osgi/framework/BundleActivator.java
deleted file mode 100644
index 56660b1..0000000
--- a/org.osgi.core/src/main/java/org/osgi/framework/BundleActivator.java
+++ /dev/null
@@ -1,87 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2000, 2009). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.osgi.framework;
-
-/**
- * Customizes the starting and stopping of a bundle.
- * <p>
- * <code>BundleActivator</code> is an interface that may be implemented when a
- * bundle is started or stopped. The Framework can create instances of a
- * bundle's <code>BundleActivator</code> as required. If an instance's
- * <code>BundleActivator.start</code> method executes successfully, it is
- * guaranteed that the same instance's <code>BundleActivator.stop</code>
- * method will be called when the bundle is to be stopped. The Framework must
- * not concurrently call a <code>BundleActivator</code> object.
- *
- * <p>
- * <code>BundleActivator</code> is specified through the
- * <code>Bundle-Activator</code> Manifest header. A bundle can only specify a
- * single <code>BundleActivator</code> in the Manifest file. Fragment bundles
- * must not have a <code>BundleActivator</code>. The form of the Manifest
- * header is:
- *
- * <p>
- * <code>Bundle-Activator: <i>class-name</i></code>
- *
- * <p>
- * where <code><i>class-name</i></code> is a fully qualified Java classname.
- * <p>
- * The specified <code>BundleActivator</code> class must have a public
- * constructor that takes no parameters so that a <code>BundleActivator</code>
- * object can be created by <code>Class.newInstance()</code>.
- *
- * @NotThreadSafe
- * @version $Revision: 6361 $
- */
-
-public interface BundleActivator {
- /**
- * Called when this bundle is started so the Framework can perform the
- * bundle-specific activities necessary to start this bundle. This method
- * can be used to register services or to allocate any resources that this
- * bundle needs.
- *
- * <p>
- * This method must complete and return to its caller in a timely manner.
- *
- * @param context The execution context of the bundle being started.
- * @throws Exception If this method throws an exception, this
- * bundle is marked as stopped and the Framework will remove this
- * bundle's listeners, unregister all services registered by this
- * bundle, and release all services used by this bundle.
- */
- public void start(BundleContext context) throws Exception;
-
- /**
- * Called when this bundle is stopped so the Framework can perform the
- * bundle-specific activities necessary to stop the bundle. In general, this
- * method should undo the work that the <code>BundleActivator.start</code>
- * method started. There should be no active threads that were started by
- * this bundle when this bundle returns. A stopped bundle must not call any
- * Framework objects.
- *
- * <p>
- * This method must complete and return to its caller in a timely manner.
- *
- * @param context The execution context of the bundle being stopped.
- * @throws Exception If this method throws an exception, the
- * bundle is still marked as stopped, and the Framework will remove
- * the bundle's listeners, unregister all services registered by the
- * bundle, and release all services used by the bundle.
- */
- public void stop(BundleContext context) throws Exception;
-}
diff --git a/org.osgi.core/src/main/java/org/osgi/framework/BundleContext.java b/org.osgi.core/src/main/java/org/osgi/framework/BundleContext.java
deleted file mode 100644
index 44b3801..0000000
--- a/org.osgi.core/src/main/java/org/osgi/framework/BundleContext.java
+++ /dev/null
@@ -1,756 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2000, 2009). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.osgi.framework;
-
-import java.io.File;
-import java.io.InputStream;
-import java.util.Dictionary;
-
-/**
- * A bundle's execution context within the Framework. The context is used to
- * grant access to other methods so that this bundle can interact with the
- * Framework.
- *
- * <p>
- * <code>BundleContext</code> methods allow a bundle to:
- * <ul>
- * <li>Subscribe to events published by the Framework.
- * <li>Register service objects with the Framework service registry.
- * <li>Retrieve <code>ServiceReferences</code> from the Framework service
- * registry.
- * <li>Get and release service objects for a referenced service.
- * <li>Install new bundles in the Framework.
- * <li>Get the list of bundles installed in the Framework.
- * <li>Get the {@link Bundle} object for a bundle.
- * <li>Create <code>File</code> objects for files in a persistent storage
- * area provided for the bundle by the Framework.
- * </ul>
- *
- * <p>
- * A <code>BundleContext</code> object will be created and provided to the
- * bundle associated with this context when it is started using the
- * {@link BundleActivator#start} method. The same <code>BundleContext</code>
- * object will be passed to the bundle associated with this context when it is
- * stopped using the {@link BundleActivator#stop} method. A
- * <code>BundleContext</code> object is generally for the private use of its
- * associated bundle and is not meant to be shared with other bundles in the
- * OSGi environment.
- *
- * <p>
- * The <code>Bundle</code> object associated with a <code>BundleContext</code>
- * object is called the <em>context bundle</em>.
- *
- * <p>
- * The <code>BundleContext</code> object is only valid during the execution of
- * its context bundle; that is, during the period from when the context bundle
- * is in the <code>STARTING</code>, <code>STOPPING</code>, and
- * <code>ACTIVE</code> bundle states. If the <code>BundleContext</code>
- * object is used subsequently, an <code>IllegalStateException</code> must be
- * thrown. The <code>BundleContext</code> object must never be reused after
- * its context bundle is stopped.
- *
- * <p>
- * The Framework is the only entity that can create <code>BundleContext</code>
- * objects and they are only valid within the Framework that created them.
- *
- * @ThreadSafe
- * @version $Revision: 6781 $
- */
-
-public interface BundleContext {
- /**
- * Returns the value of the specified property. If the key is not found in
- * the Framework properties, the system properties are then searched. The
- * method returns <code>null</code> if the property is not found.
- *
- * <p>
- * All bundles must have permission to read properties whose names start
- * with "org.osgi.".
- *
- * @param key The name of the requested property.
- * @return The value of the requested property, or <code>null</code> if the
- * property is undefined.
- * @throws SecurityException If the caller does not have the appropriate
- * <code>PropertyPermission</code> to read the property, and the
- * Java Runtime Environment supports permissions.
- */
- public String getProperty(String key);
-
- /**
- * Returns the <code>Bundle</code> object associated with this
- * <code>BundleContext</code>. This bundle is called the context bundle.
- *
- * @return The <code>Bundle</code> object associated with this
- * <code>BundleContext</code>.
- * @throws IllegalStateException If this BundleContext is no
- * longer valid.
- */
- public Bundle getBundle();
-
- /**
- * Installs a bundle from the specified <code>InputStream</code> object.
- *
- * <p>
- * If the specified <code>InputStream</code> is <code>null</code>, the
- * Framework must create the <code>InputStream</code> from which to read the
- * bundle by interpreting, in an implementation dependent manner, the
- * specified <code>location</code>.
- *
- * <p>
- * The specified <code>location</code> identifier will be used as the
- * identity of the bundle. Every installed bundle is uniquely identified by
- * its location identifier which is typically in the form of a URL.
- *
- * <p>
- * The following steps are required to install a bundle:
- * <ol>
- * <li>If a bundle containing the same location identifier is already
- * installed, the <code>Bundle</code> object for that bundle is returned.
- *
- * <li>The bundle's content is read from the input stream. If this fails, a
- * {@link BundleException} is thrown.
- *
- * <li>The bundle's associated resources are allocated. The associated
- * resources minimally consist of a unique identifier and a persistent
- * storage area if the platform has file system support. If this step fails,
- * a <code>BundleException</code> is thrown.
- *
- * <li>The bundle's state is set to <code>INSTALLED</code>.
- *
- * <li>A bundle event of type {@link BundleEvent#INSTALLED} is fired.
- *
- * <li>The <code>Bundle</code> object for the newly or previously installed
- * bundle is returned.
- * </ol>
- *
- * <b>Postconditions, no exceptions thrown </b>
- * <ul>
- * <li><code>getState()</code> in { <code>INSTALLED</code>,
- * <code>RESOLVED</code> }.
- * <li>Bundle has a unique ID.
- * </ul>
- * <b>Postconditions, when an exception is thrown </b>
- * <ul>
- * <li>Bundle is not installed and no trace of the bundle exists.
- * </ul>
- *
- * @param location The location identifier of the bundle to install.
- * @param input The <code>InputStream</code> object from which this bundle
- * will be read or <code>null</code> to indicate the Framework must
- * create the input stream from the specified location identifier.
- * The input stream must always be closed when this method completes,
- * even if an exception is thrown.
- * @return The <code>Bundle</code> object of the installed bundle.
- * @throws BundleException If the input stream cannot be read or the
- * installation failed.
- * @throws SecurityException If the caller does not have the appropriate
- * <code>AdminPermission[installed bundle,LIFECYCLE]</code>, and the
- * Java Runtime Environment supports permissions.
- * @throws IllegalStateException If this BundleContext is no longer valid.
- */
- public Bundle installBundle(String location, InputStream input)
- throws BundleException;
-
- /**
- * Installs a bundle from the specified <code>location</code> identifier.
- *
- * <p>
- * This method performs the same function as calling
- * {@link #installBundle(String,InputStream)} with the specified
- * <code>location</code> identifier and a <code>null</code> InputStream.
- *
- * @param location The location identifier of the bundle to install.
- * @return The <code>Bundle</code> object of the installed bundle.
- * @throws BundleException If the installation failed.
- * @throws SecurityException If the caller does not have the appropriate
- * <code>AdminPermission[installed bundle,LIFECYCLE]</code>, and the
- * Java Runtime Environment supports permissions.
- * @throws IllegalStateException If this BundleContext is no longer valid.
- * @see #installBundle(String, InputStream)
- */
- public Bundle installBundle(String location) throws BundleException;
-
- /**
- * Returns the bundle with the specified identifier.
- *
- * @param id The identifier of the bundle to retrieve.
- * @return A <code>Bundle</code> object or <code>null</code> if the
- * identifier does not match any installed bundle.
- */
- public Bundle getBundle(long id);
-
- /**
- * Returns a list of all installed bundles.
- * <p>
- * This method returns a list of all bundles installed in the OSGi
- * environment at the time of the call to this method. However, since the
- * Framework is a very dynamic environment, bundles can be installed or
- * uninstalled at anytime.
- *
- * @return An array of <code>Bundle</code> objects, one object per
- * installed bundle.
- */
- public Bundle[] getBundles();
-
- /**
- * Adds the specified <code>ServiceListener</code> object with the
- * specified <code>filter</code> to the context bundle's list of
- * listeners. See {@link Filter} for a description of the filter syntax.
- * <code>ServiceListener</code> objects are notified when a service has a
- * lifecycle state change.
- *
- * <p>
- * If the context bundle's list of listeners already contains a listener
- * <code>l</code> such that <code>(l==listener)</code>, then this
- * method replaces that listener's filter (which may be <code>null</code>)
- * with the specified one (which may be <code>null</code>).
- *
- * <p>
- * The listener is called if the filter criteria is met. To filter based
- * upon the class of the service, the filter should reference the
- * {@link Constants#OBJECTCLASS} property. If <code>filter</code> is
- * <code>null</code>, all services are considered to match the filter.
- *
- * <p>
- * When using a <code>filter</code>, it is possible that the
- * <code>ServiceEvent</code>s for the complete lifecycle of a service
- * will not be delivered to the listener. For example, if the
- * <code>filter</code> only matches when the property <code>x</code> has
- * the value <code>1</code>, the listener will not be called if the
- * service is registered with the property <code>x</code> not set to the
- * value <code>1</code>. Subsequently, when the service is modified
- * setting property <code>x</code> to the value <code>1</code>, the
- * filter will match and the listener will be called with a
- * <code>ServiceEvent</code> of type <code>MODIFIED</code>. Thus, the
- * listener will not be called with a <code>ServiceEvent</code> of type
- * <code>REGISTERED</code>.
- *
- * <p>
- * If the Java Runtime Environment supports permissions, the
- * <code>ServiceListener</code> object will be notified of a service event
- * only if the bundle that is registering it has the
- * <code>ServicePermission</code> to get the service using at least one of
- * the named classes the service was registered under.
- *
- * @param listener The <code>ServiceListener</code> object to be added.
- * @param filter The filter criteria.
- * @throws InvalidSyntaxException If <code>filter</code> contains an
- * invalid filter string that cannot be parsed.
- * @throws IllegalStateException If this BundleContext is no
- * longer valid.
- * @see ServiceEvent
- * @see ServiceListener
- * @see ServicePermission
- */
- public void addServiceListener(ServiceListener listener, String filter)
- throws InvalidSyntaxException;
-
- /**
- * Adds the specified <code>ServiceListener</code> object to the context
- * bundle's list of listeners.
- *
- * <p>
- * This method is the same as calling
- * <code>BundleContext.addServiceListener(ServiceListener listener,
- * String filter)</code>
- * with <code>filter</code> set to <code>null</code>.
- *
- * @param listener The <code>ServiceListener</code> object to be added.
- * @throws IllegalStateException If this BundleContext is no
- * longer valid.
- * @see #addServiceListener(ServiceListener, String)
- */
- public void addServiceListener(ServiceListener listener);
-
- /**
- * Removes the specified <code>ServiceListener</code> object from the
- * context bundle's list of listeners.
- *
- * <p>
- * If <code>listener</code> is not contained in this context bundle's list
- * of listeners, this method does nothing.
- *
- * @param listener The <code>ServiceListener</code> to be removed.
- * @throws IllegalStateException If this BundleContext is no
- * longer valid.
- */
- public void removeServiceListener(ServiceListener listener);
-
- /**
- * Adds the specified <code>BundleListener</code> object to the context
- * bundle's list of listeners if not already present. BundleListener objects
- * are notified when a bundle has a lifecycle state change.
- *
- * <p>
- * If the context bundle's list of listeners already contains a listener
- * <code>l</code> such that <code>(l==listener)</code>, this method
- * does nothing.
- *
- * @param listener The <code>BundleListener</code> to be added.
- * @throws IllegalStateException If this BundleContext is no
- * longer valid.
- * @throws SecurityException If listener is a
- * <code>SynchronousBundleListener</code> and the caller does not
- * have the appropriate
- * <code>AdminPermission[context bundle,LISTENER]</code>, and the
- * Java Runtime Environment supports permissions.
- * @see BundleEvent
- * @see BundleListener
- */
- public void addBundleListener(BundleListener listener);
-
- /**
- * Removes the specified <code>BundleListener</code> object from the
- * context bundle's list of listeners.
- *
- * <p>
- * If <code>listener</code> is not contained in the context bundle's list
- * of listeners, this method does nothing.
- *
- * @param listener The <code>BundleListener</code> object to be removed.
- * @throws IllegalStateException If this BundleContext is no
- * longer valid.
- * @throws SecurityException If listener is a
- * <code>SynchronousBundleListener</code> and the caller does not
- * have the appropriate
- * <code>AdminPermission[context bundle,LISTENER]</code>, and the
- * Java Runtime Environment supports permissions.
- */
- public void removeBundleListener(BundleListener listener);
-
- /**
- * Adds the specified <code>FrameworkListener</code> object to the context
- * bundle's list of listeners if not already present. FrameworkListeners are
- * notified of general Framework events.
- *
- * <p>
- * If the context bundle's list of listeners already contains a listener
- * <code>l</code> such that <code>(l==listener)</code>, this method
- * does nothing.
- *
- * @param listener The <code>FrameworkListener</code> object to be added.
- * @throws IllegalStateException If this BundleContext is no
- * longer valid.
- * @see FrameworkEvent
- * @see FrameworkListener
- */
- public void addFrameworkListener(FrameworkListener listener);
-
- /**
- * Removes the specified <code>FrameworkListener</code> object from the
- * context bundle's list of listeners.
- *
- * <p>
- * If <code>listener</code> is not contained in the context bundle's list
- * of listeners, this method does nothing.
- *
- * @param listener The <code>FrameworkListener</code> object to be
- * removed.
- * @throws IllegalStateException If this BundleContext is no
- * longer valid.
- */
- public void removeFrameworkListener(FrameworkListener listener);
-
- /**
- * Registers the specified service object with the specified properties
- * under the specified class names into the Framework. A
- * <code>ServiceRegistration</code> object is returned. The
- * <code>ServiceRegistration</code> object is for the private use of the
- * bundle registering the service and should not be shared with other
- * bundles. The registering bundle is defined to be the context bundle.
- * Other bundles can locate the service by using either the
- * {@link #getServiceReferences} or {@link #getServiceReference} method.
- *
- * <p>
- * A bundle can register a service object that implements the
- * {@link ServiceFactory} interface to have more flexibility in providing
- * service objects to other bundles.
- *
- * <p>
- * The following steps are required to register a service:
- * <ol>
- * <li>If <code>service</code> is not a <code>ServiceFactory</code>, an
- * <code>IllegalArgumentException</code> is thrown if <code>service</code>
- * is not an <code>instanceof</code> all the specified class names.
- * <li>The Framework adds the following service properties to the service
- * properties from the specified <code>Dictionary</code> (which may be
- * <code>null</code>): <br/>
- * A property named {@link Constants#SERVICE_ID} identifying the
- * registration number of the service <br/>
- * A property named {@link Constants#OBJECTCLASS} containing all the
- * specified classes. <br/>
- * Properties with these names in the specified <code>Dictionary</code> will
- * be ignored.
- * <li>The service is added to the Framework service registry and may now be
- * used by other bundles.
- * <li>A service event of type {@link ServiceEvent#REGISTERED} is fired.
- * <li>A <code>ServiceRegistration</code> object for this registration is
- * returned.
- * </ol>
- *
- * @param clazzes The class names under which the service can be located.
- * The class names in this array will be stored in the service's
- * properties under the key {@link Constants#OBJECTCLASS}.
- * @param service The service object or a <code>ServiceFactory</code>
- * object.
- * @param properties The properties for this service. The keys in the
- * properties object must all be <code>String</code> objects. See
- * {@link Constants} for a list of standard service property keys.
- * Changes should not be made to this object after calling this
- * method. To update the service's properties the
- * {@link ServiceRegistration#setProperties} method must be called.
- * The set of properties may be <code>null</code> if the service has
- * no properties.
- * @return A <code>ServiceRegistration</code> object for use by the bundle
- * registering the service to update the service's properties or to
- * unregister the service.
- * @throws IllegalArgumentException If one of the following is true:
- * <ul>
- * <li><code>service</code> is <code>null</code>. <li><code>service
- * </code> is not a <code>ServiceFactory</code> object and is not an
- * instance of all the named classes in <code>clazzes</code>. <li>
- * <code>properties</code> contains case variants of the same key
- * name.
- * </ul>
- * @throws SecurityException If the caller does not have the
- * <code>ServicePermission</code> to register the service for all
- * the named classes and the Java Runtime Environment supports
- * permissions.
- * @throws IllegalStateException If this BundleContext is no longer valid.
- * @see ServiceRegistration
- * @see ServiceFactory
- */
- public ServiceRegistration registerService(String[] clazzes,
- Object service, Dictionary properties);
-
- /**
- * Registers the specified service object with the specified properties
- * under the specified class name with the Framework.
- *
- * <p>
- * This method is otherwise identical to
- * {@link #registerService(String[], Object, Dictionary)} and is provided as
- * a convenience when <code>service</code> will only be registered under a
- * single class name. Note that even in this case the value of the service's
- * {@link Constants#OBJECTCLASS} property will be an array of string, rather
- * than just a single string.
- *
- * @param clazz The class name under which the service can be located.
- * @param service The service object or a <code>ServiceFactory</code>
- * object.
- * @param properties The properties for this service.
- * @return A <code>ServiceRegistration</code> object for use by the bundle
- * registering the service to update the service's properties or to
- * unregister the service.
- * @throws IllegalStateException If this BundleContext is no longer valid.
- * @see #registerService(String[], Object, Dictionary)
- */
- public ServiceRegistration registerService(String clazz, Object service,
- Dictionary properties);
-
- /**
- * Returns an array of <code>ServiceReference</code> objects. The returned
- * array of <code>ServiceReference</code> objects contains services that
- * were registered under the specified class, match the specified filter
- * expression, and the packages for the class names under which the services
- * were registered match the context bundle's packages as defined in
- * {@link ServiceReference#isAssignableTo(Bundle, String)}.
- *
- * <p>
- * The list is valid at the time of the call to this method. However since
- * the Framework is a very dynamic environment, services can be modified or
- * unregistered at any time.
- *
- * <p>
- * The specified <code>filter</code> expression is used to select the
- * registered services whose service properties contain keys and values
- * which satisfy the filter expression. See {@link Filter} for a description
- * of the filter syntax. If the specified <code>filter</code> is
- * <code>null</code>, all registered services are considered to match the
- * filter. If the specified <code>filter</code> expression cannot be parsed,
- * an {@link InvalidSyntaxException} will be thrown with a human readable
- * message where the filter became unparsable.
- *
- * <p>
- * The result is an array of <code>ServiceReference</code> objects for all
- * services that meet all of the following conditions:
- * <ul>
- * <li>If the specified class name, <code>clazz</code>, is not
- * <code>null</code>, the service must have been registered with the
- * specified class name. The complete list of class names with which a
- * service was registered is available from the service's
- * {@link Constants#OBJECTCLASS objectClass} property.
- * <li>If the specified <code>filter</code> is not <code>null</code>, the
- * filter expression must match the service.
- * <li>If the Java Runtime Environment supports permissions, the caller must
- * have <code>ServicePermission</code> with the <code>GET</code> action for
- * at least one of the class names under which the service was registered.
- * <li>For each class name with which the service was registered, calling
- * {@link ServiceReference#isAssignableTo(Bundle, String)} with the context
- * bundle and the class name on the service's <code>ServiceReference</code>
- * object must return <code>true</code>
- * </ul>
- *
- * @param clazz The class name with which the service was registered or
- * <code>null</code> for all services.
- * @param filter The filter expression or <code>null</code> for all
- * services.
- * @return An array of <code>ServiceReference</code> objects or
- * <code>null</code> if no services are registered which satisfy the
- * search.
- * @throws InvalidSyntaxException If the specified <code>filter</code>
- * contains an invalid filter expression that cannot be parsed.
- * @throws IllegalStateException If this BundleContext is no longer valid.
- */
- public ServiceReference[] getServiceReferences(String clazz, String filter)
- throws InvalidSyntaxException;
-
- /**
- * Returns an array of <code>ServiceReference</code> objects. The returned
- * array of <code>ServiceReference</code> objects contains services that
- * were registered under the specified class and match the specified filter
- * expression.
- *
- * <p>
- * The list is valid at the time of the call to this method. However since
- * the Framework is a very dynamic environment, services can be modified or
- * unregistered at any time.
- *
- * <p>
- * The specified <code>filter</code> expression is used to select the
- * registered services whose service properties contain keys and values
- * which satisfy the filter expression. See {@link Filter} for a description
- * of the filter syntax. If the specified <code>filter</code> is
- * <code>null</code>, all registered services are considered to match the
- * filter. If the specified <code>filter</code> expression cannot be parsed,
- * an {@link InvalidSyntaxException} will be thrown with a human readable
- * message where the filter became unparsable.
- *
- * <p>
- * The result is an array of <code>ServiceReference</code> objects for all
- * services that meet all of the following conditions:
- * <ul>
- * <li>If the specified class name, <code>clazz</code>, is not
- * <code>null</code>, the service must have been registered with the
- * specified class name. The complete list of class names with which a
- * service was registered is available from the service's
- * {@link Constants#OBJECTCLASS objectClass} property.
- * <li>If the specified <code>filter</code> is not <code>null</code>, the
- * filter expression must match the service.
- * <li>If the Java Runtime Environment supports permissions, the caller must
- * have <code>ServicePermission</code> with the <code>GET</code> action for
- * at least one of the class names under which the service was registered.
- * </ul>
- *
- * @param clazz The class name with which the service was registered or
- * <code>null</code> for all services.
- * @param filter The filter expression or <code>null</code> for all
- * services.
- * @return An array of <code>ServiceReference</code> objects or
- * <code>null</code> if no services are registered which satisfy the
- * search.
- * @throws InvalidSyntaxException If the specified <code>filter</code>
- * contains an invalid filter expression that cannot be parsed.
- * @throws IllegalStateException If this BundleContext is no longer valid.
- * @since 1.3
- */
- public ServiceReference[] getAllServiceReferences(String clazz,
- String filter) throws InvalidSyntaxException;
-
- /**
- * Returns a <code>ServiceReference</code> object for a service that
- * implements and was registered under the specified class.
- *
- * <p>
- * The returned <code>ServiceReference</code> object is valid at the time of
- * the call to this method. However as the Framework is a very dynamic
- * environment, services can be modified or unregistered at any time.
- *
- * <p>
- * This method is the same as calling
- * {@link BundleContext#getServiceReferences(String, String)} with a
- * <code>null</code> filter expression. It is provided as a convenience for
- * when the caller is interested in any service that implements the
- * specified class.
- * <p>
- * If multiple such services exist, the service with the highest ranking (as
- * specified in its {@link Constants#SERVICE_RANKING} property) is returned.
- * <p>
- * If there is a tie in ranking, the service with the lowest service ID (as
- * specified in its {@link Constants#SERVICE_ID} property); that is, the
- * service that was registered first is returned.
- *
- * @param clazz The class name with which the service was registered.
- * @return A <code>ServiceReference</code> object, or <code>null</code> if
- * no services are registered which implement the named class.
- * @throws IllegalStateException If this BundleContext is no longer valid.
- * @see #getServiceReferences(String, String)
- */
- public ServiceReference getServiceReference(String clazz);
-
- /**
- * Returns the service object referenced by the specified
- * <code>ServiceReference</code> object.
- * <p>
- * A bundle's use of a service is tracked by the bundle's use count of that
- * service. Each time a service's service object is returned by
- * {@link #getService(ServiceReference)} the context bundle's use count for
- * that service is incremented by one. Each time the service is released by
- * {@link #ungetService(ServiceReference)} the context bundle's use count
- * for that service is decremented by one.
- * <p>
- * When a bundle's use count for a service drops to zero, the bundle should
- * no longer use that service.
- *
- * <p>
- * This method will always return <code>null</code> when the service
- * associated with this <code>reference</code> has been unregistered.
- *
- * <p>
- * The following steps are required to get the service object:
- * <ol>
- * <li>If the service has been unregistered, <code>null</code> is returned.
- * <li>The context bundle's use count for this service is incremented by
- * one.
- * <li>If the context bundle's use count for the service is currently one
- * and the service was registered with an object implementing the
- * <code>ServiceFactory</code> interface, the
- * {@link ServiceFactory#getService(Bundle, ServiceRegistration)} method is
- * called to create a service object for the context bundle. This service
- * object is cached by the Framework. While the context bundle's use count
- * for the service is greater than zero, subsequent calls to get the
- * services's service object for the context bundle will return the cached
- * service object. <br>
- * If the service object returned by the <code>ServiceFactory</code> object
- * is not an <code>instanceof</code> all the classes named when the service
- * was registered or the <code>ServiceFactory</code> object throws an
- * exception, <code>null</code> is returned and a Framework event of type
- * {@link FrameworkEvent#ERROR} containing a {@link ServiceException}
- * describing the error is fired.
- * <li>The service object for the service is returned.
- * </ol>
- *
- * @param reference A reference to the service.
- * @return A service object for the service associated with
- * <code>reference</code> or <code>null</code> if the service is not
- * registered, the service object returned by a
- * <code>ServiceFactory</code> does not implement the classes under
- * which it was registered or the <code>ServiceFactory</code> threw
- * an exception.
- * @throws SecurityException If the caller does not have the
- * <code>ServicePermission</code> to get the service using at least
- * one of the named classes the service was registered under and the
- * Java Runtime Environment supports permissions.
- * @throws IllegalStateException If this BundleContext is no
- * longer valid.
- * @throws IllegalArgumentException If the specified
- * <code>ServiceReference</code> was not created by the same
- * framework instance as this <code>BundleContext</code>.
- * @see #ungetService(ServiceReference)
- * @see ServiceFactory
- */
- public Object getService(ServiceReference reference);
-
- /**
- * Releases the service object referenced by the specified
- * <code>ServiceReference</code> object. If the context bundle's use count
- * for the service is zero, this method returns <code>false</code>.
- * Otherwise, the context bundle's use count for the service is decremented
- * by one.
- *
- * <p>
- * The service's service object should no longer be used and all references
- * to it should be destroyed when a bundle's use count for the service drops
- * to zero.
- *
- * <p>
- * The following steps are required to unget the service object:
- * <ol>
- * <li>If the context bundle's use count for the service is zero or the
- * service has been unregistered, <code>false</code> is returned.
- * <li>The context bundle's use count for this service is decremented by
- * one.
- * <li>If the context bundle's use count for the service is currently zero
- * and the service was registered with a <code>ServiceFactory</code> object,
- * the
- * {@link ServiceFactory#ungetService(Bundle, ServiceRegistration, Object)}
- * method is called to release the service object for the context bundle.
- * <li><code>true</code> is returned.
- * </ol>
- *
- * @param reference A reference to the service to be released.
- * @return <code>false</code> if the context bundle's use count for the
- * service is zero or if the service has been unregistered;
- * <code>true</code> otherwise.
- * @throws IllegalStateException If this BundleContext is no
- * longer valid.
- * @throws IllegalArgumentException If the specified
- * <code>ServiceReference</code> was not created by the same
- * framework instance as this <code>BundleContext</code>.
- * @see #getService
- * @see ServiceFactory
- */
- public boolean ungetService(ServiceReference reference);
-
- /**
- * Creates a <code>File</code> object for a file in the persistent storage
- * area provided for the bundle by the Framework. This method will return
- * <code>null</code> if the platform does not have file system support.
- *
- * <p>
- * A <code>File</code> object for the base directory of the persistent
- * storage area provided for the context bundle by the Framework can be
- * obtained by calling this method with an empty string as
- * <code>filename</code>.
- *
- * <p>
- * If the Java Runtime Environment supports permissions, the Framework will
- * ensure that the bundle has the <code>java.io.FilePermission</code> with
- * actions <code>read</code>,<code>write</code>,<code>delete</code>
- * for all files (recursively) in the persistent storage area provided for
- * the context bundle.
- *
- * @param filename A relative name to the file to be accessed.
- * @return A <code>File</code> object that represents the requested file
- * or <code>null</code> if the platform does not have file system
- * support.
- * @throws IllegalStateException If this BundleContext is no
- * longer valid.
- */
- public File getDataFile(String filename);
-
- /**
- * Creates a <code>Filter</code> object. This <code>Filter</code> object may
- * be used to match a <code>ServiceReference</code> object or a
- * <code>Dictionary</code> object.
- *
- * <p>
- * If the filter cannot be parsed, an {@link InvalidSyntaxException} will be
- * thrown with a human readable message where the filter became unparsable.
- *
- * @param filter The filter string.
- * @return A <code>Filter</code> object encapsulating the filter string.
- * @throws InvalidSyntaxException If <code>filter</code> contains an invalid
- * filter string that cannot be parsed.
- * @throws NullPointerException If <code>filter</code> is null.
- * @throws IllegalStateException If this BundleContext is no longer valid.
- * @see "Framework specification for a description of the filter string syntax."
- * @see FrameworkUtil#createFilter(String)
- * @since 1.1
- */
- public Filter createFilter(String filter) throws InvalidSyntaxException;
-}
diff --git a/org.osgi.core/src/main/java/org/osgi/framework/BundleEvent.java b/org.osgi.core/src/main/java/org/osgi/framework/BundleEvent.java
deleted file mode 100644
index 7a8fb8d..0000000
--- a/org.osgi.core/src/main/java/org/osgi/framework/BundleEvent.java
+++ /dev/null
@@ -1,195 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2000, 2009). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.osgi.framework;
-
-import java.util.EventObject;
-
-/**
- * An event from the Framework describing a bundle lifecycle change.
- * <p>
- * <code>BundleEvent</code> objects are delivered to
- * <code>SynchronousBundleListener</code>s and <code>BundleListener</code>s
- * when a change occurs in a bundle's lifecycle. A type code is used to identify
- * the event type for future extendability.
- *
- * <p>
- * OSGi Alliance reserves the right to extend the set of types.
- *
- * @Immutable
- * @see BundleListener
- * @see SynchronousBundleListener
- * @version $Revision: 6542 $
- */
-
-public class BundleEvent extends EventObject {
- static final long serialVersionUID = 4080640865971756012L;
- /**
- * Bundle that had a change occur in its lifecycle.
- */
- private final Bundle bundle;
-
- /**
- * Type of bundle lifecycle change.
- */
- private final int type;
-
- /**
- * The bundle has been installed.
- *
- * @see BundleContext#installBundle(String)
- */
- public final static int INSTALLED = 0x00000001;
-
- /**
- * The bundle has been started.
- * <p>
- * The bundle's
- * {@link BundleActivator#start(BundleContext) BundleActivator start} method
- * has been executed if the bundle has a bundle activator class.
- *
- * @see Bundle#start()
- */
- public final static int STARTED = 0x00000002;
-
- /**
- * The bundle has been stopped.
- * <p>
- * The bundle's
- * {@link BundleActivator#stop(BundleContext) BundleActivator stop} method
- * has been executed if the bundle has a bundle activator class.
- *
- * @see Bundle#stop()
- */
- public final static int STOPPED = 0x00000004;
-
- /**
- * The bundle has been updated.
- *
- * @see Bundle#update()
- */
- public final static int UPDATED = 0x00000008;
-
- /**
- * The bundle has been uninstalled.
- *
- * @see Bundle#uninstall
- */
- public final static int UNINSTALLED = 0x00000010;
-
- /**
- * The bundle has been resolved.
- *
- * @see Bundle#RESOLVED
- * @since 1.3
- */
- public final static int RESOLVED = 0x00000020;
-
- /**
- * The bundle has been unresolved.
- *
- * @see Bundle#INSTALLED
- * @since 1.3
- */
- public final static int UNRESOLVED = 0x00000040;
-
- /**
- * The bundle is about to be activated.
- * <p>
- * The bundle's
- * {@link BundleActivator#start(BundleContext) BundleActivator start} method
- * is about to be called if the bundle has a bundle activator class. This
- * event is only delivered to {@link SynchronousBundleListener}s. It is not
- * delivered to <code>BundleListener</code>s.
- *
- * @see Bundle#start()
- * @since 1.3
- */
- public final static int STARTING = 0x00000080;
-
- /**
- * The bundle is about to deactivated.
- * <p>
- * The bundle's
- * {@link BundleActivator#stop(BundleContext) BundleActivator stop} method
- * is about to be called if the bundle has a bundle activator class. This
- * event is only delivered to {@link SynchronousBundleListener}s. It is not
- * delivered to <code>BundleListener</code>s.
- *
- * @see Bundle#stop()
- * @since 1.3
- */
- public final static int STOPPING = 0x00000100;
-
- /**
- * The bundle will be lazily activated.
- * <p>
- * The bundle has a {@link Constants#ACTIVATION_LAZY lazy activation policy}
- * and is waiting to be activated. It is now in the
- * {@link Bundle#STARTING STARTING} state and has a valid
- * <code>BundleContext</code>. This event is only delivered to
- * {@link SynchronousBundleListener}s. It is not delivered to
- * <code>BundleListener</code>s.
- *
- * @since 1.4
- */
- public final static int LAZY_ACTIVATION = 0x00000200;
-
- /**
- * Creates a bundle event of the specified type.
- *
- * @param type The event type.
- * @param bundle The bundle which had a lifecycle change.
- */
-
- public BundleEvent(int type, Bundle bundle) {
- super(bundle);
- this.bundle = bundle;
- this.type = type;
- }
-
- /**
- * Returns the bundle which had a lifecycle change. This bundle is the
- * source of the event.
- *
- * @return The bundle that had a change occur in its lifecycle.
- */
- public Bundle getBundle() {
- return bundle;
- }
-
- /**
- * Returns the type of lifecyle event. The type values are:
- * <ul>
- * <li>{@link #INSTALLED}
- * <li>{@link #RESOLVED}
- * <li>{@link #LAZY_ACTIVATION}
- * <li>{@link #STARTING}
- * <li>{@link #STARTED}
- * <li>{@link #STOPPING}
- * <li>{@link #STOPPED}
- * <li>{@link #UPDATED}
- * <li>{@link #UNRESOLVED}
- * <li>{@link #UNINSTALLED}
- * </ul>
- *
- * @return The type of lifecycle event.
- */
-
- public int getType() {
- return type;
- }
-}
diff --git a/org.osgi.core/src/main/java/org/osgi/framework/BundleException.java b/org.osgi.core/src/main/java/org/osgi/framework/BundleException.java
deleted file mode 100644
index 500d147..0000000
--- a/org.osgi.core/src/main/java/org/osgi/framework/BundleException.java
+++ /dev/null
@@ -1,218 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2000, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.osgi.framework;
-
-/**
- * A Framework exception used to indicate that a bundle lifecycle problem
- * occurred.
- *
- * <p>
- * A <code>BundleException</code> object is created by the Framework to denote
- * an exception condition in the lifecycle of a bundle.
- * <code>BundleException</code>s should not be created by bundle developers.
- * A type code is used to identify the exception type for future extendability.
- *
- * <p>
- * OSGi Alliance reserves the right to extend the set of types.
- *
- * <p>
- * This exception conforms to the general purpose exception chaining mechanism.
- *
- * @version $Revision: 6083 $
- */
-
-public class BundleException extends Exception {
- static final long serialVersionUID = 3571095144220455665L;
- /**
- * Type of bundle exception.
- *
- * @since 1.5
- */
- private final int type;
-
- /**
- * No exception type is unspecified.
- *
- * @since 1.5
- */
- public static final int UNSPECIFIED = 0;
- /**
- * The operation was unsupported.
- *
- * @since 1.5
- */
- public static final int UNSUPPORTED_OPERATION = 1;
- /**
- * The operation was invalid.
- *
- * @since 1.5
- */
- public static final int INVALID_OPERATION = 2;
- /**
- * The bundle manifest was in error.
- *
- * @since 1.5
- */
- public static final int MANIFEST_ERROR = 3;
- /**
- * The bundle was not resolved.
- *
- * @since 1.5
- */
- public static final int RESOLVE_ERROR = 4;
- /**
- * The bundle activator was in error.
- *
- * @since 1.5
- */
- public static final int ACTIVATOR_ERROR = 5;
- /**
- * The operation failed due to insufficient permissions.
- *
- * @since 1.5
- */
- public static final int SECURITY_ERROR = 6;
- /**
- * The operation failed to complete the requested lifecycle state change.
- *
- * @since 1.5
- */
- public static final int STATECHANGE_ERROR = 7;
-
- /**
- * The bundle could not be resolved due to an error with the
- * Bundle-NativeCode header.
- *
- * @since 1.5
- */
- public static final int NATIVECODE_ERROR = 8;
-
- /**
- * The install or update operation failed because another
- * already installed bundle has the same symbolic name and version.
- * @since 1.5
- */
- public static final int DUPLICATE_BUNDLE_ERROR = 9;
-
- /**
- * The start transient operation failed because the start level of the
- * bundle is greater than the current framework start level
- *
- * @since 1.5
- */
- public static final int START_TRANSIENT_ERROR = 10;
-
- /**
- * Creates a <code>BundleException</code> with the specified message and
- * exception cause.
- *
- * @param msg The associated message.
- * @param cause The cause of this exception.
- */
- public BundleException(String msg, Throwable cause) {
- this(msg, UNSPECIFIED, cause);
- }
-
- /**
- * Creates a <code>BundleException</code> with the specified message.
- *
- * @param msg The message.
- */
- public BundleException(String msg) {
- this(msg, UNSPECIFIED);
- }
-
- /**
- * Creates a <code>BundleException</code> with the specified message, type
- * and exception cause.
- *
- * @param msg The associated message.
- * @param type The type for this exception.
- * @param cause The cause of this exception.
- * @since 1.5
- */
- public BundleException(String msg, int type, Throwable cause) {
- super(msg, cause);
- this.type = type;
- }
-
- /**
- * Creates a <code>BundleException</code> with the specified message and
- * type.
- *
- * @param msg The message.
- * @param type The type for this exception.
- * @since 1.5
- */
- public BundleException(String msg, int type) {
- super(msg);
- this.type = type;
- }
-
- /**
- * Returns the cause of this exception or <code>null</code> if no cause was
- * specified when this exception was created.
- *
- * <p>
- * This method predates the general purpose exception chaining mechanism.
- * The <code>getCause()</code> method is now the preferred means of
- * obtaining this information.
- *
- * @return The result of calling <code>getCause()</code>.
- */
- public Throwable getNestedException() {
- return getCause();
- }
-
- /**
- * Returns the cause of this exception or <code>null</code> if no cause was
- * set.
- *
- * @return The cause of this exception or <code>null</code> if no cause was
- * set.
- * @since 1.3
- */
- public Throwable getCause() {
- return super.getCause();
- }
-
- /**
- * Initializes the cause of this exception to the specified value.
- *
- * @param cause The cause of this exception.
- * @return This exception.
- * @throws IllegalArgumentException If the specified cause is this
- * exception.
- * @throws IllegalStateException If the cause of this exception has already
- * been set.
- * @since 1.3
- */
- public Throwable initCause(Throwable cause) {
- return super.initCause(cause);
- }
-
- /**
- * Returns the type for this exception or <code>UNSPECIFIED</code> if the
- * type was unspecified or unknown.
- *
- * @return The type of this exception.
- * @since 1.5
- */
- public int getType() {
- return type;
- }
-}
diff --git a/org.osgi.core/src/main/java/org/osgi/framework/BundleListener.java b/org.osgi.core/src/main/java/org/osgi/framework/BundleListener.java
deleted file mode 100644
index 9dd7151..0000000
--- a/org.osgi.core/src/main/java/org/osgi/framework/BundleListener.java
+++ /dev/null
@@ -1,47 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2000, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.osgi.framework;
-
-import java.util.EventListener;
-
-/**
- * A <code>BundleEvent</code> listener. <code>BundleListener</code> is a
- * listener interface that may be implemented by a bundle developer. When a
- * <code>BundleEvent</code> is fired, it is asynchronously delivered to a
- * <code>BundleListener</code>. The Framework delivers
- * <code>BundleEvent</code> objects to a <code>BundleListener</code> in
- * order and must not concurrently call a <code>BundleListener</code>.
- * <p>
- * A <code>BundleListener</code> object is registered with the Framework using
- * the {@link BundleContext#addBundleListener} method.
- * <code>BundleListener</code>s are called with a <code>BundleEvent</code>
- * object when a bundle has been installed, resolved, started, stopped, updated,
- * unresolved, or uninstalled.
- *
- * @see BundleEvent
- * @NotThreadSafe
- * @version $Revision: 5673 $
- */
-
-public interface BundleListener extends EventListener {
- /**
- * Receives notification that a bundle has had a lifecycle change.
- *
- * @param event The <code>BundleEvent</code>.
- */
- public void bundleChanged(BundleEvent event);
-}
diff --git a/org.osgi.core/src/main/java/org/osgi/framework/BundlePermission.java b/org.osgi.core/src/main/java/org/osgi/framework/BundlePermission.java
deleted file mode 100644
index 8677e69..0000000
--- a/org.osgi.core/src/main/java/org/osgi/framework/BundlePermission.java
+++ /dev/null
@@ -1,606 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2004, 2009). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.osgi.framework;
-
-import java.io.IOException;
-import java.io.ObjectInputStream;
-import java.io.ObjectOutputStream;
-import java.io.ObjectStreamField;
-import java.security.BasicPermission;
-import java.security.Permission;
-import java.security.PermissionCollection;
-import java.util.Collections;
-import java.util.Enumeration;
-import java.util.HashMap;
-import java.util.Hashtable;
-import java.util.Map;
-
-/**
- * A bundle's authority to require or provide a bundle or to receive or attach
- * fragments.
- *
- * <p>
- * A bundle symbolic name defines a unique fully qualified name. Wildcards may
- * be used.
- *
- * <pre>
- * name ::= <symbolic name> | <symbolic name ending in ".*"> | *
- * </pre>
- *
- * Examples:
- *
- * <pre>
- * org.osgi.example.bundle
- * org.osgi.example.*
- * *
- * </pre>
- *
- * <p>
- * <code>BundlePermission</code> has four actions: <code>provide</code>,
- * <code>require</code>,<code>host</code>, and <code>fragment</code>. The
- * <code>provide</code> action implies the <code>require</code> action.
- *
- * @since 1.3
- * @ThreadSafe
- * @version $Revision: 6860 $
- */
-
-public final class BundlePermission extends BasicPermission {
-
- private static final long serialVersionUID = 3257846601685873716L;
-
- /**
- * The action string <code>provide</code>. The <code>provide</code> action
- * implies the <code>require</code> action.
- */
- public final static String PROVIDE = "provide";
-
- /**
- * The action string <code>require</code>. The <code>require</code> action
- * is implied by the <code>provide</code> action.
- */
- public final static String REQUIRE = "require";
-
- /**
- * The action string <code>host</code>.
- */
- public final static String HOST = "host";
-
- /**
- * The action string <code>fragment</code>.
- */
- public final static String FRAGMENT = "fragment";
-
- private final static int ACTION_PROVIDE = 0x00000001;
- private final static int ACTION_REQUIRE = 0x00000002;
- private final static int ACTION_HOST = 0x00000004;
- private final static int ACTION_FRAGMENT = 0x00000008;
- private final static int ACTION_ALL = ACTION_PROVIDE
- | ACTION_REQUIRE
- | ACTION_HOST
- | ACTION_FRAGMENT;
- final static int ACTION_NONE = 0;
- /**
- * The actions mask.
- */
- private transient int action_mask;
-
- /**
- * The actions in canonical form.
- *
- * @serial
- */
- private volatile String actions = null;
-
- /**
- * Defines the authority to provide and/or require and or specify a host
- * fragment symbolic name within the OSGi environment.
- * <p>
- * Bundle Permissions are granted over all possible versions of a bundle.
- *
- * A bundle that needs to provide a bundle must have the appropriate
- * <code>BundlePermission</code> for the symbolic name; a bundle that
- * requires a bundle must have the appropriate <code>BundlePermssion</code>
- * for that symbolic name; a bundle that specifies a fragment host must have
- * the appropriate <code>BundlePermission</code> for that symbolic name.
- *
- * @param symbolicName The bundle symbolic name.
- * @param actions <code>provide</code>,<code>require</code>,
- * <code>host</code>,<code>fragment</code> (canonical order).
- */
- public BundlePermission(String symbolicName, String actions) {
- this(symbolicName, parseActions(actions));
- }
-
- /**
- * Package private constructor used by BundlePermissionCollection.
- *
- * @param symbolicName the bundle symbolic name
- * @param mask the action mask
- */
- BundlePermission(String symbolicName, int mask) {
- super(symbolicName);
- setTransients(mask);
- }
-
- /**
- * Called by constructors and when deserialized.
- *
- * @param mask
- */
- private synchronized void setTransients(int mask) {
- if ((mask == ACTION_NONE) || ((mask & ACTION_ALL) != mask)) {
- throw new IllegalArgumentException("invalid action string");
- }
-
- action_mask = mask;
- }
-
- /**
- * Returns the current action mask.
- * <p>
- * Used by the BundlePermissionCollection class.
- *
- * @return Current action mask.
- */
- synchronized int getActionsMask() {
- return action_mask;
- }
-
- /**
- * Parse action string into action mask.
- *
- * @param actions Action string.
- * @return action mask.
- */
- private static int parseActions(String actions) {
- boolean seencomma = false;
-
- int mask = ACTION_NONE;
-
- if (actions == null) {
- return mask;
- }
-
- char[] a = actions.toCharArray();
-
- int i = a.length - 1;
- if (i < 0)
- return mask;
-
- while (i != -1) {
- char c;
-
- // skip whitespace
- while ((i != -1)
- && ((c = a[i]) == ' ' || c == '\r' || c == '\n'
- || c == '\f' || c == '\t'))
- i--;
-
- // check for the known strings
- int matchlen;
-
- if (i >= 6 && (a[i - 6] == 'p' || a[i - 6] == 'P')
- && (a[i - 5] == 'r' || a[i - 5] == 'R')
- && (a[i - 4] == 'o' || a[i - 4] == 'O')
- && (a[i - 3] == 'v' || a[i - 3] == 'V')
- && (a[i - 2] == 'i' || a[i - 2] == 'I')
- && (a[i - 1] == 'd' || a[i - 1] == 'D')
- && (a[i] == 'e' || a[i] == 'E')) {
- matchlen = 7;
- mask |= ACTION_PROVIDE | ACTION_REQUIRE;
- }
- else
- if (i >= 6 && (a[i - 6] == 'r' || a[i - 6] == 'R')
- && (a[i - 5] == 'e' || a[i - 5] == 'E')
- && (a[i - 4] == 'q' || a[i - 4] == 'Q')
- && (a[i - 3] == 'u' || a[i - 3] == 'U')
- && (a[i - 2] == 'i' || a[i - 2] == 'I')
- && (a[i - 1] == 'r' || a[i - 1] == 'R')
- && (a[i] == 'e' || a[i] == 'E')) {
- matchlen = 7;
- mask |= ACTION_REQUIRE;
- }
- else
- if (i >= 3 && (a[i - 3] == 'h' || a[i - 3] == 'H')
- && (a[i - 2] == 'o' || a[i - 2] == 'O')
- && (a[i - 1] == 's' || a[i - 1] == 'S')
- && (a[i] == 't' || a[i] == 'T')) {
- matchlen = 4;
- mask |= ACTION_HOST;
- }
- else
- if (i >= 7 && (a[i - 7] == 'f' || a[i - 7] == 'F')
- && (a[i - 6] == 'r' || a[i - 6] == 'R')
- && (a[i - 5] == 'a' || a[i - 5] == 'A')
- && (a[i - 4] == 'g' || a[i - 4] == 'G')
- && (a[i - 3] == 'm' || a[i - 3] == 'M')
- && (a[i - 2] == 'e' || a[i - 2] == 'E')
- && (a[i - 1] == 'n' || a[i - 1] == 'N')
- && (a[i] == 't' || a[i] == 'T')) {
- matchlen = 8;
- mask |= ACTION_FRAGMENT;
- }
- else {
- // parse error
- throw new IllegalArgumentException(
- "invalid permission: " + actions);
- }
-
- // make sure we didn't just match the tail of a word
- // like "ackbarfrequire". Also, skip to the comma.
- seencomma = false;
- while (i >= matchlen && !seencomma) {
- switch (a[i - matchlen]) {
- case ',' :
- seencomma = true;
- /* FALLTHROUGH */
- case ' ' :
- case '\r' :
- case '\n' :
- case '\f' :
- case '\t' :
- break;
- default :
- throw new IllegalArgumentException(
- "invalid permission: " + actions);
- }
- i--;
- }
-
- // point i at the location of the comma minus one (or -1).
- i -= matchlen;
- }
-
- if (seencomma) {
- throw new IllegalArgumentException("invalid permission: " + actions);
- }
-
- return mask;
- }
-
- /**
- * Determines if the specified permission is implied by this object.
- *
- * <p>
- * This method checks that the symbolic name of the target is implied by the
- * symbolic name of this object. The list of <code>BundlePermission</code>
- * actions must either match or allow for the list of the target object to
- * imply the target <code>BundlePermission</code> action.
- * <p>
- * The permission to provide a bundle implies the permission to require the
- * named symbolic name.
- *
- * <pre>
- * x.y.*,"provide" -> x.y.z,"provide" is true
- * *,"require" -> x.y, "require" is true
- * *,"provide" -> x.y, "require" is true
- * x.y,"provide" -> x.y.z, "provide" is false
- * </pre>
- *
- * @param p The requested permission.
- * @return <code>true</code> if the specified <code>BundlePermission</code>
- * action is implied by this object; <code>false</code> otherwise.
- */
- public boolean implies(Permission p) {
- if (!(p instanceof BundlePermission)) {
- return false;
- }
- BundlePermission requested = (BundlePermission) p;
-
- final int effective = getActionsMask();
- final int desired = requested.getActionsMask();
- return ((effective & desired) == desired)
- && super.implies(requested);
- }
-
- /**
- * Returns the canonical string representation of the
- * <code>BundlePermission</code> actions.
- *
- * <p>
- * Always returns present <code>BundlePermission</code> actions in the
- * following order: <code>provide</code>, <code>require</code>,
- * <code>host</code>, <code>fragment</code>.
- *
- * @return Canonical string representation of the <code>BundlePermission
- * </code> actions.
- */
- public String getActions() {
- String result = actions;
- if (result == null) {
- StringBuffer sb = new StringBuffer();
- boolean comma = false;
-
- if ((action_mask & ACTION_PROVIDE) == ACTION_PROVIDE) {
- sb.append(PROVIDE);
- comma = true;
- }
-
- if ((action_mask & ACTION_REQUIRE) == ACTION_REQUIRE) {
- if (comma)
- sb.append(',');
- sb.append(REQUIRE);
- comma = true;
- }
-
- if ((action_mask & ACTION_HOST) == ACTION_HOST) {
- if (comma)
- sb.append(',');
- sb.append(HOST);
- comma = true;
- }
-
- if ((action_mask & ACTION_FRAGMENT) == ACTION_FRAGMENT) {
- if (comma)
- sb.append(',');
- sb.append(FRAGMENT);
- }
-
- actions = result = sb.toString();
- }
- return result;
- }
-
- /**
- * Returns a new <code>PermissionCollection</code> object suitable for
- * storing <code>BundlePermission</code> objects.
- *
- * @return A new <code>PermissionCollection</code> object.
- */
- public PermissionCollection newPermissionCollection() {
- return new BundlePermissionCollection();
- }
-
- /**
- * Determines the equality of two <code>BundlePermission</code> objects.
- *
- * This method checks that specified bundle has the same bundle symbolic
- * name and <code>BundlePermission</code> actions as this
- * <code>BundlePermission</code> object.
- *
- * @param obj The object to test for equality with this
- * <code>BundlePermission</code> object.
- * @return <code>true</code> if <code>obj</code> is a
- * <code>BundlePermission</code>, and has the same bundle symbolic
- * name and actions as this <code>BundlePermission</code> object;
- * <code>false</code> otherwise.
- */
- public boolean equals(Object obj) {
- if (obj == this) {
- return true;
- }
-
- if (!(obj instanceof BundlePermission)) {
- return false;
- }
-
- BundlePermission bp = (BundlePermission) obj;
-
- return (getActionsMask() == bp.getActionsMask())
- && getName().equals(bp.getName());
- }
-
- /**
- * Returns the hash code value for this object.
- *
- * @return A hash code value for this object.
- */
- public int hashCode() {
- int h = 31 * 17 + getName().hashCode();
- h = 31 * h + getActions().hashCode();
- return h;
- }
-
- /**
- * WriteObject is called to save the state of the
- * <code>BundlePermission</code> object to a stream. The actions are
- * serialized, and the superclass takes care of the name.
- */
- private synchronized void writeObject(java.io.ObjectOutputStream s)
- throws IOException {
- // Write out the actions. The superclass takes care of the name
- // call getActions to make sure actions field is initialized
- if (actions == null)
- getActions();
- s.defaultWriteObject();
- }
-
- /**
- * readObject is called to restore the state of the BundlePermission from a
- * stream.
- */
- private synchronized void readObject(java.io.ObjectInputStream s)
- throws IOException, ClassNotFoundException {
- // Read in the action, then initialize the rest
- s.defaultReadObject();
- setTransients(parseActions(actions));
- }
-}
-
-/**
- * Stores a set of <code>BundlePermission</code> permissions.
- *
- * @see java.security.Permission
- * @see java.security.Permissions
- * @see java.security.PermissionCollection
- */
-
-final class BundlePermissionCollection extends PermissionCollection {
- private static final long serialVersionUID = 3258407326846433079L;
-
- /**
- * Table of permissions.
- *
- * @GuardedBy this
- */
- private transient Map permissions;
-
- /**
- * Boolean saying if "*" is in the collection.
- *
- * @serial
- * @GuardedBy this
- */
- private boolean all_allowed;
-
- /**
- * Create an empty BundlePermissions object.
- *
- */
- public BundlePermissionCollection() {
- permissions = new HashMap();
- all_allowed = false;
- }
-
- /**
- * Add a permission to this permission collection.
- *
- * @param permission The <code>BundlePermission</code> object to add.
- * @throws IllegalArgumentException If the permission is not a
- * <code>BundlePermission</code> instance.
- * @throws SecurityException If this <code>BundlePermissionCollection</code>
- * object has been marked read-only.
- */
- public void add(final Permission permission) {
- if (!(permission instanceof BundlePermission)) {
- throw new IllegalArgumentException("invalid permission: "
- + permission);
- }
- if (isReadOnly()) {
- throw new SecurityException("attempt to add a Permission to a "
- + "readonly PermissionCollection");
- }
- final BundlePermission bp = (BundlePermission) permission;
- final String name = bp.getName();
- synchronized (this) {
- Map pc = permissions;
- BundlePermission existing = (BundlePermission) pc.get(name);
- if (existing != null) {
- final int oldMask = existing.getActionsMask();
- final int newMask = bp.getActionsMask();
- if (oldMask != newMask) {
- pc.put(name, new BundlePermission(name, oldMask
- | newMask));
-
- }
- }
- else {
- pc.put(name, bp);
- }
-
- if (!all_allowed) {
- if (name.equals("*"))
- all_allowed = true;
- }
- }
- }
-
- /**
- * Determines if the specified permissions implies the permissions expressed
- * in <code>permission</code>.
- *
- * @param permission The Permission object to compare with this
- * <code>BundlePermission</code> object.
- * @return <code>true</code> if <code>permission</code> is a proper subset
- * of a permission in the set; <code>false</code> otherwise.
- */
- public boolean implies(final Permission permission) {
- if (!(permission instanceof BundlePermission)) {
- return false;
- }
- BundlePermission requested = (BundlePermission) permission;
- String requestedName = requested.getName();
- final int desired = requested.getActionsMask();
- int effective = BundlePermission.ACTION_NONE;
- BundlePermission bp;
-
- synchronized (this) {
- Map pc = permissions;
- /* short circuit if the "*" Permission was added */
- if (all_allowed) {
- bp = (BundlePermission) pc.get("*");
- if (bp != null) {
- effective |= bp.getActionsMask();
- if ((effective & desired) == desired) {
- return true;
- }
- }
- }
- bp = (BundlePermission) pc.get(requestedName);
- // strategy:
- // Check for full match first. Then work our way up the
- // name looking for matches on a.b.*
- if (bp != null) {
- // we have a direct hit!
- effective |= bp.getActionsMask();
- if ((effective & desired) == desired) {
- return true;
- }
- }
- // work our way up the tree...
- int last;
- int offset = requestedName.length() - 1;
- while ((last = requestedName.lastIndexOf(".", offset)) != -1) {
- requestedName = requestedName.substring(0, last + 1) + "*";
- bp = (BundlePermission) pc.get(requestedName);
- if (bp != null) {
- effective |= bp.getActionsMask();
- if ((effective & desired) == desired) {
- return true;
- }
- }
- offset = last - 1;
- }
- // we don't have to check for "*" as it was already checked
- // at the top (all_allowed), so we just return false
- return false;
- }
- }
-
- /**
- * Returns an enumeration of all <code>BundlePermission</code> objects in
- * the container.
- *
- * @return Enumeration of all <code>BundlePermission</code> objects.
- */
- public synchronized Enumeration elements() {
- return Collections.enumeration(permissions.values());
- }
-
- /* serialization logic */
- private static final ObjectStreamField[] serialPersistentFields = {
- new ObjectStreamField("permissions", Hashtable.class),
- new ObjectStreamField("all_allowed", Boolean.TYPE) };
-
- private synchronized void writeObject(ObjectOutputStream out)
- throws IOException {
- Hashtable hashtable = new Hashtable(permissions);
- ObjectOutputStream.PutField pfields = out.putFields();
- pfields.put("permissions", hashtable);
- pfields.put("all_allowed", all_allowed);
- out.writeFields();
- }
-
- private synchronized void readObject(java.io.ObjectInputStream in)
- throws IOException, ClassNotFoundException {
- ObjectInputStream.GetField gfields = in.readFields();
- Hashtable hashtable = (Hashtable) gfields.get("permissions", null);
- permissions = new HashMap(hashtable);
- all_allowed = gfields.get("all_allowed", false);
- }
-}
diff --git a/org.osgi.core/src/main/java/org/osgi/framework/BundleReference.java b/org.osgi.core/src/main/java/org/osgi/framework/BundleReference.java
deleted file mode 100644
index f9c4183..0000000
--- a/org.osgi.core/src/main/java/org/osgi/framework/BundleReference.java
+++ /dev/null
@@ -1,35 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2009). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.osgi.framework;
-
-/**
- * A reference to a Bundle.
- *
- * @since 1.5
- * @ThreadSafe
- * @version $Revision: 6860 $
- */
-public interface BundleReference {
- /**
- * Returns the <code>Bundle</code> object associated with this
- * <code>BundleReference</code>.
- *
- * @return The <code>Bundle</code> object associated with this
- * <code>BundleReference</code>.
- */
- public Bundle getBundle();
-}
diff --git a/org.osgi.core/src/main/java/org/osgi/framework/Configurable.java b/org.osgi.core/src/main/java/org/osgi/framework/Configurable.java
deleted file mode 100644
index b30910c..0000000
--- a/org.osgi.core/src/main/java/org/osgi/framework/Configurable.java
+++ /dev/null
@@ -1,51 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2000, 2009). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.osgi.framework;
-
-/**
- * Supports a configuration object.
- *
- * <p>
- * <code>Configurable</code> is an interface that should be used by a bundle
- * developer in support of a configurable service. Bundles that need to
- * configure a service may test to determine if the service object is an
- * <code>instanceof Configurable</code>.
- *
- * @deprecated As of 1.2. Please use Configuration Admin service.
- * @version $Revision: 6361 $
- */
-public interface Configurable {
- /**
- * Returns this service's configuration object.
- *
- * <p>
- * Services implementing <code>Configurable</code> should take care when
- * returning a service configuration object since this object is probably
- * sensitive.
- * <p>
- * If the Java Runtime Environment supports permissions, it is recommended
- * that the caller is checked for some appropriate permission before
- * returning the configuration object.
- *
- * @return The configuration object for this service.
- * @throws SecurityException If the caller does not have an
- * appropriate permission and the Java Runtime Environment supports
- * permissions.
- * @deprecated As of 1.2. Please use Configuration Admin service.
- */
- public Object getConfigurationObject();
-}
diff --git a/org.osgi.core/src/main/java/org/osgi/framework/Constants.java b/org.osgi.core/src/main/java/org/osgi/framework/Constants.java
deleted file mode 100644
index 16a10d8..0000000
--- a/org.osgi.core/src/main/java/org/osgi/framework/Constants.java
+++ /dev/null
@@ -1,1312 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2000, 2009). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.osgi.framework;
-
-/**
- * Defines standard names for the OSGi environment system properties, service
- * properties, and Manifest header attribute keys.
- *
- * <p>
- * The values associated with these keys are of type
- * <code>String</code>, unless otherwise indicated.
- *
- * @since 1.1
- * @version $Revision: 6552 $
- */
-
-public interface Constants {
- /**
- * Location identifier of the OSGi <i>system bundle </i>, which is defined
- * to be "System Bundle".
- */
- public static final String SYSTEM_BUNDLE_LOCATION = "System Bundle";
-
- /**
- * Alias for the symbolic name of the OSGi <i>system bundle </i>. It is
- * defined to be "system.bundle".
- *
- * @since 1.3
- */
- public static final String SYSTEM_BUNDLE_SYMBOLICNAME = "system.bundle";
-
- /**
- * Manifest header identifying the bundle's category.
- * <p>
- * The attribute value may be retrieved from the <code>Dictionary</code>
- * object returned by the <code>Bundle.getHeaders</code> method.
- */
- public static final String BUNDLE_CATEGORY = "Bundle-Category";
-
- /**
- * Manifest header identifying a list of directories and embedded JAR files,
- * which are bundle resources used to extend the bundle's classpath.
- *
- * <p>
- * The attribute value may be retrieved from the <code>Dictionary</code>
- * object returned by the <code>Bundle.getHeaders</code> method.
- */
- public static final String BUNDLE_CLASSPATH = "Bundle-ClassPath";
-
- /**
- * Manifest header identifying the bundle's copyright information.
- * <p>
- * The attribute value may be retrieved from the <code>Dictionary</code>
- * object returned by the <code>Bundle.getHeaders</code> method.
- */
- public static final String BUNDLE_COPYRIGHT = "Bundle-Copyright";
-
- /**
- * Manifest header containing a brief description of the bundle's
- * functionality.
- * <p>
- * The attribute value may be retrieved from the <code>Dictionary</code>
- * object returned by the <code>Bundle.getHeaders</code> method.
- */
- public static final String BUNDLE_DESCRIPTION = "Bundle-Description";
-
- /**
- * Manifest header identifying the bundle's name.
- * <p>
- * The attribute value may be retrieved from the <code>Dictionary</code>
- * object returned by the <code>Bundle.getHeaders</code> method.
- */
- public static final String BUNDLE_NAME = "Bundle-Name";
-
- /**
- * Manifest header identifying a number of hardware environments and the
- * native language code libraries that the bundle is carrying for each of
- * these environments.
- *
- * <p>
- * The attribute value may be retrieved from the <code>Dictionary</code>
- * object returned by the <code>Bundle.getHeaders</code> method.
- */
- public static final String BUNDLE_NATIVECODE = "Bundle-NativeCode";
-
- /**
- * Manifest header identifying the packages that the bundle offers to the
- * Framework for export.
- *
- * <p>
- * The attribute value may be retrieved from the <code>Dictionary</code>
- * object returned by the <code>Bundle.getHeaders</code> method.
- */
- public static final String EXPORT_PACKAGE = "Export-Package";
-
- /**
- * Manifest header identifying the fully qualified class names of the
- * services that the bundle may register (used for informational purposes
- * only).
- *
- * <p>
- * The attribute value may be retrieved from the <code>Dictionary</code>
- * object returned by the <code>Bundle.getHeaders</code> method.
- *
- * @deprecated As of 1.2.
- */
- public static final String EXPORT_SERVICE = "Export-Service";
-
- /**
- * Manifest header identifying the packages on which the bundle depends.
- *
- * <p>
- * The attribute value may be retrieved from the <code>Dictionary</code>
- * object returned by the <code>Bundle.getHeaders</code> method.
- */
- public static final String IMPORT_PACKAGE = "Import-Package";
-
- /**
- * Manifest header identifying the packages that the bundle may dynamically
- * import during execution.
- *
- * <p>
- * The attribute value may be retrieved from the <code>Dictionary</code>
- * object returned by the <code>Bundle.getHeaders</code> method.
- *
- * @since 1.2
- */
- public static final String DYNAMICIMPORT_PACKAGE = "DynamicImport-Package";
-
- /**
- * Manifest header identifying the fully qualified class names of the
- * services that the bundle requires (used for informational purposes only).
- *
- * <p>
- * The attribute value may be retrieved from the <code>Dictionary</code>
- * object returned by the <code>Bundle.getHeaders</code> method.
- *
- * @deprecated As of 1.2.
- */
- public static final String IMPORT_SERVICE = "Import-Service";
-
- /**
- * Manifest header identifying the bundle's vendor.
- *
- * <p>
- * The attribute value may be retrieved from the <code>Dictionary</code>
- * object returned by the <code>Bundle.getHeaders</code> method.
- */
- public static final String BUNDLE_VENDOR = "Bundle-Vendor";
-
- /**
- * Manifest header identifying the bundle's version.
- *
- * <p>
- * The attribute value may be retrieved from the <code>Dictionary</code>
- * object returned by the <code>Bundle.getHeaders</code> method.
- */
- public static final String BUNDLE_VERSION = "Bundle-Version";
-
- /**
- * Manifest header identifying the bundle's documentation URL, from which
- * further information about the bundle may be obtained.
- *
- * <p>
- * The attribute value may be retrieved from the <code>Dictionary</code>
- * object returned by the <code>Bundle.getHeaders</code> method.
- */
- public static final String BUNDLE_DOCURL = "Bundle-DocURL";
-
- /**
- * Manifest header identifying the contact address where problems with the
- * bundle may be reported; for example, an email address.
- *
- * <p>
- * The attribute value may be retrieved from the <code>Dictionary</code>
- * object returned by the <code>Bundle.getHeaders</code> method.
- */
- public static final String BUNDLE_CONTACTADDRESS = "Bundle-ContactAddress";
-
- /**
- * Manifest header attribute identifying the bundle's activator class.
- *
- * <p>
- * If present, this header specifies the name of the bundle resource class
- * that implements the <code>BundleActivator</code> interface and whose
- * <code>start</code> and <code>stop</code> methods are called by the
- * Framework when the bundle is started and stopped, respectively.
- *
- * <p>
- * The attribute value may be retrieved from the <code>Dictionary</code>
- * object returned by the <code>Bundle.getHeaders</code> method.
- */
- public static final String BUNDLE_ACTIVATOR = "Bundle-Activator";
-
- /**
- * Manifest header identifying the location from which a new bundle version
- * is obtained during a bundle update operation.
- *
- * <p>
- * The attribute value may be retrieved from the <code>Dictionary</code>
- * object returned by the <code>Bundle.getHeaders</code> method.
- */
- public static final String BUNDLE_UPDATELOCATION = "Bundle-UpdateLocation";
-
- /**
- * Manifest header attribute identifying the version of a package specified
- * in the Export-Package or Import-Package manifest header.
- *
- * @deprecated As of 1.3. This has been replaced by
- * {@link #VERSION_ATTRIBUTE}.
- */
- public static final String PACKAGE_SPECIFICATION_VERSION = "specification-version";
-
- /**
- * Manifest header attribute identifying the processor required to run
- * native bundle code specified in the Bundle-NativeCode manifest header).
- *
- * <p>
- * The attribute value is encoded in the Bundle-NativeCode manifest header
- * like:
- *
- * <pre>
- * Bundle-NativeCode: http.so ; processor=x86 ...
- * </pre>
- *
- * @see #BUNDLE_NATIVECODE
- */
- public static final String BUNDLE_NATIVECODE_PROCESSOR = "processor";
-
- /**
- * Manifest header attribute identifying the operating system required to
- * run native bundle code specified in the Bundle-NativeCode manifest
- * header).
- * <p>
- * The attribute value is encoded in the Bundle-NativeCode manifest header
- * like:
- *
- * <pre>
- * Bundle-NativeCode: http.so ; osname=Linux ...
- * </pre>
- *
- * @see #BUNDLE_NATIVECODE
- */
- public static final String BUNDLE_NATIVECODE_OSNAME = "osname";
-
- /**
- * Manifest header attribute identifying the operating system version
- * required to run native bundle code specified in the Bundle-NativeCode
- * manifest header).
- * <p>
- * The attribute value is encoded in the Bundle-NativeCode manifest header
- * like:
- *
- * <pre>
- * Bundle-NativeCode: http.so ; osversion="2.34" ...
- * </pre>
- *
- * @see #BUNDLE_NATIVECODE
- */
- public static final String BUNDLE_NATIVECODE_OSVERSION = "osversion";
-
- /**
- * Manifest header attribute identifying the language in which the native
- * bundle code is written specified in the Bundle-NativeCode manifest
- * header. See ISO 639 for possible values.
- * <p>
- * The attribute value is encoded in the Bundle-NativeCode manifest header
- * like:
- *
- * <pre>
- * Bundle-NativeCode: http.so ; language=nl_be ...
- * </pre>
- *
- * @see #BUNDLE_NATIVECODE
- */
- public static final String BUNDLE_NATIVECODE_LANGUAGE = "language";
-
- /**
- * Manifest header identifying the required execution environment for the
- * bundle. The service platform may run this bundle if any of the execution
- * environments named in this header matches one of the execution
- * environments it implements.
- *
- * <p>
- * The attribute value may be retrieved from the <code>Dictionary</code>
- * object returned by the <code>Bundle.getHeaders</code> method.
- *
- * @since 1.2
- */
- public static final String BUNDLE_REQUIREDEXECUTIONENVIRONMENT = "Bundle-RequiredExecutionEnvironment";
-
- /**
- * Manifest header identifying the bundle's symbolic name.
- *
- * <p>
- * The attribute value may be retrieved from the <code>Dictionary</code>
- * object returned by the <code>Bundle.getHeaders</code> method.
- *
- * @since 1.3
- */
- public final static String BUNDLE_SYMBOLICNAME = "Bundle-SymbolicName";
-
- /**
- * Manifest header directive identifying whether a bundle is a singleton.
- * The default value is <code>false</code>.
- *
- * <p>
- * The directive value is encoded in the Bundle-SymbolicName manifest header
- * like:
- *
- * <pre>
- * Bundle-SymbolicName: com.acme.module.test; singleton:=true
- * </pre>
- *
- * <p>
- * The attribute value may be retrieved from the <code>Dictionary</code>
- * object returned by the <code>Bundle.getHeaders</code> method.
- *
- * @see #BUNDLE_SYMBOLICNAME
- * @since 1.3
- */
- public final static String SINGLETON_DIRECTIVE = "singleton";
-
- /**
- * Manifest header directive identifying if and when a fragment may attach
- * to a host bundle. The default value is
- * {@link #FRAGMENT_ATTACHMENT_ALWAYS always}.
- *
- * <p>
- * The directive value is encoded in the Bundle-SymbolicName manifest header
- * like:
- *
- * <pre>
- * Bundle-SymbolicName: com.acme.module.test; fragment-attachment:="never"
- * </pre>
- *
- * @see #BUNDLE_SYMBOLICNAME
- * @see #FRAGMENT_ATTACHMENT_ALWAYS
- * @see #FRAGMENT_ATTACHMENT_RESOLVETIME
- * @see #FRAGMENT_ATTACHMENT_NEVER
- * @since 1.3
- */
- public final static String FRAGMENT_ATTACHMENT_DIRECTIVE = "fragment-attachment";
-
- /**
- * Manifest header directive value identifying a fragment attachment type of
- * always. A fragment attachment type of always indicates that fragments are
- * allowed to attach to the host bundle at any time (while the host is
- * resolved or during the process of resolving the host bundle).
- *
- * <p>
- * The directive value is encoded in the Bundle-SymbolicName manifest header
- * like:
- *
- * <pre>
- * Bundle-SymbolicName: com.acme.module.test; fragment-attachment:="always"
- * </pre>
- *
- * @see #FRAGMENT_ATTACHMENT_DIRECTIVE
- * @since 1.3
- */
- public final static String FRAGMENT_ATTACHMENT_ALWAYS = "always";
-
- /**
- * Manifest header directive value identifying a fragment attachment type of
- * resolve-time. A fragment attachment type of resolve-time indicates that
- * fragments are allowed to attach to the host bundle only during the
- * process of resolving the host bundle.
- *
- * <p>
- * The directive value is encoded in the Bundle-SymbolicName manifest header
- * like:
- *
- * <pre>
- * Bundle-SymbolicName: com.acme.module.test; fragment-attachment:="resolve-time"
- * </pre>
- *
- * @see #FRAGMENT_ATTACHMENT_DIRECTIVE
- * @since 1.3
- */
- public final static String FRAGMENT_ATTACHMENT_RESOLVETIME = "resolve-time";
-
- /**
- * Manifest header directive value identifying a fragment attachment type of
- * never. A fragment attachment type of never indicates that no fragments
- * are allowed to attach to the host bundle at any time.
- *
- * <p>
- * The directive value is encoded in the Bundle-SymbolicName manifest header
- * like:
- *
- * <pre>
- * Bundle-SymbolicName: com.acme.module.test; fragment-attachment:="never"
- * </pre>
- *
- * @see #FRAGMENT_ATTACHMENT_DIRECTIVE
- * @since 1.3
- */
- public final static String FRAGMENT_ATTACHMENT_NEVER = "never";
-
- /**
- * Manifest header identifying the base name of the bundle's localization
- * entries.
- *
- * <p>
- * The attribute value may be retrieved from the <code>Dictionary</code>
- * object returned by the <code>Bundle.getHeaders</code> method.
- *
- * @see #BUNDLE_LOCALIZATION_DEFAULT_BASENAME
- * @since 1.3
- */
- public final static String BUNDLE_LOCALIZATION = "Bundle-Localization";
-
- /**
- * Default value for the <code>Bundle-Localization</code> manifest header.
- *
- * @see #BUNDLE_LOCALIZATION
- * @since 1.3
- */
- public final static String BUNDLE_LOCALIZATION_DEFAULT_BASENAME = "OSGI-INF/l10n/bundle";
-
- /**
- * Manifest header identifying the symbolic names of other bundles required
- * by the bundle.
- *
- * <p>
- * The attribute value may be retrieved from the <code>Dictionary</code>
- * object returned by the <code>Bundle.getHeaders</code> method.
- *
- * @since 1.3
- */
- public final static String REQUIRE_BUNDLE = "Require-Bundle";
-
- /**
- * Manifest header attribute identifying a range of versions for a bundle
- * specified in the <code>Require-Bundle</code> or
- * <code>Fragment-Host</code> manifest headers. The default value is
- * <code>0.0.0</code>.
- *
- * <p>
- * The attribute value is encoded in the Require-Bundle manifest header
- * like:
- *
- * <pre>
- * Require-Bundle: com.acme.module.test; bundle-version="1.1"
- * Require-Bundle: com.acme.module.test; bundle-version="[1.0,2.0)"
- * </pre>
- *
- * <p>
- * The bundle-version attribute value uses a mathematical interval notation
- * to specify a range of bundle versions. A bundle-version attribute value
- * specified as a single version means a version range that includes any
- * bundle version greater than or equal to the specified version.
- *
- * @see #REQUIRE_BUNDLE
- * @since 1.3
- */
- public static final String BUNDLE_VERSION_ATTRIBUTE = "bundle-version";
-
- /**
- * Manifest header identifying the symbolic name of another bundle for which
- * that the bundle is a fragment.
- *
- * <p>
- * The attribute value may be retrieved from the <code>Dictionary</code>
- * object returned by the <code>Bundle.getHeaders</code> method.
- *
- * @since 1.3
- */
- public final static String FRAGMENT_HOST = "Fragment-Host";
-
- /**
- * Manifest header attribute is used for selection by filtering based upon
- * system properties.
- *
- * <p>
- * The attribute value is encoded in manifest headers like:
- *
- * <pre>
- * Bundle-NativeCode: libgtk.so; selection-filter="(ws=gtk)"; ...
- * </pre>
- *
- * @see #BUNDLE_NATIVECODE
- * @since 1.3
- */
- public final static String SELECTION_FILTER_ATTRIBUTE = "selection-filter";
-
- /**
- * Manifest header identifying the bundle manifest version. A bundle
- * manifest may express the version of the syntax in which it is written by
- * specifying a bundle manifest version. Bundles exploiting OSGi Release 4,
- * or later, syntax must specify a bundle manifest version.
- * <p>
- * The bundle manifest version defined by OSGi Release 4 or, more
- * specifically, by version 1.3 of the OSGi Core Specification is "2".
- *
- * <p>
- * The attribute value may be retrieved from the <code>Dictionary</code>
- * object returned by the <code>Bundle.getHeaders</code> method.
- *
- * @since 1.3
- */
- public final static String BUNDLE_MANIFESTVERSION = "Bundle-ManifestVersion";
-
- /**
- * Manifest header attribute identifying the version of a package specified
- * in the Export-Package or Import-Package manifest header.
- *
- * <p>
- * The attribute value is encoded in the Export-Package or Import-Package
- * manifest header like:
- *
- * <pre>
- * Import-Package: org.osgi.framework; version="1.1"
- * </pre>
- *
- * @see #EXPORT_PACKAGE
- * @see #IMPORT_PACKAGE
- * @since 1.3
- */
- public final static String VERSION_ATTRIBUTE = "version";
-
- /**
- * Manifest header attribute identifying the symbolic name of a bundle that
- * exports a package specified in the Import-Package manifest header.
- *
- * <p>
- * The attribute value is encoded in the Import-Package manifest header
- * like:
- *
- * <pre>
- * Import-Package: org.osgi.framework; bundle-symbolic-name="com.acme.module.test"
- * </pre>
- *
- * @see #IMPORT_PACKAGE
- * @since 1.3
- */
- public final static String BUNDLE_SYMBOLICNAME_ATTRIBUTE = "bundle-symbolic-name";
-
- /**
- * Manifest header directive identifying the resolution type in the
- * Import-Package or Require-Bundle manifest header. The default value is
- * {@link #RESOLUTION_MANDATORY mandatory}.
- *
- * <p>
- * The directive value is encoded in the Import-Package or Require-Bundle
- * manifest header like:
- *
- * <pre>
- * Import-Package: org.osgi.framework; resolution:="optional"
- * Require-Bundle: com.acme.module.test; resolution:="optional"
- * </pre>
- *
- * @see #IMPORT_PACKAGE
- * @see #REQUIRE_BUNDLE
- * @see #RESOLUTION_MANDATORY
- * @see #RESOLUTION_OPTIONAL
- * @since 1.3
- */
- public final static String RESOLUTION_DIRECTIVE = "resolution";
-
- /**
- * Manifest header directive value identifying a mandatory resolution type.
- * A mandatory resolution type indicates that the import package or require
- * bundle must be resolved when the bundle is resolved. If such an import or
- * require bundle cannot be resolved, the module fails to resolve.
- *
- * <p>
- * The directive value is encoded in the Import-Package or Require-Bundle
- * manifest header like:
- *
- * <pre>
- * Import-Package: org.osgi.framework; resolution:="manditory"
- * Require-Bundle: com.acme.module.test; resolution:="manditory"
- * </pre>
- *
- * @see #RESOLUTION_DIRECTIVE
- * @since 1.3
- */
- public final static String RESOLUTION_MANDATORY = "mandatory";
-
- /**
- * Manifest header directive value identifying an optional resolution type.
- * An optional resolution type indicates that the import or require bundle
- * is optional and the bundle may be resolved without the import or require
- * bundle being resolved. If the import or require bundle is not resolved
- * when the bundle is resolved, the import or require bundle may not be
- * resolved before the bundle is refreshed.
- *
- * <p>
- * The directive value is encoded in the Import-Package or Require-Bundle
- * manifest header like:
- *
- * <pre>
- * Import-Package: org.osgi.framework; resolution:="optional"
- * Require-Bundle: com.acme.module.test; resolution:="optional"
- * </pre>
- *
- * @see #RESOLUTION_DIRECTIVE
- * @since 1.3
- */
- public final static String RESOLUTION_OPTIONAL = "optional";
-
- /**
- * Manifest header directive identifying a list of packages that an exported
- * package uses.
- *
- * <p>
- * The directive value is encoded in the Export-Package manifest header
- * like:
- *
- * <pre>
- * Export-Package: org.osgi.util.tracker; uses:="org.osgi.framework"
- * </pre>
- *
- * @see #EXPORT_PACKAGE
- * @since 1.3
- */
- public final static String USES_DIRECTIVE = "uses";
-
- /**
- * Manifest header directive identifying a list of classes to include in the
- * exported package.
- *
- * <p>
- * This directive is used by the Export-Package manifest header to identify
- * a list of classes of the specified package which must be allowed to be
- * exported. The directive value is encoded in the Export-Package manifest
- * header like:
- *
- * <pre>
- * Export-Package: org.osgi.framework; include:="MyClass*"
- * </pre>
- *
- * <p>
- * This directive is also used by the Bundle-ActivationPolicy manifest
- * header to identify the packages from which class loads will trigger lazy
- * activation. The directive value is encoded in the Bundle-ActivationPolicy
- * manifest header like:
- *
- * <pre>
- * Bundle-ActivationPolicy: lazy; include:="org.osgi.framework"
- * </pre>
- *
- * @see #EXPORT_PACKAGE
- * @see #BUNDLE_ACTIVATIONPOLICY
- * @since 1.3
- */
- public final static String INCLUDE_DIRECTIVE = "include";
-
- /**
- * Manifest header directive identifying a list of classes to exclude in the
- * exported package..
- * <p>
- * This directive is used by the Export-Package manifest header to identify
- * a list of classes of the specified package which must not be allowed to
- * be exported. The directive value is encoded in the Export-Package
- * manifest header like:
- *
- * <pre>
- * Export-Package: org.osgi.framework; exclude:="*Impl"
- * </pre>
- *
- * <p>
- * This directive is also used by the Bundle-ActivationPolicy manifest
- * header to identify the packages from which class loads will not trigger
- * lazy activation. The directive value is encoded in the
- * Bundle-ActivationPolicy manifest header like:
- *
- * <pre>
- * Bundle-ActivationPolicy: lazy; exclude:="org.osgi.framework"
- * </pre>
- *
- * @see #EXPORT_PACKAGE
- * @see #BUNDLE_ACTIVATIONPOLICY
- * @since 1.3
- */
- public final static String EXCLUDE_DIRECTIVE = "exclude";
-
- /**
- * Manifest header directive identifying names of matching attributes which
- * must be specified by matching Import-Package statements in the
- * Export-Package manifest header.
- *
- * <p>
- * The directive value is encoded in the Export-Package manifest header
- * like:
- *
- * <pre>
- * Export-Package: org.osgi.framework; mandatory:="bundle-symbolic-name"
- * </pre>
- *
- * @see #EXPORT_PACKAGE
- * @since 1.3
- */
- public final static String MANDATORY_DIRECTIVE = "mandatory";
-
- /**
- * Manifest header directive identifying the visibility of a required bundle
- * in the Require-Bundle manifest header. The default value is
- * {@link #VISIBILITY_PRIVATE private}.
- *
- * <p>
- * The directive value is encoded in the Require-Bundle manifest header
- * like:
- *
- * <pre>
- * Require-Bundle: com.acme.module.test; visibility:="reexport"
- * </pre>
- *
- * @see #REQUIRE_BUNDLE
- * @see #VISIBILITY_PRIVATE
- * @see #VISIBILITY_REEXPORT
- * @since 1.3
- */
- public final static String VISIBILITY_DIRECTIVE = "visibility";
-
- /**
- * Manifest header directive value identifying a private visibility type. A
- * private visibility type indicates that any packages that are exported by
- * the required bundle are not made visible on the export signature of the
- * requiring bundle.
- *
- * <p>
- * The directive value is encoded in the Require-Bundle manifest header
- * like:
- *
- * <pre>
- * Require-Bundle: com.acme.module.test; visibility:="private"
- * </pre>
- *
- * @see #VISIBILITY_DIRECTIVE
- * @since 1.3
- */
- public final static String VISIBILITY_PRIVATE = "private";
-
- /**
- * Manifest header directive value identifying a reexport visibility type. A
- * reexport visibility type indicates any packages that are exported by the
- * required bundle are re-exported by the requiring bundle. Any arbitrary
- * arbitrary matching attributes with which they were exported by the
- * required bundle are deleted.
- *
- * <p>
- * The directive value is encoded in the Require-Bundle manifest header
- * like:
- *
- * <pre>
- * Require-Bundle: com.acme.module.test; visibility:="reexport"
- * </pre>
- *
- * @see #VISIBILITY_DIRECTIVE
- * @since 1.3
- */
- public final static String VISIBILITY_REEXPORT = "reexport";
-
- /**
- * Manifest header directive identifying the type of the extension fragment.
- *
- * <p>
- * The directive value is encoded in the Fragment-Host manifest header like:
- *
- * <pre>
- * Fragment-Host: system.bundle; extension:="framework"
- * </pre>
- *
- * @see #FRAGMENT_HOST
- * @see #EXTENSION_FRAMEWORK
- * @see #EXTENSION_BOOTCLASSPATH
- * @since 1.3
- */
- public final static String EXTENSION_DIRECTIVE = "extension";
-
- /**
- * Manifest header directive value identifying the type of extension
- * fragment. An extension fragment type of framework indicates that the
- * extension fragment is to be loaded by the framework's class loader.
- *
- * <p>
- * The directive value is encoded in the Fragment-Host manifest header like:
- *
- * <pre>
- * Fragment-Host: system.bundle; extension:="framework"
- * </pre>
- *
- * @see #EXTENSION_DIRECTIVE
- * @since 1.3
- */
- public final static String EXTENSION_FRAMEWORK = "framework";
-
- /**
- * Manifest header directive value identifying the type of extension
- * fragment. An extension fragment type of bootclasspath indicates that the
- * extension fragment is to be loaded by the boot class loader.
- *
- * <p>
- * The directive value is encoded in the Fragment-Host manifest header like:
- *
- * <pre>
- * Fragment-Host: system.bundle; extension:="bootclasspath"
- * </pre>
- *
- * @see #EXTENSION_DIRECTIVE
- * @since 1.3
- */
- public final static String EXTENSION_BOOTCLASSPATH = "bootclasspath";
-
- /**
- * Manifest header identifying the bundle's activation policy.
- * <p>
- * The attribute value may be retrieved from the <code>Dictionary</code>
- * object returned by the <code>Bundle.getHeaders</code> method.
- *
- * @since 1.4
- * @see #ACTIVATION_LAZY
- * @see #INCLUDE_DIRECTIVE
- * @see #EXCLUDE_DIRECTIVE
- */
- public final static String BUNDLE_ACTIVATIONPOLICY = "Bundle-ActivationPolicy";
-
- /**
- * Bundle activation policy declaring the bundle must be activated when the
- * first class load is made from the bundle.
- * <p>
- * A bundle with the lazy activation policy that is started with the
- * {@link Bundle#START_ACTIVATION_POLICY START_ACTIVATION_POLICY} option
- * will wait in the {@link Bundle#STARTING STARTING} state until the first
- * class load from the bundle occurs. The bundle will then be activated
- * before the class is returned to the requester.
- * <p>
- * The activation policy value is specified as in the
- * Bundle-ActivationPolicy manifest header like:
- *
- * <pre>
- * Bundle-ActivationPolicy: lazy
- * </pre>
- *
- * @see #BUNDLE_ACTIVATIONPOLICY
- * @see Bundle#start(int)
- * @see Bundle#START_ACTIVATION_POLICY
- * @since 1.4
- */
- public final static String ACTIVATION_LAZY = "lazy";
-
- /**
- * Framework environment property identifying the Framework version.
- *
- * <p>
- * The value of this property may be retrieved by calling the
- * <code>BundleContext.getProperty</code> method.
- */
- public static final String FRAMEWORK_VERSION = "org.osgi.framework.version";
-
- /**
- * Framework environment property identifying the Framework implementation
- * vendor.
- *
- * <p>
- * The value of this property may be retrieved by calling the
- * <code>BundleContext.getProperty</code> method.
- */
- public static final String FRAMEWORK_VENDOR = "org.osgi.framework.vendor";
-
- /**
- * Framework environment property identifying the Framework implementation
- * language (see ISO 639 for possible values).
- *
- * <p>
- * The value of this property may be retrieved by calling the
- * <code>BundleContext.getProperty</code> method.
- */
- public static final String FRAMEWORK_LANGUAGE = "org.osgi.framework.language";
-
- /**
- * Framework environment property identifying the Framework host-computer's
- * operating system.
- *
- * <p>
- * The value of this property may be retrieved by calling the
- * <code>BundleContext.getProperty</code> method.
- */
- public static final String FRAMEWORK_OS_NAME = "org.osgi.framework.os.name";
-
- /**
- * Framework environment property identifying the Framework host-computer's
- * operating system version number.
- *
- * <p>
- * The value of this property may be retrieved by calling the
- * <code>BundleContext.getProperty</code> method.
- */
- public static final String FRAMEWORK_OS_VERSION = "org.osgi.framework.os.version";
-
- /**
- * Framework environment property identifying the Framework host-computer's
- * processor name.
- *
- * <p>
- * The value of this property may be retrieved by calling the
- * <code>BundleContext.getProperty</code> method.
- */
- public static final String FRAMEWORK_PROCESSOR = "org.osgi.framework.processor";
-
- /**
- * Framework environment property identifying execution environments
- * provided by the Framework.
- *
- * <p>
- * The value of this property may be retrieved by calling the
- * <code>BundleContext.getProperty</code> method.
- *
- * @since 1.2
- */
- public static final String FRAMEWORK_EXECUTIONENVIRONMENT = "org.osgi.framework.executionenvironment";
-
- /**
- * Framework environment property identifying packages for which the
- * Framework must delegate class loading to the parent class loader of the
- * bundle.
- *
- * <p>
- * The value of this property may be retrieved by calling the
- * <code>BundleContext.getProperty</code> method.
- *
- * @see #FRAMEWORK_BUNDLE_PARENT
- * @since 1.3
- */
- public static final String FRAMEWORK_BOOTDELEGATION = "org.osgi.framework.bootdelegation";
-
- /**
- * Framework environment property identifying packages which the system
- * bundle must export.
- *
- * <p>
- * If this property is not specified then the framework must calculate a
- * reasonable default value for the current execution environment.
- *
- * <p>
- * The value of this property may be retrieved by calling the
- * <code>BundleContext.getProperty</code> method.
- *
- * @since 1.3
- */
- public static final String FRAMEWORK_SYSTEMPACKAGES = "org.osgi.framework.system.packages";
-
- /**
- * Framework environment property identifying extra packages which the
- * system bundle must export from the current execution environment.
- *
- * <p>
- * This property is useful for configuring extra system packages in addition
- * to the system packages calculated by the framework.
- *
- * <p>
- * The value of this property may be retrieved by calling the
- * <code>BundleContext.getProperty</code> method.
- *
- * @see #FRAMEWORK_SYSTEMPACKAGES
- * @since 1.5
- */
- public static final String FRAMEWORK_SYSTEMPACKAGES_EXTRA = "org.osgi.framework.system.packages.extra";
-
- /**
- * Framework environment property identifying whether the Framework supports
- * framework extension bundles.
- *
- * <p>
- * As of version 1.4, the value of this property must be <code>true</code>.
- * The Framework must support framework extension bundles.
- *
- * <p>
- * The value of this property may be retrieved by calling the
- * <code>BundleContext.getProperty</code> method.
- *
- * @since 1.3
- */
- public static final String SUPPORTS_FRAMEWORK_EXTENSION = "org.osgi.supports.framework.extension";
-
- /**
- * Framework environment property identifying whether the Framework supports
- * bootclasspath extension bundles.
- *
- * <p>
- * If the value of this property is <code>true</code>, then the Framework
- * supports bootclasspath extension bundles. The default value is
- * <code>false</code>.
- * <p>
- * The value of this property may be retrieved by calling the
- * <code>BundleContext.getProperty</code> method.
- *
- * @since 1.3
- */
- public static final String SUPPORTS_BOOTCLASSPATH_EXTENSION = "org.osgi.supports.bootclasspath.extension";
-
- /**
- * Framework environment property identifying whether the Framework supports
- * fragment bundles.
- *
- * <p>
- * As of version 1.4, the value of this property must be <code>true</code>.
- * The Framework must support fragment bundles.
- * <p>
- * The value of this property may be retrieved by calling the
- * <code>BundleContext.getProperty</code> method.
- *
- * @since 1.3
- */
- public static final String SUPPORTS_FRAMEWORK_FRAGMENT = "org.osgi.supports.framework.fragment";
-
- /**
- * Framework environment property identifying whether the Framework supports
- * the {@link #REQUIRE_BUNDLE Require-Bundle} manifest header.
- *
- * <p>
- * As of version 1.4, the value of this property must be <code>true</code>.
- * The Framework must support the <code>Require-Bundle</code> manifest
- * header.
- * <p>
- * The value of this property may be retrieved by calling the
- * <code>BundleContext.getProperty</code> method.
- *
- * @since 1.3
- */
- public static final String SUPPORTS_FRAMEWORK_REQUIREBUNDLE = "org.osgi.supports.framework.requirebundle";
-
- /**
- * Specifies the type of security manager the framework must use. If not
- * specified then the framework will not set the VM security manager.
- *
- * @see #FRAMEWORK_SECURITY_OSGI
- * @since 1.5
- */
- public final static String FRAMEWORK_SECURITY = "org.osgi.framework.security";
-
- /**
- * Specifies that a security manager that supports all security aspects of
- * the OSGi core specification including postponed conditions must be
- * installed.
- *
- * <p>
- * If this value is specified and there is a security manager already
- * installed, then a <code>SecurityException</code> must be thrown when the
- * Framework is initialized.
- *
- * @see #FRAMEWORK_SECURITY
- * @since 1.5
- */
- public final static String FRAMEWORK_SECURITY_OSGI = "osgi";
-
- /**
- * Specified the persistent storage area used by the framework. The value of
- * this property must be a valid file path in the file system to a
- * directory. If the specified directory does not exist then the framework
- * will create the directory. If the specified path exists but is not a
- * directory or if the framework fails to create the storage directory, then
- * framework initialization must fail. The framework is free to use this
- * directory as it sees fit. This area can not be shared with anything else.
- * <p>
- * If this property is not set, the framework should use a reasonable
- * platform default for the persistent storage area.
- *
- * @since 1.5
- */
- public final static String FRAMEWORK_STORAGE = "org.osgi.framework.storage";
-
- /**
- * Specifies if and when the persistent storage area for the framework
- * should be cleaned. If this property is not set, then the framework
- * storage area must not be cleaned.
- *
- * @see #FRAMEWORK_STORAGE_CLEAN_ONFIRSTINIT
- * @since 1.5
- */
- public final static String FRAMEWORK_STORAGE_CLEAN = "org.osgi.framework.storage.clean";
-
- /**
- * Specifies that the framework storage area must be cleaned before the
- * framework is initialized for the first time. Subsequent inits, starts or
- * updates of the framework will not result in cleaning the framework
- * storage area.
- *
- * @since 1.5
- */
- public final static String FRAMEWORK_STORAGE_CLEAN_ONFIRSTINIT = "onFirstInit";
-
- /**
- * Specifies a comma separated list of additional library file extensions
- * that must be used when a bundle's class loader is searching for native
- * libraries. If this property is not set, then only the library name
- * returned by <code>System.mapLibraryName(String)</code> will be used to
- * search. This is needed for certain operating systems which allow more
- * than one extension for a library. For example, AIX allows library
- * extensions of <code>.a</code> and <code>.so</code>, but
- * <code>System.mapLibraryName(String)</code> will only return names with
- * the <code>.a</code> extension.
- *
- * @since 1.5
- */
- public final static String FRAMEWORK_LIBRARY_EXTENSIONS = "org.osgi.framework.library.extensions";
-
- /**
- * Specifies an optional OS specific command to set file permissions on
- * extracted native code. On some operating systems, it is required that
- * native libraries be set to executable. This optional property allows you
- * to specify the command. For example, on a UNIX style OS, this property
- * could have the following value.
- *
- * <pre>
- * chmod +rx ${abspath}
- * </pre>
- *
- * The <code>${abspath}</code> is used by the framework to substitute the
- * actual absolute file path.
- *
- * @since 1.5
- */
- public final static String FRAMEWORK_EXECPERMISSION = "org.osgi.framework.command.execpermission";
-
- /**
- * Specifies the trust repositories used by the framework. The value is a
- * <code>java.io.File.pathSeparator</code> separated list of valid file
- * paths to files that contain key stores of type <code>JKS</code>. The
- * framework will use the key stores as trust repositories to authenticate
- * certificates of trusted signers. The key stores are only used as
- * read-only trust repositories to access public keys. No passwords are
- * required to access the key stores' public keys.
- * <p>
- * Note that framework implementations are allowed to use other trust
- * repositories in addition to the trust repositories specified by this
- * property. How these other trust repositories are configured and populated
- * is implementation specific.
- *
- * @since 1.5
- */
- public final static String FRAMEWORK_TRUST_REPOSITORIES = "org.osgi.framework.trust.repositories";
-
- /**
- * Specifies the current windowing system. The framework should provide a
- * reasonable default if this is not set.
- *
- * @since 1.5
- */
- public final static String FRAMEWORK_WINDOWSYSTEM = "org.osgi.framework.windowsystem";
-
- /**
- * Specifies the beginning start level of the framework.
- *
- * @see "Core Specification, section 8.2.3."
- * @since 1.5
- */
- public final static String FRAMEWORK_BEGINNING_STARTLEVEL = "org.osgi.framework.startlevel.beginning";
-
- /**
- * Specifies the parent class loader type for all bundle class loaders.
- * Default value is {@link #FRAMEWORK_BUNDLE_PARENT_BOOT boot}.
- *
- * @see #FRAMEWORK_BUNDLE_PARENT_BOOT
- * @see #FRAMEWORK_BUNDLE_PARENT_EXT
- * @see #FRAMEWORK_BUNDLE_PARENT_APP
- * @see #FRAMEWORK_BUNDLE_PARENT_FRAMEWORK
- * @since 1.5
- */
- public final static String FRAMEWORK_BUNDLE_PARENT = "org.osgi.framework.bundle.parent";
-
- /**
- * Specifies to use of the boot class loader as the parent class loader for
- * all bundle class loaders.
- *
- * @since 1.5
- * @see #FRAMEWORK_BUNDLE_PARENT
- */
- public final static String FRAMEWORK_BUNDLE_PARENT_BOOT = "boot";
-
- /**
- * Specifies to use the extension class loader as the parent class loader
- * for all bundle class loaders.
- *
- * @since 1.5
- * @see #FRAMEWORK_BUNDLE_PARENT
- */
- public final static String FRAMEWORK_BUNDLE_PARENT_EXT = "ext";
-
- /**
- * Specifies to use the application class loader as the parent class loader
- * for all bundle class loaders. Depending on how the framework is
- * launched, this may refer to the same class loader as
- * {@link #FRAMEWORK_BUNDLE_PARENT_FRAMEWORK}.
- *
- * @since 1.5
- * @see #FRAMEWORK_BUNDLE_PARENT
- */
- public final static String FRAMEWORK_BUNDLE_PARENT_APP = "app";
-
- /**
- * Specifies to use the framework class loader as the parent class loader
- * for all bundle class loaders. The framework class loader is the class
- * loader used to load the framework implementation. Depending on how the
- * framework is launched, this may refer to the same class loader as
- * {@link #FRAMEWORK_BUNDLE_PARENT_APP}.
- *
- * @since 1.5
- * @see #FRAMEWORK_BUNDLE_PARENT
- */
- public final static String FRAMEWORK_BUNDLE_PARENT_FRAMEWORK = "framework";
-
- /*
- * Service properties.
- */
-
- /**
- * Service property identifying all of the class names under which a service
- * was registered in the Framework. The value of this property must be of
- * type <code>String[]</code>.
- *
- * <p>
- * This property is set by the Framework when a service is registered.
- */
- public static final String OBJECTCLASS = "objectClass";
-
- /**
- * Service property identifying a service's registration number. The value
- * of this property must be of type <code>Long</code>.
- *
- * <p>
- * The value of this property is assigned by the Framework when a service is
- * registered. The Framework assigns a unique value that is larger than all
- * previously assigned values since the Framework was started. These values
- * are NOT persistent across restarts of the Framework.
- */
- public static final String SERVICE_ID = "service.id";
-
- /**
- * Service property identifying a service's persistent identifier.
- *
- * <p>
- * This property may be supplied in the <code>properties</code>
- * <code>Dictionary</code> object passed to the
- * <code>BundleContext.registerService</code> method. The value of this
- * property must be of type <code>String</code>, <code>String[]</code>, or
- * <code>Collection</code> of <code>String</code>.
- *
- * <p>
- * A service's persistent identifier uniquely identifies the service and
- * persists across multiple Framework invocations.
- *
- * <p>
- * By convention, every bundle has its own unique namespace, starting with
- * the bundle's identifier (see {@link Bundle#getBundleId}) and followed by
- * a dot (.). A bundle may use this as the prefix of the persistent
- * identifiers for the services it registers.
- */
- public static final String SERVICE_PID = "service.pid";
-
- /**
- * Service property identifying a service's ranking number.
- *
- * <p>
- * This property may be supplied in the <code>properties
- * Dictionary</code> object passed to the
- * <code>BundleContext.registerService</code> method. The value of this
- * property must be of type <code>Integer</code>.
- *
- * <p>
- * The service ranking is used by the Framework to determine the <i>natural
- * order</i> of services, see {@link ServiceReference#compareTo(Object)},
- * and the <i>default</i> service to be returned from a call to the
- * {@link BundleContext#getServiceReference} method.
- *
- * <p>
- * The default ranking is zero (0). A service with a ranking of
- * <code>Integer.MAX_VALUE</code> is very likely to be returned as the
- * default service, whereas a service with a ranking of
- * <code>Integer.MIN_VALUE</code> is very unlikely to be returned.
- *
- * <p>
- * If the supplied property value is not of type <code>Integer</code>, it is
- * deemed to have a ranking value of zero.
- */
- public static final String SERVICE_RANKING = "service.ranking";
-
- /**
- * Service property identifying a service's vendor.
- *
- * <p>
- * This property may be supplied in the properties <code>Dictionary</code>
- * object passed to the <code>BundleContext.registerService</code> method.
- */
- public static final String SERVICE_VENDOR = "service.vendor";
-
- /**
- * Service property identifying a service's description.
- *
- * <p>
- * This property may be supplied in the properties <code>Dictionary</code>
- * object passed to the <code>BundleContext.registerService</code> method.
- */
- public static final String SERVICE_DESCRIPTION = "service.description";
-}
diff --git a/org.osgi.core/src/main/java/org/osgi/framework/Filter.java b/org.osgi.core/src/main/java/org/osgi/framework/Filter.java
deleted file mode 100644
index 81c3e5b..0000000
--- a/org.osgi.core/src/main/java/org/osgi/framework/Filter.java
+++ /dev/null
@@ -1,123 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2000, 2009). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.osgi.framework;
-
-import java.util.Dictionary;
-
-/**
- * An RFC 1960-based Filter.
- * <p>
- * <code>Filter</code>s can be created by calling
- * {@link BundleContext#createFilter} or {@link FrameworkUtil#createFilter} with
- * a filter string.
- * <p>
- * A <code>Filter</code> can be used numerous times to determine if the match
- * argument matches the filter string that was used to create the
- * <code>Filter</code>.
- * <p>
- * Some examples of LDAP filters are:
- *
- * <pre>
- * "(cn=Babs Jensen)"
- * "(!(cn=Tim Howes))"
- * "(&(" + Constants.OBJECTCLASS + "=Person)(|(sn=Jensen)(cn=Babs J*)))"
- * "(o=univ*of*mich*)"
- * </pre>
- *
- * @since 1.1
- * @see "Core Specification, section 5.5, for a description of the filter string syntax."
- * @ThreadSafe
- * @version $Revision: 6860 $
- */
-public interface Filter {
- /**
- * Filter using a service's properties.
- * <p>
- * This <code>Filter</code> is executed using the keys and values of the
- * referenced service's properties. The keys are case insensitively matched
- * with this <code>Filter</code>.
- *
- * @param reference The reference to the service whose properties are used
- * in the match.
- * @return <code>true</code> if the service's properties match this
- * <code>Filter</code>; <code>false</code> otherwise.
- */
- public boolean match(ServiceReference reference);
-
- /**
- * Filter using a <code>Dictionary</code>. This <code>Filter</code> is
- * executed using the specified <code>Dictionary</code>'s keys and values.
- * The keys are case insensitively matched with this <code>Filter</code>.
- *
- * @param dictionary The <code>Dictionary</code> whose keys are used in the
- * match.
- * @return <code>true</code> if the <code>Dictionary</code>'s keys and
- * values match this filter; <code>false</code> otherwise.
- * @throws IllegalArgumentException If <code>dictionary</code> contains case
- * variants of the same key name.
- */
- public boolean match(Dictionary dictionary);
-
- /**
- * Returns this <code>Filter</code>'s filter string.
- * <p>
- * The filter string is normalized by removing whitespace which does not
- * affect the meaning of the filter.
- *
- * @return This <code>Filter</code>'s filter string.
- */
- public String toString();
-
- /**
- * Compares this <code>Filter</code> to another <code>Filter</code>.
- *
- * <p>
- * This method returns the result of calling
- * <code>this.toString().equals(obj.toString())</code>.
- *
- * @param obj The object to compare against this <code>Filter</code>.
- * @return If the other object is a <code>Filter</code> object, then returns
- * the result of calling
- * <code>this.toString().equals(obj.toString())</code>;
- * <code>false</code> otherwise.
- */
- public boolean equals(Object obj);
-
- /**
- * Returns the hashCode for this <code>Filter</code>.
- *
- * <p>
- * This method returns the result of calling
- * <code>this.toString().hashCode()</code>.
- *
- * @return The hashCode of this <code>Filter</code>.
- */
- public int hashCode();
-
- /**
- * Filter with case sensitivity using a <code>Dictionary</code>. This
- * <code>Filter</code> is executed using the specified
- * <code>Dictionary</code>'s keys and values. The keys are case sensitively
- * matched with this <code>Filter</code>.
- *
- * @param dictionary The <code>Dictionary</code> whose keys are used in the
- * match.
- * @return <code>true</code> if the <code>Dictionary</code>'s keys and
- * values match this filter; <code>false</code> otherwise.
- * @since 1.3
- */
- public boolean matchCase(Dictionary dictionary);
-}
diff --git a/org.osgi.core/src/main/java/org/osgi/framework/FrameworkEvent.java b/org.osgi.core/src/main/java/org/osgi/framework/FrameworkEvent.java
deleted file mode 100644
index 747b249..0000000
--- a/org.osgi.core/src/main/java/org/osgi/framework/FrameworkEvent.java
+++ /dev/null
@@ -1,242 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2004, 2009). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.osgi.framework;
-
-import java.util.EventObject;
-
-/**
- * A general event from the Framework.
- *
- * <p>
- * <code>FrameworkEvent</code> objects are delivered to
- * <code>FrameworkListener</code>s when a general event occurs within the OSGi
- * environment. A type code is used to identify the event type for future
- * extendability.
- *
- * <p>
- * OSGi Alliance reserves the right to extend the set of event types.
- *
- * @Immutable
- * @see FrameworkListener
- * @version $Revision: 6542 $
- */
-
-public class FrameworkEvent extends EventObject {
- static final long serialVersionUID = 207051004521261705L;
- /**
- * Bundle related to the event.
- */
- private final Bundle bundle;
-
- /**
- * Exception related to the event.
- */
- private final Throwable throwable;
-
- /**
- * Type of event.
- */
- private final int type;
-
- /**
- * The Framework has started.
- *
- * <p>
- * This event is fired when the Framework has started after all installed
- * bundles that are marked to be started have been started and the Framework
- * has reached the initial start level. The source of this event is the
- * System Bundle.
- *
- * @see "The Start Level Service"
- */
- public final static int STARTED = 0x00000001;
-
- /**
- * An error has occurred.
- *
- * <p>
- * There was an error associated with a bundle.
- */
- public final static int ERROR = 0x00000002;
-
- /**
- * A PackageAdmin.refreshPackage operation has completed.
- *
- * <p>
- * This event is fired when the Framework has completed the refresh packages
- * operation initiated by a call to the PackageAdmin.refreshPackages method.
- * The source of this event is the System Bundle.
- *
- * @since 1.2
- * @see "<code>PackageAdmin.refreshPackages</code>"
- */
- public final static int PACKAGES_REFRESHED = 0x00000004;
-
- /**
- * A StartLevel.setStartLevel operation has completed.
- *
- * <p>
- * This event is fired when the Framework has completed changing the active
- * start level initiated by a call to the StartLevel.setStartLevel method.
- * The source of this event is the System Bundle.
- *
- * @since 1.2
- * @see "The Start Level Service"
- */
- public final static int STARTLEVEL_CHANGED = 0x00000008;
-
- /**
- * A warning has occurred.
- *
- * <p>
- * There was a warning associated with a bundle.
- *
- * @since 1.3
- */
- public final static int WARNING = 0x00000010;
-
- /**
- * An informational event has occurred.
- *
- * <p>
- * There was an informational event associated with a bundle.
- *
- * @since 1.3
- */
- public final static int INFO = 0x00000020;
-
- /**
- * The Framework has stopped.
- *
- * <p>
- * This event is fired when the Framework has been stopped because of a stop
- * operation on the system bundle. The source of this event is the System
- * Bundle.
- *
- * @since 1.5
- */
- public final static int STOPPED = 0x00000040;
-
- /**
- * The Framework has stopped during update.
- *
- * <p>
- * This event is fired when the Framework has been stopped because of an
- * update operation on the system bundle. The Framework will be restarted
- * after this event is fired. The source of this event is the System Bundle.
- *
- * @since 1.5
- */
- public final static int STOPPED_UPDATE = 0x00000080;
-
- /**
- * The Framework has stopped and the boot class path has changed.
- *
- * <p>
- * This event is fired when the Framework has been stopped because of a stop
- * operation on the system bundle and a bootclasspath extension bundle has
- * been installed or updated. The source of this event is the System Bundle.
- *
- * @since 1.5
- */
- public final static int STOPPED_BOOTCLASSPATH_MODIFIED = 0x00000100;
-
- /**
- * The Framework did not stop before the wait timeout expired.
- *
- * <p>
- * This event is fired when the Framework did not stop before the wait
- * timeout expired. The source of this event is the System Bundle.
- *
- * @since 1.5
- */
- public final static int WAIT_TIMEDOUT = 0x00000200;
-
- /**
- * Creates a Framework event.
- *
- * @param type The event type.
- * @param source The event source object. This may not be <code>null</code>.
- * @deprecated As of 1.2. This constructor is deprecated in favor of using
- * the other constructor with the System Bundle as the event
- * source.
- */
- public FrameworkEvent(int type, Object source) {
- super(source);
- this.type = type;
- this.bundle = null;
- this.throwable = null;
- }
-
- /**
- * Creates a Framework event regarding the specified bundle.
- *
- * @param type The event type.
- * @param bundle The event source.
- * @param throwable The related exception. This argument may be
- * <code>null</code> if there is no related exception.
- */
- public FrameworkEvent(int type, Bundle bundle, Throwable throwable) {
- super(bundle);
- this.type = type;
- this.bundle = bundle;
- this.throwable = throwable;
- }
-
- /**
- * Returns the exception related to this event.
- *
- * @return The related exception or <code>null</code> if none.
- */
- public Throwable getThrowable() {
- return throwable;
- }
-
- /**
- * Returns the bundle associated with the event. This bundle is also the
- * source of the event.
- *
- * @return The bundle associated with the event.
- */
- public Bundle getBundle() {
- return bundle;
- }
-
- /**
- * Returns the type of framework event.
- * <p>
- * The type values are:
- * <ul>
- * <li>{@link #STARTED}
- * <li>{@link #ERROR}
- * <li>{@link #WARNING}
- * <li>{@link #INFO}
- * <li>{@link #PACKAGES_REFRESHED}
- * <li>{@link #STARTLEVEL_CHANGED}
- * <li>{@link #STOPPED}
- * <li>{@link #STOPPED_BOOTCLASSPATH_MODIFIED}
- * <li>{@link #STOPPED_UPDATE}
- * <li>{@link #WAIT_TIMEDOUT}
- * </ul>
- *
- * @return The type of state change.
- */
-
- public int getType() {
- return type;
- }
-}
diff --git a/org.osgi.core/src/main/java/org/osgi/framework/FrameworkListener.java b/org.osgi.core/src/main/java/org/osgi/framework/FrameworkListener.java
deleted file mode 100644
index c96c490..0000000
--- a/org.osgi.core/src/main/java/org/osgi/framework/FrameworkListener.java
+++ /dev/null
@@ -1,49 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2000, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.osgi.framework;
-
-import java.util.EventListener;
-
-/**
- * A <code>FrameworkEvent</code> listener. <code>FrameworkListener</code> is
- * a listener interface that may be implemented by a bundle developer. When a
- * <code>FrameworkEvent</code> is fired, it is asynchronously delivered to a
- * <code>FrameworkListener</code>. The Framework delivers
- * <code>FrameworkEvent</code> objects to a <code>FrameworkListener</code>
- * in order and must not concurrently call a <code>FrameworkListener</code>.
- *
- * <p>
- * A <code>FrameworkListener</code> object is registered with the Framework
- * using the {@link BundleContext#addFrameworkListener} method.
- * <code>FrameworkListener</code> objects are called with a
- * <code>FrameworkEvent</code> objects when the Framework starts and when
- * asynchronous errors occur.
- *
- * @see FrameworkEvent
- * @NotThreadSafe
- * @version $Revision: 5673 $
- */
-
-public interface FrameworkListener extends EventListener {
-
- /**
- * Receives notification of a general <code>FrameworkEvent</code> object.
- *
- * @param event The <code>FrameworkEvent</code> object.
- */
- public void frameworkEvent(FrameworkEvent event);
-}
diff --git a/org.osgi.core/src/main/java/org/osgi/framework/FrameworkUtil.java b/org.osgi.core/src/main/java/org/osgi/framework/FrameworkUtil.java
deleted file mode 100644
index b565b86..0000000
--- a/org.osgi.core/src/main/java/org/osgi/framework/FrameworkUtil.java
+++ /dev/null
@@ -1,2143 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2005, 2009). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.osgi.framework;
-
-import java.lang.reflect.AccessibleObject;
-import java.lang.reflect.Constructor;
-import java.lang.reflect.InvocationTargetException;
-import java.security.AccessController;
-import java.security.PrivilegedAction;
-import java.util.ArrayList;
-import java.util.Collection;
-import java.util.Dictionary;
-import java.util.Enumeration;
-import java.util.Iterator;
-import java.util.List;
-
-import javax.security.auth.x500.X500Principal;
-
-/**
- * Framework Utility class.
- *
- * <p>
- * This class contains utility methods which access Framework functions that may
- * be useful to bundles.
- *
- * @since 1.3
- * @ThreadSafe
- * @version $Revision: 7761 $
- */
-public class FrameworkUtil {
- /**
- * FrameworkUtil objects may not be constructed.
- */
- private FrameworkUtil() {
- // private empty constructor to prevent construction
- }
-
- /**
- * Creates a <code>Filter</code> object. This <code>Filter</code> object may
- * be used to match a <code>ServiceReference</code> object or a
- * <code>Dictionary</code> object.
- *
- * <p>
- * If the filter cannot be parsed, an {@link InvalidSyntaxException} will be
- * thrown with a human readable message where the filter became unparsable.
- *
- * <p>
- * This method returns a Filter implementation which may not perform as well
- * as the framework implementation-specific Filter implementation returned
- * by {@link BundleContext#createFilter(String)}.
- *
- * @param filter The filter string.
- * @return A <code>Filter</code> object encapsulating the filter string.
- * @throws InvalidSyntaxException If <code>filter</code> contains an invalid
- * filter string that cannot be parsed.
- * @throws NullPointerException If <code>filter</code> is null.
- *
- * @see Filter
- */
- public static Filter createFilter(String filter)
- throws InvalidSyntaxException {
- return FilterImpl.newInstance(filter);
- }
-
- /**
- * Match a Distinguished Name (DN) chain against a pattern. DNs can be
- * matched using wildcards. A wildcard ('*' \u002A) replaces all
- * possible values. Due to the structure of the DN, the comparison is more
- * complicated than string-based wildcard matching.
- * <p>
- * A wildcard can stand for zero or more DNs in a chain, a number of
- * relative distinguished names (RDNs) within a DN, or the value of a single
- * RDN. The DNs in the chain and the matching pattern are canonicalized
- * before processing. This means, among other things, that spaces must be
- * ignored, except in values.
- * <p>
- * The format of a wildcard match pattern is:
- *
- * <pre>
- * matchPattern ::= dn-match ( ';' dn-match ) *
- * dn-match ::= ( '*' | rdn-match ) ( ',' rdn-match ) * | '-'
- * rdn-match ::= name '=' value-match
- * value-match ::= '*' | value-star
- * value-star ::= < value, requires escaped '*' and '-' >
- * </pre>
- * <p>
- * The most simple case is a single wildcard; it must match any DN. A
- * wildcard can also replace the first list of RDNs of a DN. The first RDNs
- * are the least significant. Such lists of matched RDNs can be empty.
- * <p>
- * For example, a match pattern with a wildcard that matches all all DNs
- * that end with RDNs of o=ACME and c=US would look like this:
- *
- * <pre>
- * *, o=ACME, c=US
- * </pre>
- *
- * This match pattern would match the following DNs:
- *
- * <pre>
- * cn = Bugs Bunny, o = ACME, c = US
- * ou = Carrots, cn=Daffy Duck, o=ACME, c=US
- * street = 9C\, Avenue St. Drézéry, o=ACME, c=US
- * dc=www, dc=acme, dc=com, o=ACME, c=US
- * o=ACME, c=US
- * </pre>
- *
- * The following DNs would not match:
- *
- * <pre>
- * street = 9C\, Avenue St. Drézéry, o=ACME, c=FR
- * dc=www, dc=acme, dc=com, c=US
- * </pre>
- *
- * If a wildcard is used for a value of an RDN, the value must be exactly *.
- * The wildcard must match any value, and no substring matching must be
- * done. For example:
- *
- * <pre>
- * cn=*,o=ACME,c=*
- * </pre>
- *
- * This match pattern with wildcard must match the following DNs:
- *
- * <pre>
- * cn=Bugs Bunny,o=ACME,c=US
- * cn = Daffy Duck , o = ACME , c = US
- * cn=Road Runner, o=ACME, c=NL
- * </pre>
- *
- * But not:
- *
- * <pre>
- * o=ACME, c=NL
- * dc=acme.com, cn=Bugs Bunny, o=ACME, c=US
- * </pre>
- *
- * <p>
- * A match pattern may contain a chain of DN match patterns. The
- * semicolon(';' \u003B) must be used to separate DN match patterns in a
- * chain. Wildcards can also be used to match against a complete DN within a
- * chain.
- * <p>
- * The following example matches a certificate signed by Tweety Inc. in the
- * US.
- * </p>
- *
- * <pre>
- * * ; ou=S & V, o=Tweety Inc., c=US
- * </pre>
- * <p>
- * The wildcard ('*') matches zero or one DN in the chain, however,
- * sometimes it is necessary to match a longer chain. The minus sign ('-'
- * \u002D) represents zero or more DNs, whereas the asterisk only
- * represents a single DN. For example, to match a DN where the Tweety Inc.
- * is in the DN chain, use the following expression:
- * </p>
- *
- * <pre>
- * - ; *, o=Tweety Inc., c=US
- * </pre>
- *
- * @param matchPattern The pattern against which to match the DN chain.
- * @param dnChain The DN chain to match against the specified pattern. Each
- * element of the chain must be of type <code>String</code> and use
- * the format defined in RFC 2253.
- * @return <code>true</code> If the pattern matches the DN chain; otherwise
- * <code>false</code> is returned.
- * @throws IllegalArgumentException If the specified match pattern or DN
- * chain is invalid.
- * @since 1.5
- */
- public static boolean matchDistinguishedNameChain(String matchPattern,
- List /* <String> */dnChain) {
- return DNChainMatching.match(matchPattern, dnChain);
- }
-
- /**
- * Return a <code>Bundle</code> for the specified bundle class. The returned
- * <code>Bundle</code> is the bundle associated with the bundle class loader
- * which defined the specified class.
- *
- * @param classFromBundle A class defined by a bundle class loader.
- * @return A <code>Bundle</code> for the specified bundle class or
- * <code>null</code> if the specified class was not defined by a
- * bundle class loader.
- * @since 1.5
- */
- public static Bundle getBundle(final Class classFromBundle) {
- // We use doPriv since the caller may not have permission
- // to call getClassLoader.
- Object cl = AccessController.doPrivileged(new PrivilegedAction() {
- public Object run() {
- return classFromBundle.getClassLoader();
- }
- });
-
- if (cl instanceof BundleReference) {
- return ((BundleReference) cl).getBundle();
- }
- return null;
- }
-
- /**
- * RFC 1960-based Filter. Filter objects can be created by calling the
- * constructor with the desired filter string. A Filter object can be called
- * numerous times to determine if the match argument matches the filter
- * string that was used to create the Filter object.
- *
- * <p>
- * The syntax of a filter string is the string representation of LDAP search
- * filters as defined in RFC 1960: <i>A String Representation of LDAP Search
- * Filters</i> (available at http://www.ietf.org/rfc/rfc1960.txt). It should
- * be noted that RFC 2254: <i>A String Representation of LDAP Search
- * Filters</i> (available at http://www.ietf.org/rfc/rfc2254.txt) supersedes
- * RFC 1960 but only adds extensible matching and is not applicable for this
- * API.
- *
- * <p>
- * The string representation of an LDAP search filter is defined by the
- * following grammar. It uses a prefix format.
- *
- * <pre>
- * <filter> ::= '(' <filtercomp> ')'
- * <filtercomp> ::= <and> | <or> | <not> | <item>
- * <and> ::= '&' <filterlist>
- * <or> ::= '|' <filterlist>
- * <not> ::= '!' <filter>
- * <filterlist> ::= <filter> | <filter> <filterlist>
- * <item> ::= <simple> | <present> | <substring>
- * <simple> ::= <attr> <filtertype> <value>
- * <filtertype> ::= <equal> | <approx> | <greater> | <less>
- * <equal> ::= '='
- * <approx> ::= '˜='
- * <greater> ::= '>='
- * <less> ::= '<='
- * <present> ::= <attr> '=*'
- * <substring> ::= <attr> '=' <initial> <any> <final>
- * <initial> ::= NULL | <value>
- * <any> ::= '*' <starval>
- * <starval> ::= NULL | <value> '*' <starval>
- * <final> ::= NULL | <value>
- * </pre>
- *
- * <code><attr></code> is a string representing an attribute, or key,
- * in the properties objects of the registered services. Attribute names are
- * not case sensitive; that is cn and CN both refer to the same attribute.
- * <code><value></code> is a string representing the value, or part of
- * one, of a key in the properties objects of the registered services. If a
- * <code><value></code> must contain one of the characters '
- * <code>*</code>' or '<code>(</code>' or '<code>)</code>', these characters
- * should be escaped by preceding them with the backslash '<code>\</code>'
- * character. Note that although both the <code><substring></code> and
- * <code><present></code> productions can produce the <code>'attr=*'</code>
- * construct, this construct is used only to denote a presence filter.
- *
- * <p>
- * Examples of LDAP filters are:
- *
- * <pre>
- * "(cn=Babs Jensen)"
- * "(!(cn=Tim Howes))"
- * "(&(" + Constants.OBJECTCLASS + "=Person)(|(sn=Jensen)(cn=Babs J*)))"
- * "(o=univ*of*mich*)"
- * </pre>
- *
- * <p>
- * The approximate match (<code>~=</code>) is implementation specific but
- * should at least ignore case and white space differences. Optional are
- * codes like soundex or other smart "closeness" comparisons.
- *
- * <p>
- * Comparison of values is not straightforward. Strings are compared
- * differently than numbers and it is possible for a key to have multiple
- * values. Note that that keys in the match argument must always be strings.
- * The comparison is defined by the object type of the key's value. The
- * following rules apply for comparison:
- *
- * <blockquote>
- * <TABLE BORDER=0>
- * <TR>
- * <TD><b>Property Value Type </b></TD>
- * <TD><b>Comparison Type</b></TD>
- * </TR>
- * <TR>
- * <TD>String</TD>
- * <TD>String comparison</TD>
- * </TR>
- * <TR valign=top>
- * <TD>Integer, Long, Float, Double, Byte, Short, BigInteger, BigDecimal</TD>
- * <TD>numerical comparison</TD>
- * </TR>
- * <TR>
- * <TD>Character</TD>
- * <TD>character comparison</TD>
- * </TR>
- * <TR>
- * <TD>Boolean</TD>
- * <TD>equality comparisons only</TD>
- * </TR>
- * <TR>
- * <TD>[] (array)</TD>
- * <TD>recursively applied to values</TD>
- * </TR>
- * <TR>
- * <TD>Collection</TD>
- * <TD>recursively applied to values</TD>
- * </TR>
- * </TABLE>
- * Note: arrays of primitives are also supported. </blockquote>
- *
- * A filter matches a key that has multiple values if it matches at least
- * one of those values. For example,
- *
- * <pre>
- * Dictionary d = new Hashtable();
- * d.put("cn", new String[] {"a", "b", "c"});
- * </pre>
- *
- * d will match <code>(cn=a)</code> and also <code>(cn=b)</code>
- *
- * <p>
- * A filter component that references a key having an unrecognizable data
- * type will evaluate to <code>false</code> .
- */
- private static class FilterImpl implements Filter {
- /* filter operators */
- private static final int EQUAL = 1;
- private static final int APPROX = 2;
- private static final int GREATER = 3;
- private static final int LESS = 4;
- private static final int PRESENT = 5;
- private static final int SUBSTRING = 6;
- private static final int AND = 7;
- private static final int OR = 8;
- private static final int NOT = 9;
-
- /** filter operation */
- private final int op;
- /** filter attribute or null if operation AND, OR or NOT */
- private final String attr;
- /** filter operands */
- private final Object value;
-
- /* normalized filter string for Filter object */
- private transient volatile String filterString;
-
- /**
- * Constructs a {@link FilterImpl} object. This filter object may be
- * used to match a {@link ServiceReference} or a Dictionary.
- *
- * <p>
- * If the filter cannot be parsed, an {@link InvalidSyntaxException}
- * will be thrown with a human readable message where the filter became
- * unparsable.
- *
- * @param filterString the filter string.
- * @exception InvalidSyntaxException If the filter parameter contains an
- * invalid filter string that cannot be parsed.
- */
- static FilterImpl newInstance(String filterString)
- throws InvalidSyntaxException {
- return new Parser(filterString).parse();
- }
-
- FilterImpl(int operation, String attr, Object value) {
- this.op = operation;
- this.attr = attr;
- this.value = value;
- }
-
- /**
- * Filter using a service's properties.
- * <p>
- * This <code>Filter</code> is executed using the keys and values of the
- * referenced service's properties. The keys are case insensitively
- * matched with this <code>Filter</code>.
- *
- * @param reference The reference to the service whose properties are
- * used in the match.
- * @return <code>true</code> if the service's properties match this
- * <code>Filter</code>; <code>false</code> otherwise.
- */
- public boolean match(ServiceReference reference) {
- return match0(new ServiceReferenceDictionary(reference));
- }
-
- /**
- * Filter using a <code>Dictionary</code>. This <code>Filter</code> is
- * executed using the specified <code>Dictionary</code>'s keys and
- * values. The keys are case insensitively matched with this
- * <code>Filter</code>.
- *
- * @param dictionary The <code>Dictionary</code> whose keys are used in
- * the match.
- * @return <code>true</code> if the <code>Dictionary</code>'s keys and
- * values match this filter; <code>false</code> otherwise.
- * @throws IllegalArgumentException If <code>dictionary</code> contains
- * case variants of the same key name.
- */
- public boolean match(Dictionary dictionary) {
- return match0(new CaseInsensitiveDictionary(dictionary));
- }
-
- /**
- * Filter with case sensitivity using a <code>Dictionary</code>. This
- * <code>Filter</code> is executed using the specified
- * <code>Dictionary</code>'s keys and values. The keys are case
- * sensitively matched with this <code>Filter</code>.
- *
- * @param dictionary The <code>Dictionary</code> whose keys are used in
- * the match.
- * @return <code>true</code> if the <code>Dictionary</code>'s keys and
- * values match this filter; <code>false</code> otherwise.
- * @since 1.3
- */
- public boolean matchCase(Dictionary dictionary) {
- return match0(dictionary);
- }
-
- /**
- * Returns this <code>Filter</code>'s filter string.
- * <p>
- * The filter string is normalized by removing whitespace which does not
- * affect the meaning of the filter.
- *
- * @return This <code>Filter</code>'s filter string.
- */
- public String toString() {
- String result = filterString;
- if (result == null) {
- filterString = result = normalize();
- }
- return result;
- }
-
- /**
- * Returns this <code>Filter</code>'s normalized filter string.
- * <p>
- * The filter string is normalized by removing whitespace which does not
- * affect the meaning of the filter.
- *
- * @return This <code>Filter</code>'s filter string.
- */
- private String normalize() {
- StringBuffer sb = new StringBuffer();
- sb.append('(');
-
- switch (op) {
- case AND : {
- sb.append('&');
-
- FilterImpl[] filters = (FilterImpl[]) value;
- for (int i = 0, size = filters.length; i < size; i++) {
- sb.append(filters[i].normalize());
- }
-
- break;
- }
-
- case OR : {
- sb.append('|');
-
- FilterImpl[] filters = (FilterImpl[]) value;
- for (int i = 0, size = filters.length; i < size; i++) {
- sb.append(filters[i].normalize());
- }
-
- break;
- }
-
- case NOT : {
- sb.append('!');
- FilterImpl filter = (FilterImpl) value;
- sb.append(filter.normalize());
-
- break;
- }
-
- case SUBSTRING : {
- sb.append(attr);
- sb.append('=');
-
- String[] substrings = (String[]) value;
-
- for (int i = 0, size = substrings.length; i < size; i++) {
- String substr = substrings[i];
-
- if (substr == null) /* * */{
- sb.append('*');
- }
- else /* xxx */{
- sb.append(encodeValue(substr));
- }
- }
-
- break;
- }
- case EQUAL : {
- sb.append(attr);
- sb.append('=');
- sb.append(encodeValue((String) value));
-
- break;
- }
- case GREATER : {
- sb.append(attr);
- sb.append(">=");
- sb.append(encodeValue((String) value));
-
- break;
- }
- case LESS : {
- sb.append(attr);
- sb.append("<=");
- sb.append(encodeValue((String) value));
-
- break;
- }
- case APPROX : {
- sb.append(attr);
- sb.append("~=");
- sb.append(encodeValue(approxString((String) value)));
-
- break;
- }
-
- case PRESENT : {
- sb.append(attr);
- sb.append("=*");
-
- break;
- }
- }
-
- sb.append(')');
-
- return sb.toString();
- }
-
- /**
- * Compares this <code>Filter</code> to another <code>Filter</code>.
- *
- * <p>
- * This implementation returns the result of calling
- * <code>this.toString().equals(obj.toString()</code>.
- *
- * @param obj The object to compare against this <code>Filter</code>.
- * @return If the other object is a <code>Filter</code> object, then
- * returns the result of calling
- * <code>this.toString().equals(obj.toString()</code>;
- * <code>false</code> otherwise.
- */
- public boolean equals(Object obj) {
- if (obj == this) {
- return true;
- }
-
- if (!(obj instanceof Filter)) {
- return false;
- }
-
- return this.toString().equals(obj.toString());
- }
-
- /**
- * Returns the hashCode for this <code>Filter</code>.
- *
- * <p>
- * This implementation returns the result of calling
- * <code>this.toString().hashCode()</code>.
- *
- * @return The hashCode of this <code>Filter</code>.
- */
- public int hashCode() {
- return this.toString().hashCode();
- }
-
- /**
- * Internal match routine. Dictionary parameter must support
- * case-insensitive get.
- *
- * @param properties A dictionary whose keys are used in the match.
- * @return If the Dictionary's keys match the filter, return
- * <code>true</code>. Otherwise, return <code>false</code>.
- */
- private boolean match0(Dictionary properties) {
- switch (op) {
- case AND : {
- FilterImpl[] filters = (FilterImpl[]) value;
- for (int i = 0, size = filters.length; i < size; i++) {
- if (!filters[i].match0(properties)) {
- return false;
- }
- }
-
- return true;
- }
-
- case OR : {
- FilterImpl[] filters = (FilterImpl[]) value;
- for (int i = 0, size = filters.length; i < size; i++) {
- if (filters[i].match0(properties)) {
- return true;
- }
- }
-
- return false;
- }
-
- case NOT : {
- FilterImpl filter = (FilterImpl) value;
-
- return !filter.match0(properties);
- }
-
- case SUBSTRING :
- case EQUAL :
- case GREATER :
- case LESS :
- case APPROX : {
- Object prop = (properties == null) ? null : properties
- .get(attr);
-
- return compare(op, prop, value);
- }
-
- case PRESENT : {
- Object prop = (properties == null) ? null : properties
- .get(attr);
-
- return prop != null;
- }
- }
-
- return false;
- }
-
- /**
- * Encode the value string such that '(', '*', ')' and '\' are escaped.
- *
- * @param value unencoded value string.
- * @return encoded value string.
- */
- private static String encodeValue(String value) {
- boolean encoded = false;
- int inlen = value.length();
- int outlen = inlen << 1; /* inlen 2 */
-
- char[] output = new char[outlen];
- value.getChars(0, inlen, output, inlen);
-
- int cursor = 0;
- for (int i = inlen; i < outlen; i++) {
- char c = output[i];
-
- switch (c) {
- case '(' :
- case '*' :
- case ')' :
- case '\\' : {
- output[cursor] = '\\';
- cursor++;
- encoded = true;
-
- break;
- }
- }
-
- output[cursor] = c;
- cursor++;
- }
-
- return encoded ? new String(output, 0, cursor) : value;
- }
-
- private boolean compare(int operation, Object value1, Object value2) {
- if (value1 == null) {
- return false;
- }
- if (value1 instanceof String) {
- return compare_String(operation, (String) value1, value2);
- }
-
- Class clazz = value1.getClass();
- if (clazz.isArray()) {
- Class type = clazz.getComponentType();
- if (type.isPrimitive()) {
- return compare_PrimitiveArray(operation, type, value1,
- value2);
- }
- return compare_ObjectArray(operation, (Object[]) value1, value2);
- }
- if (value1 instanceof Collection) {
- return compare_Collection(operation, (Collection) value1,
- value2);
- }
- if (value1 instanceof Integer) {
- return compare_Integer(operation,
- ((Integer) value1).intValue(), value2);
- }
- if (value1 instanceof Long) {
- return compare_Long(operation, ((Long) value1).longValue(),
- value2);
- }
- if (value1 instanceof Byte) {
- return compare_Byte(operation, ((Byte) value1).byteValue(),
- value2);
- }
- if (value1 instanceof Short) {
- return compare_Short(operation, ((Short) value1).shortValue(),
- value2);
- }
- if (value1 instanceof Character) {
- return compare_Character(operation, ((Character) value1)
- .charValue(), value2);
- }
- if (value1 instanceof Float) {
- return compare_Float(operation, ((Float) value1).floatValue(),
- value2);
- }
- if (value1 instanceof Double) {
- return compare_Double(operation, ((Double) value1)
- .doubleValue(), value2);
- }
- if (value1 instanceof Boolean) {
- return compare_Boolean(operation, ((Boolean) value1)
- .booleanValue(), value2);
- }
- if (value1 instanceof Comparable) {
- return compare_Comparable(operation, (Comparable) value1,
- value2);
- }
- return compare_Unknown(operation, value1, value2); // RFC 59
- }
-
- private boolean compare_Collection(int operation,
- Collection collection, Object value2) {
- for (Iterator iterator = collection.iterator(); iterator.hasNext();) {
- if (compare(operation, iterator.next(), value2)) {
- return true;
- }
- }
- return false;
- }
-
- private boolean compare_ObjectArray(int operation, Object[] array,
- Object value2) {
- for (int i = 0, size = array.length; i < size; i++) {
- if (compare(operation, array[i], value2)) {
- return true;
- }
- }
- return false;
- }
-
- private boolean compare_PrimitiveArray(int operation, Class type,
- Object primarray, Object value2) {
- if (Integer.TYPE.isAssignableFrom(type)) {
- int[] array = (int[]) primarray;
- for (int i = 0, size = array.length; i < size; i++) {
- if (compare_Integer(operation, array[i], value2)) {
- return true;
- }
- }
- return false;
- }
- if (Long.TYPE.isAssignableFrom(type)) {
- long[] array = (long[]) primarray;
- for (int i = 0, size = array.length; i < size; i++) {
- if (compare_Long(operation, array[i], value2)) {
- return true;
- }
- }
- return false;
- }
- if (Byte.TYPE.isAssignableFrom(type)) {
- byte[] array = (byte[]) primarray;
- for (int i = 0, size = array.length; i < size; i++) {
- if (compare_Byte(operation, array[i], value2)) {
- return true;
- }
- }
- return false;
- }
- if (Short.TYPE.isAssignableFrom(type)) {
- short[] array = (short[]) primarray;
- for (int i = 0, size = array.length; i < size; i++) {
- if (compare_Short(operation, array[i], value2)) {
- return true;
- }
- }
- return false;
- }
- if (Character.TYPE.isAssignableFrom(type)) {
- char[] array = (char[]) primarray;
- for (int i = 0, size = array.length; i < size; i++) {
- if (compare_Character(operation, array[i], value2)) {
- return true;
- }
- }
- return false;
- }
- if (Float.TYPE.isAssignableFrom(type)) {
- float[] array = (float[]) primarray;
- for (int i = 0, size = array.length; i < size; i++) {
- if (compare_Float(operation, array[i], value2)) {
- return true;
- }
- }
- return false;
- }
- if (Double.TYPE.isAssignableFrom(type)) {
- double[] array = (double[]) primarray;
- for (int i = 0, size = array.length; i < size; i++) {
- if (compare_Double(operation, array[i], value2)) {
- return true;
- }
- }
- return false;
- }
- if (Boolean.TYPE.isAssignableFrom(type)) {
- boolean[] array = (boolean[]) primarray;
- for (int i = 0, size = array.length; i < size; i++) {
- if (compare_Boolean(operation, array[i], value2)) {
- return true;
- }
- }
- return false;
- }
- return false;
- }
-
- private boolean compare_String(int operation, String string,
- Object value2) {
- switch (operation) {
- case SUBSTRING : {
- String[] substrings = (String[]) value2;
- int pos = 0;
- for (int i = 0, size = substrings.length; i < size; i++) {
- String substr = substrings[i];
-
- if (i + 1 < size) /* if this is not that last substr */{
- if (substr == null) /* * */{
- String substr2 = substrings[i + 1];
-
- if (substr2 == null) /* ** */
- continue; /* ignore first star */
- /* xxx */
- int index = string.indexOf(substr2, pos);
- if (index == -1) {
- return false;
- }
-
- pos = index + substr2.length();
- if (i + 2 < size) // if there are more
- // substrings, increment
- // over the string we just
- // matched; otherwise need
- // to do the last substr
- // check
- i++;
- }
- else /* xxx */{
- int len = substr.length();
- if (string.regionMatches(pos, substr, 0, len)) {
- pos += len;
- }
- else {
- return false;
- }
- }
- }
- else /* last substr */{
- if (substr == null) /* * */{
- return true;
- }
- /* xxx */
- return string.endsWith(substr);
- }
- }
-
- return true;
- }
- case EQUAL : {
- return string.equals(value2);
- }
- case APPROX : {
- string = approxString(string);
- String string2 = approxString((String) value2);
-
- return string.equalsIgnoreCase(string2);
- }
- case GREATER : {
- return string.compareTo((String) value2) >= 0;
- }
- case LESS : {
- return string.compareTo((String) value2) <= 0;
- }
- }
- return false;
- }
-
- private boolean compare_Integer(int operation, int intval, Object value2) {
- if (operation == SUBSTRING) {
- return false;
- }
- int intval2 = Integer.parseInt(((String) value2).trim());
- switch (operation) {
- case APPROX :
- case EQUAL : {
- return intval == intval2;
- }
- case GREATER : {
- return intval >= intval2;
- }
- case LESS : {
- return intval <= intval2;
- }
- }
- return false;
- }
-
- private boolean compare_Long(int operation, long longval, Object value2) {
- if (operation == SUBSTRING) {
- return false;
- }
- long longval2 = Long.parseLong(((String) value2).trim());
- switch (operation) {
- case APPROX :
- case EQUAL : {
- return longval == longval2;
- }
- case GREATER : {
- return longval >= longval2;
- }
- case LESS : {
- return longval <= longval2;
- }
- }
- return false;
- }
-
- private boolean compare_Byte(int operation, byte byteval, Object value2) {
- if (operation == SUBSTRING) {
- return false;
- }
- byte byteval2 = Byte.parseByte(((String) value2).trim());
- switch (operation) {
- case APPROX :
- case EQUAL : {
- return byteval == byteval2;
- }
- case GREATER : {
- return byteval >= byteval2;
- }
- case LESS : {
- return byteval <= byteval2;
- }
- }
- return false;
- }
-
- private boolean compare_Short(int operation, short shortval,
- Object value2) {
- if (operation == SUBSTRING) {
- return false;
- }
- short shortval2 = Short.parseShort(((String) value2).trim());
- switch (operation) {
- case APPROX :
- case EQUAL : {
- return shortval == shortval2;
- }
- case GREATER : {
- return shortval >= shortval2;
- }
- case LESS : {
- return shortval <= shortval2;
- }
- }
- return false;
- }
-
- private boolean compare_Character(int operation, char charval,
- Object value2) {
- if (operation == SUBSTRING) {
- return false;
- }
- char charval2 = (((String) value2).trim()).charAt(0);
- switch (operation) {
- case EQUAL : {
- return charval == charval2;
- }
- case APPROX : {
- return (charval == charval2)
- || (Character.toUpperCase(charval) == Character
- .toUpperCase(charval2))
- || (Character.toLowerCase(charval) == Character
- .toLowerCase(charval2));
- }
- case GREATER : {
- return charval >= charval2;
- }
- case LESS : {
- return charval <= charval2;
- }
- }
- return false;
- }
-
- private boolean compare_Boolean(int operation, boolean boolval,
- Object value2) {
- if (operation == SUBSTRING) {
- return false;
- }
- boolean boolval2 = Boolean.valueOf(((String) value2).trim())
- .booleanValue();
- switch (operation) {
- case APPROX :
- case EQUAL :
- case GREATER :
- case LESS : {
- return boolval == boolval2;
- }
- }
- return false;
- }
-
- private boolean compare_Float(int operation, float floatval,
- Object value2) {
- if (operation == SUBSTRING) {
- return false;
- }
- float floatval2 = Float.parseFloat(((String) value2).trim());
- switch (operation) {
- case APPROX :
- case EQUAL : {
- return Float.compare(floatval, floatval2) == 0;
- }
- case GREATER : {
- return Float.compare(floatval, floatval2) >= 0;
- }
- case LESS : {
- return Float.compare(floatval, floatval2) <= 0;
- }
- }
- return false;
- }
-
- private boolean compare_Double(int operation, double doubleval,
- Object value2) {
- if (operation == SUBSTRING) {
- return false;
- }
- double doubleval2 = Double.parseDouble(((String) value2).trim());
- switch (operation) {
- case APPROX :
- case EQUAL : {
- return Double.compare(doubleval, doubleval2) == 0;
- }
- case GREATER : {
- return Double.compare(doubleval, doubleval2) >= 0;
- }
- case LESS : {
- return Double.compare(doubleval, doubleval2) <= 0;
- }
- }
- return false;
- }
-
- private static final Class[] constructorType = new Class[] {String.class};
-
- private boolean compare_Comparable(int operation, Comparable value1,
- Object value2) {
- if (operation == SUBSTRING) {
- return false;
- }
- Constructor constructor;
- try {
- constructor = value1.getClass().getConstructor(constructorType);
- }
- catch (NoSuchMethodException e) {
- return false;
- }
- try {
- if (!constructor.isAccessible())
- AccessController.doPrivileged(new SetAccessibleAction(
- constructor));
- value2 = constructor
- .newInstance(new Object[] {((String) value2).trim()});
- }
- catch (IllegalAccessException e) {
- return false;
- }
- catch (InvocationTargetException e) {
- return false;
- }
- catch (InstantiationException e) {
- return false;
- }
-
- switch (operation) {
- case APPROX :
- case EQUAL : {
- return value1.compareTo(value2) == 0;
- }
- case GREATER : {
- return value1.compareTo(value2) >= 0;
- }
- case LESS : {
- return value1.compareTo(value2) <= 0;
- }
- }
- return false;
- }
-
- private boolean compare_Unknown(int operation, Object value1,
- Object value2) {
- if (operation == SUBSTRING) {
- return false;
- }
- Constructor constructor;
- try {
- constructor = value1.getClass().getConstructor(constructorType);
- }
- catch (NoSuchMethodException e) {
- return false;
- }
- try {
- if (!constructor.isAccessible())
- AccessController.doPrivileged(new SetAccessibleAction(
- constructor));
- value2 = constructor
- .newInstance(new Object[] {((String) value2).trim()});
- }
- catch (IllegalAccessException e) {
- return false;
- }
- catch (InvocationTargetException e) {
- return false;
- }
- catch (InstantiationException e) {
- return false;
- }
-
- switch (operation) {
- case APPROX :
- case EQUAL :
- case GREATER :
- case LESS : {
- return value1.equals(value2);
- }
- }
- return false;
- }
-
- /**
- * Map a string for an APPROX (~=) comparison.
- *
- * This implementation removes white spaces. This is the minimum
- * implementation allowed by the OSGi spec.
- *
- * @param input Input string.
- * @return String ready for APPROX comparison.
- */
- private static String approxString(String input) {
- boolean changed = false;
- char[] output = input.toCharArray();
- int cursor = 0;
- for (int i = 0, length = output.length; i < length; i++) {
- char c = output[i];
-
- if (Character.isWhitespace(c)) {
- changed = true;
- continue;
- }
-
- output[cursor] = c;
- cursor++;
- }
-
- return changed ? new String(output, 0, cursor) : input;
- }
-
- /**
- * Parser class for OSGi filter strings. This class parses the complete
- * filter string and builds a tree of Filter objects rooted at the
- * parent.
- */
- private static class Parser {
- private final String filterstring;
- private final char[] filterChars;
- private int pos;
-
- Parser(String filterstring) {
- this.filterstring = filterstring;
- filterChars = filterstring.toCharArray();
- pos = 0;
- }
-
- FilterImpl parse() throws InvalidSyntaxException {
- FilterImpl filter;
- try {
- filter = parse_filter();
- }
- catch (ArrayIndexOutOfBoundsException e) {
- throw new InvalidSyntaxException("Filter ended abruptly",
- filterstring);
- }
-
- if (pos != filterChars.length) {
- throw new InvalidSyntaxException(
- "Extraneous trailing characters: "
- + filterstring.substring(pos), filterstring);
- }
- return filter;
- }
-
- private FilterImpl parse_filter() throws InvalidSyntaxException {
- FilterImpl filter;
- skipWhiteSpace();
-
- if (filterChars[pos] != '(') {
- throw new InvalidSyntaxException("Missing '(': "
- + filterstring.substring(pos), filterstring);
- }
-
- pos++;
-
- filter = parse_filtercomp();
-
- skipWhiteSpace();
-
- if (filterChars[pos] != ')') {
- throw new InvalidSyntaxException("Missing ')': "
- + filterstring.substring(pos), filterstring);
- }
-
- pos++;
-
- skipWhiteSpace();
-
- return filter;
- }
-
- private FilterImpl parse_filtercomp() throws InvalidSyntaxException {
- skipWhiteSpace();
-
- char c = filterChars[pos];
-
- switch (c) {
- case '&' : {
- pos++;
- return parse_and();
- }
- case '|' : {
- pos++;
- return parse_or();
- }
- case '!' : {
- pos++;
- return parse_not();
- }
- }
- return parse_item();
- }
-
- private FilterImpl parse_and() throws InvalidSyntaxException {
- skipWhiteSpace();
-
- if (filterChars[pos] != '(') {
- throw new InvalidSyntaxException("Missing '(': "
- + filterstring.substring(pos), filterstring);
- }
-
- List operands = new ArrayList(10);
-
- while (filterChars[pos] == '(') {
- FilterImpl child = parse_filter();
- operands.add(child);
- }
-
- return new FilterImpl(FilterImpl.AND, null, operands
- .toArray(new FilterImpl[operands.size()]));
- }
-
- private FilterImpl parse_or() throws InvalidSyntaxException {
- skipWhiteSpace();
-
- if (filterChars[pos] != '(') {
- throw new InvalidSyntaxException("Missing '(': "
- + filterstring.substring(pos), filterstring);
- }
-
- List operands = new ArrayList(10);
-
- while (filterChars[pos] == '(') {
- FilterImpl child = parse_filter();
- operands.add(child);
- }
-
- return new FilterImpl(FilterImpl.OR, null, operands
- .toArray(new FilterImpl[operands.size()]));
- }
-
- private FilterImpl parse_not() throws InvalidSyntaxException {
- skipWhiteSpace();
-
- if (filterChars[pos] != '(') {
- throw new InvalidSyntaxException("Missing '(': "
- + filterstring.substring(pos), filterstring);
- }
-
- FilterImpl child = parse_filter();
-
- return new FilterImpl(FilterImpl.NOT, null, child);
- }
-
- private FilterImpl parse_item() throws InvalidSyntaxException {
- String attr = parse_attr();
-
- skipWhiteSpace();
-
- switch (filterChars[pos]) {
- case '~' : {
- if (filterChars[pos + 1] == '=') {
- pos += 2;
- return new FilterImpl(FilterImpl.APPROX, attr,
- parse_value());
- }
- break;
- }
- case '>' : {
- if (filterChars[pos + 1] == '=') {
- pos += 2;
- return new FilterImpl(FilterImpl.GREATER, attr,
- parse_value());
- }
- break;
- }
- case '<' : {
- if (filterChars[pos + 1] == '=') {
- pos += 2;
- return new FilterImpl(FilterImpl.LESS, attr,
- parse_value());
- }
- break;
- }
- case '=' : {
- if (filterChars[pos + 1] == '*') {
- int oldpos = pos;
- pos += 2;
- skipWhiteSpace();
- if (filterChars[pos] == ')') {
- return new FilterImpl(FilterImpl.PRESENT, attr,
- null);
- }
- pos = oldpos;
- }
-
- pos++;
- Object string = parse_substring();
-
- if (string instanceof String) {
- return new FilterImpl(FilterImpl.EQUAL, attr,
- string);
- }
- return new FilterImpl(FilterImpl.SUBSTRING, attr,
- string);
- }
- }
-
- throw new InvalidSyntaxException("Invalid operator: "
- + filterstring.substring(pos), filterstring);
- }
-
- private String parse_attr() throws InvalidSyntaxException {
- skipWhiteSpace();
-
- int begin = pos;
- int end = pos;
-
- char c = filterChars[pos];
-
- while (c != '~' && c != '<' && c != '>' && c != '=' && c != '('
- && c != ')') {
- pos++;
-
- if (!Character.isWhitespace(c)) {
- end = pos;
- }
-
- c = filterChars[pos];
- }
-
- int length = end - begin;
-
- if (length == 0) {
- throw new InvalidSyntaxException("Missing attr: "
- + filterstring.substring(pos), filterstring);
- }
-
- return new String(filterChars, begin, length);
- }
-
- private String parse_value() throws InvalidSyntaxException {
- StringBuffer sb = new StringBuffer(filterChars.length - pos);
-
- parseloop: while (true) {
- char c = filterChars[pos];
-
- switch (c) {
- case ')' : {
- break parseloop;
- }
-
- case '(' : {
- throw new InvalidSyntaxException("Invalid value: "
- + filterstring.substring(pos), filterstring);
- }
-
- case '\\' : {
- pos++;
- c = filterChars[pos];
- /* fall through into default */
- }
-
- default : {
- sb.append(c);
- pos++;
- break;
- }
- }
- }
-
- if (sb.length() == 0) {
- throw new InvalidSyntaxException("Missing value: "
- + filterstring.substring(pos), filterstring);
- }
-
- return sb.toString();
- }
-
- private Object parse_substring() throws InvalidSyntaxException {
- StringBuffer sb = new StringBuffer(filterChars.length - pos);
-
- List operands = new ArrayList(10);
-
- parseloop: while (true) {
- char c = filterChars[pos];
-
- switch (c) {
- case ')' : {
- if (sb.length() > 0) {
- operands.add(sb.toString());
- }
-
- break parseloop;
- }
-
- case '(' : {
- throw new InvalidSyntaxException("Invalid value: "
- + filterstring.substring(pos), filterstring);
- }
-
- case '*' : {
- if (sb.length() > 0) {
- operands.add(sb.toString());
- }
-
- sb.setLength(0);
-
- operands.add(null);
- pos++;
-
- break;
- }
-
- case '\\' : {
- pos++;
- c = filterChars[pos];
- /* fall through into default */
- }
-
- default : {
- sb.append(c);
- pos++;
- break;
- }
- }
- }
-
- int size = operands.size();
-
- if (size == 0) {
- throw new InvalidSyntaxException("Missing value: "
- + filterstring.substring(pos), filterstring);
- }
-
- if (size == 1) {
- Object single = operands.get(0);
-
- if (single != null) {
- return single;
- }
- }
-
- return operands.toArray(new String[size]);
- }
-
- private void skipWhiteSpace() {
- for (int length = filterChars.length; (pos < length)
- && Character.isWhitespace(filterChars[pos]);) {
- pos++;
- }
- }
- }
- }
-
- /**
- * This Dictionary is used for case-insensitive key lookup during filter
- * evaluation. This Dictionary implementation only supports the get
- * operation using a String key as no other operations are used by the
- * Filter implementation.
- */
- private static class CaseInsensitiveDictionary extends Dictionary {
- private final Dictionary dictionary;
- private final String[] keys;
-
- /**
- * Create a case insensitive dictionary from the specified dictionary.
- *
- * @param dictionary
- * @throws IllegalArgumentException If <code>dictionary</code> contains
- * case variants of the same key name.
- */
- CaseInsensitiveDictionary(Dictionary dictionary) {
- if (dictionary == null) {
- this.dictionary = null;
- this.keys = new String[0];
- return;
- }
- this.dictionary = dictionary;
- List keyList = new ArrayList(dictionary.size());
- for (Enumeration e = dictionary.keys(); e.hasMoreElements();) {
- Object k = e.nextElement();
- if (k instanceof String) {
- String key = (String) k;
- for (Iterator i = keyList.iterator(); i.hasNext();) {
- if (key.equalsIgnoreCase((String) i.next())) {
- throw new IllegalArgumentException();
- }
- }
- keyList.add(key);
- }
- }
- this.keys = (String[]) keyList.toArray(new String[keyList.size()]);
- }
-
- public Object get(Object o) {
- String k = (String) o;
- for (int i = 0, length = keys.length; i < length; i++) {
- String key = keys[i];
- if (key.equalsIgnoreCase(k)) {
- return dictionary.get(key);
- }
- }
- return null;
- }
-
- public boolean isEmpty() {
- throw new UnsupportedOperationException();
- }
-
- public Enumeration keys() {
- throw new UnsupportedOperationException();
- }
-
- public Enumeration elements() {
- throw new UnsupportedOperationException();
- }
-
- public Object put(Object key, Object value) {
- throw new UnsupportedOperationException();
- }
-
- public Object remove(Object key) {
- throw new UnsupportedOperationException();
- }
-
- public int size() {
- throw new UnsupportedOperationException();
- }
- }
-
- /**
- * This Dictionary is used for key lookup from a ServiceReference during
- * filter evaluation. This Dictionary implementation only supports the get
- * operation using a String key as no other operations are used by the
- * Filter implementation.
- */
- private static class ServiceReferenceDictionary extends Dictionary {
- private final ServiceReference reference;
-
- ServiceReferenceDictionary(ServiceReference reference) {
- this.reference = reference;
- }
-
- public Object get(Object key) {
- if (reference == null) {
- return null;
- }
- return reference.getProperty((String) key);
- }
-
- public boolean isEmpty() {
- throw new UnsupportedOperationException();
- }
-
- public Enumeration keys() {
- throw new UnsupportedOperationException();
- }
-
- public Enumeration elements() {
- throw new UnsupportedOperationException();
- }
-
- public Object put(Object key, Object value) {
- throw new UnsupportedOperationException();
- }
-
- public Object remove(Object key) {
- throw new UnsupportedOperationException();
- }
-
- public int size() {
- throw new UnsupportedOperationException();
- }
- }
-
- private static class SetAccessibleAction implements PrivilegedAction {
- private final AccessibleObject accessible;
-
- SetAccessibleAction(AccessibleObject accessible) {
- this.accessible = accessible;
- }
-
- public Object run() {
- accessible.setAccessible(true);
- return null;
- }
- }
-
- /**
- * This class contains a method to match a distinguished name (DN) chain
- * against and DN chain pattern.
- * <p>
- * The format of DNs are given in RFC 2253. We represent a signature chain
- * for an X.509 certificate as a semicolon separated list of DNs. This is
- * what we refer to as the DN chain. Each DN is made up of relative
- * distinguished names (RDN) which in turn are made up of key value pairs.
- * For example:
- *
- * <pre>
- * cn=ben+ou=research,o=ACME,c=us;ou=Super CA,c=CA
- * </pre>
- *
- * is made up of two DNs: "<code>cn=ben+ou=research,o=ACME,c=us</code>
- * " and " <code>ou=Super CA,c=CA</code>
- * ". The first DN is made of of three RDNs: "
- * <code>cn=ben+ou=research</code>" and "<code>o=ACME</code>" and "
- * <code>c=us</code>". The first RDN has two name value pairs: "
- * <code>cn=ben</code>" and "<code>ou=research</code>".
- * <p>
- * A chain pattern makes use of wildcards ('*' or '-') to match against DNs,
- * and wildcards ('*') to match againts DN prefixes, and value. If a DN in a
- * match pattern chain is made up of a wildcard ("*"), that wildcard will
- * match zero or one DNs in the chain. If a DN in a match pattern chain is
- * made up of a wildcard ("-"), that wildcard will match zero or more DNs in
- * the chain. If the first RDN of a DN is the wildcard ("*"), that DN will
- * match any other DN with the same suffix (the DN with the wildcard RDN
- * removed). If a value of a name/value pair is a wildcard ("*"), the value
- * will match any value for that name.
- */
- private static class DNChainMatching {
- private static final String MINUS_WILDCARD = "-";
- private static final String STAR_WILDCARD = "*";
-
- /**
- * Check the name/value pairs of the rdn against the pattern.
- *
- * @param rdn List of name value pairs for a given RDN.
- * @param rdnPattern List of name value pattern pairs.
- * @return true if the list of name value pairs match the pattern.
- */
- private static boolean rdnmatch(List rdn, List rdnPattern) {
- if (rdn.size() != rdnPattern.size()) {
- return false;
- }
- for (int i = 0; i < rdn.size(); i++) {
- String rdnNameValue = (String) rdn.get(i);
- String patNameValue = (String) rdnPattern.get(i);
- int rdnNameEnd = rdnNameValue.indexOf('=');
- int patNameEnd = patNameValue.indexOf('=');
- if (rdnNameEnd != patNameEnd
- || !rdnNameValue.regionMatches(0, patNameValue, 0,
- rdnNameEnd)) {
- return false;
- }
- String patValue = patNameValue.substring(patNameEnd);
- String rdnValue = rdnNameValue.substring(rdnNameEnd);
- if (!rdnValue.equals(patValue) && !patValue.equals("=*")
- && !patValue.equals("=#16012a")) {
- return false;
- }
- }
- return true;
- }
-
- private static boolean dnmatch(List dn, List dnPattern) {
- int dnStart = 0;
- int patStart = 0;
- int patLen = dnPattern.size();
- if (patLen == 0) {
- return false;
- }
- if (dnPattern.get(0).equals(STAR_WILDCARD)) {
- patStart = 1;
- patLen--;
- }
- if (dn.size() < patLen) {
- return false;
- }
- else {
- if (dn.size() > patLen) {
- if (!dnPattern.get(0).equals(STAR_WILDCARD)) {
- // If the number of rdns do not match we must have a
- // prefix map
- return false;
- }
- // The rdnPattern and rdn must have the same number of
- // elements
- dnStart = dn.size() - patLen;
- }
- }
- for (int i = 0; i < patLen; i++) {
- if (!rdnmatch((List) dn.get(i + dnStart), (List) dnPattern
- .get(i + patStart))) {
- return false;
- }
- }
- return true;
- }
-
- /**
- * Parses a distinguished name chain pattern and returns a List where
- * each element represents a distinguished name (DN) in the chain of
- * DNs. Each element will be either a String, if the element represents
- * a wildcard ("*" or "-"), or a List representing an RDN. Each element
- * in the RDN List will be a String, if the element represents a
- * wildcard ("*"), or a List of Strings, each String representing a
- * name/value pair in the RDN.
- *
- * @param dnChain
- * @return a list of DNs.
- * @throws IllegalArgumentException
- */
- private static List parseDNchainPattern(String dnChain) {
- if (dnChain == null) {
- throw new IllegalArgumentException(
- "The DN chain must not be null.");
- }
- List parsed = new ArrayList();
- int startIndex = 0;
- startIndex = skipSpaces(dnChain, startIndex);
- while (startIndex < dnChain.length()) {
- int endIndex = startIndex;
- boolean inQuote = false;
- out: while (endIndex < dnChain.length()) {
- char c = dnChain.charAt(endIndex);
- switch (c) {
- case '"' :
- inQuote = !inQuote;
- break;
- case '\\' :
- endIndex++; // skip the escaped char
- break;
- case ';' :
- if (!inQuote)
- break out;
- }
- endIndex++;
- }
- if (endIndex > dnChain.length()) {
- throw new IllegalArgumentException("unterminated escape");
- }
- parsed.add(dnChain.substring(startIndex, endIndex));
- startIndex = endIndex + 1;
- startIndex = skipSpaces(dnChain, startIndex);
- }
- return parseDNchain(parsed);
- }
-
- private static List parseDNchain(List chain) {
- if (chain == null) {
- throw new IllegalArgumentException("DN chain must not be null.");
- }
- chain = new ArrayList(chain);
- // Now we parse is a list of strings, lets make List of rdn out
- // of them
- for (int i = 0; i < chain.size(); i++) {
- String dn = (String) chain.get(i);
- if (dn.equals(STAR_WILDCARD) || dn.equals(MINUS_WILDCARD)) {
- continue;
- }
- List rdns = new ArrayList();
- if (dn.charAt(0) == '*') {
- if (dn.charAt(1) != ',') {
- throw new IllegalArgumentException(
- "invalid wildcard prefix");
- }
- rdns.add(STAR_WILDCARD);
- dn = new X500Principal(dn.substring(2))
- .getName(X500Principal.CANONICAL);
- }
- else {
- dn = new X500Principal(dn).getName(X500Principal.CANONICAL);
- }
- // Now dn is a nice CANONICAL DN
- parseDN(dn, rdns);
- chain.set(i, rdns);
- }
- if (chain.size() == 0) {
- throw new IllegalArgumentException("empty DN chain");
- }
- return chain;
- }
-
- /**
- * Increment startIndex until the end of dnChain is hit or until it is
- * the index of a non-space character.
- */
- private static int skipSpaces(String dnChain, int startIndex) {
- while (startIndex < dnChain.length()
- && dnChain.charAt(startIndex) == ' ') {
- startIndex++;
- }
- return startIndex;
- }
-
- /**
- * Takes a distinguished name in canonical form and fills in the
- * rdnArray with the extracted RDNs.
- *
- * @param dn the distinguished name in canonical form.
- * @param rdn the list to fill in with RDNs extracted from the dn
- * @throws IllegalArgumentException if a formatting error is found.
- */
- private static void parseDN(String dn, List rdn) {
- int startIndex = 0;
- char c = '\0';
- List nameValues = new ArrayList();
- while (startIndex < dn.length()) {
- int endIndex;
- for (endIndex = startIndex; endIndex < dn.length(); endIndex++) {
- c = dn.charAt(endIndex);
- if (c == ',' || c == '+') {
- break;
- }
- if (c == '\\') {
- endIndex++; // skip the escaped char
- }
- }
- if (endIndex > dn.length()) {
- throw new IllegalArgumentException("unterminated escape "
- + dn);
- }
- nameValues.add(dn.substring(startIndex, endIndex));
- if (c != '+') {
- rdn.add(nameValues);
- if (endIndex != dn.length()) {
- nameValues = new ArrayList();
- }
- else {
- nameValues = null;
- }
- }
- startIndex = endIndex + 1;
- }
- if (nameValues != null) {
- throw new IllegalArgumentException("improperly terminated DN "
- + dn);
- }
- }
-
- /**
- * This method will return an 'index' which points to a non-wildcard DN
- * or the end-of-list.
- */
- private static int skipWildCards(List dnChainPattern,
- int dnChainPatternIndex) {
- int i;
- for (i = dnChainPatternIndex; i < dnChainPattern.size(); i++) {
- Object dnPattern = dnChainPattern.get(i);
- if (dnPattern instanceof String) {
- if (!dnPattern.equals(STAR_WILDCARD)
- && !dnPattern.equals(MINUS_WILDCARD)) {
- throw new IllegalArgumentException(
- "expected wildcard in DN pattern");
- }
- // otherwise continue skipping over wild cards
- }
- else {
- if (dnPattern instanceof List) {
- // if its a list then we have our 'non-wildcard' DN
- break;
- }
- else {
- // unknown member of the DNChainPattern
- throw new IllegalArgumentException(
- "expected String or List in DN Pattern");
- }
- }
- }
- // i either points to end-of-list, or to the first
- // non-wildcard pattern after dnChainPatternIndex
- return i;
- }
-
- /**
- * recursively attempt to match the DNChain, and the DNChainPattern
- * where DNChain is of the format: "DN;DN;DN;" and DNChainPattern is of
- * the format: "DNPattern;*;DNPattern" (or combinations of this)
- */
- private static boolean dnChainMatch(List dnChain, int dnChainIndex,
- List dnChainPattern, int dnChainPatternIndex)
- throws IllegalArgumentException {
- if (dnChainIndex >= dnChain.size()) {
- return false;
- }
- if (dnChainPatternIndex >= dnChainPattern.size()) {
- return false;
- }
- // check to see what the pattern starts with
- Object dnPattern = dnChainPattern.get(dnChainPatternIndex);
- if (dnPattern instanceof String) {
- if (!dnPattern.equals(STAR_WILDCARD)
- && !dnPattern.equals(MINUS_WILDCARD)) {
- throw new IllegalArgumentException(
- "expected wildcard in DN pattern");
- }
- // here we are processing a wild card as the first DN
- // skip all wildcard DN's
- if (dnPattern.equals(MINUS_WILDCARD)) {
- dnChainPatternIndex = skipWildCards(dnChainPattern,
- dnChainPatternIndex);
- }
- else {
- dnChainPatternIndex++; // only skip the '*' wildcard
- }
- if (dnChainPatternIndex >= dnChainPattern.size()) {
- // return true iff the wild card is '-' or if we are at the
- // end of the chain
- return dnPattern.equals(MINUS_WILDCARD) ? true : dnChain
- .size() - 1 == dnChainIndex;
- }
- //
- // we will now recursively call to see if the rest of the
- // DNChainPattern matches increasingly smaller portions of the
- // rest of the DNChain
- //
- if (dnPattern.equals(STAR_WILDCARD)) {
- // '*' option: only wildcard on 0 or 1
- return dnChainMatch(dnChain, dnChainIndex, dnChainPattern,
- dnChainPatternIndex)
- || dnChainMatch(dnChain, dnChainIndex + 1,
- dnChainPattern, dnChainPatternIndex);
- }
- for (int i = dnChainIndex; i < dnChain.size(); i++) {
- // '-' option: wildcard 0 or more
- if (dnChainMatch(dnChain, i, dnChainPattern,
- dnChainPatternIndex)) {
- return true;
- }
- }
- // if we are here, then we didn't find a match.. fall through to
- // failure
- }
- else {
- if (dnPattern instanceof List) {
- // here we have to do a deeper check for each DN in the
- // pattern until we hit a wild card
- do {
- if (!dnmatch((List) dnChain.get(dnChainIndex),
- (List) dnPattern)) {
- return false;
- }
- // go to the next set of DN's in both chains
- dnChainIndex++;
- dnChainPatternIndex++;
- // if we finished the pattern then it all matched
- if ((dnChainIndex >= dnChain.size())
- && (dnChainPatternIndex >= dnChainPattern
- .size())) {
- return true;
- }
- // if the DN Chain is finished, but the pattern isn't
- // finished then if the rest of the pattern is not
- // wildcard then we are done
- if (dnChainIndex >= dnChain.size()) {
- dnChainPatternIndex = skipWildCards(dnChainPattern,
- dnChainPatternIndex);
- // return TRUE iff the pattern index moved past the
- // list-size (implying that the rest of the pattern
- // is all wildcards)
- return dnChainPatternIndex >= dnChainPattern.size();
- }
- // if the pattern finished, but the chain continues then
- // we have a mis-match
- if (dnChainPatternIndex >= dnChainPattern.size()) {
- return false;
- }
- // get the next DN Pattern
- dnPattern = dnChainPattern.get(dnChainPatternIndex);
- if (dnPattern instanceof String) {
- if (!dnPattern.equals(STAR_WILDCARD)
- && !dnPattern.equals(MINUS_WILDCARD)) {
- throw new IllegalArgumentException(
- "expected wildcard in DN pattern");
- }
- // if the next DN is a 'wildcard', then we will
- // recurse
- return dnChainMatch(dnChain, dnChainIndex,
- dnChainPattern, dnChainPatternIndex);
- }
- else {
- if (!(dnPattern instanceof List)) {
- throw new IllegalArgumentException(
- "expected String or List in DN Pattern");
- }
- }
- // if we are here, then we will just continue to the
- // match the next set of DN's from the DNChain, and the
- // DNChainPattern since both are lists
- } while (true);
- // should never reach here?
- }
- else {
- throw new IllegalArgumentException(
- "expected String or List in DN Pattern");
- }
- }
- // if we get here, the the default return is 'mis-match'
- return false;
- }
-
- /**
- * Matches a distinguished name chain against a pattern of a
- * distinguished name chain.
- *
- * @param dnChain
- * @param pattern the pattern of distinguished name (DN) chains to match
- * against the dnChain. Wildcards ("*" or "-") can be used in
- * three cases:
- * <ol>
- * <li>As a DN. In this case, the DN will consist of just the "*"
- * or "-". When "*" is used it will match zero or one DNs. When
- * "-" is used it will match zero or more DNs. For example,
- * "cn=me,c=US;*;cn=you" will match
- * "cn=me,c=US";cn=you" and "cn=me,c=US;cn=her;cn=you". The
- * pattern "cn=me,c=US;-;cn=you" will match "cn=me,c=US";cn=you"
- * and "cn=me,c=US;cn=her;cn=him;cn=you".
- * <li>As a DN prefix. In this case, the DN must start with "*,".
- * The wild card will match zero or more RDNs at the start of a
- * DN. For example, "*,cn=me,c=US;cn=you" will match
- * "cn=me,c=US";cn=you" and
- * "ou=my org unit,o=my org,cn=me,c=US;cn=you"</li>
- * <li>As a value. In this case the value of a name value pair in
- * an RDN will be a "*". The wildcard will match any value for
- * the given name. For example, "cn=*,c=US;cn=you" will match
- * "cn=me,c=US";cn=you" and "cn=her,c=US;cn=you", but it will not
- * match "ou=my org unit,c=US;cn=you". If the wildcard does not
- * occur by itself in the value, it will not be used as a
- * wildcard. In other words, "cn=m*,c=US;cn=you" represents the
- * common name of "m*" not any common name starting with "m".</li>
- * </ol>
- * @return true if dnChain matches the pattern.
- * @throws IllegalArgumentException
- */
- static boolean match(String pattern, List/* <String> */dnChain) {
- List parsedDNChain;
- List parsedDNPattern;
- try {
- parsedDNChain = parseDNchain(dnChain);
- }
- catch (RuntimeException e) {
- IllegalArgumentException iae = new IllegalArgumentException(
- "Invalid DN chain: " + toString(dnChain));
- iae.initCause(e);
- throw iae;
- }
- try {
- parsedDNPattern = parseDNchainPattern(pattern);
- }
- catch (RuntimeException e) {
- IllegalArgumentException iae = new IllegalArgumentException(
- "Invalid match pattern: " + pattern);
- iae.initCause(e);
- throw iae;
- }
- return dnChainMatch(parsedDNChain, 0, parsedDNPattern, 0);
- }
-
- private static String toString(List dnChain) {
- if (dnChain == null) {
- return null;
- }
- StringBuffer sb = new StringBuffer();
- for (Iterator iChain = dnChain.iterator(); iChain.hasNext();) {
- sb.append(iChain.next());
- if (iChain.hasNext()) {
- sb.append("; ");
- }
- }
- return sb.toString();
- }
- }
-}
diff --git a/org.osgi.core/src/main/java/org/osgi/framework/InvalidSyntaxException.java b/org.osgi.core/src/main/java/org/osgi/framework/InvalidSyntaxException.java
deleted file mode 100644
index f67fd43..0000000
--- a/org.osgi.core/src/main/java/org/osgi/framework/InvalidSyntaxException.java
+++ /dev/null
@@ -1,113 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2000, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.osgi.framework;
-
-/**
- * A Framework exception used to indicate that a filter string has an invalid
- * syntax.
- *
- * <p>
- * An <code>InvalidSyntaxException</code> object indicates that a filter
- * string parameter has an invalid syntax and cannot be parsed. See
- * {@link Filter} for a description of the filter string syntax.
- *
- * <p>
- * This exception conforms to the general purpose exception chaining mechanism.
- *
- * @version $Revision: 6083 $
- */
-
-public class InvalidSyntaxException extends Exception {
- static final long serialVersionUID = -4295194420816491875L;
- /**
- * The invalid filter string.
- */
- private final String filter;
-
- /**
- * Creates an exception of type <code>InvalidSyntaxException</code>.
- *
- * <p>
- * This method creates an <code>InvalidSyntaxException</code> object with
- * the specified message and the filter string which generated the
- * exception.
- *
- * @param msg The message.
- * @param filter The invalid filter string.
- */
- public InvalidSyntaxException(String msg, String filter) {
- super(msg);
- this.filter = filter;
- }
-
- /**
- * Creates an exception of type <code>InvalidSyntaxException</code>.
- *
- * <p>
- * This method creates an <code>InvalidSyntaxException</code> object with
- * the specified message and the filter string which generated the
- * exception.
- *
- * @param msg The message.
- * @param filter The invalid filter string.
- * @param cause The cause of this exception.
- * @since 1.3
- */
- public InvalidSyntaxException(String msg, String filter, Throwable cause) {
- super(msg, cause);
- this.filter = filter;
- }
-
- /**
- * Returns the filter string that generated the
- * <code>InvalidSyntaxException</code> object.
- *
- * @return The invalid filter string.
- * @see BundleContext#getServiceReferences
- * @see BundleContext#addServiceListener(ServiceListener,String)
- */
- public String getFilter() {
- return filter;
- }
-
- /**
- * Returns the cause of this exception or <code>null</code> if no cause was
- * set.
- *
- * @return The cause of this exception or <code>null</code> if no cause was
- * set.
- * @since 1.3
- */
- public Throwable getCause() {
- return super.getCause();
- }
-
- /**
- * Initializes the cause of this exception to the specified value.
- *
- * @param cause The cause of this exception.
- * @return This exception.
- * @throws IllegalArgumentException If the specified cause is this
- * exception.
- * @throws IllegalStateException If the cause of this exception has already
- * been set.
- * @since 1.3
- */
- public Throwable initCause(Throwable cause) {
- return super.initCause(cause);
- }
-}
diff --git a/org.osgi.core/src/main/java/org/osgi/framework/PackagePermission.java b/org.osgi.core/src/main/java/org/osgi/framework/PackagePermission.java
deleted file mode 100644
index da2f540..0000000
--- a/org.osgi.core/src/main/java/org/osgi/framework/PackagePermission.java
+++ /dev/null
@@ -1,811 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2000, 2009). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.osgi.framework;
-
-import java.io.IOException;
-import java.io.NotSerializableException;
-import java.io.ObjectInputStream;
-import java.io.ObjectOutputStream;
-import java.io.ObjectStreamField;
-import java.security.AccessController;
-import java.security.BasicPermission;
-import java.security.Permission;
-import java.security.PermissionCollection;
-import java.security.PrivilegedAction;
-import java.util.ArrayList;
-import java.util.Collection;
-import java.util.Collections;
-import java.util.Dictionary;
-import java.util.Enumeration;
-import java.util.HashMap;
-import java.util.Hashtable;
-import java.util.Iterator;
-import java.util.List;
-import java.util.Map;
-
-/**
- * A bundle's authority to import or export a package.
- *
- * <p>
- * A package is a dot-separated string that defines a fully qualified Java
- * package.
- * <p>
- * For example:
- *
- * <pre>
- * org.osgi.service.http
- * </pre>
- *
- * <p>
- * <code>PackagePermission</code> has three actions: <code>exportonly</code>,
- * <code>import</code> and <code>export</code>. The <code>export</code> action,
- * which is deprecated, implies the <code>import</code> action.
- *
- * @ThreadSafe
- * @version $Revision: 7189 $
- */
-
-public final class PackagePermission extends BasicPermission {
- static final long serialVersionUID = -5107705877071099135L;
-
- /**
- * The action string <code>export</code>. The <code>export</code> action
- * implies the <code>import</code> action.
- *
- * @deprecated Since 1.5. Use <code>exportonly</code> instead.
- */
- public final static String EXPORT = "export";
-
- /**
- * The action string <code>exportonly</code>. The <code>exportonly</code>
- * action does not imply the <code>import</code> action.
- *
- * @since 1.5
- */
- public final static String EXPORTONLY = "exportonly";
-
- /**
- * The action string <code>import</code>.
- */
- public final static String IMPORT = "import";
-
- private final static int ACTION_EXPORT = 0x00000001;
- private final static int ACTION_IMPORT = 0x00000002;
- private final static int ACTION_ALL = ACTION_EXPORT
- | ACTION_IMPORT;
- final static int ACTION_NONE = 0;
-
- /**
- * The actions mask.
- */
- transient int action_mask;
-
- /**
- * The actions in canonical form.
- *
- * @serial
- */
- private volatile String actions = null;
-
- /**
- * The bundle used by this PackagePermission.
- */
- transient final Bundle bundle;
-
- /**
- * If this PackagePermission was constructed with a filter, this holds a
- * Filter matching object used to evaluate the filter in implies.
- */
- transient Filter filter;
-
- /**
- * This dictionary holds the properties of the permission, used to match a
- * filter in implies. This is not initialized until necessary, and then
- * cached in this object.
- */
- private transient volatile Dictionary properties;
-
- /**
- * Creates a new <code>PackagePermission</code> object.
- *
- * <p>
- * The name is specified as a normal Java package name: a dot-separated
- * string. Wildcards may be used.
- *
- * <pre>
- * name ::= <package name> | <package name ending in ".*"> | *
- * </pre>
- *
- * Examples:
- *
- * <pre>
- * org.osgi.service.http
- * javax.servlet.*
- * *
- * </pre>
- *
- * For the <code>import</code> action, the name can also be a filter
- * expression. The filter gives access to the following attributes:
- * <ul>
- * <li>signer - A Distinguished Name chain used to sign the exporting
- * bundle. Wildcards in a DN are not matched according to the filter string
- * rules, but according to the rules defined for a DN chain.</li>
- * <li>location - The location of the exporting bundle.</li>
- * <li>id - The bundle ID of the exporting bundle.</li>
- * <li>name - The symbolic name of the exporting bundle.</li>
- * <li>package.name - The name of the requested package.</li>
- * </ul>
- * Filter attribute names are processed in a case sensitive manner.
- *
- * <p>
- * Package Permissions are granted over all possible versions of a package.
- *
- * A bundle that needs to export a package must have the appropriate
- * <code>PackagePermission</code> for that package; similarly, a bundle that
- * needs to import a package must have the appropriate
- * <code>PackagePermssion</code> for that package.
- * <p>
- * Permission is granted for both classes and resources.
- *
- * @param name Package name or filter expression. A filter expression can
- * only be specified if the specified action is <code>import</code>.
- * @param actions <code>exportonly</code>,<code>import</code> (canonical
- * order).
- * @throws IllegalArgumentException If the specified name is a filter
- * expression and either the specified action is not
- * <code>import</code> or the filter has an invalid syntax.
- */
- public PackagePermission(String name, String actions) {
- this(name, parseActions(actions));
- if ((filter != null)
- && ((action_mask & ACTION_ALL) != ACTION_IMPORT)) {
- throw new IllegalArgumentException(
- "invalid action string for filter expression");
- }
- }
-
- /**
- * Creates a new requested <code>PackagePermission</code> object to be used
- * by code that must perform <code>checkPermission</code> for the
- * <code>import</code> action. <code>PackagePermission</code> objects
- * created with this constructor cannot be added to a
- * <code>PackagePermission</code> permission collection.
- *
- * @param name The name of the requested package to import.
- * @param exportingBundle The bundle exporting the requested package.
- * @param actions The action <code>import</code>.
- * @throws IllegalArgumentException If the specified action is not
- * <code>import</code> or the name is a filter expression.
- * @since 1.5
- */
- public PackagePermission(String name, Bundle exportingBundle, String actions) {
- super(name);
- setTransients(name, parseActions(actions));
- this.bundle = exportingBundle;
- if (exportingBundle == null) {
- throw new IllegalArgumentException("bundle must not be null");
- }
- if (filter != null) {
- throw new IllegalArgumentException("invalid name");
- }
- if ((action_mask & ACTION_ALL) != ACTION_IMPORT) {
- throw new IllegalArgumentException("invalid action string");
- }
- }
-
- /**
- * Package private constructor used by PackagePermissionCollection.
- *
- * @param name package name
- * @param mask action mask
- */
- PackagePermission(String name, int mask) {
- super(name);
- setTransients(name, mask);
- this.bundle = null;
- }
-
- /**
- * Called by constructors and when deserialized.
- *
- * @param mask action mask
- */
- private void setTransients(String name, int mask) {
- if ((mask == ACTION_NONE) || ((mask & ACTION_ALL) != mask)) {
- throw new IllegalArgumentException("invalid action string");
- }
- action_mask = mask;
- filter = parseFilter(name);
- }
-
- /**
- * Parse action string into action mask.
- *
- * @param actions Action string.
- * @return action mask.
- */
- private static int parseActions(String actions) {
- boolean seencomma = false;
-
- int mask = ACTION_NONE;
-
- if (actions == null) {
- return mask;
- }
-
- char[] a = actions.toCharArray();
-
- int i = a.length - 1;
- if (i < 0)
- return mask;
-
- while (i != -1) {
- char c;
-
- // skip whitespace
- while ((i != -1)
- && ((c = a[i]) == ' ' || c == '\r' || c == '\n'
- || c == '\f' || c == '\t'))
- i--;
-
- // check for the known strings
- int matchlen;
-
- if (i >= 5 && (a[i - 5] == 'i' || a[i - 5] == 'I')
- && (a[i - 4] == 'm' || a[i - 4] == 'M')
- && (a[i - 3] == 'p' || a[i - 3] == 'P')
- && (a[i - 2] == 'o' || a[i - 2] == 'O')
- && (a[i - 1] == 'r' || a[i - 1] == 'R')
- && (a[i] == 't' || a[i] == 'T')) {
- matchlen = 6;
- mask |= ACTION_IMPORT;
-
- }
- else
- if (i >= 5 && (a[i - 5] == 'e' || a[i - 5] == 'E')
- && (a[i - 4] == 'x' || a[i - 4] == 'X')
- && (a[i - 3] == 'p' || a[i - 3] == 'P')
- && (a[i - 2] == 'o' || a[i - 2] == 'O')
- && (a[i - 1] == 'r' || a[i - 1] == 'R')
- && (a[i] == 't' || a[i] == 'T')) {
- matchlen = 6;
- mask |= ACTION_EXPORT | ACTION_IMPORT;
-
- }
- else {
- if (i >= 9 && (a[i - 9] == 'e' || a[i - 9] == 'E')
- && (a[i - 8] == 'x' || a[i - 8] == 'X')
- && (a[i - 7] == 'p' || a[i - 7] == 'P')
- && (a[i - 6] == 'o' || a[i - 6] == 'O')
- && (a[i - 5] == 'r' || a[i - 5] == 'R')
- && (a[i - 4] == 't' || a[i - 4] == 'T')
- && (a[i - 3] == 'o' || a[i - 3] == 'O')
- && (a[i - 2] == 'n' || a[i - 2] == 'N')
- && (a[i - 1] == 'l' || a[i - 1] == 'L')
- && (a[i] == 'y' || a[i] == 'Y')) {
- matchlen = 10;
- mask |= ACTION_EXPORT;
-
- }
- else {
- // parse error
- throw new IllegalArgumentException(
- "invalid permission: " + actions);
- }
- }
-
- // make sure we didn't just match the tail of a word
- // like "ackbarfimport". Also, skip to the comma.
- seencomma = false;
- while (i >= matchlen && !seencomma) {
- switch (a[i - matchlen]) {
- case ',' :
- seencomma = true;
- /* FALLTHROUGH */
- case ' ' :
- case '\r' :
- case '\n' :
- case '\f' :
- case '\t' :
- break;
- default :
- throw new IllegalArgumentException(
- "invalid permission: " + actions);
- }
- i--;
- }
-
- // point i at the location of the comma minus one (or -1).
- i -= matchlen;
- }
-
- if (seencomma) {
- throw new IllegalArgumentException("invalid permission: " + actions);
- }
-
- return mask;
- }
-
- /**
- * Parse filter string into a Filter object.
- *
- * @param filterString The filter string to parse.
- * @return a Filter for this bundle. If the specified filterString is not a
- * filter expression, then <code>null</code> is returned.
- * @throws IllegalArgumentException If the filter syntax is invalid.
- */
- private static Filter parseFilter(String filterString) {
- filterString = filterString.trim();
- if (filterString.charAt(0) != '(') {
- return null;
- }
-
- try {
- return FrameworkUtil.createFilter(filterString);
- }
- catch (InvalidSyntaxException e) {
- IllegalArgumentException iae = new IllegalArgumentException(
- "invalid filter");
- iae.initCause(e);
- throw iae;
- }
- }
-
- /**
- * Determines if the specified permission is implied by this object.
- *
- * <p>
- * This method checks that the package name of the target is implied by the
- * package name of this object. The list of <code>PackagePermission</code>
- * actions must either match or allow for the list of the target object to
- * imply the target <code>PackagePermission</code> action.
- * <p>
- * The permission to export a package implies the permission to import the
- * named package.
- *
- * <pre>
- * x.y.*,"export" -> x.y.z,"export" is true
- * *,"import" -> x.y, "import" is true
- * *,"export" -> x.y, "import" is true
- * x.y,"export" -> x.y.z, "export" is false
- * </pre>
- *
- * @param p The requested permission.
- * @return <code>true</code> if the specified permission is implied by this
- * object; <code>false</code> otherwise.
- */
- public boolean implies(Permission p) {
- if (!(p instanceof PackagePermission)) {
- return false;
- }
- PackagePermission requested = (PackagePermission) p;
- if (bundle != null) {
- return false;
- }
- // if requested permission has a filter, then it is an invalid argument
- if (requested.filter != null) {
- return false;
- }
- return implies0(requested, ACTION_NONE);
- }
-
- /**
- * Internal implies method. Used by the implies and the permission
- * collection implies methods.
- *
- * @param requested The requested PackagePermission which has already be
- * validated as a proper argument. The requested PackagePermission
- * must not have a filter expression.
- * @param effective The effective actions with which to start.
- * @return <code>true</code> if the specified permission is implied by this
- * object; <code>false</code> otherwise.
- */
- boolean implies0(PackagePermission requested, int effective) {
- /* check actions first - much faster */
- effective |= action_mask;
- final int desired = requested.action_mask;
- if ((effective & desired) != desired) {
- return false;
- }
- /* Get filter if any */
- Filter f = filter;
- if (f == null) {
- return super.implies(requested);
- }
- return f.matchCase(requested.getProperties());
- }
-
- /**
- * Returns the canonical string representation of the
- * <code>PackagePermission</code> actions.
- *
- * <p>
- * Always returns present <code>PackagePermission</code> actions in the
- * following order: <code>EXPORTONLY</code>,<code>IMPORT</code>.
- *
- * @return Canonical string representation of the
- * <code>PackagePermission</code> actions.
- */
- public String getActions() {
- String result = actions;
- if (result == null) {
- StringBuffer sb = new StringBuffer();
- boolean comma = false;
-
- int mask = action_mask;
- if ((mask & ACTION_EXPORT) == ACTION_EXPORT) {
- sb.append(EXPORTONLY);
- comma = true;
- }
-
- if ((mask & ACTION_IMPORT) == ACTION_IMPORT) {
- if (comma)
- sb.append(',');
- sb.append(IMPORT);
- }
-
- actions = result = sb.toString();
- }
- return result;
- }
-
- /**
- * Returns a new <code>PermissionCollection</code> object suitable for
- * storing <code>PackagePermission</code> objects.
- *
- * @return A new <code>PermissionCollection</code> object.
- */
- public PermissionCollection newPermissionCollection() {
- return new PackagePermissionCollection();
- }
-
- /**
- * Determines the equality of two <code>PackagePermission</code> objects.
- *
- * This method checks that specified package has the same package name and
- * <code>PackagePermission</code> actions as this
- * <code>PackagePermission</code> object.
- *
- * @param obj The object to test for equality with this
- * <code>PackagePermission</code> object.
- * @return <code>true</code> if <code>obj</code> is a
- * <code>PackagePermission</code>, and has the same package name and
- * actions as this <code>PackagePermission</code> object;
- * <code>false</code> otherwise.
- */
- public boolean equals(Object obj) {
- if (obj == this) {
- return true;
- }
-
- if (!(obj instanceof PackagePermission)) {
- return false;
- }
-
- PackagePermission pp = (PackagePermission) obj;
-
- return (action_mask == pp.action_mask)
- && getName().equals(pp.getName())
- && ((bundle == pp.bundle) || ((bundle != null) && bundle
- .equals(pp.bundle)));
- }
-
- /**
- * Returns the hash code value for this object.
- *
- * @return A hash code value for this object.
- */
- public int hashCode() {
- int h = 31 * 17 + getName().hashCode();
- h = 31 * h + getActions().hashCode();
- if (bundle != null) {
- h = 31 * h + bundle.hashCode();
- }
- return h;
- }
-
- /**
- * WriteObject is called to save the state of this permission object to a
- * stream. The actions are serialized, and the superclass takes care of the
- * name.
- */
- private synchronized void writeObject(java.io.ObjectOutputStream s)
- throws IOException {
- if (bundle != null) {
- throw new NotSerializableException("cannot serialize");
- }
- // Write out the actions. The superclass takes care of the name
- // call getActions to make sure actions field is initialized
- if (actions == null)
- getActions();
- s.defaultWriteObject();
- }
-
- /**
- * readObject is called to restore the state of this permission from a
- * stream.
- */
- private synchronized void readObject(java.io.ObjectInputStream s)
- throws IOException, ClassNotFoundException {
- // Read in the action, then initialize the rest
- s.defaultReadObject();
- setTransients(getName(), parseActions(actions));
- }
-
- /**
- * Called by <code><@link PackagePermission#implies(Permission)></code>.
- *
- * @return a dictionary of properties for this permission.
- */
- private Dictionary getProperties() {
- Dictionary result = properties;
- if (result != null) {
- return result;
- }
- final Dictionary dict = new Hashtable(5);
- if (filter == null) {
- dict.put("package.name", getName());
- }
- if (bundle != null) {
- AccessController.doPrivileged(new PrivilegedAction() {
- public Object run() {
- dict.put("id", new Long(bundle.getBundleId()));
- dict.put("location", bundle.getLocation());
- String name = bundle.getSymbolicName();
- if (name != null) {
- dict.put("name", name);
- }
- SignerProperty signer = new SignerProperty(bundle);
- if (signer.isBundleSigned()) {
- dict.put("signer", signer);
- }
- return null;
- }
- });
- }
- return properties = dict;
- }
-}
-
-/**
- * Stores a set of <code>PackagePermission</code> permissions.
- *
- * @see java.security.Permission
- * @see java.security.Permissions
- * @see java.security.PermissionCollection
- */
-
-final class PackagePermissionCollection extends PermissionCollection {
- static final long serialVersionUID = -3350758995234427603L;
- /**
- * Table of permissions with names.
- *
- * @GuardedBy this
- */
- private transient Map permissions;
-
- /**
- * Boolean saying if "*" is in the collection.
- *
- * @serial
- * @GuardedBy this
- */
- private boolean all_allowed;
-
- /**
- * Table of permissions with filter expressions.
- *
- * @serial
- * @GuardedBy this
- */
- private Map filterPermissions;
-
- /**
- * Create an empty PackagePermissions object.
- */
- public PackagePermissionCollection() {
- permissions = new HashMap();
- all_allowed = false;
- }
-
- /**
- * Adds a permission to this permission collection.
- *
- * @param permission The <code>PackagePermission</code> object to add.
- * @throws IllegalArgumentException If the specified permission is not a
- * <code>PackagePermission</code> instance or was constructed with a
- * Bundle object.
- * @throws SecurityException If this
- * <code>PackagePermissionCollection</code> object has been marked
- * read-only.
- */
- public void add(final Permission permission) {
- if (!(permission instanceof PackagePermission)) {
- throw new IllegalArgumentException("invalid permission: "
- + permission);
- }
- if (isReadOnly()) {
- throw new SecurityException("attempt to add a Permission to a "
- + "readonly PermissionCollection");
- }
-
- final PackagePermission pp = (PackagePermission) permission;
- if (pp.bundle != null) {
- throw new IllegalArgumentException("cannot add to collection: "
- + pp);
- }
-
- final String name = pp.getName();
- final Filter f = pp.filter;
- synchronized (this) {
- /* select the bucket for the permission */
- Map pc;
- if (f != null) {
- pc = filterPermissions;
- if (pc == null) {
- filterPermissions = pc = new HashMap();
- }
- }
- else {
- pc = permissions;
- }
-
- final PackagePermission existing = (PackagePermission) pc.get(name);
- if (existing != null) {
- final int oldMask = existing.action_mask;
- final int newMask = pp.action_mask;
- if (oldMask != newMask) {
- pc
- .put(name, new PackagePermission(name, oldMask
- | newMask));
-
- }
- }
- else {
- pc.put(name, pp);
- }
-
- if (!all_allowed) {
- if (name.equals("*")) {
- all_allowed = true;
- }
- }
- }
- }
-
- /**
- * Determines if the specified permissions implies the permissions expressed
- * in <code>permission</code>.
- *
- * @param permission The Permission object to compare with this
- * <code>PackagePermission</code> object.
- * @return <code>true</code> if <code>permission</code> is a proper subset
- * of a permission in the set; <code>false</code> otherwise.
- */
- public boolean implies(final Permission permission) {
- if (!(permission instanceof PackagePermission)) {
- return false;
- }
- final PackagePermission requested = (PackagePermission) permission;
- /* if requested permission has a filter, then it is an invalid argument */
- if (requested.filter != null) {
- return false;
- }
- String requestedName = requested.getName();
- final int desired = requested.action_mask;
- int effective = PackagePermission.ACTION_NONE;
-
- Collection perms;
- synchronized (this) {
- Map pc = permissions;
- PackagePermission pp;
- /* short circuit if the "*" Permission was added */
- if (all_allowed) {
- pp = (PackagePermission) pc.get("*");
- if (pp != null) {
- effective |= pp.action_mask;
- if ((effective & desired) == desired) {
- return true;
- }
- }
- }
- /*
- * strategy: Check for full match first. Then work our way up the
- * name looking for matches on a.b.*
- */
- pp = (PackagePermission) pc.get(requestedName);
- if (pp != null) {
- /* we have a direct hit! */
- effective |= pp.action_mask;
- if ((effective & desired) == desired) {
- return true;
- }
- }
- /* work our way up the tree... */
- int last;
- int offset = requestedName.length() - 1;
- while ((last = requestedName.lastIndexOf(".", offset)) != -1) {
- requestedName = requestedName.substring(0, last + 1) + "*";
- pp = (PackagePermission) pc.get(requestedName);
- if (pp != null) {
- effective |= pp.action_mask;
- if ((effective & desired) == desired) {
- return true;
- }
- }
- offset = last - 1;
- }
- /*
- * we don't have to check for "*" as it was already checked before
- * we were called.
- */
- pc = filterPermissions;
- if (pc == null) {
- return false;
- }
- perms = pc.values();
- }
- /* iterate one by one over filteredPermissions */
- for (Iterator iter = perms.iterator(); iter.hasNext();) {
- if (((PackagePermission) iter.next())
- .implies0(requested, effective)) {
- return true;
- }
- }
- return false;
- }
-
- /**
- * Returns an enumeration of all <code>PackagePermission</code> objects in
- * the container.
- *
- * @return Enumeration of all <code>PackagePermission</code> objects.
- */
- public synchronized Enumeration elements() {
- List all = new ArrayList(permissions.values());
- Map pc = filterPermissions;
- if (pc != null) {
- all.addAll(pc.values());
- }
- return Collections.enumeration(all);
- }
-
- /* serialization logic */
- private static final ObjectStreamField[] serialPersistentFields = {
- new ObjectStreamField("permissions", Hashtable.class),
- new ObjectStreamField("all_allowed", Boolean.TYPE),
- new ObjectStreamField("filterPermissions", HashMap.class) };
-
- private synchronized void writeObject(ObjectOutputStream out)
- throws IOException {
- Hashtable hashtable = new Hashtable(permissions);
- ObjectOutputStream.PutField pfields = out.putFields();
- pfields.put("permissions", hashtable);
- pfields.put("all_allowed", all_allowed);
- pfields.put("filterPermissions", filterPermissions);
- out.writeFields();
- }
-
- private synchronized void readObject(java.io.ObjectInputStream in)
- throws IOException, ClassNotFoundException {
- ObjectInputStream.GetField gfields = in.readFields();
- Hashtable hashtable = (Hashtable) gfields.get("permissions", null);
- permissions = new HashMap(hashtable);
- all_allowed = gfields.get("all_allowed", false);
- filterPermissions = (HashMap) gfields.get("filterPermissions", null);
- }
-}
diff --git a/org.osgi.core/src/main/java/org/osgi/framework/ServiceEvent.java b/org.osgi.core/src/main/java/org/osgi/framework/ServiceEvent.java
deleted file mode 100644
index b7c9928..0000000
--- a/org.osgi.core/src/main/java/org/osgi/framework/ServiceEvent.java
+++ /dev/null
@@ -1,144 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2000, 2009). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.osgi.framework;
-
-import java.util.Dictionary;
-import java.util.EventObject;
-
-/**
- * An event from the Framework describing a service lifecycle change.
- * <p>
- * <code>ServiceEvent</code> objects are delivered to
- * <code>ServiceListener</code>s and <code>AllServiceListener</code>s when a
- * change occurs in this service's lifecycle. A type code is used to identify
- * the event type for future extendability.
- *
- * <p>
- * OSGi Alliance reserves the right to extend the set of types.
- *
- * @Immutable
- * @see ServiceListener
- * @see AllServiceListener
- * @version $Revision: 6542 $
- */
-
-public class ServiceEvent extends EventObject {
- static final long serialVersionUID = 8792901483909409299L;
- /**
- * Reference to the service that had a change occur in its lifecycle.
- */
- private final ServiceReference reference;
-
- /**
- * Type of service lifecycle change.
- */
- private final int type;
-
- /**
- * This service has been registered.
- * <p>
- * This event is synchronously delivered <strong>after</strong> the service
- * has been registered with the Framework.
- *
- * @see BundleContext#registerService(String[],Object,Dictionary)
- */
- public final static int REGISTERED = 0x00000001;
-
- /**
- * The properties of a registered service have been modified.
- * <p>
- * This event is synchronously delivered <strong>after</strong> the service
- * properties have been modified.
- *
- * @see ServiceRegistration#setProperties
- */
- public final static int MODIFIED = 0x00000002;
-
- /**
- * This service is in the process of being unregistered.
- * <p>
- * This event is synchronously delivered <strong>before</strong> the service
- * has completed unregistering.
- *
- * <p>
- * If a bundle is using a service that is <code>UNREGISTERING</code>, the
- * bundle should release its use of the service when it receives this event.
- * If the bundle does not release its use of the service when it receives
- * this event, the Framework will automatically release the bundle's use of
- * the service while completing the service unregistration operation.
- *
- * @see ServiceRegistration#unregister
- * @see BundleContext#ungetService
- */
- public final static int UNREGISTERING = 0x00000004;
-
- /**
- * The properties of a registered service have been modified and the new
- * properties no longer match the listener's filter.
- * <p>
- * This event is synchronously delivered <strong>after</strong> the service
- * properties have been modified. This event is only delivered to listeners
- * which were added with a non-<code>null</code> filter where the filter
- * matched the service properties prior to the modification but the filter
- * does not match the modified service properties.
- *
- * @see ServiceRegistration#setProperties
- * @since 1.5
- */
- public final static int MODIFIED_ENDMATCH = 0x00000008;
-
- /**
- * Creates a new service event object.
- *
- * @param type The event type.
- * @param reference A <code>ServiceReference</code> object to the service
- * that had a lifecycle change.
- */
- public ServiceEvent(int type, ServiceReference reference) {
- super(reference);
- this.reference = reference;
- this.type = type;
- }
-
- /**
- * Returns a reference to the service that had a change occur in its
- * lifecycle.
- * <p>
- * This reference is the source of the event.
- *
- * @return Reference to the service that had a lifecycle change.
- */
- public ServiceReference getServiceReference() {
- return reference;
- }
-
- /**
- * Returns the type of event. The event type values are:
- * <ul>
- * <li>{@link #REGISTERED} </li>
- * <li>{@link #MODIFIED} </li>
- * <li>{@link #MODIFIED_ENDMATCH} </li>
- * <li>{@link #UNREGISTERING} </li>
- * </ul>
- *
- * @return Type of service lifecycle change.
- */
-
- public int getType() {
- return type;
- }
-}
diff --git a/org.osgi.core/src/main/java/org/osgi/framework/ServiceException.java b/org.osgi.core/src/main/java/org/osgi/framework/ServiceException.java
deleted file mode 100644
index 4cf04a0..0000000
--- a/org.osgi.core/src/main/java/org/osgi/framework/ServiceException.java
+++ /dev/null
@@ -1,126 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2007, 2009). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.osgi.framework;
-
-/**
- * A service exception used to indicate that a service problem occurred.
- *
- * <p>
- * A <code>ServiceException</code> object is created by the Framework or
- * service implementation to denote an exception condition in the service. A
- * type code is used to identify the exception type for future extendability.
- * Service implementations may also create subclasses of
- * <code>ServiceException</code>. When subclassing, the subclass should set
- * the type to {@link #SUBCLASSED} to indicate that
- * <code>ServiceException</code> has been subclassed.
- *
- * <p>
- * This exception conforms to the general purpose exception chaining mechanism.
- *
- * @version $Revision: 6518 $
- * @since 1.5
- */
-
-public class ServiceException extends RuntimeException {
- static final long serialVersionUID = 3038963223712959631L;
-
- /**
- * Type of service exception.
- */
- private final int type;
-
- /**
- * No exception type is unspecified.
- */
- public static final int UNSPECIFIED = 0;
- /**
- * The service has been unregistered.
- */
- public static final int UNREGISTERED = 1;
- /**
- * The service factory produced an invalid service object.
- */
- public static final int FACTORY_ERROR = 2;
- /**
- * The service factory threw an exception.
- */
- public static final int FACTORY_EXCEPTION = 3;
- /**
- * The exception is a subclass of ServiceException. The subclass should be
- * examined for the type of the exception.
- */
- public static final int SUBCLASSED = 4;
- /**
- * An error occurred invoking a remote service.
- */
- public static final int REMOTE = 5;
-
- /**
- * Creates a <code>ServiceException</code> with the specified message and
- * exception cause.
- *
- * @param msg The associated message.
- * @param cause The cause of this exception.
- */
- public ServiceException(String msg, Throwable cause) {
- this(msg, UNSPECIFIED, cause);
- }
-
- /**
- * Creates a <code>ServiceException</code> with the specified message.
- *
- * @param msg The message.
- */
- public ServiceException(String msg) {
- this(msg, UNSPECIFIED);
- }
-
- /**
- * Creates a <code>ServiceException</code> with the specified message,
- * type and exception cause.
- *
- * @param msg The associated message.
- * @param type The type for this exception.
- * @param cause The cause of this exception.
- */
- public ServiceException(String msg, int type, Throwable cause) {
- super(msg, cause);
- this.type = type;
- }
-
- /**
- * Creates a <code>ServiceException</code> with the specified message and
- * type.
- *
- * @param msg The message.
- * @param type The type for this exception.
- */
- public ServiceException(String msg, int type) {
- super(msg);
- this.type = type;
- }
-
- /**
- * Returns the type for this exception or <code>UNSPECIFIED</code> if the
- * type was unspecified or unknown.
- *
- * @return The type of this exception.
- */
- public int getType() {
- return type;
- }
-}
diff --git a/org.osgi.core/src/main/java/org/osgi/framework/ServiceFactory.java b/org.osgi.core/src/main/java/org/osgi/framework/ServiceFactory.java
deleted file mode 100644
index c8f6bf3..0000000
--- a/org.osgi.core/src/main/java/org/osgi/framework/ServiceFactory.java
+++ /dev/null
@@ -1,100 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2000, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.osgi.framework;
-
-/**
- * Allows services to provide customized service objects in the OSGi
- * environment.
- *
- * <p>
- * When registering a service, a <code>ServiceFactory</code> object can be
- * used instead of a service object, so that the bundle developer can gain
- * control of the specific service object granted to a bundle that is using the
- * service.
- *
- * <p>
- * When this happens, the
- * <code>BundleContext.getService(ServiceReference)</code> method calls the
- * <code>ServiceFactory.getService</code> method to create a service object
- * specifically for the requesting bundle. The service object returned by the
- * <code>ServiceFactory</code> is cached by the Framework until the bundle
- * releases its use of the service.
- *
- * <p>
- * When the bundle's use count for the service equals zero (including the bundle
- * stopping or the service being unregistered), the
- * <code>ServiceFactory.ungetService</code> method is called.
- *
- * <p>
- * <code>ServiceFactory</code> objects are only used by the Framework and are
- * not made available to other bundles in the OSGi environment. The Framework
- * may concurrently call a <code>ServiceFactory</code>.
- *
- * @see BundleContext#getService
- * @ThreadSafe
- * @version $Revision: 5967 $
- */
-
-public interface ServiceFactory {
- /**
- * Creates a new service object.
- *
- * <p>
- * The Framework invokes this method the first time the specified
- * <code>bundle</code> requests a service object using the
- * <code>BundleContext.getService(ServiceReference)</code> method. The
- * service factory can then return a specific service object for each
- * bundle.
- *
- * <p>
- * The Framework caches the value returned (unless it is <code>null</code>),
- * and will return the same service object on any future call to
- * <code>BundleContext.getService</code> for the same bundle. This means the
- * Framework must not allow this method to be concurrently called for the
- * same bundle.
- *
- * <p>
- * The Framework will check if the returned service object is an instance of
- * all the classes named when the service was registered. If not, then
- * <code>null</code> is returned to the bundle.
- *
- * @param bundle The bundle using the service.
- * @param registration The <code>ServiceRegistration</code> object for the
- * service.
- * @return A service object that <strong>must</strong> be an instance of all
- * the classes named when the service was registered.
- * @see BundleContext#getService
- */
- public Object getService(Bundle bundle, ServiceRegistration registration);
-
- /**
- * Releases a service object.
- *
- * <p>
- * The Framework invokes this method when a service has been released by a
- * bundle. The service object may then be destroyed.
- *
- * @param bundle The bundle releasing the service.
- * @param registration The <code>ServiceRegistration</code> object for the
- * service.
- * @param service The service object returned by a previous call to the
- * <code>ServiceFactory.getService</code> method.
- * @see BundleContext#ungetService
- */
- public void ungetService(Bundle bundle, ServiceRegistration registration,
- Object service);
-}
diff --git a/org.osgi.core/src/main/java/org/osgi/framework/ServiceListener.java b/org.osgi.core/src/main/java/org/osgi/framework/ServiceListener.java
deleted file mode 100644
index ec08560..0000000
--- a/org.osgi.core/src/main/java/org/osgi/framework/ServiceListener.java
+++ /dev/null
@@ -1,64 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2000, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.osgi.framework;
-
-import java.util.EventListener;
-
-/**
- * A <code>ServiceEvent</code> listener. <code>ServiceListener</code> is a
- * listener interface that may be implemented by a bundle developer. When a
- * <code>ServiceEvent</code> is fired, it is synchronously delivered to a
- * <code>ServiceListener</code>. The Framework may deliver
- * <code>ServiceEvent</code> objects to a <code>ServiceListener</code> out
- * of order and may concurrently call and/or reenter a
- * <code>ServiceListener</code>.
- *
- * <p>
- * A <code>ServiceListener</code> object is registered with the Framework
- * using the <code>BundleContext.addServiceListener</code> method.
- * <code>ServiceListener</code> objects are called with a
- * <code>ServiceEvent</code> object when a service is registered, modified, or
- * is in the process of unregistering.
- *
- * <p>
- * <code>ServiceEvent</code> object delivery to <code>ServiceListener</code>
- * objects is filtered by the filter specified when the listener was registered.
- * If the Java Runtime Environment supports permissions, then additional
- * filtering is done. <code>ServiceEvent</code> objects are only delivered to
- * the listener if the bundle which defines the listener object's class has the
- * appropriate <code>ServicePermission</code> to get the service using at
- * least one of the named classes under which the service was registered.
- *
- * <p>
- * <code>ServiceEvent</code> object delivery to <code>ServiceListener</code>
- * objects is further filtered according to package sources as defined in
- * {@link ServiceReference#isAssignableTo(Bundle, String)}.
- *
- * @see ServiceEvent
- * @see ServicePermission
- * @ThreadSafe
- * @version $Revision: 5673 $
- */
-
-public interface ServiceListener extends EventListener {
- /**
- * Receives notification that a service has had a lifecycle change.
- *
- * @param event The <code>ServiceEvent</code> object.
- */
- public void serviceChanged(ServiceEvent event);
-}
diff --git a/org.osgi.core/src/main/java/org/osgi/framework/ServicePermission.java b/org.osgi.core/src/main/java/org/osgi/framework/ServicePermission.java
deleted file mode 100644
index d2f3c31..0000000
--- a/org.osgi.core/src/main/java/org/osgi/framework/ServicePermission.java
+++ /dev/null
@@ -1,932 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2000, 2009). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.osgi.framework;
-
-import java.io.IOException;
-import java.io.NotSerializableException;
-import java.io.ObjectInputStream;
-import java.io.ObjectOutputStream;
-import java.io.ObjectStreamField;
-import java.security.AccessController;
-import java.security.BasicPermission;
-import java.security.Permission;
-import java.security.PermissionCollection;
-import java.security.PrivilegedAction;
-import java.util.ArrayList;
-import java.util.Collection;
-import java.util.Collections;
-import java.util.Dictionary;
-import java.util.Enumeration;
-import java.util.HashMap;
-import java.util.Hashtable;
-import java.util.Iterator;
-import java.util.List;
-import java.util.Map;
-
-/**
- * A bundle's authority to register or get a service.
- * <ul>
- * <li>The <code>register</code> action allows a bundle to register a service on
- * the specified names.
- * <li>The <code>get</code> action allows a bundle to detect a service and get
- * it.
- * </ul>
- * Permission to get a service is required in order to detect events regarding
- * the service. Untrusted bundles should not be able to detect the presence of
- * certain services unless they have the appropriate
- * <code>ServicePermission</code> to get the specific service.
- *
- * @ThreadSafe
- * @version $Revision: 7189 $
- */
-
-public final class ServicePermission extends BasicPermission {
- static final long serialVersionUID = -7662148639076511574L;
- /**
- * The action string <code>get</code>.
- */
- public final static String GET = "get";
- /**
- * The action string <code>register</code>.
- */
- public final static String REGISTER = "register";
-
- private final static int ACTION_GET = 0x00000001;
- private final static int ACTION_REGISTER = 0x00000002;
- private final static int ACTION_ALL = ACTION_GET
- | ACTION_REGISTER;
- final static int ACTION_NONE = 0;
-
- /**
- * The actions mask.
- */
- transient int action_mask;
-
- /**
- * The actions in canonical form.
- *
- * @serial
- */
- private volatile String actions = null;
-
- /**
- * The service used by this ServicePermission. Must be null if not
- * constructed with a service.
- */
- transient final ServiceReference service;
-
- /**
- * The object classes for this ServicePermission. Must be null if not
- * constructed with a service.
- */
- transient final String[] objectClass;
-
- /**
- * If this ServicePermission was constructed with a filter, this holds a
- * Filter matching object used to evaluate the filter in implies.
- */
- transient Filter filter;
-
- /**
- * This dictionary holds the properties of the permission, used to match a
- * filter in implies. This is not initialized until necessary, and then
- * cached in this object.
- */
- private transient volatile Dictionary properties;
-
- /**
- * True if constructed with a name and the name is "*" or ends with ".*".
- */
- private transient boolean wildcard;
-
- /**
- * If constructed with a name and the name ends with ".*", this contains the
- * name without the final "*".
- */
- private transient String prefix;
-
- /**
- * Create a new ServicePermission.
- *
- * <p>
- * The name of the service is specified as a fully qualified class name.
- * Wildcards may be used.
- *
- * <pre>
- * name ::= <class name> | <class name ending in ".*"> | *
- * </pre>
- *
- * Examples:
- *
- * <pre>
- * org.osgi.service.http.HttpService
- * org.osgi.service.http.*
- * *
- * </pre>
- *
- * For the <code>get</code> action, the name can also be a filter
- * expression. The filter gives access to the service properties as well as
- * the following attributes:
- * <ul>
- * <li>signer - A Distinguished Name chain used to sign the bundle
- * publishing the service. Wildcards in a DN are not matched according to
- * the filter string rules, but according to the rules defined for a DN
- * chain.</li>
- * <li>location - The location of the bundle publishing the service.</li>
- * <li>id - The bundle ID of the bundle publishing the service.</li>
- * <li>name - The symbolic name of the bundle publishing the service.</li>
- * </ul>
- * Since the above attribute names may conflict with service property names
- * used by a service, you can prefix an attribute name with '@' in the
- * filter expression to match against the service property and not one of
- * the above attributes. Filter attribute names are processed in a case
- * sensitive manner unless the attribute references a service property.
- * Service properties names are case insensitive.
- *
- * <p>
- * There are two possible actions: <code>get</code> and
- * <code>register</code>. The <code>get</code> permission allows the owner
- * of this permission to obtain a service with this name. The
- * <code>register</code> permission allows the bundle to register a service
- * under that name.
- *
- * @param name The service class name
- * @param actions <code>get</code>,<code>register</code> (canonical order)
- * @throws IllegalArgumentException If the specified name is a filter
- * expression and either the specified action is not
- * <code>get</code> or the filter has an invalid syntax.
- */
- public ServicePermission(String name, String actions) {
- this(name, parseActions(actions));
- if ((filter != null)
- && ((action_mask & ACTION_ALL) != ACTION_GET)) {
- throw new IllegalArgumentException(
- "invalid action string for filter expression");
- }
- }
-
- /**
- * Creates a new requested <code>ServicePermission</code> object to be used
- * by code that must perform <code>checkPermission</code> for the
- * <code>get</code> action. <code>ServicePermission</code> objects created
- * with this constructor cannot be added to a <code>ServicePermission</code>
- * permission collection.
- *
- * @param reference The requested service.
- * @param actions The action <code>get</code>.
- * @throws IllegalArgumentException If the specified action is not
- * <code>get</code> or reference is <code>null</code>.
- * @since 1.5
- */
- public ServicePermission(ServiceReference reference, String actions) {
- super(createName(reference));
- setTransients(null, parseActions(actions));
- this.service = reference;
- this.objectClass = (String[]) reference
- .getProperty(Constants.OBJECTCLASS);
- if ((action_mask & ACTION_ALL) != ACTION_GET) {
- throw new IllegalArgumentException("invalid action string");
- }
- }
-
- /**
- * Create a permission name from a ServiceReference
- *
- * @param reference ServiceReference to use to create permission name.
- * @return permission name.
- */
- private static String createName(ServiceReference reference) {
- if (reference == null) {
- throw new IllegalArgumentException("reference must not be null");
- }
- StringBuffer sb = new StringBuffer("(service.id=");
- sb.append(reference.getProperty(Constants.SERVICE_ID));
- sb.append(")");
- return sb.toString();
- }
-
- /**
- * Package private constructor used by ServicePermissionCollection.
- *
- * @param name class name
- * @param mask action mask
- */
- ServicePermission(String name, int mask) {
- super(name);
- setTransients(parseFilter(name), mask);
- this.service = null;
- this.objectClass = null;
- }
-
- /**
- * Called by constructors and when deserialized.
- *
- * @param mask action mask
- */
- private void setTransients(Filter f, int mask) {
- if ((mask == ACTION_NONE) || ((mask & ACTION_ALL) != mask)) {
- throw new IllegalArgumentException("invalid action string");
- }
- action_mask = mask;
- filter = f;
- if (f == null) {
- String name = getName();
- int l = name.length();
- /* if "*" or endsWith ".*" */
- wildcard = ((name.charAt(l - 1) == '*') && ((l == 1) || (name
- .charAt(l - 2) == '.')));
- if (wildcard && (l > 1)) {
- prefix = name.substring(0, l - 1);
- }
- }
- }
-
- /**
- * Parse action string into action mask.
- *
- * @param actions Action string.
- * @return action mask.
- */
- private static int parseActions(String actions) {
- boolean seencomma = false;
-
- int mask = ACTION_NONE;
-
- if (actions == null) {
- return mask;
- }
-
- char[] a = actions.toCharArray();
-
- int i = a.length - 1;
- if (i < 0)
- return mask;
-
- while (i != -1) {
- char c;
-
- // skip whitespace
- while ((i != -1)
- && ((c = a[i]) == ' ' || c == '\r' || c == '\n'
- || c == '\f' || c == '\t'))
- i--;
-
- // check for the known strings
- int matchlen;
-
- if (i >= 2 && (a[i - 2] == 'g' || a[i - 2] == 'G')
- && (a[i - 1] == 'e' || a[i - 1] == 'E')
- && (a[i] == 't' || a[i] == 'T')) {
- matchlen = 3;
- mask |= ACTION_GET;
-
- }
- else
- if (i >= 7 && (a[i - 7] == 'r' || a[i - 7] == 'R')
- && (a[i - 6] == 'e' || a[i - 6] == 'E')
- && (a[i - 5] == 'g' || a[i - 5] == 'G')
- && (a[i - 4] == 'i' || a[i - 4] == 'I')
- && (a[i - 3] == 's' || a[i - 3] == 'S')
- && (a[i - 2] == 't' || a[i - 2] == 'T')
- && (a[i - 1] == 'e' || a[i - 1] == 'E')
- && (a[i] == 'r' || a[i] == 'R')) {
- matchlen = 8;
- mask |= ACTION_REGISTER;
-
- }
- else {
- // parse error
- throw new IllegalArgumentException("invalid permission: "
- + actions);
- }
-
- // make sure we didn't just match the tail of a word
- // like "ackbarfregister". Also, skip to the comma.
- seencomma = false;
- while (i >= matchlen && !seencomma) {
- switch (a[i - matchlen]) {
- case ',' :
- seencomma = true;
- /* FALLTHROUGH */
- case ' ' :
- case '\r' :
- case '\n' :
- case '\f' :
- case '\t' :
- break;
- default :
- throw new IllegalArgumentException(
- "invalid permission: " + actions);
- }
- i--;
- }
-
- // point i at the location of the comma minus one (or -1).
- i -= matchlen;
- }
-
- if (seencomma) {
- throw new IllegalArgumentException("invalid permission: " + actions);
- }
-
- return mask;
- }
-
- /**
- * Parse filter string into a Filter object.
- *
- * @param filterString The filter string to parse.
- * @return a Filter for this bundle. If the specified filterString is not a
- * filter expression, then <code>null</code> is returned.
- * @throws IllegalArgumentException If the filter syntax is invalid.
- */
- private static Filter parseFilter(String filterString) {
- filterString = filterString.trim();
- if (filterString.charAt(0) != '(') {
- return null;
- }
-
- try {
- return FrameworkUtil.createFilter(filterString);
- }
- catch (InvalidSyntaxException e) {
- IllegalArgumentException iae = new IllegalArgumentException(
- "invalid filter");
- iae.initCause(e);
- throw iae;
- }
- }
-
- /**
- * Determines if a <code>ServicePermission</code> object "implies" the
- * specified permission.
- *
- * @param p The target permission to check.
- * @return <code>true</code> if the specified permission is implied by this
- * object; <code>false</code> otherwise.
- */
- public boolean implies(Permission p) {
- if (!(p instanceof ServicePermission)) {
- return false;
- }
- ServicePermission requested = (ServicePermission) p;
- if (service != null) {
- return false;
- }
- // if requested permission has a filter, then it is an invalid argument
- if (requested.filter != null) {
- return false;
- }
- return implies0(requested, ACTION_NONE);
- }
-
- /**
- * Internal implies method. Used by the implies and the permission
- * collection implies methods.
- *
- * @param requested The requested ServicePermission which has already be
- * validated as a proper argument. The requested ServicePermission
- * must not have a filter expression.
- * @param effective The effective actions with which to start.
- * @return <code>true</code> if the specified permission is implied by this
- * object; <code>false</code> otherwise.
- */
- boolean implies0(ServicePermission requested, int effective) {
- /* check actions first - much faster */
- effective |= action_mask;
- final int desired = requested.action_mask;
- if ((effective & desired) != desired) {
- return false;
- }
- /* we have name of "*" */
- if (wildcard && (prefix == null)) {
- return true;
- }
- /* if we have a filter */
- Filter f = filter;
- if (f != null) {
- return f.matchCase(requested.getProperties());
- }
- /* if requested permission not created with ServiceReference */
- String[] requestedNames = requested.objectClass;
- if (requestedNames == null) {
- return super.implies(requested);
- }
- /* requested permission created with ServiceReference */
- if (wildcard) {
- int pl = prefix.length();
- for (int i = 0, l = requestedNames.length; i < l; i++) {
- String requestedName = requestedNames[i];
- if ((requestedName.length() > pl)
- && requestedName.startsWith(prefix)) {
- return true;
- }
- }
- }
- else {
- String name = getName();
- for (int i = 0, l = requestedNames.length; i < l; i++) {
- if (requestedNames[i].equals(name)) {
- return true;
- }
- }
- }
- return false;
- }
-
- /**
- * Returns the canonical string representation of the actions. Always
- * returns present actions in the following order: <code>get</code>,
- * <code>register</code>.
- *
- * @return The canonical string representation of the actions.
- */
- public String getActions() {
- String result = actions;
- if (result == null) {
- StringBuffer sb = new StringBuffer();
- boolean comma = false;
-
- int mask = action_mask;
- if ((mask & ACTION_GET) == ACTION_GET) {
- sb.append(GET);
- comma = true;
- }
-
- if ((mask & ACTION_REGISTER) == ACTION_REGISTER) {
- if (comma)
- sb.append(',');
- sb.append(REGISTER);
- }
-
- actions = result = sb.toString();
- }
-
- return result;
- }
-
- /**
- * Returns a new <code>PermissionCollection</code> object for storing
- * <code>ServicePermission<code> objects.
- *
- * @return A new <code>PermissionCollection</code> object suitable for storing
- * <code>ServicePermission</code> objects.
- */
- public PermissionCollection newPermissionCollection() {
- return new ServicePermissionCollection();
- }
-
- /**
- * Determines the equality of two ServicePermission objects.
- *
- * Checks that specified object has the same class name and action as this
- * <code>ServicePermission</code>.
- *
- * @param obj The object to test for equality.
- * @return true if obj is a <code>ServicePermission</code>, and has the same
- * class name and actions as this <code>ServicePermission</code>
- * object; <code>false</code> otherwise.
- */
- public boolean equals(Object obj) {
- if (obj == this) {
- return true;
- }
-
- if (!(obj instanceof ServicePermission)) {
- return false;
- }
-
- ServicePermission sp = (ServicePermission) obj;
-
- return (action_mask == sp.action_mask)
- && getName().equals(sp.getName())
- && ((service == sp.service) || ((service != null) && (service
- .compareTo(sp.service) == 0)));
- }
-
- /**
- * Returns the hash code value for this object.
- *
- * @return Hash code value for this object.
- */
- public int hashCode() {
- int h = 31 * 17 + getName().hashCode();
- h = 31 * h + getActions().hashCode();
- if (service != null) {
- h = 31 * h + service.hashCode();
- }
- return h;
- }
-
- /**
- * WriteObject is called to save the state of this permission to a stream.
- * The actions are serialized, and the superclass takes care of the name.
- */
- private synchronized void writeObject(java.io.ObjectOutputStream s)
- throws IOException {
- if (service != null) {
- throw new NotSerializableException("cannot serialize");
- }
- // Write out the actions. The superclass takes care of the name
- // call getActions to make sure actions field is initialized
- if (actions == null)
- getActions();
- s.defaultWriteObject();
- }
-
- /**
- * readObject is called to restore the state of this permission from a
- * stream.
- */
- private synchronized void readObject(java.io.ObjectInputStream s)
- throws IOException, ClassNotFoundException {
- // Read in the action, then initialize the rest
- s.defaultReadObject();
- setTransients(parseFilter(getName()), parseActions(actions));
- }
- /**
- * Called by <code><@link ServicePermission#implies(Permission)></code>.
- *
- * @return a dictionary of properties for this permission.
- */
- private Dictionary getProperties() {
- Dictionary result = properties;
- if (result != null) {
- return result;
- }
- if (service == null) {
- result = new Hashtable(1);
- if (filter == null) {
- result.put(Constants.OBJECTCLASS, new String[] {getName()});
- }
- return properties = result;
- }
- final Map props = new HashMap(4);
- final Bundle bundle = service.getBundle();
- if (bundle != null) {
- AccessController.doPrivileged(new PrivilegedAction() {
- public Object run() {
- props.put("id", new Long(bundle.getBundleId()));
- props.put("location", bundle.getLocation());
- String name = bundle.getSymbolicName();
- if (name != null) {
- props.put("name", name);
- }
- SignerProperty signer = new SignerProperty(bundle);
- if (signer.isBundleSigned()) {
- props.put("signer", signer);
- }
- return null;
- }
- });
- }
- return properties = new Properties(props, service);
- }
-
- private static class Properties extends Dictionary {
- private final Map properties;
- private final ServiceReference service;
-
- Properties(Map properties, ServiceReference service) {
- this.properties = properties;
- this.service = service;
- }
-
- public Object get(Object k) {
- if (!(k instanceof String)) {
- return null;
- }
- String key = (String) k;
- if (key.charAt(0) == '@') {
- return service.getProperty(key.substring(1));
- }
- Object value = properties.get(key);
- if (value != null) { // fall back to service properties
- return value;
- }
- return service.getProperty(key);
- }
-
- public int size() {
- return properties.size() + service.getPropertyKeys().length;
- }
-
- public boolean isEmpty() {
- // we can return false because this must never be empty
- return false;
- }
-
- public Enumeration keys() {
- Collection pk = properties.keySet();
- String spk[] = service.getPropertyKeys();
- List all = new ArrayList(pk.size() + spk.length);
- all.addAll(pk);
- add:
- for (int i = 0, length = spk.length; i < length; i++) {
- String key = spk[i];
- for (Iterator iter = pk.iterator(); iter.hasNext();) {
- if (key.equalsIgnoreCase((String) iter.next())) {
- continue add;
- }
- }
- all.add(key);
- }
- return Collections.enumeration(all);
- }
-
- public Enumeration elements() {
- Collection pk = properties.keySet();
- String spk[] = service.getPropertyKeys();
- List all = new ArrayList(pk.size() + spk.length);
- all.addAll(properties.values());
- add:
- for (int i = 0, length = spk.length; i < length; i++) {
- String key = spk[i];
- for (Iterator iter = pk.iterator(); iter.hasNext();) {
- if (key.equalsIgnoreCase((String) iter.next())) {
- continue add;
- }
- }
- all.add(service.getProperty(key));
- }
- return Collections.enumeration(all);
- }
-
- public Object put(Object key, Object value) {
- throw new UnsupportedOperationException();
- }
-
- public Object remove(Object key) {
- throw new UnsupportedOperationException();
- }
- }
-}
-
-/**
- * Stores a set of ServicePermission permissions.
- *
- * @see java.security.Permission
- * @see java.security.Permissions
- * @see java.security.PermissionCollection
- */
-final class ServicePermissionCollection extends PermissionCollection {
- static final long serialVersionUID = 662615640374640621L;
- /**
- * Table of permissions.
- *
- * @GuardedBy this
- */
- private transient Map permissions;
-
- /**
- * Boolean saying if "*" is in the collection.
- *
- * @serial
- * @GuardedBy this
- */
- private boolean all_allowed;
-
- /**
- * Table of permissions with filter expressions.
- *
- * @serial
- * @GuardedBy this
- */
- private Map filterPermissions;
-
- /**
- * Creates an empty ServicePermissions object.
- */
- public ServicePermissionCollection() {
- permissions = new HashMap();
- all_allowed = false;
- }
-
- /**
- * Adds a permission to this permission collection.
- *
- * @param permission The Permission object to add.
- * @throws IllegalArgumentException If the specified permission is not a
- * ServicePermission object.
- * @throws SecurityException If this
- * <code>ServicePermissionCollection</code> object has been marked
- * read-only.
- */
- public void add(final Permission permission) {
- if (!(permission instanceof ServicePermission)) {
- throw new IllegalArgumentException("invalid permission: "
- + permission);
- }
- if (isReadOnly()) {
- throw new SecurityException("attempt to add a Permission to a "
- + "readonly PermissionCollection");
- }
-
- final ServicePermission sp = (ServicePermission) permission;
- if (sp.service != null) {
- throw new IllegalArgumentException("cannot add to collection: "
- + sp);
- }
-
- final String name = sp.getName();
- final Filter f = sp.filter;
- synchronized (this) {
- /* select the bucket for the permission */
- Map pc;
- if (f != null) {
- pc = filterPermissions;
- if (pc == null) {
- filterPermissions = pc = new HashMap();
- }
- }
- else {
- pc = permissions;
- }
- final ServicePermission existing = (ServicePermission) pc.get(name);
-
- if (existing != null) {
- final int oldMask = existing.action_mask;
- final int newMask = sp.action_mask;
- if (oldMask != newMask) {
- pc
- .put(name, new ServicePermission(name, oldMask
- | newMask));
- }
- }
- else {
- pc.put(name, sp);
- }
-
- if (!all_allowed) {
- if (name.equals("*")) {
- all_allowed = true;
- }
- }
- }
- }
-
- /**
- * Determines if a set of permissions implies the permissions expressed in
- * <code>permission</code>.
- *
- * @param permission The Permission object to compare.
- * @return <code>true</code> if <code>permission</code> is a proper
- * subset of a permission in the set; <code>false</code>
- * otherwise.
- */
- public boolean implies(final Permission permission) {
- if (!(permission instanceof ServicePermission)) {
- return false;
- }
- final ServicePermission requested = (ServicePermission) permission;
- /* if requested permission has a filter, then it is an invalid argument */
- if (requested.filter != null) {
- return false;
- }
-
- int effective = ServicePermission.ACTION_NONE;
- Collection perms;
- synchronized (this) {
- final int desired = requested.action_mask;
- /* short circuit if the "*" Permission was added */
- if (all_allowed) {
- ServicePermission sp = (ServicePermission) permissions.get("*");
- if (sp != null) {
- effective |= sp.action_mask;
- if ((effective & desired) == desired) {
- return true;
- }
- }
- }
-
- String[] requestedNames = requested.objectClass;
- /* if requested permission not created with ServiceReference */
- if (requestedNames == null) {
- effective |= effective(requested.getName(), desired, effective);
- if ((effective & desired) == desired) {
- return true;
- }
- }
- /* requested permission created with ServiceReference */
- else {
- for (int i = 0, l = requestedNames.length; i < l; i++) {
- if ((effective(requestedNames[i], desired, effective) & desired) == desired) {
- return true;
- }
- }
- }
- Map pc = filterPermissions;
- if (pc == null) {
- return false;
- }
- perms = pc.values();
- }
-
- /* iterate one by one over filteredPermissions */
- for (Iterator iter = perms.iterator(); iter.hasNext();) {
- if (((ServicePermission) iter.next())
- .implies0(requested, effective)) {
- return true;
- }
- }
- return false;
- }
-
- /**
- * Consult permissions map to compute the effective permission for the
- * requested permission name.
- *
- * @param requestedName The requested service name.
- * @param desired The desired actions.
- * @param effective The effective actions.
- * @return The new effective actions.
- */
- private int effective(String requestedName, final int desired,
- int effective) {
- final Map pc = permissions;
- ServicePermission sp = (ServicePermission) pc.get(requestedName);
- // strategy:
- // Check for full match first. Then work our way up the
- // name looking for matches on a.b.*
- if (sp != null) {
- // we have a direct hit!
- effective |= sp.action_mask;
- if ((effective & desired) == desired) {
- return effective;
- }
- }
- // work our way up the tree...
- int last;
- int offset = requestedName.length() - 1;
- while ((last = requestedName.lastIndexOf(".", offset)) != -1) {
- requestedName = requestedName.substring(0, last + 1) + "*";
- sp = (ServicePermission) pc.get(requestedName);
- if (sp != null) {
- effective |= sp.action_mask;
- if ((effective & desired) == desired) {
- return effective;
- }
- }
- offset = last - 1;
- }
- /*
- * we don't have to check for "*" as it was already checked before we
- * were called.
- */
- return effective;
- }
-
- /**
- * Returns an enumeration of all the <code>ServicePermission</code>
- * objects in the container.
- *
- * @return Enumeration of all the ServicePermission objects.
- */
- public synchronized Enumeration elements() {
- List all = new ArrayList(permissions.values());
- Map pc = filterPermissions;
- if (pc != null) {
- all.addAll(pc.values());
- }
- return Collections.enumeration(all);
- }
-
- /* serialization logic */
- private static final ObjectStreamField[] serialPersistentFields = {
- new ObjectStreamField("permissions", Hashtable.class),
- new ObjectStreamField("all_allowed", Boolean.TYPE),
- new ObjectStreamField("filterPermissions", HashMap.class) };
-
- private synchronized void writeObject(ObjectOutputStream out)
- throws IOException {
- Hashtable hashtable = new Hashtable(permissions);
- ObjectOutputStream.PutField pfields = out.putFields();
- pfields.put("permissions", hashtable);
- pfields.put("all_allowed", all_allowed);
- pfields.put("filterPermissions", filterPermissions);
- out.writeFields();
- }
-
- private synchronized void readObject(java.io.ObjectInputStream in)
- throws IOException, ClassNotFoundException {
- ObjectInputStream.GetField gfields = in.readFields();
- Hashtable hashtable = (Hashtable) gfields.get("permissions", null);
- permissions = new HashMap(hashtable);
- all_allowed = gfields.get("all_allowed", false);
- filterPermissions = (HashMap) gfields.get("filterPermissions", null);
- }
-}
diff --git a/org.osgi.core/src/main/java/org/osgi/framework/ServiceReference.java b/org.osgi.core/src/main/java/org/osgi/framework/ServiceReference.java
deleted file mode 100644
index a6dd9bd..0000000
--- a/org.osgi.core/src/main/java/org/osgi/framework/ServiceReference.java
+++ /dev/null
@@ -1,184 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2000, 2009). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.osgi.framework;
-
-import java.util.Dictionary;
-
-/**
- * A reference to a service.
- *
- * <p>
- * The Framework returns <code>ServiceReference</code> objects from the
- * <code>BundleContext.getServiceReference</code> and
- * <code>BundleContext.getServiceReferences</code> methods.
- * <p>
- * A <code>ServiceReference</code> object may be shared between bundles and
- * can be used to examine the properties of the service and to get the service
- * object.
- * <p>
- * Every service registered in the Framework has a unique
- * <code>ServiceRegistration</code> object and may have multiple, distinct
- * <code>ServiceReference</code> objects referring to it.
- * <code>ServiceReference</code> objects associated with a
- * <code>ServiceRegistration</code> object have the same <code>hashCode</code>
- * and are considered equal (more specifically, their <code>equals()</code>
- * method will return <code>true</code> when compared).
- * <p>
- * If the same service object is registered multiple times,
- * <code>ServiceReference</code> objects associated with different
- * <code>ServiceRegistration</code> objects are not equal.
- *
- * @see BundleContext#getServiceReference
- * @see BundleContext#getServiceReferences
- * @see BundleContext#getService
- * @ThreadSafe
- * @version $Revision: 6374 $
- */
-
-public interface ServiceReference extends Comparable {
- /**
- * Returns the property value to which the specified property key is mapped
- * in the properties <code>Dictionary</code> object of the service
- * referenced by this <code>ServiceReference</code> object.
- *
- * <p>
- * Property keys are case-insensitive.
- *
- * <p>
- * This method must continue to return property values after the service has
- * been unregistered. This is so references to unregistered services (for
- * example, <code>ServiceReference</code> objects stored in the log) can
- * still be interrogated.
- *
- * @param key The property key.
- * @return The property value to which the key is mapped; <code>null</code>
- * if there is no property named after the key.
- */
- public Object getProperty(String key);
-
- /**
- * Returns an array of the keys in the properties <code>Dictionary</code>
- * object of the service referenced by this <code>ServiceReference</code>
- * object.
- *
- * <p>
- * This method will continue to return the keys after the service has been
- * unregistered. This is so references to unregistered services (for
- * example, <code>ServiceReference</code> objects stored in the log) can
- * still be interrogated.
- *
- * <p>
- * This method is <i>case-preserving </i>; this means that every key in the
- * returned array must have the same case as the corresponding key in the
- * properties <code>Dictionary</code> that was passed to the
- * {@link BundleContext#registerService(String[],Object,Dictionary)} or
- * {@link ServiceRegistration#setProperties} methods.
- *
- * @return An array of property keys.
- */
- public String[] getPropertyKeys();
-
- /**
- * Returns the bundle that registered the service referenced by this
- * <code>ServiceReference</code> object.
- *
- * <p>
- * This method must return <code>null</code> when the service has been
- * unregistered. This can be used to determine if the service has been
- * unregistered.
- *
- * @return The bundle that registered the service referenced by this
- * <code>ServiceReference</code> object; <code>null</code> if that
- * service has already been unregistered.
- * @see BundleContext#registerService(String[],Object,Dictionary)
- */
- public Bundle getBundle();
-
- /**
- * Returns the bundles that are using the service referenced by this
- * <code>ServiceReference</code> object. Specifically, this method returns
- * the bundles whose usage count for that service is greater than zero.
- *
- * @return An array of bundles whose usage count for the service referenced
- * by this <code>ServiceReference</code> object is greater than
- * zero; <code>null</code> if no bundles are currently using that
- * service.
- *
- * @since 1.1
- */
- public Bundle[] getUsingBundles();
-
- /**
- * Tests if the bundle that registered the service referenced by this
- * <code>ServiceReference</code> and the specified bundle use the same
- * source for the package of the specified class name.
- * <p>
- * This method performs the following checks:
- * <ol>
- * <li>Get the package name from the specified class name.</li>
- * <li>For the bundle that registered the service referenced by this
- * <code>ServiceReference</code> (registrant bundle); find the source for
- * the package. If no source is found then return <code>true</code> if the
- * registrant bundle is equal to the specified bundle; otherwise return
- * <code>false</code>.</li>
- * <li>If the package source of the registrant bundle is equal to the
- * package source of the specified bundle then return <code>true</code>;
- * otherwise return <code>false</code>.</li>
- * </ol>
- *
- * @param bundle The <code>Bundle</code> object to check.
- * @param className The class name to check.
- * @return <code>true</code> if the bundle which registered the service
- * referenced by this <code>ServiceReference</code> and the
- * specified bundle use the same source for the package of the
- * specified class name. Otherwise <code>false</code> is returned.
- * @throws IllegalArgumentException If the specified <code>Bundle</code> was
- * not created by the same framework instance as this
- * <code>ServiceReference</code>.
- * @since 1.3
- */
- public boolean isAssignableTo(Bundle bundle, String className);
-
- /**
- * Compares this <code>ServiceReference</code> with the specified
- * <code>ServiceReference</code> for order.
- *
- * <p>
- * If this <code>ServiceReference</code> and the specified
- * <code>ServiceReference</code> have the same {@link Constants#SERVICE_ID
- * service id} they are equal. This <code>ServiceReference</code> is less
- * than the specified <code>ServiceReference</code> if it has a lower
- * {@link Constants#SERVICE_RANKING service ranking} and greater if it has a
- * higher service ranking. Otherwise, if this <code>ServiceReference</code>
- * and the specified <code>ServiceReference</code> have the same
- * {@link Constants#SERVICE_RANKING service ranking}, this
- * <code>ServiceReference</code> is less than the specified
- * <code>ServiceReference</code> if it has a higher
- * {@link Constants#SERVICE_ID service id} and greater if it has a lower
- * service id.
- *
- * @param reference The <code>ServiceReference</code> to be compared.
- * @return Returns a negative integer, zero, or a positive integer if this
- * <code>ServiceReference</code> is less than, equal to, or greater
- * than the specified <code>ServiceReference</code>.
- * @throws IllegalArgumentException If the specified
- * <code>ServiceReference</code> was not created by the same
- * framework instance as this <code>ServiceReference</code>.
- * @since 1.4
- */
- public int compareTo(Object reference);
-}
diff --git a/org.osgi.core/src/main/java/org/osgi/framework/ServiceRegistration.java b/org.osgi.core/src/main/java/org/osgi/framework/ServiceRegistration.java
deleted file mode 100644
index 9186cf7..0000000
--- a/org.osgi.core/src/main/java/org/osgi/framework/ServiceRegistration.java
+++ /dev/null
@@ -1,112 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2000, 2009). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.osgi.framework;
-
-import java.util.Dictionary;
-
-/**
- * A registered service.
- *
- * <p>
- * The Framework returns a <code>ServiceRegistration</code> object when a
- * <code>BundleContext.registerService</code> method invocation is successful.
- * The <code>ServiceRegistration</code> object is for the private use of the
- * registering bundle and should not be shared with other bundles.
- * <p>
- * The <code>ServiceRegistration</code> object may be used to update the
- * properties of the service or to unregister the service.
- *
- * @see BundleContext#registerService(String[],Object,Dictionary)
- * @ThreadSafe
- * @version $Revision: 6361 $
- */
-
-public interface ServiceRegistration {
- /**
- * Returns a <code>ServiceReference</code> object for a service being
- * registered.
- * <p>
- * The <code>ServiceReference</code> object may be shared with other
- * bundles.
- *
- * @throws IllegalStateException If this
- * <code>ServiceRegistration</code> object has already been
- * unregistered.
- * @return <code>ServiceReference</code> object.
- */
- public ServiceReference getReference();
-
- /**
- * Updates the properties associated with a service.
- *
- * <p>
- * The {@link Constants#OBJECTCLASS} and {@link Constants#SERVICE_ID} keys
- * cannot be modified by this method. These values are set by the Framework
- * when the service is registered in the OSGi environment.
- *
- * <p>
- * The following steps are required to modify service properties:
- * <ol>
- * <li>The service's properties are replaced with the provided properties.
- * <li>A service event of type {@link ServiceEvent#MODIFIED} is fired.
- * </ol>
- *
- * @param properties The properties for this service. See {@link Constants}
- * for a list of standard service property keys. Changes should not
- * be made to this object after calling this method. To update the
- * service's properties this method should be called again.
- *
- * @throws IllegalStateException If this <code>ServiceRegistration</code>
- * object has already been unregistered.
- * @throws IllegalArgumentException If <code>properties</code> contains
- * case variants of the same key name.
- */
- public void setProperties(Dictionary properties);
-
- /**
- * Unregisters a service. Remove a <code>ServiceRegistration</code> object
- * from the Framework service registry. All <code>ServiceReference</code>
- * objects associated with this <code>ServiceRegistration</code> object
- * can no longer be used to interact with the service once unregistration is
- * complete.
- *
- * <p>
- * The following steps are required to unregister a service:
- * <ol>
- * <li>The service is removed from the Framework service registry so that
- * it can no longer be obtained.
- * <li>A service event of type {@link ServiceEvent#UNREGISTERING} is fired
- * so that bundles using this service can release their use of the service.
- * Once delivery of the service event is complete, the
- * <code>ServiceReference</code> objects for the service may no longer be
- * used to get a service object for the service.
- * <li>For each bundle whose use count for this service is greater than
- * zero: <br>
- * The bundle's use count for this service is set to zero. <br>
- * If the service was registered with a {@link ServiceFactory} object, the
- * <code>ServiceFactory.ungetService</code> method is called to release
- * the service object for the bundle.
- * </ol>
- *
- * @throws IllegalStateException If this
- * <code>ServiceRegistration</code> object has already been
- * unregistered.
- * @see BundleContext#ungetService
- * @see ServiceFactory#ungetService
- */
- public void unregister();
-}
diff --git a/org.osgi.core/src/main/java/org/osgi/framework/SignerProperty.java b/org.osgi.core/src/main/java/org/osgi/framework/SignerProperty.java
deleted file mode 100644
index 2ba0389..0000000
--- a/org.osgi.core/src/main/java/org/osgi/framework/SignerProperty.java
+++ /dev/null
@@ -1,113 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2009). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.osgi.framework;
-
-import java.security.cert.X509Certificate;
-import java.util.ArrayList;
-import java.util.Iterator;
-import java.util.List;
-import java.util.Map;
-
-/**
- * Package private class used by permissions for filter matching on signer key
- * during filter expression evaluation in the permission implies method.
- *
- * @Immutable
- * @version $Revision: 6479 $
- */
-class SignerProperty {
- private final Bundle bundle;
- private final String pattern;
-
- /**
- * String constructor used by the filter matching algorithm to construct a
- * SignerProperty from the attribute value in a filter expression.
- *
- * @param pattern Attribute value in the filter expression.
- */
- public SignerProperty(String pattern) {
- this.pattern = pattern;
- this.bundle = null;
- }
-
- /**
- * Used by the permission implies method to build the properties for a
- * filter match.
- *
- * @param bundle The bundle whose signers are to be matched.
- */
- SignerProperty(Bundle bundle) {
- this.bundle = bundle;
- this.pattern = null;
- }
-
- /**
- * Used by the filter matching algorithm. This methods does NOT satisfy the
- * normal equals contract. Since the class is only used in filter expression
- * evaluations, it only needs to support comparing an instance created with
- * a Bundle to an instance created with a pattern string from the filter
- * expression.
- *
- * @param o SignerProperty to compare against.
- * @return true if the DN name chain matches the pattern.
- */
- public boolean equals(Object o) {
- if (!(o instanceof SignerProperty))
- return false;
- SignerProperty other = (SignerProperty) o;
- Bundle matchBundle = bundle != null ? bundle : other.bundle;
- String matchPattern = bundle != null ? other.pattern : pattern;
- Map/* <X509Certificate, List<X509Certificate>> */signers = matchBundle
- .getSignerCertificates(Bundle.SIGNERS_TRUSTED);
- for (Iterator iSigners = signers.values().iterator(); iSigners
- .hasNext();) {
- List/* <X509Certificate> */signerCerts = (List) iSigners.next();
- List/* <String> */dnChain = new ArrayList(signerCerts.size());
- for (Iterator iCerts = signerCerts.iterator(); iCerts.hasNext();) {
- dnChain.add(((X509Certificate) iCerts.next()).getSubjectDN()
- .getName());
- }
- if (FrameworkUtil
- .matchDistinguishedNameChain(matchPattern, dnChain)) {
- return true;
- }
- }
- return false;
- }
-
- /**
- * Since the equals method does not obey the general equals contract, this
- * method cannot generate hash codes which obey the equals contract.
- */
- public int hashCode() {
- return 31;
- }
-
- /**
- * Check if the bundle is signed.
- *
- * @return true if constructed with a bundle that is signed.
- */
- boolean isBundleSigned() {
- if (bundle == null) {
- return false;
- }
- Map/* <X509Certificate, List<X509Certificate>> */signers = bundle
- .getSignerCertificates(Bundle.SIGNERS_TRUSTED);
- return !signers.isEmpty();
- }
-}
diff --git a/org.osgi.core/src/main/java/org/osgi/framework/SynchronousBundleListener.java b/org.osgi.core/src/main/java/org/osgi/framework/SynchronousBundleListener.java
deleted file mode 100644
index 9104f04..0000000
--- a/org.osgi.core/src/main/java/org/osgi/framework/SynchronousBundleListener.java
+++ /dev/null
@@ -1,53 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2001, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.osgi.framework;
-
-/**
- * A synchronous <code>BundleEvent</code> listener.
- * <code>SynchronousBundleListener</code> is a listener interface that may be
- * implemented by a bundle developer. When a <code>BundleEvent</code> is
- * fired, it is synchronously delivered to a
- * <code>SynchronousBundleListener</code>. The Framework may deliver
- * <code>BundleEvent</code> objects to a
- * <code>SynchronousBundleListener</code> out of order and may concurrently
- * call and/or reenter a <code>SynchronousBundleListener</code>.
- * <p>
- * A <code>SynchronousBundleListener</code> object is registered with the
- * Framework using the {@link BundleContext#addBundleListener} method.
- * <code>SynchronousBundleListener</code> objects are called with a
- * <code>BundleEvent</code> object when a bundle has been installed, resolved,
- * starting, started, stopping, stopped, updated, unresolved, or uninstalled.
- * <p>
- * Unlike normal <code>BundleListener</code> objects,
- * <code>SynchronousBundleListener</code>s are synchronously called during
- * bundle lifecycle processing. The bundle lifecycle processing will not proceed
- * until all <code>SynchronousBundleListener</code>s have completed.
- * <code>SynchronousBundleListener</code> objects will be called prior to
- * <code>BundleListener</code> objects.
- * <p>
- * <code>AdminPermission[bundle,LISTENER]</code> is required to add or remove
- * a <code>SynchronousBundleListener</code> object.
- *
- * @since 1.1
- * @see BundleEvent
- * @ThreadSafe
- * @version $Revision: 5673 $
- */
-
-public interface SynchronousBundleListener extends BundleListener {
- // This is a marker interface
-}
diff --git a/org.osgi.core/src/main/java/org/osgi/framework/Version.java b/org.osgi.core/src/main/java/org/osgi/framework/Version.java
deleted file mode 100644
index 7317495..0000000
--- a/org.osgi.core/src/main/java/org/osgi/framework/Version.java
+++ /dev/null
@@ -1,368 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2004, 2009). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.osgi.framework;
-
-import java.util.NoSuchElementException;
-import java.util.StringTokenizer;
-
-/**
- * Version identifier for bundles and packages.
- *
- * <p>
- * Version identifiers have four components.
- * <ol>
- * <li>Major version. A non-negative integer.</li>
- * <li>Minor version. A non-negative integer.</li>
- * <li>Micro version. A non-negative integer.</li>
- * <li>Qualifier. A text string. See <code>Version(String)</code> for the
- * format of the qualifier string.</li>
- * </ol>
- *
- * <p>
- * <code>Version</code> objects are immutable.
- *
- * @since 1.3
- * @Immutable
- * @version $Revision: 6860 $
- */
-
-public class Version implements Comparable {
- private final int major;
- private final int minor;
- private final int micro;
- private final String qualifier;
- private static final String SEPARATOR = "."; //$NON-NLS-1$
-
- /**
- * The empty version "0.0.0".
- */
- public static final Version emptyVersion = new Version(0, 0, 0);
-
- /**
- * Creates a version identifier from the specified numerical components.
- *
- * <p>
- * The qualifier is set to the empty string.
- *
- * @param major Major component of the version identifier.
- * @param minor Minor component of the version identifier.
- * @param micro Micro component of the version identifier.
- * @throws IllegalArgumentException If the numerical components are
- * negative.
- */
- public Version(int major, int minor, int micro) {
- this(major, minor, micro, null);
- }
-
- /**
- * Creates a version identifier from the specified components.
- *
- * @param major Major component of the version identifier.
- * @param minor Minor component of the version identifier.
- * @param micro Micro component of the version identifier.
- * @param qualifier Qualifier component of the version identifier. If
- * <code>null</code> is specified, then the qualifier will be set to
- * the empty string.
- * @throws IllegalArgumentException If the numerical components are negative
- * or the qualifier string is invalid.
- */
- public Version(int major, int minor, int micro, String qualifier) {
- if (qualifier == null) {
- qualifier = ""; //$NON-NLS-1$
- }
-
- this.major = major;
- this.minor = minor;
- this.micro = micro;
- this.qualifier = qualifier;
- validate();
- }
-
- /**
- * Created a version identifier from the specified string.
- *
- * <p>
- * Here is the grammar for version strings.
- *
- * <pre>
- * version ::= major('.'minor('.'micro('.'qualifier)?)?)?
- * major ::= digit+
- * minor ::= digit+
- * micro ::= digit+
- * qualifier ::= (alpha|digit|'_'|'-')+
- * digit ::= [0..9]
- * alpha ::= [a..zA..Z]
- * </pre>
- *
- * There must be no whitespace in version.
- *
- * @param version String representation of the version identifier.
- * @throws IllegalArgumentException If <code>version</code> is improperly
- * formatted.
- */
- public Version(String version) {
- int maj = 0;
- int min = 0;
- int mic = 0;
- String qual = ""; //$NON-NLS-1$
-
- try {
- StringTokenizer st = new StringTokenizer(version, SEPARATOR, true);
- maj = Integer.parseInt(st.nextToken());
-
- if (st.hasMoreTokens()) {
- st.nextToken(); // consume delimiter
- min = Integer.parseInt(st.nextToken());
-
- if (st.hasMoreTokens()) {
- st.nextToken(); // consume delimiter
- mic = Integer.parseInt(st.nextToken());
-
- if (st.hasMoreTokens()) {
- st.nextToken(); // consume delimiter
- qual = st.nextToken();
-
- if (st.hasMoreTokens()) {
- throw new IllegalArgumentException("invalid format"); //$NON-NLS-1$
- }
- }
- }
- }
- }
- catch (NoSuchElementException e) {
- throw new IllegalArgumentException("invalid format"); //$NON-NLS-1$
- }
-
- major = maj;
- minor = min;
- micro = mic;
- qualifier = qual;
- validate();
- }
-
- /**
- * Called by the Version constructors to validate the version components.
- *
- * @throws IllegalArgumentException If the numerical components are negative
- * or the qualifier string is invalid.
- */
- private void validate() {
- if (major < 0) {
- throw new IllegalArgumentException("negative major"); //$NON-NLS-1$
- }
- if (minor < 0) {
- throw new IllegalArgumentException("negative minor"); //$NON-NLS-1$
- }
- if (micro < 0) {
- throw new IllegalArgumentException("negative micro"); //$NON-NLS-1$
- }
- char[] chars = qualifier.toCharArray();
- for (int i = 0, length = chars.length; i < length; i++) {
- char ch = chars[i];
- if (('A' <= ch) && (ch <= 'Z')) {
- continue;
- }
- if (('a' <= ch) && (ch <= 'z')) {
- continue;
- }
- if (('0' <= ch) && (ch <= '9')) {
- continue;
- }
- if ((ch == '_') || (ch == '-')) {
- continue;
- }
- throw new IllegalArgumentException(
- "invalid qualifier: " + qualifier); //$NON-NLS-1$
- }
- }
-
- /**
- * Parses a version identifier from the specified string.
- *
- * <p>
- * See <code>Version(String)</code> for the format of the version string.
- *
- * @param version String representation of the version identifier. Leading
- * and trailing whitespace will be ignored.
- * @return A <code>Version</code> object representing the version
- * identifier. If <code>version</code> is <code>null</code> or
- * the empty string then <code>emptyVersion</code> will be
- * returned.
- * @throws IllegalArgumentException If <code>version</code> is improperly
- * formatted.
- */
- public static Version parseVersion(String version) {
- if (version == null) {
- return emptyVersion;
- }
-
- version = version.trim();
- if (version.length() == 0) {
- return emptyVersion;
- }
-
- return new Version(version);
- }
-
- /**
- * Returns the major component of this version identifier.
- *
- * @return The major component.
- */
- public int getMajor() {
- return major;
- }
-
- /**
- * Returns the minor component of this version identifier.
- *
- * @return The minor component.
- */
- public int getMinor() {
- return minor;
- }
-
- /**
- * Returns the micro component of this version identifier.
- *
- * @return The micro component.
- */
- public int getMicro() {
- return micro;
- }
-
- /**
- * Returns the qualifier component of this version identifier.
- *
- * @return The qualifier component.
- */
- public String getQualifier() {
- return qualifier;
- }
-
- /**
- * Returns the string representation of this version identifier.
- *
- * <p>
- * The format of the version string will be <code>major.minor.micro</code>
- * if qualifier is the empty string or
- * <code>major.minor.micro.qualifier</code> otherwise.
- *
- * @return The string representation of this version identifier.
- */
- public String toString() {
- int q = qualifier.length();
- StringBuffer result = new StringBuffer(20 + q);
- result.append(major);
- result.append(SEPARATOR);
- result.append(minor);
- result.append(SEPARATOR);
- result.append(micro);
- if (q > 0) {
- result.append(SEPARATOR);
- result.append(qualifier);
- }
- return result.toString();
- }
-
- /**
- * Returns a hash code value for the object.
- *
- * @return An integer which is a hash code value for this object.
- */
- public int hashCode() {
- return (major << 24) + (minor << 16) + (micro << 8)
- + qualifier.hashCode();
- }
-
- /**
- * Compares this <code>Version</code> object to another object.
- *
- * <p>
- * A version is considered to be <b>equal to </b> another version if the
- * major, minor and micro components are equal and the qualifier component
- * is equal (using <code>String.equals</code>).
- *
- * @param object The <code>Version</code> object to be compared.
- * @return <code>true</code> if <code>object</code> is a
- * <code>Version</code> and is equal to this object;
- * <code>false</code> otherwise.
- */
- public boolean equals(Object object) {
- if (object == this) { // quicktest
- return true;
- }
-
- if (!(object instanceof Version)) {
- return false;
- }
-
- Version other = (Version) object;
- return (major == other.major) && (minor == other.minor)
- && (micro == other.micro) && qualifier.equals(other.qualifier);
- }
-
- /**
- * Compares this <code>Version</code> object to another object.
- *
- * <p>
- * A version is considered to be <b>less than </b> another version if its
- * major component is less than the other version's major component, or the
- * major components are equal and its minor component is less than the other
- * version's minor component, or the major and minor components are equal
- * and its micro component is less than the other version's micro component,
- * or the major, minor and micro components are equal and it's qualifier
- * component is less than the other version's qualifier component (using
- * <code>String.compareTo</code>).
- *
- * <p>
- * A version is considered to be <b>equal to</b> another version if the
- * major, minor and micro components are equal and the qualifier component
- * is equal (using <code>String.compareTo</code>).
- *
- * @param object The <code>Version</code> object to be compared.
- * @return A negative integer, zero, or a positive integer if this object is
- * less than, equal to, or greater than the specified
- * <code>Version</code> object.
- * @throws ClassCastException If the specified object is not a
- * <code>Version</code>.
- */
- public int compareTo(Object object) {
- if (object == this) { // quicktest
- return 0;
- }
-
- Version other = (Version) object;
-
- int result = major - other.major;
- if (result != 0) {
- return result;
- }
-
- result = minor - other.minor;
- if (result != 0) {
- return result;
- }
-
- result = micro - other.micro;
- if (result != 0) {
- return result;
- }
-
- return qualifier.compareTo(other.qualifier);
- }
-}
diff --git a/org.osgi.core/src/main/java/org/osgi/framework/hooks/service/EventHook.java b/org.osgi.core/src/main/java/org/osgi/framework/hooks/service/EventHook.java
deleted file mode 100644
index 1249493..0000000
--- a/org.osgi.core/src/main/java/org/osgi/framework/hooks/service/EventHook.java
+++ /dev/null
@@ -1,54 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2008, 2009). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.osgi.framework.hooks.service;
-
-import java.util.Collection;
-
-import org.osgi.framework.ServiceEvent;
-
-/**
- * OSGi Framework Service Event Hook Service.
- *
- * <p>
- * Bundles registering this service will be called during framework service
- * (register, modify, and unregister service) operations.
- *
- * @ThreadSafe
- * @version $Revision: 6967 $
- */
-
-public interface EventHook {
- /**
- * Event hook method. This method is called prior to service event delivery
- * when a publishing bundle registers, modifies or unregisters a service.
- * This method can filter the bundles which receive the event.
- *
- * @param event The service event to be delivered.
- * @param contexts A <code>Collection</code> of Bundle Contexts for bundles
- * which have listeners to which the specified event will be
- * delivered. The implementation of this method may remove bundle
- * contexts from the collection to prevent the event from being
- * delivered to the associated bundles. The collection supports all
- * the optional <code>Collection</code> operations except
- * <code>add</code> and <code>addAll</code>. Attempting to add to the
- * collection will result in an
- * <code>UnsupportedOperationException</code>. The collection is not
- * synchronized.
- */
- void event(ServiceEvent event,
- Collection/* <BundleContext> */contexts);
-}
diff --git a/org.osgi.core/src/main/java/org/osgi/framework/hooks/service/FindHook.java b/org.osgi.core/src/main/java/org/osgi/framework/hooks/service/FindHook.java
deleted file mode 100644
index 0de1f0b..0000000
--- a/org.osgi.core/src/main/java/org/osgi/framework/hooks/service/FindHook.java
+++ /dev/null
@@ -1,63 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2008, 2009). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.osgi.framework.hooks.service;
-
-import java.util.Collection;
-
-import org.osgi.framework.BundleContext;
-
-/**
- * OSGi Framework Service Find Hook Service.
- *
- * <p>
- * Bundles registering this service will be called during framework service find
- * (get service references) operations.
- *
- * @ThreadSafe
- * @version $Revision: 6967 $
- */
-
-public interface FindHook {
- /**
- * Find hook method. This method is called during the service find operation
- * (for example, {@link BundleContext#getServiceReferences(String, String)}
- * ). This method can filter the result of the find operation.
- *
- * @param context The bundle context of the bundle performing the find
- * operation.
- * @param name The class name of the services to find or <code>null</code>
- * to find all services.
- * @param filter The filter criteria of the services to find or
- * <code>null</code> for no filter criteria.
- * @param allServices <code>true</code> if the find operation is the result
- * of a call to
- * {@link BundleContext#getAllServiceReferences(String, String)}
- * @param references A <code>Collection</code> of Service References to be
- * returned as a result of the find operation. The implementation of
- * this method may remove service references from the collection to
- * prevent the references from being returned to the bundle
- * performing the find operation. The collection supports all the
- * optional <code>Collection</code> operations except
- * <code>add</code> and <code>addAll</code>. Attempting to add to the
- * collection will result in an
- * <code>UnsupportedOperationException</code>. The collection is not
- * synchronized.
- */
- void find(BundleContext context, String name, String filter,
- boolean allServices,
- Collection/* <ServiceReference> */references);
-}
diff --git a/org.osgi.core/src/main/java/org/osgi/framework/hooks/service/ListenerHook.java b/org.osgi.core/src/main/java/org/osgi/framework/hooks/service/ListenerHook.java
deleted file mode 100644
index 5934c0c..0000000
--- a/org.osgi.core/src/main/java/org/osgi/framework/hooks/service/ListenerHook.java
+++ /dev/null
@@ -1,134 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2008, 2009). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.osgi.framework.hooks.service;
-
-import java.util.Collection;
-
-import org.osgi.framework.BundleContext;
-
-/**
- * OSGi Framework Service Listener Hook Service.
- *
- * <p>
- * Bundles registering this service will be called during service listener
- * addition and removal.
- *
- * @ThreadSafe
- * @version $Revision: 6967 $
- */
-
-public interface ListenerHook {
- /**
- * Added listeners hook method. This method is called to provide the hook
- * implementation with information on newly added service listeners. This
- * method will be called as service listeners are added while this hook is
- * registered. Also, immediately after registration of this hook, this
- * method will be called to provide the current collection of service
- * listeners which had been added prior to the hook being registered.
- *
- * @param listeners A <code>Collection</code> of {@link ListenerInfo}s for
- * newly added service listeners which are now listening to service
- * events. Attempting to add to or remove from the collection will
- * result in an <code>UnsupportedOperationException</code>. The
- * collection is not synchronized.
- */
- void added(Collection/* <ListenerInfo> */listeners);
-
- /**
- * Removed listeners hook method. This method is called to provide the hook
- * implementation with information on newly removed service listeners. This
- * method will be called as service listeners are removed while this hook is
- * registered.
- *
- * @param listeners A <code>Collection</code> of {@link ListenerInfo}s for
- * newly removed service listeners which are no longer listening to
- * service events. Attempting to add to or remove from the collection
- * will result in an <code>UnsupportedOperationException</code>. The
- * collection is not synchronized.
- */
- void removed(Collection/* <ListenerInfo> */listeners);
-
- /**
- * Information about a Service Listener. This interface describes the bundle
- * which added the Service Listener and the filter with which it was added.
- *
- * @ThreadSafe
- */
- public interface ListenerInfo {
- /**
- * Return the context of the bundle which added the listener.
- *
- * @return The context of the bundle which added the listener.
- */
- BundleContext getBundleContext();
-
- /**
- * Return the filter string with which the listener was added.
- *
- * @return The filter string with which the listener was added. This may
- * be <code>null</code> if the listener was added without a
- * filter.
- */
- String getFilter();
-
- /**
- * Return the state of the listener for this addition and removal life
- * cycle. Initially this method will return <code>false</code>
- * indicating the listener has been added but has not been removed.
- * After the listener has been removed, this method must always return
- * <code>true</code>.
- *
- * <p>
- * There is an extremely rare case in which removed notification to
- * {@link ListenerHook}s can be made before added notification if two
- * threads are racing to add and remove the same service listener.
- * Because {@link ListenerHook}s are called synchronously during service
- * listener addition and removal, the Framework cannot guarantee
- * in-order delivery of added and removed notification for a given
- * service listener. This method can be used to detect this rare
- * occurrence.
- *
- * @return <code>false</code> if the listener has not been been removed,
- * <code>true</code> otherwise.
- */
- boolean isRemoved();
-
- /**
- * Compares this <code>ListenerInfo</code> to another
- * <code>ListenerInfo</code>. Two <code>ListenerInfo</code>s are equals
- * if they refer to the same listener for a given addition and removal
- * life cycle. If the same listener is added again, it must have a
- * different <code>ListenerInfo</code> which is not equal to this
- * <code>ListenerInfo</code>.
- *
- * @param obj The object to compare against this
- * <code>ListenerInfo</code>.
- * @return <code>true</code> if the other object is a
- * <code>ListenerInfo</code> object and both objects refer to
- * the same listener for a given addition and removal life
- * cycle.
- */
- boolean equals(Object obj);
-
- /**
- * Returns the hash code for this <code>ListenerInfo</code>.
- *
- * @return The hash code of this <code>ListenerInfo</code>.
- */
- int hashCode();
- }
-}
diff --git a/org.osgi.core/src/main/java/org/osgi/framework/hooks/service/package.html b/org.osgi.core/src/main/java/org/osgi/framework/hooks/service/package.html
deleted file mode 100644
index 46d18ac..0000000
--- a/org.osgi.core/src/main/java/org/osgi/framework/hooks/service/package.html
+++ /dev/null
@@ -1,11 +0,0 @@
-<!-- $Revision: 6211 $ -->
-<BODY>
-<p>Framework Service Hooks Package Version 1.0.
-<p>Bundles wishing to use this package must list the package
-in the Import-Package header of the bundle's manifest.
-For example:
-<pre>
-Import-Package: org.osgi.framework.hooks.service;version="[1.0,2.0)"
-</pre>
-</BODY>
-
diff --git a/org.osgi.core/src/main/java/org/osgi/framework/hooks/service/packageinfo b/org.osgi.core/src/main/java/org/osgi/framework/hooks/service/packageinfo
deleted file mode 100644
index 7c8de03..0000000
--- a/org.osgi.core/src/main/java/org/osgi/framework/hooks/service/packageinfo
+++ /dev/null
@@ -1 +0,0 @@
-version 1.0
diff --git a/org.osgi.core/src/main/java/org/osgi/framework/launch/Framework.java b/org.osgi.core/src/main/java/org/osgi/framework/launch/Framework.java
deleted file mode 100644
index f7618aa..0000000
--- a/org.osgi.core/src/main/java/org/osgi/framework/launch/Framework.java
+++ /dev/null
@@ -1,308 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2008, 2009). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.osgi.framework.launch;
-
-import java.io.InputStream;
-
-import org.osgi.framework.Bundle;
-import org.osgi.framework.BundleException;
-import org.osgi.framework.Constants;
-import org.osgi.framework.FrameworkEvent;
-
-/**
- * A Framework instance. A Framework is also known as a System Bundle.
- *
- * <p>
- * Framework instances are created using a {@link FrameworkFactory}. The methods
- * of this interface can be used to manage and control the created framework
- * instance.
- *
- * @ThreadSafe
- * @version $Revision: 6542 $
- */
-public interface Framework extends Bundle {
-
- /**
- * Initialize this Framework. After calling this method, this Framework
- * must:
- * <ul>
- * <li>Be in the {@link #STARTING} state.</li>
- * <li>Have a valid Bundle Context.</li>
- * <li>Be at start level 0.</li>
- * <li>Have event handling enabled.</li>
- * <li>Have reified Bundle objects for all installed bundles.</li>
- * <li>Have registered any framework services. For example,
- * <code>PackageAdmin</code>, <code>ConditionalPermissionAdmin</code>,
- * <code>StartLevel</code>.</li>
- * </ul>
- *
- * <p>
- * This Framework will not actually be started until {@link #start() start}
- * is called.
- *
- * <p>
- * This method does nothing if called when this Framework is in the
- * {@link #STARTING}, {@link #ACTIVE} or {@link #STOPPING} states.
- *
- * @throws BundleException If this Framework could not be initialized.
- * @throws SecurityException If the Java Runtime Environment supports
- * permissions and the caller does not have the appropriate
- * <code>AdminPermission[this,EXECUTE]</code> or if there is a
- * security manager already installed and the
- * {@link Constants#FRAMEWORK_SECURITY} configuration property is
- * set.
- *
- */
- void init() throws BundleException;
-
- /**
- * Wait until this Framework has completely stopped. The <code>stop</code>
- * and <code>update</code> methods on a Framework performs an asynchronous
- * stop of the Framework. This method can be used to wait until the
- * asynchronous stop of this Framework has completed. This method will only
- * wait if called when this Framework is in the {@link #STARTING},
- * {@link #ACTIVE}, or {@link #STOPPING} states. Otherwise it will return
- * immediately.
- * <p>
- * A Framework Event is returned to indicate why this Framework has stopped.
- *
- * @param timeout Maximum number of milliseconds to wait until this
- * Framework has completely stopped. A value of zero will wait
- * indefinitely.
- * @return A Framework Event indicating the reason this method returned. The
- * following <code>FrameworkEvent</code> types may be returned by
- * this method.
- * <ul>
- * <li>{@link FrameworkEvent#STOPPED STOPPED} - This Framework has
- * been stopped. </li>
- *
- * <li>{@link FrameworkEvent#STOPPED_UPDATE STOPPED_UPDATE} - This
- * Framework has been updated which has shutdown and will now
- * restart.</li>
- *
- * <li> {@link FrameworkEvent#STOPPED_BOOTCLASSPATH_MODIFIED
- * STOPPED_BOOTCLASSPATH_MODIFIED} - This Framework has been stopped
- * and a bootclasspath extension bundle has been installed or
- * updated. The VM must be restarted in order for the changed boot
- * class path to take affect. </li>
- *
- * <li>{@link FrameworkEvent#ERROR ERROR} - The Framework
- * encountered an error while shutting down or an error has occurred
- * which forced the framework to shutdown. </li>
- *
- * <li> {@link FrameworkEvent#WAIT_TIMEDOUT WAIT_TIMEDOUT} - This
- * method has timed out and returned before this Framework has
- * stopped.</li>
- * </ul>
- * @throws InterruptedException If another thread interrupted the current
- * thread before or while the current thread was waiting for this
- * Framework to completely stop. The <i>interrupted status</i> of
- * the current thread is cleared when this exception is thrown.
- * @throws IllegalArgumentException If the value of timeout is negative.
- */
- FrameworkEvent waitForStop(long timeout) throws InterruptedException;
-
- /**
- * Start this Framework.
- *
- * <p>
- * The following steps are taken to start this Framework:
- * <ol>
- * <li>If this Framework is not in the {@link #STARTING} state,
- * {@link #init() initialize} this Framework.</li>
- * <li>All installed bundles must be started in accordance with each
- * bundle's persistent <i>autostart setting</i>. This means some bundles
- * will not be started, some will be started with <i>eager activation</i>
- * and some will be started with their <i>declared activation</i> policy. If
- * this Framework implements the optional <i>Start Level Service
- * Specification</i>, then the start level of this Framework is moved to the
- * start level specified by the
- * {@link Constants#FRAMEWORK_BEGINNING_STARTLEVEL beginning start level}
- * framework property, as described in the <i>Start Level Service
- * Specification</i>. If this framework property is not specified, then the
- * start level of this Framework is moved to start level one (1). Any
- * exceptions that occur during bundle starting must be wrapped in a
- * {@link BundleException} and then published as a framework event of type
- * {@link FrameworkEvent#ERROR}</li>
- * <li>This Framework's state is set to {@link #ACTIVE}.</li>
- * <li>A framework event of type {@link FrameworkEvent#STARTED} is fired</li>
- * </ol>
- *
- * @throws BundleException If this Framework could not be started.
- * @throws SecurityException If the caller does not have the appropriate
- * <code>AdminPermission[this,EXECUTE]</code>, and the Java Runtime
- * Environment supports permissions.
- * @see "Start Level Service Specification"
- */
- void start() throws BundleException;
-
- /**
- * Start this Framework.
- *
- * <p>
- * Calling this method is the same as calling {@link #start()}. There are no
- * start options for the Framework.
- *
- * @param options Ignored. There are no start options for the Framework.
- * @throws BundleException If this Framework could not be started.
- * @throws SecurityException If the caller does not have the appropriate
- * <code>AdminPermission[this,EXECUTE]</code>, and the Java Runtime
- * Environment supports permissions.
- * @see #start()
- */
- void start(int options) throws BundleException;
-
- /**
- * Stop this Framework.
- *
- * <p>
- * The method returns immediately to the caller after initiating the
- * following steps to be taken on another thread.
- * <ol>
- * <li>This Framework's state is set to {@link #STOPPING}.</li>
- * <li>All installed bundles must be stopped without changing each bundle's
- * persistent <i>autostart setting</i>. If this Framework implements the
- * optional <i>Start Level Service Specification</i>, then the start level
- * of this Framework is moved to start level zero (0), as described in the
- * <i>Start Level Service Specification</i>. Any exceptions that occur
- * during bundle stopping must be wrapped in a {@link BundleException} and
- * then published as a framework event of type {@link FrameworkEvent#ERROR}</li>
- * <li>Unregister all services registered by this Framework.</li>
- * <li>Event handling is disabled.</li>
- * <li>This Framework's state is set to {@link #RESOLVED}.</li>
- * <li>All resources held by this Framework are released. This includes
- * threads, bundle class loaders, open files, etc.</li>
- * <li>Notify all threads that are waiting at {@link #waitForStop(long)
- * waitForStop} that the stop operation has completed.</li>
- * </ol>
- * <p>
- * After being stopped, this Framework may be discarded, initialized or
- * started.
- *
- * @throws BundleException If stopping this Framework could not be
- * initiated.
- * @throws SecurityException If the caller does not have the appropriate
- * <code>AdminPermission[this,EXECUTE]</code>, and the Java Runtime
- * Environment supports permissions.
- * @see "Start Level Service Specification"
- */
- void stop() throws BundleException;
-
- /**
- * Stop this Framework.
- *
- * <p>
- * Calling this method is the same as calling {@link #stop()}. There are no
- * stop options for the Framework.
- *
- * @param options Ignored. There are no stop options for the Framework.
- * @throws BundleException If stopping this Framework could not be
- * initiated.
- * @throws SecurityException If the caller does not have the appropriate
- * <code>AdminPermission[this,EXECUTE]</code>, and the Java Runtime
- * Environment supports permissions.
- * @see #stop()
- */
- void stop(int options) throws BundleException;
-
- /**
- * The Framework cannot be uninstalled.
- *
- * <p>
- * This method always throws a BundleException.
- *
- * @throws BundleException This Framework cannot be uninstalled.
- * @throws SecurityException If the caller does not have the appropriate
- * <code>AdminPermission[this,LIFECYCLE]</code>, and the Java
- * Runtime Environment supports permissions.
- */
- void uninstall() throws BundleException;
-
- /**
- * Stop and restart this Framework.
- *
- * <p>
- * The method returns immediately to the caller after initiating the
- * following steps to be taken on another thread.
- * <ol>
- * <li>Perform the steps in the {@link #stop()} method to stop this
- * Framework.</li>
- * <li>Perform the steps in the {@link #start()} method to start this
- * Framework.</li>
- * </ol>
- *
- * @throws BundleException If stopping and restarting this Framework could
- * not be initiated.
- * @throws SecurityException If the caller does not have the appropriate
- * <code>AdminPermission[this,LIFECYCLE]</code>, and the Java
- * Runtime Environment supports permissions.
- */
- void update() throws BundleException;
-
- /**
- * Stop and restart this Framework.
- *
- * <p>
- * Calling this method is the same as calling {@link #update()} except that
- * any provided InputStream is immediately closed.
- *
- * @param in Any provided InputStream is immediately closed before returning
- * from this method and otherwise ignored.
- * @throws BundleException If stopping and restarting this Framework could
- * not be initiated.
- * @throws SecurityException If the caller does not have the appropriate
- * <code>AdminPermission[this,LIFECYCLE]</code>, and the Java
- * Runtime Environment supports permissions.
- */
- void update(InputStream in) throws BundleException;
-
- /**
- * Returns the Framework unique identifier. This Framework is assigned the
- * unique identifier zero (0) since this Framework is also a System Bundle.
- *
- * @return 0.
- * @see Bundle#getBundleId()
- */
- long getBundleId();
-
- /**
- * Returns the Framework location identifier. This Framework is assigned the
- * unique location "<code>System Bundle</code>" since this
- * Framework is also a System Bundle.
- *
- * @return The string "<code>System Bundle</code>".
- * @throws SecurityException If the caller does not have the appropriate
- * <code>AdminPermission[this,METADATA]</code>, and the Java Runtime
- * Environment supports permissions.
- * @see Bundle#getLocation()
- * @see Constants#SYSTEM_BUNDLE_LOCATION
- */
- String getLocation();
-
- /**
- * Returns the symbolic name of this Framework. The symbolic name is unique
- * for the implementation of the framework. However, the symbolic name
- * "<code>system.bundle</code>" must be recognized as an alias to
- * the implementation-defined symbolic name since this Framework is also a
- * System Bundle.
- *
- * @return The symbolic name of this Framework.
- * @see Bundle#getSymbolicName()
- * @see Constants#SYSTEM_BUNDLE_SYMBOLICNAME
- */
- String getSymbolicName();
-}
diff --git a/org.osgi.core/src/main/java/org/osgi/framework/launch/FrameworkFactory.java b/org.osgi.core/src/main/java/org/osgi/framework/launch/FrameworkFactory.java
deleted file mode 100644
index bcb6da3..0000000
--- a/org.osgi.core/src/main/java/org/osgi/framework/launch/FrameworkFactory.java
+++ /dev/null
@@ -1,72 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2009). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.osgi.framework.launch;
-
-import java.util.Map;
-
-import org.osgi.framework.Bundle;
-
-/**
- * A factory for creating {@link Framework} instances.
- *
- * <p>
- * A framework implementation jar must contain the following resource:
- *
- * <pre>
- * /META-INF/services/org.osgi.framework.launch.FrameworkFactory
- * </pre>
- *
- * This UTF-8 encoded resource must contain the name of the framework
- * implementation's FrameworkFactory implementation class. Space and tab
- * characters, including blank lines, in the resource must be ignored. The
- * number sign ('#' \u0023) and all characters following it on each line are
- * a comment and must be ignored.
- *
- * <p>
- * Launchers can find the name of the FrameworkFactory implementation class in
- * the resource and then load and construct a FrameworkFactory object for the
- * framework implementation. The FrameworkFactory implementation class must have
- * a public, no-argument constructor. Java™ SE 6 introduced the
- * <code>ServiceLoader</code> class which can create a FrameworkFactory instance
- * from the resource.
- *
- * @ThreadSafe
- * @version $Revision: 6888 $
- */
-public interface FrameworkFactory {
-
- /**
- * Create a new {@link Framework} instance.
- *
- * @param configuration The framework properties to configure the new
- * framework instance. If framework properties are not provided by
- * the configuration argument, the created framework instance must
- * use some reasonable default configuration appropriate for the
- * current VM. For example, the system packages for the current
- * execution environment should be properly exported. The specified
- * configuration argument may be <code>null</code>. The created
- * framework instance must copy any information needed from the
- * specified configuration argument since the configuration argument
- * can be changed after the framework instance has been created.
- * @return A new, configured {@link Framework} instance. The framework
- * instance must be in the {@link Bundle#INSTALLED} state.
- * @throws SecurityException If the caller does not have
- * <code>AllPermission</code>, and the Java Runtime Environment
- * supports permissions.
- */
- Framework newFramework(Map configuration);
-}
diff --git a/org.osgi.core/src/main/java/org/osgi/framework/launch/package.html b/org.osgi.core/src/main/java/org/osgi/framework/launch/package.html
deleted file mode 100644
index 6b0407b..0000000
--- a/org.osgi.core/src/main/java/org/osgi/framework/launch/package.html
+++ /dev/null
@@ -1,11 +0,0 @@
-<!-- $Revision: 6204 $ -->
-<BODY>
-<p>Framework Launch Package Version 1.0.
-<p>Bundles wishing to use this package must list the package
-in the Import-Package header of the bundle's manifest.
-For example:
-<pre>
-Import-Package: org.osgi.framework.launch;version="[1.0,2.0)"
-</pre>
-</BODY>
-
diff --git a/org.osgi.core/src/main/java/org/osgi/framework/launch/packageinfo b/org.osgi.core/src/main/java/org/osgi/framework/launch/packageinfo
deleted file mode 100644
index 7c8de03..0000000
--- a/org.osgi.core/src/main/java/org/osgi/framework/launch/packageinfo
+++ /dev/null
@@ -1 +0,0 @@
-version 1.0
diff --git a/org.osgi.core/src/main/java/org/osgi/framework/package.html b/org.osgi.core/src/main/java/org/osgi/framework/package.html
deleted file mode 100644
index 44d6c48..0000000
--- a/org.osgi.core/src/main/java/org/osgi/framework/package.html
+++ /dev/null
@@ -1,11 +0,0 @@
-<!-- $Revision: 6204 $ -->
-<BODY>
-<p>Framework Package Version 1.5.
-<p>Bundles wishing to use this package must list the package
-in the Import-Package header of the bundle's manifest.
-For example:
-<pre>
-Import-Package: org.osgi.framework;version="[1.5,2.0)"
-</pre>
-</BODY>
-
diff --git a/org.osgi.core/src/main/java/org/osgi/framework/packageinfo b/org.osgi.core/src/main/java/org/osgi/framework/packageinfo
deleted file mode 100644
index ccee95e..0000000
--- a/org.osgi.core/src/main/java/org/osgi/framework/packageinfo
+++ /dev/null
@@ -1 +0,0 @@
-version 1.5
diff --git a/org.osgi.core/src/main/java/org/osgi/service/condpermadmin/BundleLocationCondition.java b/org.osgi.core/src/main/java/org/osgi/service/condpermadmin/BundleLocationCondition.java
deleted file mode 100644
index 25c4ad9..0000000
--- a/org.osgi.core/src/main/java/org/osgi/service/condpermadmin/BundleLocationCondition.java
+++ /dev/null
@@ -1,132 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2005, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.osgi.service.condpermadmin;
-
-import java.security.AccessController;
-import java.security.PrivilegedAction;
-import java.util.Hashtable;
-
-import org.osgi.framework.Bundle;
-import org.osgi.framework.Filter;
-import org.osgi.framework.FrameworkUtil;
-import org.osgi.framework.InvalidSyntaxException;
-
-/**
- * Condition to test if the location of a bundle matches or does not match a
- * pattern. Since the bundle's location cannot be changed, this condition is
- * immutable.
- *
- * <p>
- * Pattern matching is done according to the filter string matching rules.
- *
- * @ThreadSafe
- * @version $Revision: 5901 $
- */
-public class BundleLocationCondition {
- private static final String CONDITION_TYPE = "org.osgi.service.condpermadmin.BundleLocationCondition";
-
- /**
- * Constructs a condition that tries to match the passed Bundle's location
- * to the location pattern.
- *
- * @param bundle The Bundle being evaluated.
- * @param info The ConditionInfo from which to construct the condition. The
- * ConditionInfo must specify one or two arguments. The first
- * argument of the ConditionInfo specifies the location pattern
- * against which to match the bundle location. Matching is done
- * according to the filter string matching rules. Any '*' characters
- * in the first argument are used as wildcards when matching bundle
- * locations unless they are escaped with a '\' character. The
- * Condition is satisfied if the bundle location matches the pattern.
- * The second argument of the ConditionInfo is optional. If a second
- * argument is present and equal to "!", then the satisfaction of the
- * Condition is negated. That is, the Condition is satisfied if the
- * bundle location does NOT match the pattern. If the second argument
- * is present but does not equal "!", then the second argument is
- * ignored.
- * @return Condition object for the requested condition.
- */
- static public Condition getCondition(final Bundle bundle,
- final ConditionInfo info) {
- if (!CONDITION_TYPE.equals(info.getType()))
- throw new IllegalArgumentException(
- "ConditionInfo must be of type \"" + CONDITION_TYPE + "\"");
- String[] args = info.getArgs();
- if (args.length != 1 && args.length != 2)
- throw new IllegalArgumentException("Illegal number of args: " + args.length);
- String bundleLocation = (String) AccessController.doPrivileged(new PrivilegedAction() {
- public Object run() {
- return bundle.getLocation();
- }
- });
- Filter filter = null;
- try {
- filter = FrameworkUtil.createFilter("(location="
- + escapeLocation(args[0]) + ")");
- }
- catch (InvalidSyntaxException e) {
- // this should never happen, but just in case
- throw new RuntimeException("Invalid filter: " + e.getFilter(), e);
- }
- Hashtable matchProps = new Hashtable(2);
- matchProps.put("location", bundleLocation);
- boolean negate = (args.length == 2) ? "!".equals(args[1]) : false;
- return (negate ^ filter.match(matchProps)) ? Condition.TRUE
- : Condition.FALSE;
- }
-
- private BundleLocationCondition() {
- // private constructor to prevent objects of this type
- }
-
- /**
- * Escape the value string such that '(', ')' and '\' are escaped. The '\'
- * char is only escaped if it is not followed by a '*'.
- *
- * @param value unescaped value string.
- * @return escaped value string.
- */
- private static String escapeLocation(final String value) {
- boolean escaped = false;
- int inlen = value.length();
- int outlen = inlen << 1; /* inlen * 2 */
-
- char[] output = new char[outlen];
- value.getChars(0, inlen, output, inlen);
-
- int cursor = 0;
- for (int i = inlen; i < outlen; i++) {
- char c = output[i];
- switch (c) {
- case '\\' :
- if (i + 1 < outlen && output[i + 1] == '*')
- break;
- case '(' :
- case ')' :
- output[cursor] = '\\';
- cursor++;
- escaped = true;
- break;
- }
-
- output[cursor] = c;
- cursor++;
- }
-
- return escaped ? new String(output, 0, cursor) : value;
- }
-}
diff --git a/org.osgi.core/src/main/java/org/osgi/service/condpermadmin/BundleSignerCondition.java b/org.osgi.core/src/main/java/org/osgi/service/condpermadmin/BundleSignerCondition.java
deleted file mode 100644
index 31b6481..0000000
--- a/org.osgi.core/src/main/java/org/osgi/service/condpermadmin/BundleSignerCondition.java
+++ /dev/null
@@ -1,110 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2005, 2009). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.osgi.service.condpermadmin;
-
-import java.security.cert.X509Certificate;
-import java.util.ArrayList;
-import java.util.Iterator;
-import java.util.List;
-import java.util.Map;
-
-import org.osgi.framework.Bundle;
-import org.osgi.framework.FrameworkUtil;
-
-/**
- * Condition to test if the signer of a bundle matches or does not match a
- * pattern. Since the bundle's signer can only change when the bundle is
- * updated, this condition is immutable.
- * <p>
- * The condition expressed using a single String that specifies a Distinguished
- * Name (DN) chain to match bundle signers against. DN's are encoded using IETF
- * RFC 2253. Usually signers use certificates that are issued by certificate
- * authorities, which also have a corresponding DN and certificate. The
- * certificate authorities can form a chain of trust where the last DN and
- * certificate is known by the framework. The signer of a bundle is expressed as
- * signers DN followed by the DN of its issuer followed by the DN of the next
- * issuer until the DN of the root certificate authority. Each DN is separated
- * by a semicolon.
- * <p>
- * A bundle can satisfy this condition if one of its signers has a DN chain that
- * matches the DN chain used to construct this condition. Wildcards (`*') can be
- * used to allow greater flexibility in specifying the DN chains. Wildcards can
- * be used in place of DNs, RDNs, or the value in an RDN. If a wildcard is used
- * for a value of an RDN, the value must be exactly "*" and will match any value
- * for the corresponding type in that RDN. If a wildcard is used for a RDN, it
- * must be the first RDN and will match any number of RDNs (including zero
- * RDNs).
- *
- * @ThreadSafe
- * @version $Revision: 6860 $
- */
-public class BundleSignerCondition {
- private static final String CONDITION_TYPE = "org.osgi.service.condpermadmin.BundleSignerCondition";
-
- /**
- * Constructs a Condition that tries to match the passed Bundle's location
- * to the location pattern.
- *
- * @param bundle The Bundle being evaluated.
- * @param info The ConditionInfo from which to construct the condition. The
- * ConditionInfo must specify one or two arguments. The first
- * argument of the ConditionInfo specifies the chain of distinguished
- * names pattern to match against the signer of the bundle. The
- * Condition is satisfied if the signer of the bundle matches the
- * pattern. The second argument of the ConditionInfo is optional. If
- * a second argument is present and equal to "!", then the
- * satisfaction of the Condition is negated. That is, the Condition
- * is satisfied if the signer of the bundle does NOT match the
- * pattern. If the second argument is present but does not equal "!",
- * then the second argument is ignored.
- * @return A Condition which checks the signers of the specified bundle.
- */
- public static Condition getCondition(final Bundle bundle,
- final ConditionInfo info) {
- if (!CONDITION_TYPE.equals(info.getType()))
- throw new IllegalArgumentException(
- "ConditionInfo must be of type \"" + CONDITION_TYPE + "\"");
- String[] args = info.getArgs();
- if (args.length != 1 && args.length != 2)
- throw new IllegalArgumentException("Illegal number of args: "
- + args.length);
-
- Map/* <X509Certificate, List<X509Certificate>> */signers = bundle
- .getSignerCertificates(Bundle.SIGNERS_TRUSTED);
- boolean match = false;
- for (Iterator iSigners = signers.values().iterator(); iSigners
- .hasNext();) {
- List/* <X509Certificate> */signerCerts = (List) iSigners.next();
- List/* <String> */dnChain = new ArrayList(signerCerts.size());
- for (Iterator iCerts = signerCerts.iterator(); iCerts.hasNext();) {
- dnChain.add(((X509Certificate) iCerts.next()).getSubjectDN()
- .getName());
- }
- if (FrameworkUtil.matchDistinguishedNameChain(args[0], dnChain)) {
- match = true;
- break;
- }
- }
-
- boolean negate = (args.length == 2) ? "!".equals(args[1]) : false;
- return negate ^ match ? Condition.TRUE : Condition.FALSE;
- }
-
- private BundleSignerCondition() {
- // private constructor to prevent objects of this type
- }
-}
diff --git a/org.osgi.core/src/main/java/org/osgi/service/condpermadmin/Condition.java b/org.osgi.core/src/main/java/org/osgi/service/condpermadmin/Condition.java
deleted file mode 100644
index 63c33b4..0000000
--- a/org.osgi.core/src/main/java/org/osgi/service/condpermadmin/Condition.java
+++ /dev/null
@@ -1,137 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2004, 2009). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.osgi.service.condpermadmin;
-
-import java.util.Dictionary;
-
-/**
- * The interface implemented by a Condition. Conditions are bound to Permissions
- * using Conditional Permission Info. The Permissions of a ConditionalPermission
- * Info can only be used if the associated Conditions are satisfied.
- *
- * @ThreadSafe
- * @version $Revision: 6464 $
- */
-public interface Condition {
- /**
- * A Condition object that will always evaluate to true and that is never
- * postponed.
- */
- public final static Condition TRUE = new BooleanCondition(true);
-
- /**
- * A Condition object that will always evaluate to false and that is never
- * postponed.
- */
- public final static Condition FALSE = new BooleanCondition(false);
-
- /**
- * Returns whether the evaluation must be postponed until the end of the
- * permission check. If this method returns <code>false</code> (or this
- * Condition is immutable), then this Condition must be able to directly
- * answer the {@link #isSatisfied()} method. In other words, isSatisfied()
- * will return very quickly since no external sources, such as for example
- * users or networks, need to be consulted. <br/>
- * This method must always return the same value whenever it is called so
- * that the Conditional Permission Admin can cache its result.
- *
- * @return <code>true</code> to indicate the evaluation must be postponed.
- * Otherwise, <code>false</code> if the evaluation can be performed
- * immediately.
- */
- boolean isPostponed();
-
- /**
- * Returns whether the Condition is satisfied. This method is only called
- * for immediate Condition objects or immutable postponed conditions, and
- * must always be called inside a permission check. Mutable postponed
- * Condition objects will be called with the grouped version
- * {@link #isSatisfied(Condition[],Dictionary)} at the end of the permission
- * check.
- *
- * @return <code>true</code> to indicate the Conditions is satisfied.
- * Otherwise, <code>false</code> if the Condition is not satisfied.
- */
- boolean isSatisfied();
-
- /**
- * Returns whether the Condition is mutable. A Condition can go from mutable
- * (<code>true</code>) to immutable (<code>false</code>) over time but never
- * from immutable (<code>false</code>) to mutable (<code>true</code>).
- *
- * @return <code>true</code> {@link #isSatisfied()} can change. Otherwise,
- * <code>false</code> if the value returned by
- * {@link #isSatisfied()} will not change for this condition.
- */
- boolean isMutable();
-
- /**
- * Returns whether a the set of Condition objects are satisfied. Although
- * this method is not static, it must be implemented as if it were static.
- * All of the passed Condition objects will be of the same type and will
- * correspond to the class type of the object on which this method is
- * invoked.This method must be called inside a permission check only.
- *
- * @param conditions The array of Condition objects, which must all be of
- * the same class and mutable. The receiver must be one of those
- * Condition objects.
- * @param context A Dictionary object that implementors can use to track
- * state. If this method is invoked multiple times in the same
- * permission check, the same Dictionary will be passed multiple
- * times. The SecurityManager treats this Dictionary as an opaque
- * object and simply creates an empty dictionary and passes it to
- * subsequent invocations if multiple invocations are needed.
- * @return <code>true</code> if all the Condition objects are satisfied.
- * Otherwise, <code>false</code> if one of the Condition objects is
- * not satisfied.
- */
- boolean isSatisfied(Condition conditions[], Dictionary context);
-}
-
-/**
- * Package private class used to define the {@link Condition#FALSE} and
- * {@link Condition#TRUE} constants.
- *
- * @Immutable
- */
-final class BooleanCondition implements Condition {
- private final boolean satisfied;
-
- BooleanCondition(boolean satisfied) {
- this.satisfied = satisfied;
- }
-
- public boolean isPostponed() {
- return false;
- }
-
- public boolean isSatisfied() {
- return satisfied;
- }
-
- public boolean isMutable() {
- return false;
- }
-
- public boolean isSatisfied(Condition[] conds, Dictionary context) {
- for (int i = 0, length = conds.length; i < length; i++) {
- if (!conds[i].isSatisfied())
- return false;
- }
- return true;
- }
-}
diff --git a/org.osgi.core/src/main/java/org/osgi/service/condpermadmin/ConditionInfo.java b/org.osgi.core/src/main/java/org/osgi/service/condpermadmin/ConditionInfo.java
deleted file mode 100644
index 6cb235c..0000000
--- a/org.osgi.core/src/main/java/org/osgi/service/condpermadmin/ConditionInfo.java
+++ /dev/null
@@ -1,344 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2004, 2009). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.osgi.service.condpermadmin;
-
-import java.util.ArrayList;
-
-/**
- * Condition representation used by the Conditional Permission Admin service.
- *
- * <p>
- * This class encapsulates two pieces of information: a Condition <i>type</i>
- * (class name), which must implement <code>Condition</code>, and the
- * arguments passed to its constructor.
- *
- * <p>
- * In order for a Condition represented by a <code>ConditionInfo</code> to be
- * instantiated and considered during a permission check, its Condition class
- * must be available from the system classpath.
- *
- * <p>
- * The Condition class must either:
- * <ul>
- * <li>Declare a public static <code>getCondition</code> method that takes a
- * <code>Bundle</code> object and a <code>ConditionInfo</code> object as
- * arguments. That method must return an object that implements the
- * <code>Condition</code> interface.</li>
- * <li>Implement the <code>Condition</code> interface and define a public
- * constructor that takes a <code>Bundle</code> object and a
- * <code>ConditionInfo</code> object as arguments.
- * </ul>
- *
- * @Immutable
- * @version $Revision: 6492 $
- */
-public class ConditionInfo {
- private final String type;
- private final String[] args;
-
- /**
- * Constructs a <code>ConditionInfo</code> from the specified type and args.
- *
- * @param type The fully qualified class name of the Condition represented
- * by this <code>ConditionInfo</code>.
- * @param args The arguments for the Condition. These arguments are
- * available to the newly created Condition by calling the
- * {@link #getArgs()} method.
- * @throws NullPointerException If <code>type</code> is <code>null</code>.
- */
- public ConditionInfo(String type, String[] args) {
- this.type = type;
- this.args = (args != null) ? (String[]) args.clone() : new String[0];
- if (type == null) {
- throw new NullPointerException("type is null");
- }
- }
-
- /**
- * Constructs a <code>ConditionInfo</code> object from the specified encoded
- * <code>ConditionInfo</code> string. White space in the encoded
- * <code>ConditionInfo</code> string is ignored.
- *
- * @param encodedCondition The encoded <code>ConditionInfo</code>.
- * @see #getEncoded
- * @throws IllegalArgumentException If the specified
- * <code>encodedCondition</code> is not properly formatted.
- */
- public ConditionInfo(String encodedCondition) {
- if (encodedCondition == null) {
- throw new NullPointerException("missing encoded condition");
- }
- if (encodedCondition.length() == 0) {
- throw new IllegalArgumentException("empty encoded condition");
- }
- try {
- char[] encoded = encodedCondition.toCharArray();
- int length = encoded.length;
- int pos = 0;
-
- /* skip whitespace */
- while (Character.isWhitespace(encoded[pos])) {
- pos++;
- }
-
- /* the first character must be '[' */
- if (encoded[pos] != '[') {
- throw new IllegalArgumentException("expecting open bracket");
- }
- pos++;
-
- /* skip whitespace */
- while (Character.isWhitespace(encoded[pos])) {
- pos++;
- }
-
- /* type is not quoted or encoded */
- int begin = pos;
- while (!Character.isWhitespace(encoded[pos])
- && (encoded[pos] != ']')) {
- pos++;
- }
- if (pos == begin || encoded[begin] == '"') {
- throw new IllegalArgumentException("expecting type");
- }
- this.type = new String(encoded, begin, pos - begin);
-
- /* skip whitespace */
- while (Character.isWhitespace(encoded[pos])) {
- pos++;
- }
-
- /* type may be followed by args which are quoted and encoded */
- ArrayList argsList = new ArrayList();
- while (encoded[pos] == '"') {
- pos++;
- begin = pos;
- while (encoded[pos] != '"') {
- if (encoded[pos] == '\\') {
- pos++;
- }
- pos++;
- }
- argsList.add(unescapeString(encoded, begin, pos));
- pos++;
-
- if (Character.isWhitespace(encoded[pos])) {
- /* skip whitespace */
- while (Character.isWhitespace(encoded[pos])) {
- pos++;
- }
- }
- }
- this.args = (String[]) argsList
- .toArray(new String[argsList.size()]);
-
- /* the final character must be ']' */
- char c = encoded[pos];
- pos++;
- while ((pos < length) && Character.isWhitespace(encoded[pos])) {
- pos++;
- }
- if ((c != ']') || (pos != length)) {
- throw new IllegalArgumentException("expecting close bracket");
- }
- }
- catch (ArrayIndexOutOfBoundsException e) {
- throw new IllegalArgumentException("parsing terminated abruptly");
- }
- }
-
- /**
- * Returns the string encoding of this <code>ConditionInfo</code> in a form
- * suitable for restoring this <code>ConditionInfo</code>.
- *
- * <p>
- * The encoded format is:
- *
- * <pre>
- * [type "arg0" "arg1" ...]
- * </pre>
- *
- * where <i>argN</i> are strings that must be encoded for proper parsing.
- * Specifically, the <code>"</code>, <code>\</code>, carriage return,
- * and line feed characters must be escaped using <code>\"</code>,
- * <code>\\</code>, <code>\r</code>, and <code>\n</code>, respectively.
- *
- * <p>
- * The encoded string contains no leading or trailing whitespace characters.
- * A single space character is used between type and "<i>arg0</i>"
- * and between the arguments.
- *
- * @return The string encoding of this <code>ConditionInfo</code>.
- */
- public final String getEncoded() {
- StringBuffer output = new StringBuffer();
- output.append('[');
- output.append(type);
-
- for (int i = 0; i < args.length; i++) {
- output.append(" \"");
- escapeString(args[i], output);
- output.append('\"');
- }
-
- output.append(']');
-
- return output.toString();
- }
-
- /**
- * Returns the string representation of this <code>ConditionInfo</code>.
- * The string is created by calling the <code>getEncoded</code> method on
- * this <code>ConditionInfo</code>.
- *
- * @return The string representation of this <code>ConditionInfo</code>.
- */
- public String toString() {
- return getEncoded();
- }
-
- /**
- * Returns the fully qualified class name of the condition represented by
- * this <code>ConditionInfo</code>.
- *
- * @return The fully qualified class name of the condition represented by
- * this <code>ConditionInfo</code>.
- */
- public final String getType() {
- return type;
- }
-
- /**
- * Returns arguments of this <code>ConditionInfo</code>.
- *
- * @return The arguments of this <code>ConditionInfo</code>. An empty
- * array is returned if the <code>ConditionInfo</code> has no
- * arguments.
- */
- public final String[] getArgs() {
- return (String[]) args.clone();
- }
-
- /**
- * Determines the equality of two <code>ConditionInfo</code> objects.
- *
- * This method checks that specified object has the same type and args as
- * this <code>ConditionInfo</code> object.
- *
- * @param obj The object to test for equality with this
- * <code>ConditionInfo</code> object.
- * @return <code>true</code> if <code>obj</code> is a
- * <code>ConditionInfo</code>, and has the same type and args as
- * this <code>ConditionInfo</code> object; <code>false</code>
- * otherwise.
- */
- public boolean equals(Object obj) {
- if (obj == this) {
- return true;
- }
-
- if (!(obj instanceof ConditionInfo)) {
- return false;
- }
-
- ConditionInfo other = (ConditionInfo) obj;
-
- if (!type.equals(other.type) || args.length != other.args.length)
- return false;
-
- for (int i = 0; i < args.length; i++) {
- if (!args[i].equals(other.args[i]))
- return false;
- }
- return true;
- }
-
- /**
- * Returns the hash code value for this object.
- *
- * @return A hash code value for this object.
- */
-
- public int hashCode() {
- int h = 31 * 17 + type.hashCode();
- for (int i = 0; i < args.length; i++) {
- h = 31 * h + args[i].hashCode();
- }
- return h;
- }
-
- /**
- * This escapes the quotes, backslashes, \n, and \r in the string using a
- * backslash and appends the newly escaped string to a StringBuffer.
- */
- private static void escapeString(String str, StringBuffer output) {
- int len = str.length();
- for (int i = 0; i < len; i++) {
- char c = str.charAt(i);
- switch (c) {
- case '"' :
- case '\\' :
- output.append('\\');
- output.append(c);
- break;
- case '\r' :
- output.append("\\r");
- break;
- case '\n' :
- output.append("\\n");
- break;
- default :
- output.append(c);
- break;
- }
- }
- }
-
- /**
- * Takes an encoded character array and decodes it into a new String.
- */
- private static String unescapeString(char[] str, int begin, int end) {
- StringBuffer output = new StringBuffer(end - begin);
- for (int i = begin; i < end; i++) {
- char c = str[i];
- if (c == '\\') {
- i++;
- if (i < end) {
- c = str[i];
- switch (c) {
- case '"' :
- case '\\' :
- break;
- case 'r' :
- c = '\r';
- break;
- case 'n' :
- c = '\n';
- break;
- default :
- c = '\\';
- i--;
- break;
- }
- }
- }
- output.append(c);
- }
-
- return output.toString();
- }
-}
diff --git a/org.osgi.core/src/main/java/org/osgi/service/condpermadmin/ConditionalPermissionAdmin.java b/org.osgi.core/src/main/java/org/osgi/service/condpermadmin/ConditionalPermissionAdmin.java
deleted file mode 100644
index 2ea7d87..0000000
--- a/org.osgi.core/src/main/java/org/osgi/service/condpermadmin/ConditionalPermissionAdmin.java
+++ /dev/null
@@ -1,236 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2005, 2009). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.osgi.service.condpermadmin;
-
-import java.security.AccessControlContext;
-import java.util.Enumeration;
-
-import org.osgi.service.permissionadmin.PermissionInfo;
-
-/**
- * Framework service to administer Conditional Permissions. Conditional
- * Permissions can be added to, retrieved from, and removed from the framework.
- * Conditional Permissions are conceptually managed in an ordered table called
- * the Conditional Permission Table.
- *
- * @ThreadSafe
- * @version $Revision: 6782 $
- */
-public interface ConditionalPermissionAdmin {
- /**
- * Create a new Conditional Permission Info in the Conditional Permission
- * Table.
- * <p>
- * The Conditional Permission Info will be given a unique, never reused
- * name. This entry will be added at the beginning of the Conditional
- * Permission Table with an access decision of
- * {@link ConditionalPermissionInfo#ALLOW ALLOW}.
- * <p>
- * Since this method changes the Conditional Permission Table any
- * {@link ConditionalPermissionUpdate}s that were created prior to calling
- * this method can no longer be committed.
- *
- * @param conditions The conditions that need to be satisfied to enable the
- * specified permissions. This argument can be <code>null</code> or
- * an empty array indicating the specified permissions are not
- * guarded by any conditions.
- * @param permissions The permissions that are enabled when the specified
- * conditions, if any, are satisfied. This argument must not be
- * <code>null</code> and must specify at least one permission.
- * @return The ConditionalPermissionInfo for the specified Conditions and
- * Permissions.
- * @throws IllegalArgumentException If no permissions are specified.
- * @throws SecurityException If the caller does not have
- * <code>AllPermission</code>.
- * @deprecated Since 1.1. Use {@link #newConditionalPermissionUpdate()}
- * instead.
- */
- ConditionalPermissionInfo addConditionalPermissionInfo(
- ConditionInfo conditions[], PermissionInfo permissions[]);
-
- /**
- * Set or create a Conditional Permission Info with a specified name in the
- * Conditional Permission Table.
- * <p>
- * If the specified name is <code>null</code>, a new Conditional Permission
- * Info must be created and will be given a unique, never reused name. If
- * there is currently no Conditional Permission Info with the specified
- * name, a new Conditional Permission Info must be created with the
- * specified name. Otherwise, the Conditional Permission Info with the
- * specified name must be updated with the specified Conditions and
- * Permissions. If a new entry was created in the Conditional Permission
- * Table it will be added at the beginning of the table with an access
- * decision of {@link ConditionalPermissionInfo#ALLOW ALLOW}.
- * <p>
- * Since this method changes the underlying permission table any
- * {@link ConditionalPermissionUpdate}s that were created prior to calling
- * this method can no longer be committed.
- *
- * @param name The name of the Conditional Permission Info, or
- * <code>null</code>.
- * @param conditions The conditions that need to be satisfied to enable the
- * specified permissions. This argument can be <code>null</code> or
- * an empty array indicating the specified permissions are not
- * guarded by any conditions.
- * @param permissions The permissions that are enabled when the specified
- * conditions, if any, are satisfied. This argument must not be
- * <code>null</code> and must specify at least one permission.
- * @return The ConditionalPermissionInfo for the specified name, Conditions
- * and Permissions.
- * @throws IllegalArgumentException If no permissions are specified.
- * @throws SecurityException If the caller does not have
- * <code>AllPermission</code>.
- * @deprecated Since 1.1. Use {@link #newConditionalPermissionUpdate()}
- * instead.
- */
- ConditionalPermissionInfo setConditionalPermissionInfo(String name,
- ConditionInfo conditions[], PermissionInfo permissions[]);
-
- /**
- * Returns the Conditional Permission Infos from the Conditional Permission
- * Table.
- * <p>
- * The returned Enumeration will return elements in the order they are kept
- * in the Conditional Permission Table.
- * <p>
- * The Enumeration returned is based on a copy of the Conditional Permission
- * Table and therefore will not throw exceptions if the Conditional
- * Permission Table is changed during the course of reading elements from
- * the Enumeration.
- *
- * @return An enumeration of the Conditional Permission Infos that are
- * currently in the Conditional Permission Table.
- * @deprecated Since 1.1. Use {@link #newConditionalPermissionUpdate()}
- * instead.
- */
- Enumeration/* <ConditionalPermissionInfo> */getConditionalPermissionInfos();
-
- /**
- * Return the Conditional Permission Info with the specified name.
- *
- * @param name The name of the Conditional Permission Info to be returned.
- * @return The Conditional Permission Info with the specified name or
- * <code>null</code> if no Conditional Permission Info with the
- * specified name exists in the Conditional Permission Table.
- * @deprecated Since 1.1. Use {@link #newConditionalPermissionUpdate()}
- * instead.
- */
- ConditionalPermissionInfo getConditionalPermissionInfo(String name);
-
- /**
- * Returns the Access Control Context that corresponds to the specified
- * signers.
- *
- * The returned Access Control Context must act as if its protection domain
- * came from a bundle that has the following characteristics:
- * <ul>
- * <li>It is signed by all of the given signers</li>
- * <li>It has a bundle id of -1</li>
- * <li>Its location is the empty string</li>
- * <li>Its state is UNINSTALLED</li>
- * <li>It has no headers</li>
- * <li>It has the empty version (0.0.0)</li>
- * <li>Its last modified time=0</li>
- * <li>Many methods will throw <code>IllegalStateException</code> because the state is UNINSTALLED</li>
- * <li>All other methods return a <code>null</code></li>
- * </ul>
- * @param signers The signers for which to return an Access Control Context.
- * @return An <code>AccessControlContext</code> that has the Permissions
- * associated with the signer.
- */
- AccessControlContext getAccessControlContext(String[] signers);
-
- /**
- * Creates a new update for the Conditional Permission Table. The update is
- * a working copy of the current Conditional Permission Table. If the
- * running Conditional Permission Table is modified before commit is called
- * on the returned update, then the call to commit on the returned update
- * will fail. That is, the commit method will return false and no change
- * will be made to the running Conditional Permission Table. There is no
- * requirement that commit is eventually called on the returned update.
- *
- * @return A new update for the Conditional Permission Table.
- * @since 1.1
- */
- ConditionalPermissionUpdate newConditionalPermissionUpdate();
-
- /**
- * Creates a new ConditionalPermissionInfo with the specified fields
- * suitable for insertion into a {@link ConditionalPermissionUpdate}. The
- * <code>delete</code> method on <code>ConditionalPermissionInfo</code>
- * objects created with this method must throw
- * UnsupportedOperationException.
- *
- * @param name The name of the created
- * <code>ConditionalPermissionInfo</code> or <code>null</code> to
- * have a unique name generated when the returned
- * <code>ConditionalPermissionInfo</code> is committed in an update
- * to the Conditional Permission Table.
- * @param conditions The conditions that need to be satisfied to enable the
- * specified permissions. This argument can be <code>null</code> or
- * an empty array indicating the specified permissions are not
- * guarded by any conditions.
- * @param permissions The permissions that are enabled when the specified
- * conditions, if any, are satisfied. This argument must not be
- * <code>null</code> and must specify at least one permission.
- * @param access Access decision. Must be one of the following values:
- * <ul>
- * <li>{@link ConditionalPermissionInfo#ALLOW allow}</li>
- * <li>{@link ConditionalPermissionInfo#DENY deny}</li>
- * </ul>
- * The specified access decision value must be evaluated case
- * insensitively.
- * @return A <code>ConditionalPermissionInfo</code> object suitable for
- * insertion into a {@link ConditionalPermissionUpdate}.
- * @throws IllegalArgumentException If no permissions are specified or if
- * the specified access decision is not a valid value.
- * @since 1.1
- */
- ConditionalPermissionInfo newConditionalPermissionInfo(String name,
- ConditionInfo conditions[], PermissionInfo permissions[],
- String access);
-
- /**
- * Creates a new <code>ConditionalPermissionInfo</code> from the specified
- * encoded <code>ConditionalPermissionInfo</code> string suitable for
- * insertion into a {@link ConditionalPermissionUpdate}. The
- * <code>delete</code> method on <code>ConditionalPermissionInfo</code>
- * objects created with this method must throw
- * UnsupportedOperationException.
- *
- * @param encodedConditionalPermissionInfo The encoded
- * <code>ConditionalPermissionInfo</code>. White space in the encoded
- * <code>ConditionalPermissionInfo</code> is ignored. The access
- * decision value in the encoded
- * <code>ConditionalPermissionInfo</code> must be evaluated case
- * insensitively. If the encoded
- * <code>ConditionalPermissionInfo</code> does not contain the
- * optional name, <code>null</code> must be used for the name and a
- * unique name will be generated when the returned
- * <code>ConditionalPermissionInfo</code> is committed in an update
- * to the Conditional Permission Table.
- * @return A <code>ConditionalPermissionInfo</code> object suitable for
- * insertion into a {@link ConditionalPermissionUpdate}.
- * @throws IllegalArgumentException If the specified
- * <code>encodedConditionalPermissionInfo</code> is not properly
- * formatted.
- * @see ConditionalPermissionInfo#getEncoded
- * @since 1.1
- */
- ConditionalPermissionInfo newConditionalPermissionInfo(
- String encodedConditionalPermissionInfo);
-}
diff --git a/org.osgi.core/src/main/java/org/osgi/service/condpermadmin/ConditionalPermissionInfo.java b/org.osgi.core/src/main/java/org/osgi/service/condpermadmin/ConditionalPermissionInfo.java
deleted file mode 100644
index dbe09be..0000000
--- a/org.osgi.core/src/main/java/org/osgi/service/condpermadmin/ConditionalPermissionInfo.java
+++ /dev/null
@@ -1,190 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2004, 2009). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.osgi.service.condpermadmin;
-
-import org.osgi.service.permissionadmin.PermissionInfo;
-
-/**
- * A list of Permissions guarded by a list of conditions with an access
- * decision. Instances of this interface are obtained from the Conditional
- * Permission Admin service.
- *
- * @Immutable
- * @version $Revision: 6492 $
- */
-public interface ConditionalPermissionInfo {
- /**
- * This string is used to indicate that a row in the Conditional Permission
- * Table should return an access decision of "allow" if the
- * conditions are all satisfied and at least one of the permissions is
- * implied.
- *
- * @since 1.1
- */
- public final static String ALLOW = "allow";
-
- /**
- * This string is used to indicate that a row in the Conditional Permission
- * Table should return an access decision of "deny" if the
- * conditions are all satisfied and at least one of the permissions is
- * implied.
- *
- * @since 1.1
- */
- public final static String DENY = "deny";
-
- /**
- * Returns the Condition Infos for the Conditions that must be satisfied to
- * enable the Permissions.
- *
- * @return The Condition Infos for the Conditions in this Conditional
- * Permission Info.
- */
- ConditionInfo[] getConditionInfos();
-
- /**
- * Returns the Permission Infos for the Permissions in this Conditional
- * Permission Info.
- *
- * @return The Permission Infos for the Permissions in this Conditional
- * Permission Info.
- */
- PermissionInfo[] getPermissionInfos();
-
- /**
- * Removes this Conditional Permission Info from the Conditional Permission
- * Table.
- * <p>
- * Since this method changes the underlying permission table, any
- * {@link ConditionalPermissionUpdate}s that were created prior to calling
- * this method can no longer be committed.
- *
- * @throws UnsupportedOperationException If this object was created by
- * {@link ConditionalPermissionAdmin#newConditionalPermissionInfo}
- * or obtained from a {@link ConditionalPermissionUpdate}. This
- * method only functions if this object was obtained from one of the
- * {@link ConditionalPermissionAdmin} methods deprecated in version
- * 1.1.
- * @throws SecurityException If the caller does not have
- * <code>AllPermission</code>.
- * @deprecated Since 1.1. Use
- * {@link ConditionalPermissionAdmin#newConditionalPermissionUpdate()}
- * instead to manage the Conditional Permissions.
- */
- void delete();
-
- /**
- * Returns the name of this Conditional Permission Info.
- *
- * @return The name of this Conditional Permission Info. This can be
- * <code>null</code> if this Conditional Permission Info was created
- * without a name.
- */
- String getName();
-
- /**
- * Returns the access decision for this Conditional Permission Info.
- *
- * @return One of the following values:
- * <ul>
- * <li>{@link #ALLOW allow} - The access decision is
- * "allow".</li>
- * <li>{@link #DENY deny} - The access decision is "deny".
- * </li>
- * </ul>
- * @since 1.1
- */
- String getAccessDecision();
-
- /**
- * Returns the string encoding of this
- * <code>ConditionalPermissionInfo</code> in a form suitable for restoring
- * this <code>ConditionalPermissionInfo</code>.
- *
- * <p>
- * The encoded format is:
- *
- * <pre>
- * access {conditions permissions} name
- * </pre>
- *
- * where <i>access</i> is the access decision, <i>conditions</i> is zero or
- * more {@link ConditionInfo#getEncoded() encoded conditions},
- * <i>permissions</i> is one or more {@link PermissionInfo#getEncoded()
- * encoded permissions} and <i>name</i> is the name of the
- * <code>ConditionalPermissionInfo</code>.
- *
- * <p>
- * <i>name</i> is optional. If <i>name</i> is present in the encoded string,
- * it must quoted, beginning and ending with <code>"</code>. The
- * <i>name</i> value must be encoded for proper parsing. Specifically, the
- * <code>"</code>, <code>\</code>, carriage return, and line feed
- * characters must be escaped using <code>\"</code>, <code>\\</code>,
- * <code>\r</code>, and <code>\n</code>, respectively.
- *
- * <p>
- * The encoded string contains no leading or trailing whitespace characters.
- * A single space character is used between <i>access</i> and <code>{</code>
- * and between <code>}</code> and <i>name</i>, if <i>name</i> is present.
- * All encoded conditions and permissions are separated by a single space
- * character.
- *
- * @return The string encoding of this
- * <code>ConditionalPermissionInfo</code>.
- * @since 1.1
- */
- String getEncoded();
-
- /**
- * Returns the string representation of this
- * <code>ConditionalPermissionInfo</code>. The string is created by calling
- * the <code>getEncoded</code> method on this
- * <code>ConditionalPermissionInfo</code>.
- *
- * @return The string representation of this
- * <code>ConditionalPermissionInfo</code>.
- * @since 1.1
- */
- String toString();
-
- /**
- * Determines the equality of two <code>ConditionalPermissionInfo</code>
- * objects.
- *
- * This method checks that specified object has the same access decision,
- * conditions, permissions and name as this
- * <code>ConditionalPermissionInfo</code> object.
- *
- * @param obj The object to test for equality with this
- * <code>ConditionalPermissionInfo</code> object.
- * @return <code>true</code> if <code>obj</code> is a
- * <code>ConditionalPermissionInfo</code>, and has the same access
- * decision, conditions, permissions and name as this
- * <code>ConditionalPermissionInfo</code> object; <code>false</code>
- * otherwise.
- * @since 1.1
- */
- boolean equals(Object obj);
-
- /**
- * Returns the hash code value for this object.
- *
- * @return A hash code value for this object.
- * @since 1.1
- */
- int hashCode();
-}
diff --git a/org.osgi.core/src/main/java/org/osgi/service/condpermadmin/ConditionalPermissionUpdate.java b/org.osgi.core/src/main/java/org/osgi/service/condpermadmin/ConditionalPermissionUpdate.java
deleted file mode 100644
index b116cf9..0000000
--- a/org.osgi.core/src/main/java/org/osgi/service/condpermadmin/ConditionalPermissionUpdate.java
+++ /dev/null
@@ -1,87 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2008, 2009). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.osgi.service.condpermadmin;
-
-import java.util.List;
-
-/**
- * Update the Conditional Permission Table. There may be many update objects in
- * the system at one time. If commit is called and the Conditional Permission
- * Table has been modified since this update was created, then the call to
- * commit will fail and this object should be discarded.
- *
- * @ThreadSafe
- * @version $Revision: 6492 $
- * @since 1.1
- */
-public interface ConditionalPermissionUpdate {
- /**
- * This method returns the list of {@link ConditionalPermissionInfo}s for
- * this update. This list is originally based on the Conditional Permission
- * Table at the time this update was created. The list returned by this
- * method will be replace the Conditional Permission Table if commit is
- * called and is successful.
- * <p>
- * The {@link ConditionalPermissionInfo#delete delete} method of the
- * ConditionalPermissionInfos in the list must throw
- * UnsupportedOperationException.
- * <p>
- * The list returned by this method is ordered and the most significant
- * table entry is the first entry in the list.
- *
- * @return A <code>List</code> of the {@link ConditionalPermissionInfo}s
- * which represent the Conditional Permissions maintained by this
- * update. Modifications to this list will not affect the
- * Conditional Permission Table until successfully committed. The
- * list may be empty if the Conditional Permission Table was empty
- * when this update was created.
- */
- List /* <ConditionalPermissionInfo> */getConditionalPermissionInfos();
-
- /**
- * Commit this update. If no changes have been made to the Conditional
- * Permission Table since this update was created, then this method will
- * replace the Conditional Permission Table with this update's Conditional
- * Permissions. This method may only be successfully called once on this
- * object.
- * <p>
- * If any of the {@link ConditionalPermissionInfo}s in the update list has
- * <code>null</code> as a name it will be replaced with a new
- * {@link ConditionalPermissionInfo} object that has a generated name which
- * is unique within the list.
- * <p>
- * No two entries in this update's Conditional Permissions may have the same
- * name. Other consistency checks may also be performed. If this update's
- * Conditional Permissions are determined to be inconsistent in some way
- * then an <code>IllegalStateException</code> will be thrown.
- * <p>
- * This method returns <code>false</code> if the commit did not occur
- * because the Conditional Permission Table has been modified since the
- * creation of this update.
- *
- * @return <code>true</code> if the commit was successful.
- * <code>false</code> if the commit did not occur because the
- * Conditional Permission Table has been modified since the creation
- * of this update.
- * @throws SecurityException If the caller does not have
- * <code>AllPermission</code>.
- * @throws IllegalStateException If this update's Conditional Permissions
- * are not valid or inconsistent. For example, this update has two
- * Conditional Permissions in it with the same name.
- */
- boolean commit();
-}
diff --git a/org.osgi.core/src/main/java/org/osgi/service/condpermadmin/package.html b/org.osgi.core/src/main/java/org/osgi/service/condpermadmin/package.html
deleted file mode 100644
index 7930813..0000000
--- a/org.osgi.core/src/main/java/org/osgi/service/condpermadmin/package.html
+++ /dev/null
@@ -1,10 +0,0 @@
-<!-- $Revision: 6204 $ -->
-<BODY>
-<p>Conditional Permission Admin Package Version 1.1.
-<p>Bundles wishing to use this package must list the package
-in the Import-Package header of the bundle's manifest.
-For example:
-<pre>
-Import-Package: org.osgi.service.condpermadmin; version="[1.1,2.0)"
-</pre>
-</BODY>
diff --git a/org.osgi.core/src/main/java/org/osgi/service/condpermadmin/packageinfo b/org.osgi.core/src/main/java/org/osgi/service/condpermadmin/packageinfo
deleted file mode 100644
index 3987f9c..0000000
--- a/org.osgi.core/src/main/java/org/osgi/service/condpermadmin/packageinfo
+++ /dev/null
@@ -1 +0,0 @@
-version 1.1
diff --git a/org.osgi.core/src/main/java/org/osgi/service/packageadmin/ExportedPackage.java b/org.osgi.core/src/main/java/org/osgi/service/packageadmin/ExportedPackage.java
deleted file mode 100644
index 67ba3e9..0000000
--- a/org.osgi.core/src/main/java/org/osgi/service/packageadmin/ExportedPackage.java
+++ /dev/null
@@ -1,110 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2001, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.osgi.service.packageadmin;
-
-import org.osgi.framework.Bundle;
-import org.osgi.framework.Version;
-
-/**
- * An exported package.
- *
- * Objects implementing this interface are created by the Package Admin service.
- *
- * <p>
- * The term <i>exported package</i> refers to a package that has been exported
- * from a resolved bundle. This package may or may not be currently wired to
- * other bundles.
- *
- * <p>
- * The information about an exported package provided by this object may change.
- * An <code>ExportedPackage</code> object becomes stale if the package it
- * references has been updated or removed as a result of calling
- * <code>PackageAdmin.refreshPackages()</code>.
- *
- * If this object becomes stale, its <code>getName()</code> and
- * <code>getVersion()</code> methods continue to return their original values,
- * <code>isRemovalPending()</code> returns <code>true</code>, and
- * <code>getExportingBundle()</code> and <code>getImportingBundles()</code>
- * return <code>null</code>.
- *
- * @ThreadSafe
- * @version $Revision: 5673 $
- */
-public interface ExportedPackage {
- /**
- * Returns the name of the package associated with this exported package.
- *
- * @return The name of this exported package.
- */
- public String getName();
-
- /**
- * Returns the bundle exporting the package associated with this exported
- * package.
- *
- * @return The exporting bundle, or <code>null</code> if this
- * <code>ExportedPackage</code> object has become stale.
- */
- public Bundle getExportingBundle();
-
- /**
- * Returns the resolved bundles that are currently wired to this exported
- * package.
- *
- * <p>
- * Bundles which require the exporting bundle associated with this exported
- * package are considered to be wired to this exported package are included
- * in the returned array. See {@link RequiredBundle#getRequiringBundles()}.
- *
- * @return The array of resolved bundles currently wired to this exported
- * package, or <code>null</code> if this
- * <code>ExportedPackage</code> object has become stale. The array
- * will be empty if no bundles are wired to this exported package.
- */
- public Bundle[] getImportingBundles();
-
- /**
- * Returns the version of this exported package.
- *
- * @return The version of this exported package, or <code>null</code> if
- * no version information is available.
- * @deprecated As of 1.2, replaced by {@link #getVersion}.
- */
- public String getSpecificationVersion();
-
- /**
- * Returns the version of this exported package.
- *
- * @return The version of this exported package, or
- * {@link Version#emptyVersion} if no version information is
- * available.
- * @since 1.2
- */
- public Version getVersion();
-
- /**
- * Returns <code>true</code> if the package associated with this
- * <code>ExportedPackage</code> object has been exported by a bundle that
- * has been updated or uninstalled.
- *
- * @return <code>true</code> if the associated package is being exported
- * by a bundle that has been updated or uninstalled, or if this
- * <code>ExportedPackage</code> object has become stale;
- * <code>false</code> otherwise.
- */
- public boolean isRemovalPending();
-}
diff --git a/org.osgi.core/src/main/java/org/osgi/service/packageadmin/PackageAdmin.java b/org.osgi.core/src/main/java/org/osgi/service/packageadmin/PackageAdmin.java
deleted file mode 100644
index c93cd28..0000000
--- a/org.osgi.core/src/main/java/org/osgi/service/packageadmin/PackageAdmin.java
+++ /dev/null
@@ -1,295 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2001, 2009). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.osgi.service.packageadmin;
-
-import org.osgi.framework.Bundle;
-
-/**
- * Framework service which allows bundle programmers to inspect the package
- * wiring state of bundles in the Framework as well as other functions related
- * to the class loader network among bundles.
- *
- * <p>
- * If present, there will only be a single instance of this service registered
- * with the Framework.
- *
- * @ThreadSafe
- * @version $Revision: 6779 $
- * @see org.osgi.service.packageadmin.ExportedPackage
- * @see org.osgi.service.packageadmin.RequiredBundle
- */
-public interface PackageAdmin {
- /**
- * Gets the exported packages for the specified bundle.
- *
- * @param bundle The bundle whose exported packages are to be returned, or
- * <code>null</code> if all exported packages are to be returned. If
- * the specified bundle is the system bundle (that is, the bundle
- * with id zero), this method returns all the packages known to be
- * exported by the system bundle. This will include the package
- * specified by the <code>org.osgi.framework.system.packages</code>
- * system property as well as any other package exported by the
- * framework implementation.
- *
- * @return An array of exported packages, or <code>null</code> if the
- * specified bundle has no exported packages.
- * @throws IllegalArgumentException If the specified <code>Bundle</code> was
- * not created by the same framework instance that registered this
- * <code>PackageAdmin</code> service.
- */
- public ExportedPackage[] getExportedPackages(Bundle bundle);
-
- /**
- * Gets the exported packages for the specified package name.
- *
- * @param name The name of the exported packages to be returned.
- *
- * @return An array of the exported packages, or <code>null</code> if no
- * exported packages with the specified name exists.
- * @since 1.2
- */
- public ExportedPackage[] getExportedPackages(String name);
-
- /**
- * Gets the exported package for the specified package name.
- *
- * <p>
- * If there are multiple exported packages with specified name, the exported
- * package with the highest version will be returned.
- *
- * @param name The name of the exported package to be returned.
- *
- * @return The exported package, or <code>null</code> if no exported
- * package with the specified name exists.
- * @see #getExportedPackages(String)
- */
- public ExportedPackage getExportedPackage(String name);
-
- /**
- * Forces the update (replacement) or removal of packages exported by the
- * specified bundles.
- *
- * <p>
- * If no bundles are specified, this method will update or remove any
- * packages exported by any bundles that were previously updated or
- * uninstalled since the last call to this method. The technique by which
- * this is accomplished may vary among different Framework implementations.
- * One permissible implementation is to stop and restart the Framework.
- *
- * <p>
- * This method returns to the caller immediately and then performs the
- * following steps on a separate thread:
- *
- * <ol>
- * <li>Compute a graph of bundles starting with the specified bundles. If no
- * bundles are specified, compute a graph of bundles starting with bundle
- * updated or uninstalled since the last call to this method. Add to the
- * graph any bundle that is wired to a package that is currently exported by
- * a bundle in the graph. The graph is fully constructed when there is no
- * bundle outside the graph that is wired to a bundle in the graph. The
- * graph may contain <code>UNINSTALLED</code> bundles that are currently
- * still exporting packages.
- *
- * <li>Each bundle in the graph that is in the <code>ACTIVE</code> state
- * will be stopped as described in the <code>Bundle.stop</code> method.
- *
- * <li>Each bundle in the graph that is in the <code>RESOLVED</code> state
- * is unresolved and thus moved to the <code>INSTALLED</code> state. The
- * effect of this step is that bundles in the graph are no longer
- * <code>RESOLVED</code>.
- *
- * <li>Each bundle in the graph that is in the <code>UNINSTALLED</code>
- * state is removed from the graph and is now completely removed from the
- * Framework.
- *
- * <li>Each bundle in the graph that was in the <code>ACTIVE</code> state
- * prior to Step 2 is started as described in the <code>Bundle.start</code>
- * method, causing all bundles required for the restart to be resolved. It
- * is possible that, as a result of the previous steps, packages that were
- * previously exported no longer are. Therefore, some bundles may be
- * unresolvable until another bundle offering a compatible package for
- * export has been installed in the Framework.
- * <li>A framework event of type
- * <code>FrameworkEvent.PACKAGES_REFRESHED</code> is fired.
- * </ol>
- *
- * <p>
- * For any exceptions that are thrown during any of these steps, a
- * <code>FrameworkEvent</code> of type <code>ERROR</code> is fired
- * containing the exception. The source bundle for these events should be
- * the specific bundle to which the exception is related. If no specific
- * bundle can be associated with the exception then the System Bundle must
- * be used as the source bundle for the event.
- *
- * @param bundles The bundles whose exported packages are to be updated or
- * removed, or <code>null</code> for all bundles updated or
- * uninstalled since the last call to this method.
- * @throws SecurityException If the caller does not have
- * <code>AdminPermission[System Bundle,RESOLVE]</code> and the Java
- * runtime environment supports permissions.
- * @throws IllegalArgumentException If the specified <code>Bundle</code>s
- * were not created by the same framework instance that registered
- * this <code>PackageAdmin</code> service.
- */
- public void refreshPackages(Bundle[] bundles);
-
- /**
- * Resolve the specified bundles. The Framework must attempt to resolve the
- * specified bundles that are unresolved. Additional bundles that are not
- * included in the specified bundles may be resolved as a result of calling
- * this method. A permissible implementation of this method is to attempt to
- * resolve all unresolved bundles installed in the framework.
- *
- * <p>
- * If <code>null</code> is specified then the Framework will attempt to
- * resolve all unresolved bundles. This method must not cause any bundle to
- * be refreshed, stopped, or started. This method will not return until the
- * operation has completed.
- *
- * @param bundles The bundles to resolve or <code>null</code> to resolve all
- * unresolved bundles installed in the Framework.
- * @return <code>true</code> if all specified bundles are resolved;
- * @throws SecurityException If the caller does not have
- * <code>AdminPermission[System Bundle,RESOLVE]</code> and the Java
- * runtime environment supports permissions.
- * @throws IllegalArgumentException If the specified <code>Bundle</code>s
- * were not created by the same framework instance that registered
- * this <code>PackageAdmin</code> service.
- * @since 1.2
- */
- public boolean resolveBundles(Bundle[] bundles);
-
- /**
- * Returns an array of required bundles having the specified symbolic name.
- *
- * <p>
- * If <code>null</code> is specified, then all required bundles will be
- * returned.
- *
- * @param symbolicName The bundle symbolic name or <code>null</code> for
- * all required bundles.
- * @return An array of required bundles or <code>null</code> if no
- * required bundles exist for the specified symbolic name.
- * @since 1.2
- */
- public RequiredBundle[] getRequiredBundles(String symbolicName);
-
- /**
- * Returns the bundles with the specified symbolic name whose bundle version
- * is within the specified version range. If no bundles are installed that
- * have the specified symbolic name, then <code>null</code> is returned.
- * If a version range is specified, then only the bundles that have the
- * specified symbolic name and whose bundle versions belong to the specified
- * version range are returned. The returned bundles are ordered by version
- * in descending version order so that the first element of the array
- * contains the bundle with the highest version.
- *
- * @see org.osgi.framework.Constants#BUNDLE_VERSION_ATTRIBUTE
- * @param symbolicName The symbolic name of the desired bundles.
- * @param versionRange The version range of the desired bundles, or
- * <code>null</code> if all versions are desired.
- * @return An array of bundles with the specified name belonging to the
- * specified version range ordered in descending version order, or
- * <code>null</code> if no bundles are found.
- * @since 1.2
- */
- public Bundle[] getBundles(String symbolicName, String versionRange);
-
- /**
- * Returns an array of attached fragment bundles for the specified bundle.
- * If the specified bundle is a fragment then <code>null</code> is returned.
- * If no fragments are attached to the specified bundle then
- * <code>null</code> is returned.
- * <p>
- * This method does not attempt to resolve the specified bundle. If the
- * specified bundle is not resolved then <code>null</code> is returned.
- *
- * @param bundle The bundle whose attached fragment bundles are to be
- * returned.
- * @return An array of fragment bundles or <code>null</code> if the bundle
- * does not have any attached fragment bundles or the bundle is not
- * resolved.
- * @throws IllegalArgumentException If the specified <code>Bundle</code> was
- * not created by the same framework instance that registered this
- * <code>PackageAdmin</code> service.
- * @since 1.2
- */
- public Bundle[] getFragments(Bundle bundle);
-
- /**
- * Returns the host bundles to which the specified fragment bundle is
- * attached.
- *
- * @param bundle The fragment bundle whose host bundles are to be returned.
- * @return An array containing the host bundles to which the specified
- * fragment is attached or <code>null</code> if the specified bundle
- * is not a fragment or is not attached to any host bundles.
- * @throws IllegalArgumentException If the specified <code>Bundle</code> was
- * not created by the same framework instance that registered this
- * <code>PackageAdmin</code> service.
- * @since 1.2
- */
- public Bundle[] getHosts(Bundle bundle);
-
- /**
- * Returns the bundle from which the specified class is loaded. The class
- * loader of the returned bundle must have been used to load the specified
- * class. If the class was not loaded by a bundle class loader then
- * <code>null</code> is returned.
- *
- * @param clazz The class object from which to locate the bundle.
- * @return The bundle from which the specified class is loaded or
- * <code>null</code> if the class was not loaded by a bundle class
- * loader created by the same framework instance that registered
- * this <code>PackageAdmin</code> service.
- * @since 1.2
- */
- public Bundle getBundle(Class clazz);
-
- /**
- * Bundle type indicating the bundle is a fragment bundle.
- *
- * <p>
- * The value of <code>BUNDLE_TYPE_FRAGMENT</code> is 0x00000001.
- *
- * @since 1.2
- */
- public static final int BUNDLE_TYPE_FRAGMENT = 0x00000001;
-
- /**
- * Returns the special type of the specified bundle. The bundle type values
- * are:
- * <ul>
- * <li>{@link #BUNDLE_TYPE_FRAGMENT}
- * </ul>
- *
- * A bundle may be more than one type at a time. A type code is used to
- * identify the bundle type for future extendability.
- *
- * <p>
- * If a bundle is not one or more of the defined types then 0x00000000 is
- * returned.
- *
- * @param bundle The bundle for which to return the special type.
- * @return The special type of the bundle.
- * @throws IllegalArgumentException If the specified <code>Bundle</code> was
- * not created by the same framework instance that registered this
- * <code>PackageAdmin</code> service.
- * @since 1.2
- */
- public int getBundleType(Bundle bundle);
-}
diff --git a/org.osgi.core/src/main/java/org/osgi/service/packageadmin/RequiredBundle.java b/org.osgi.core/src/main/java/org/osgi/service/packageadmin/RequiredBundle.java
deleted file mode 100644
index b15c5df..0000000
--- a/org.osgi.core/src/main/java/org/osgi/service/packageadmin/RequiredBundle.java
+++ /dev/null
@@ -1,97 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2004, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.osgi.service.packageadmin;
-
-import org.osgi.framework.Bundle;
-import org.osgi.framework.Version;
-
-/**
- * A required bundle.
- *
- * Objects implementing this interface are created by the Package Admin service.
- *
- * <p>
- * The term <i>required bundle</i> refers to a resolved bundle that has a
- * bundle symbolic name and is not a fragment. That is, a bundle that may be
- * required by other bundles. This bundle may or may not be currently required
- * by other bundles.
- *
- * <p>
- * The information about a required bundle provided by this object may change. A
- * <code>RequiredBundle</code> object becomes stale if an exported package of
- * the bundle it references has been updated or removed as a result of calling
- * <code>PackageAdmin.refreshPackages()</code>).
- *
- * If this object becomes stale, its <code>getSymbolicName()</code> and
- * <code>getVersion()</code> methods continue to return their original values,
- * <code>isRemovalPending()</code> returns true, and <code>getBundle()</code>
- * and <code>getRequiringBundles()</code> return <code>null</code>.
- *
- * @since 1.2
- * @ThreadSafe
- * @version $Revision: 5673 $
- */
-public interface RequiredBundle {
- /**
- * Returns the symbolic name of this required bundle.
- *
- * @return The symbolic name of this required bundle.
- */
- public String getSymbolicName();
-
- /**
- * Returns the bundle associated with this required bundle.
- *
- * @return The bundle, or <code>null</code> if this
- * <code>RequiredBundle</code> object has become stale.
- */
- public Bundle getBundle();
-
- /**
- * Returns the bundles that currently require this required bundle.
- *
- * <p>
- * If this required bundle is required and then re-exported by another
- * bundle then all the requiring bundles of the re-exporting bundle are
- * included in the returned array.
- *
- * @return An array of bundles currently requiring this required bundle, or
- * <code>null</code> if this <code>RequiredBundle</code> object
- * has become stale. The array will be empty if no bundles require
- * this required package.
- */
- public Bundle[] getRequiringBundles();
-
- /**
- * Returns the version of this required bundle.
- *
- * @return The version of this required bundle, or
- * {@link Version#emptyVersion} if no version information is
- * available.
- */
- public Version getVersion();
-
- /**
- * Returns <code>true</code> if the bundle associated with this
- * <code>RequiredBundle</code> object has been updated or uninstalled.
- *
- * @return <code>true</code> if the required bundle has been updated or
- * uninstalled, or if the <code>RequiredBundle</code> object has
- * become stale; <code>false</code> otherwise.
- */
- public boolean isRemovalPending();
-}
diff --git a/org.osgi.core/src/main/java/org/osgi/service/packageadmin/package.html b/org.osgi.core/src/main/java/org/osgi/service/packageadmin/package.html
deleted file mode 100644
index 9fc9cab..0000000
--- a/org.osgi.core/src/main/java/org/osgi/service/packageadmin/package.html
+++ /dev/null
@@ -1,11 +0,0 @@
-<!-- $Revision: 6204 $ -->
-<BODY>
-<p>Package Admin Package Version 1.2.
-<p>Bundles wishing to use this package must list the package
-in the Import-Package header of the bundle's manifest.
-For example:
-<pre>
-Import-Package: org.osgi.service.packageadmin; version="[1.2,2.0)"
-</pre>
-</BODY>
-
diff --git a/org.osgi.core/src/main/java/org/osgi/service/packageadmin/packageinfo b/org.osgi.core/src/main/java/org/osgi/service/packageadmin/packageinfo
deleted file mode 100644
index ef7df68..0000000
--- a/org.osgi.core/src/main/java/org/osgi/service/packageadmin/packageinfo
+++ /dev/null
@@ -1 +0,0 @@
-version 1.2
diff --git a/org.osgi.core/src/main/java/org/osgi/service/permissionadmin/PermissionAdmin.java b/org.osgi.core/src/main/java/org/osgi/service/permissionadmin/PermissionAdmin.java
deleted file mode 100644
index d51a9d4..0000000
--- a/org.osgi.core/src/main/java/org/osgi/service/permissionadmin/PermissionAdmin.java
+++ /dev/null
@@ -1,122 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2001, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.osgi.service.permissionadmin;
-
-/**
- * The Permission Admin service allows management agents to manage the
- * permissions of bundles. There is at most one Permission Admin service present
- * in the OSGi environment.
- * <p>
- * Access to the Permission Admin service is protected by corresponding
- * <code>ServicePermission</code>. In addition <code>AdminPermission</code>
- * is required to actually set permissions.
- *
- * <p>
- * Bundle permissions are managed using a permission table. A bundle's location
- * serves as the key into this permission table. The value of a table entry is
- * the set of permissions (of type <code>PermissionInfo</code>) granted to
- * the bundle named by the given location. A bundle may have an entry in the
- * permission table prior to being installed in the Framework.
- *
- * <p>
- * The permissions specified in <code>setDefaultPermissions</code> are used as
- * the default permissions which are granted to all bundles that do not have an
- * entry in the permission table.
- *
- * <p>
- * Any changes to a bundle's permissions in the permission table will take
- * effect no later than when bundle's
- * <code>java.security.ProtectionDomain</code> is next involved in a
- * permission check, and will be made persistent.
- *
- * <p>
- * Only permission classes on the system classpath or from an exported package
- * are considered during a permission check. Additionally, only permission
- * classes that are subclasses of <code>java.security.Permission</code> and
- * define a 2-argument constructor that takes a <i>name </i> string and an
- * <i>actions </i> string can be used.
- * <p>
- * Permissions implicitly granted by the Framework (for example, a bundle's
- * permission to access its persistent storage area) cannot be changed, and are
- * not reflected in the permissions returned by <code>getPermissions</code>
- * and <code>getDefaultPermissions</code>.
- *
- * @ThreadSafe
- * @version $Revision: 5673 $
- */
-public interface PermissionAdmin {
- /**
- * Gets the permissions assigned to the bundle with the specified location.
- *
- * @param location The location of the bundle whose permissions are to be
- * returned.
- *
- * @return The permissions assigned to the bundle with the specified
- * location, or <code>null</code> if that bundle has not been
- * assigned any permissions.
- */
- PermissionInfo[] getPermissions(String location);
-
- /**
- * Assigns the specified permissions to the bundle with the specified
- * location.
- *
- * @param location The location of the bundle that will be assigned the
- * permissions.
- * @param permissions The permissions to be assigned, or <code>null</code>
- * if the specified location is to be removed from the permission
- * table.
- * @throws SecurityException If the caller does not have
- * <code>AllPermission</code>.
- */
- void setPermissions(String location, PermissionInfo[] permissions);
-
- /**
- * Returns the bundle locations that have permissions assigned to them, that
- * is, bundle locations for which an entry exists in the permission table.
- *
- * @return The locations of bundles that have been assigned any permissions,
- * or <code>null</code> if the permission table is empty.
- */
- String[] getLocations();
-
- /**
- * Gets the default permissions.
- *
- * <p>
- * These are the permissions granted to any bundle that does not have
- * permissions assigned to its location.
- *
- * @return The default permissions, or <code>null</code> if no default
- * permissions are set.
- */
- PermissionInfo[] getDefaultPermissions();
-
- /**
- * Sets the default permissions.
- *
- * <p>
- * These are the permissions granted to any bundle that does not have
- * permissions assigned to its location.
- *
- * @param permissions The default permissions, or <code>null</code> if the
- * default permissions are to be removed from the permission table.
- * @throws SecurityException If the caller does not have
- * <code>AllPermission</code>.
- */
- void setDefaultPermissions(PermissionInfo[] permissions);
-}
diff --git a/org.osgi.core/src/main/java/org/osgi/service/permissionadmin/PermissionInfo.java b/org.osgi.core/src/main/java/org/osgi/service/permissionadmin/PermissionInfo.java
deleted file mode 100644
index e4bfae7..0000000
--- a/org.osgi.core/src/main/java/org/osgi/service/permissionadmin/PermissionInfo.java
+++ /dev/null
@@ -1,417 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2001, 2009). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.osgi.service.permissionadmin;
-
-/**
- * Permission representation used by the Permission Admin service.
- *
- * <p>
- * This class encapsulates three pieces of information: a Permission <i>type
- * </i> (class name), which must be a subclass of
- * <code>java.security.Permission</code>, and the <i>name</i> and <i>actions</i>
- * arguments passed to its constructor.
- *
- * <p>
- * In order for a permission represented by a <code>PermissionInfo</code> to be
- * instantiated and considered during a permission check, its Permission class
- * must be available from the system classpath or an exported package. This
- * means that the instantiation of a permission represented by a
- * <code>PermissionInfo</code> may be delayed until the package containing its
- * Permission class has been exported by a bundle.
- *
- * @Immutable
- * @version $Revision: 6492 $
- */
-public class PermissionInfo {
- private final String type;
- private final String name;
- private final String actions;
-
- /**
- * Constructs a <code>PermissionInfo</code> from the specified type, name,
- * and actions.
- *
- * @param type The fully qualified class name of the permission represented
- * by this <code>PermissionInfo</code>. The class must be a subclass
- * of <code>java.security.Permission</code> and must define a
- * 2-argument constructor that takes a <i>name</i> string and an
- * <i>actions</i> string.
- *
- * @param name The permission name that will be passed as the first argument
- * to the constructor of the <code>Permission</code> class identified
- * by <code>type</code>.
- *
- * @param actions The permission actions that will be passed as the second
- * argument to the constructor of the <code>Permission</code> class
- * identified by <code>type</code>.
- *
- * @throws NullPointerException If <code>type</code> is <code>null</code>.
- * @throws IllegalArgumentException If <code>action</code> is not
- * <code>null</code> and <code>name</code> is <code>null</code>.
- */
- public PermissionInfo(String type, String name, String actions) {
- this.type = type;
- this.name = name;
- this.actions = actions;
- if (type == null) {
- throw new NullPointerException("type is null");
- }
- if ((name == null) && (actions != null)) {
- throw new IllegalArgumentException("name missing");
- }
- }
-
- /**
- * Constructs a <code>PermissionInfo</code> object from the specified
- * encoded <code>PermissionInfo</code> string. White space in the encoded
- * <code>PermissionInfo</code> string is ignored.
- *
- *
- * @param encodedPermission The encoded <code>PermissionInfo</code>.
- * @see #getEncoded
- * @throws IllegalArgumentException If the specified
- * <code>encodedPermission</code> is not properly formatted.
- */
- public PermissionInfo(String encodedPermission) {
- if (encodedPermission == null) {
- throw new NullPointerException("missing encoded permission");
- }
- if (encodedPermission.length() == 0) {
- throw new IllegalArgumentException("empty encoded permission");
- }
- String parsedType = null;
- String parsedName = null;
- String parsedActions = null;
- try {
- char[] encoded = encodedPermission.toCharArray();
- int length = encoded.length;
- int pos = 0;
-
- /* skip whitespace */
- while (Character.isWhitespace(encoded[pos])) {
- pos++;
- }
-
- /* the first character must be '(' */
- if (encoded[pos] != '(') {
- throw new IllegalArgumentException("expecting open parenthesis");
- }
- pos++;
-
- /* skip whitespace */
- while (Character.isWhitespace(encoded[pos])) {
- pos++;
- }
-
- /* type is not quoted or encoded */
- int begin = pos;
- while (!Character.isWhitespace(encoded[pos])
- && (encoded[pos] != ')')) {
- pos++;
- }
- if (pos == begin || encoded[begin] == '"') {
- throw new IllegalArgumentException("expecting type");
- }
- parsedType = new String(encoded, begin, pos - begin);
-
- /* skip whitespace */
- while (Character.isWhitespace(encoded[pos])) {
- pos++;
- }
-
- /* type may be followed by name which is quoted and encoded */
- if (encoded[pos] == '"') {
- pos++;
- begin = pos;
- while (encoded[pos] != '"') {
- if (encoded[pos] == '\\') {
- pos++;
- }
- pos++;
- }
- parsedName = unescapeString(encoded, begin, pos);
- pos++;
-
- if (Character.isWhitespace(encoded[pos])) {
- /* skip whitespace */
- while (Character.isWhitespace(encoded[pos])) {
- pos++;
- }
-
- /*
- * name may be followed by actions which is quoted and
- * encoded
- */
- if (encoded[pos] == '"') {
- pos++;
- begin = pos;
- while (encoded[pos] != '"') {
- if (encoded[pos] == '\\') {
- pos++;
- }
- pos++;
- }
- parsedActions = unescapeString(encoded, begin, pos);
- pos++;
-
- /* skip whitespace */
- while (Character.isWhitespace(encoded[pos])) {
- pos++;
- }
- }
- }
- }
-
- /* the final character must be ')' */
- char c = encoded[pos];
- pos++;
- while ((pos < length) && Character.isWhitespace(encoded[pos])) {
- pos++;
- }
- if ((c != ')') || (pos != length)) {
- throw new IllegalArgumentException(
- "expecting close parenthesis");
- }
- }
- catch (ArrayIndexOutOfBoundsException e) {
- throw new IllegalArgumentException("parsing terminated abruptly");
- }
-
- type = parsedType;
- name = parsedName;
- actions = parsedActions;
- }
-
- /**
- * Returns the string encoding of this <code>PermissionInfo</code> in a form
- * suitable for restoring this <code>PermissionInfo</code>.
- *
- * <p>
- * The encoded format is:
- *
- * <pre>
- * (type)
- * </pre>
- *
- * or
- *
- * <pre>
- * (type "name")
- * </pre>
- *
- * or
- *
- * <pre>
- * (type "name" "actions")
- * </pre>
- *
- * where <i>name</i> and <i>actions</i> are strings that must be encoded for
- * proper parsing. Specifically, the <code>"</code>,<code>\</code>,
- * carriage return, and line feed characters must be escaped using
- * <code>\"</code>, <code>\\</code>,<code>\r</code>, and
- * <code>\n</code>, respectively.
- *
- * <p>
- * The encoded string contains no leading or trailing whitespace characters.
- * A single space character is used between <i>type</i> and
- * "<i>name</i>" and between "<i>name</i>" and
- * "<i>actions</i>".
- *
- * @return The string encoding of this <code>PermissionInfo</code>.
- */
- public final String getEncoded() {
- StringBuffer output = new StringBuffer(
- 8
- + type.length()
- + ((((name == null) ? 0 : name.length()) + ((actions == null) ? 0
- : actions.length())) << 1));
- output.append('(');
- output.append(type);
- if (name != null) {
- output.append(" \"");
- escapeString(name, output);
- if (actions != null) {
- output.append("\" \"");
- escapeString(actions, output);
- }
- output.append('\"');
- }
- output.append(')');
- return output.toString();
- }
-
- /**
- * Returns the string representation of this <code>PermissionInfo</code>.
- * The string is created by calling the <code>getEncoded</code> method on
- * this <code>PermissionInfo</code>.
- *
- * @return The string representation of this <code>PermissionInfo</code>.
- */
- public String toString() {
- return getEncoded();
- }
-
- /**
- * Returns the fully qualified class name of the permission represented by
- * this <code>PermissionInfo</code>.
- *
- * @return The fully qualified class name of the permission represented by
- * this <code>PermissionInfo</code>.
- */
- public final String getType() {
- return type;
- }
-
- /**
- * Returns the name of the permission represented by this
- * <code>PermissionInfo</code>.
- *
- * @return The name of the permission represented by this
- * <code>PermissionInfo</code>, or <code>null</code> if the
- * permission does not have a name.
- */
- public final String getName() {
- return name;
- }
-
- /**
- * Returns the actions of the permission represented by this
- * <code>PermissionInfo</code>.
- *
- * @return The actions of the permission represented by this
- * <code>PermissionInfo</code>, or <code>null</code> if the
- * permission does not have any actions associated with it.
- */
- public final String getActions() {
- return actions;
- }
-
- /**
- * Determines the equality of two <code>PermissionInfo</code> objects.
- *
- * This method checks that specified object has the same type, name and
- * actions as this <code>PermissionInfo</code> object.
- *
- * @param obj The object to test for equality with this
- * <code>PermissionInfo</code> object.
- * @return <code>true</code> if <code>obj</code> is a
- * <code>PermissionInfo</code>, and has the same type, name and
- * actions as this <code>PermissionInfo</code> object;
- * <code>false</code> otherwise.
- */
- public boolean equals(Object obj) {
- if (obj == this) {
- return true;
- }
- if (!(obj instanceof PermissionInfo)) {
- return false;
- }
- PermissionInfo other = (PermissionInfo) obj;
- if (!type.equals(other.type) || ((name == null) ^ (other.name == null))
- || ((actions == null) ^ (other.actions == null))) {
- return false;
- }
- if (name != null) {
- if (actions != null) {
- return name.equals(other.name) && actions.equals(other.actions);
- }
- else {
- return name.equals(other.name);
- }
- }
- else {
- return true;
- }
- }
-
- /**
- * Returns the hash code value for this object.
- *
- * @return A hash code value for this object.
- */
- public int hashCode() {
- int h = 31 * 17 + type.hashCode();
- if (name != null) {
- h = 31 * h + name.hashCode();
- if (actions != null) {
- h = 31 * h + actions.hashCode();
- }
- }
- return h;
- }
-
- /**
- * This escapes the quotes, backslashes, \n, and \r in the string using a
- * backslash and appends the newly escaped string to a StringBuffer.
- */
- private static void escapeString(String str, StringBuffer output) {
- int len = str.length();
- for (int i = 0; i < len; i++) {
- char c = str.charAt(i);
- switch (c) {
- case '"' :
- case '\\' :
- output.append('\\');
- output.append(c);
- break;
- case '\r' :
- output.append("\\r");
- break;
- case '\n' :
- output.append("\\n");
- break;
- default :
- output.append(c);
- break;
- }
- }
- }
-
- /**
- * Takes an encoded character array and decodes it into a new String.
- */
- private static String unescapeString(char[] str, int begin, int end) {
- StringBuffer output = new StringBuffer(end - begin);
- for (int i = begin; i < end; i++) {
- char c = str[i];
- if (c == '\\') {
- i++;
- if (i < end) {
- c = str[i];
- switch (c) {
- case '"' :
- case '\\' :
- break;
- case 'r' :
- c = '\r';
- break;
- case 'n' :
- c = '\n';
- break;
- default :
- c = '\\';
- i--;
- break;
- }
- }
- }
- output.append(c);
- }
-
- return output.toString();
- }
-}
diff --git a/org.osgi.core/src/main/java/org/osgi/service/permissionadmin/package.html b/org.osgi.core/src/main/java/org/osgi/service/permissionadmin/package.html
deleted file mode 100644
index 396264c..0000000
--- a/org.osgi.core/src/main/java/org/osgi/service/permissionadmin/package.html
+++ /dev/null
@@ -1,11 +0,0 @@
-<!-- $Revision: 6204 $ -->
-<BODY>
-<p>Permission Admin Package Version 1.2.
-<p>Bundles wishing to use this package must list the package
-in the Import-Package header of the bundle's manifest.
-For example:
-<pre>
-Import-Package: org.osgi.service.permissionadmin; version="[1.2,2.0)"
-</pre>
-</BODY>
-
diff --git a/org.osgi.core/src/main/java/org/osgi/service/permissionadmin/packageinfo b/org.osgi.core/src/main/java/org/osgi/service/permissionadmin/packageinfo
deleted file mode 100644
index ef7df68..0000000
--- a/org.osgi.core/src/main/java/org/osgi/service/permissionadmin/packageinfo
+++ /dev/null
@@ -1 +0,0 @@
-version 1.2
diff --git a/org.osgi.core/src/main/java/org/osgi/service/startlevel/StartLevel.java b/org.osgi.core/src/main/java/org/osgi/service/startlevel/StartLevel.java
deleted file mode 100644
index 8a69b03..0000000
--- a/org.osgi.core/src/main/java/org/osgi/service/startlevel/StartLevel.java
+++ /dev/null
@@ -1,273 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2002, 2009). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.osgi.service.startlevel;
-
-import org.osgi.framework.Bundle;
-
-/**
- * The StartLevel service allows management agents to manage a start level
- * assigned to each bundle and the active start level of the Framework. There is
- * at most one StartLevel service present in the OSGi environment.
- *
- * <p>
- * A start level is defined to be a state of execution in which the Framework
- * exists. StartLevel values are defined as unsigned integers with 0 (zero)
- * being the state where the Framework is not launched. Progressively higher
- * integral values represent progressively higher start levels. e.g. 2 is a
- * higher start level than 1.
- * <p>
- * Access to the StartLevel service is protected by corresponding
- * <code>ServicePermission</code>. In addition <code>AdminPermission</code>
- * is required to actually modify start level information.
- * <p>
- * Start Level support in the Framework includes the ability to control the
- * beginning start level of the Framework, to modify the active start level of
- * the Framework and to assign a specific start level to a bundle. How the
- * beginning start level of a Framework is specified is implementation
- * dependent. It may be a command line argument when invoking the Framework
- * implementation.
- * <p>
- * When the Framework is first started it must be at start level zero. In this
- * state, no bundles are running. This is the initial state of the Framework
- * before it is launched.
- *
- * When the Framework is launched, the Framework will enter start level one and
- * all bundles which are assigned to start level one and whose autostart setting
- * indicates the bundle should be started are started as described in the
- * <code>Bundle.start</code> method. The Framework will continue to increase
- * the start level, starting bundles at each start level, until the Framework
- * has reached a beginning start level. At this point the Framework has
- * completed starting bundles and will then fire a Framework event of type
- * <code>FrameworkEvent.STARTED</code> to announce it has completed its
- * launch.
- *
- * <p>
- * Within a start level, bundles may be started in an order defined by the
- * Framework implementation. This may be something like ascending
- * <code>Bundle.getBundleId</code> order or an order based upon dependencies
- * between bundles. A similar but reversed order may be used when stopping
- * bundles within a start level.
- *
- * <p>
- * The StartLevel service can be used by management bundles to alter the active
- * start level of the framework.
- *
- * @ThreadSafe
- * @version $Revision: 6747 $
- */
-public interface StartLevel {
- /**
- * Return the active start level value of the Framework.
- *
- * If the Framework is in the process of changing the start level this
- * method must return the active start level if this differs from the
- * requested start level.
- *
- * @return The active start level value of the Framework.
- */
- public int getStartLevel();
-
- /**
- * Modify the active start level of the Framework.
- *
- * <p>
- * The Framework will move to the requested start level. This method will
- * return immediately to the caller and the start level change will occur
- * asynchronously on another thread.
- *
- * <p>
- * If the specified start level is higher than the active start level, the
- * Framework will continue to increase the start level until the Framework
- * has reached the specified start level.
- *
- * At each intermediate start level value on the way to and including the
- * target start level, the Framework must:
- * <ol>
- * <li>Change the active start level to the intermediate start level value.
- * <li>Start bundles at the intermediate start level whose autostart
- * setting indicate they must be started. They are started as described in
- * the {@link Bundle#start(int)} method using the
- * {@link Bundle#START_TRANSIENT} option. The
- * {@link Bundle#START_ACTIVATION_POLICY} option must also be used if
- * {@link #isBundleActivationPolicyUsed(Bundle)} returns <code>true</code>
- * for the bundle.
- * </ol>
- * When this process completes after the specified start level is reached,
- * the Framework will fire a Framework event of type
- * <code>FrameworkEvent.STARTLEVEL_CHANGED</code> to announce it has moved
- * to the specified start level.
- *
- * <p>
- * If the specified start level is lower than the active start level, the
- * Framework will continue to decrease the start level until the Framework
- * has reached the specified start level.
- *
- * At each intermediate start level value on the way to and including the
- * specified start level, the framework must:
- * <ol>
- * <li>Stop bundles at the intermediate start level as described in the
- * {@link Bundle#stop(int)} method using the {@link Bundle#STOP_TRANSIENT}
- * option.
- * <li>Change the active start level to the intermediate start level value.
- * </ol>
- * When this process completes after the specified start level is reached,
- * the Framework will fire a Framework event of type
- * <code>FrameworkEvent.STARTLEVEL_CHANGED</code> to announce it has moved
- * to the specified start level.
- *
- * <p>
- * If the specified start level is equal to the active start level, then no
- * bundles are started or stopped, however, the Framework must fire a
- * Framework event of type <code>FrameworkEvent.STARTLEVEL_CHANGED</code>
- * to announce it has finished moving to the specified start level. This
- * event may arrive before this method return.
- *
- * @param startlevel The requested start level for the Framework.
- * @throws IllegalArgumentException If the specified start level is less
- * than or equal to zero.
- * @throws SecurityException If the caller does not have
- * <code>AdminPermission[System Bundle,STARTLEVEL]</code> and the
- * Java runtime environment supports permissions.
- */
- public void setStartLevel(int startlevel);
-
- /**
- * Return the assigned start level value for the specified Bundle.
- *
- * @param bundle The target bundle.
- * @return The start level value of the specified Bundle.
- * @throws java.lang.IllegalArgumentException If the specified bundle has
- * been uninstalled or if the specified bundle was not created by
- * the same framework instance that registered this
- * <code>StartLevel</code> service.
- */
- public int getBundleStartLevel(Bundle bundle);
-
- /**
- * Assign a start level value to the specified Bundle.
- *
- * <p>
- * The specified bundle will be assigned the specified start level. The
- * start level value assigned to the bundle will be persistently recorded by
- * the Framework.
- * <p>
- * If the new start level for the bundle is lower than or equal to the
- * active start level of the Framework and the bundle's autostart setting
- * indicates the bundle must be started, the Framework will start the
- * specified bundle as described in the {@link Bundle#start(int)} method
- * using the {@link Bundle#START_TRANSIENT} option. The
- * {@link Bundle#START_ACTIVATION_POLICY} option must also be used if
- * {@link #isBundleActivationPolicyUsed(Bundle)} returns <code>true</code>
- * for the bundle. The actual starting of this bundle must occur
- * asynchronously.
- * <p>
- * If the new start level for the bundle is higher than the active start
- * level of the Framework, the Framework will stop the specified bundle as
- * described in the {@link Bundle#stop(int)} method using the
- * {@link Bundle#STOP_TRANSIENT} option. The actual stopping of this bundle
- * must occur asynchronously.
- *
- * @param bundle The target bundle.
- * @param startlevel The new start level for the specified Bundle.
- * @throws IllegalArgumentException If the specified bundle has been
- * uninstalled, or if the specified start level is less than or
- * equal to zero, or if the specified bundle is the system bundle,
- * or if the specified bundle was not created by the same framework
- * instance that registered this <code>StartLevel</code> service.
- * @throws SecurityException If the caller does not have
- * <code>AdminPermission[bundle,EXECUTE]</code> and the Java runtime
- * environment supports permissions.
- */
- public void setBundleStartLevel(Bundle bundle, int startlevel);
-
- /**
- * Return the initial start level value that is assigned to a Bundle when it
- * is first installed.
- *
- * @return The initial start level value for Bundles.
- * @see #setInitialBundleStartLevel
- */
- public int getInitialBundleStartLevel();
-
- /**
- * Set the initial start level value that is assigned to a Bundle when it is
- * first installed.
- *
- * <p>
- * The initial bundle start level will be set to the specified start level.
- * The initial bundle start level value will be persistently recorded by the
- * Framework.
- *
- * <p>
- * When a Bundle is installed via <code>BundleContext.installBundle</code>,
- * it is assigned the initial bundle start level value.
- *
- * <p>
- * The default initial bundle start level value is 1 unless this method has
- * been called to assign a different initial bundle start level value.
- *
- * <p>
- * This method does not change the start level values of installed bundles.
- *
- * @param startlevel The initial start level for newly installed bundles.
- * @throws IllegalArgumentException If the specified start level is less
- * than or equal to zero.
- * @throws SecurityException If the caller does not have
- * <code>AdminPermission[System Bundle,STARTLEVEL]</code> and the
- * Java runtime environment supports permissions.
- */
- public void setInitialBundleStartLevel(int startlevel);
-
- /**
- * Returns whether the specified bundle's autostart setting indicates the
- * bundle must be started.
- * <p>
- * The autostart setting of a bundle indicates whether the bundle is to be
- * started when its start level is reached.
- *
- * @param bundle The bundle whose autostart setting is to be examined.
- * @return <code>true</code> if the autostart setting of the bundle
- * indicates the bundle is to be started. <code>false</code>
- * otherwise.
- * @throws java.lang.IllegalArgumentException If the specified bundle has
- * been uninstalled or if the specified bundle was not created by
- * the same framework instance that registered this
- * <code>StartLevel</code> service.
- * @see Bundle#START_TRANSIENT
- */
- public boolean isBundlePersistentlyStarted(Bundle bundle);
-
- /**
- * Returns whether the specified bundle's autostart setting indicates that
- * the activation policy declared in the bundle's manifest must be used.
- * <p>
- * The autostart setting of a bundle indicates whether the bundle's declared
- * activation policy is to be used when the bundle is started.
- *
- * @param bundle The bundle whose autostart setting is to be examined.
- * @return <code>true</code> if the bundle's autostart setting indicates the
- * activation policy declared in the manifest must be used.
- * <code>false</code> if the bundle must be eagerly activated.
- * @throws java.lang.IllegalArgumentException If the specified bundle has
- * been uninstalled or if the specified bundle was not created by
- * the same framework instance that registered this
- * <code>StartLevel</code> service.
- * @since 1.1
- * @see Bundle#START_ACTIVATION_POLICY
- */
- public boolean isBundleActivationPolicyUsed(Bundle bundle);
-}
diff --git a/org.osgi.core/src/main/java/org/osgi/service/startlevel/package.html b/org.osgi.core/src/main/java/org/osgi/service/startlevel/package.html
deleted file mode 100644
index 4c27532..0000000
--- a/org.osgi.core/src/main/java/org/osgi/service/startlevel/package.html
+++ /dev/null
@@ -1,11 +0,0 @@
-<!-- $Revision: 6204 $ -->
-<BODY>
-<p>Start Level Package Version 1.1.
-<p>Bundles wishing to use this package must list the package
-in the Import-Package header of the bundle's manifest.
-For example:
-<pre>
-Import-Package: org.osgi.service.startlevel; version="[1.1,2.0)"
-</pre>
-</BODY>
-
diff --git a/org.osgi.core/src/main/java/org/osgi/service/startlevel/packageinfo b/org.osgi.core/src/main/java/org/osgi/service/startlevel/packageinfo
deleted file mode 100644
index 3987f9c..0000000
--- a/org.osgi.core/src/main/java/org/osgi/service/startlevel/packageinfo
+++ /dev/null
@@ -1 +0,0 @@
-version 1.1
diff --git a/org.osgi.core/src/main/java/org/osgi/service/url/AbstractURLStreamHandlerService.java b/org.osgi.core/src/main/java/org/osgi/service/url/AbstractURLStreamHandlerService.java
deleted file mode 100644
index 1ad37a2..0000000
--- a/org.osgi.core/src/main/java/org/osgi/service/url/AbstractURLStreamHandlerService.java
+++ /dev/null
@@ -1,149 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2002, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.osgi.service.url;
-
-import java.net.*;
-
-/**
- * Abstract implementation of the <code>URLStreamHandlerService</code>
- * interface. All the methods simply invoke the corresponding methods on
- * <code>java.net.URLStreamHandler</code> except for <code>parseURL</code>
- * and <code>setURL</code>, which use the <code>URLStreamHandlerSetter</code>
- * parameter. Subclasses of this abstract class should not need to override the
- * <code>setURL</code> and <code>parseURL(URLStreamHandlerSetter,...)</code>
- * methods.
- *
- * @ThreadSafe
- * @version $Revision: 5673 $
- */
-public abstract class AbstractURLStreamHandlerService extends URLStreamHandler
- implements URLStreamHandlerService {
- /**
- * @see "java.net.URLStreamHandler.openConnection"
- */
- public abstract URLConnection openConnection(URL u)
- throws java.io.IOException;
-
- /**
- * The <code>URLStreamHandlerSetter</code> object passed to the parseURL
- * method.
- */
- protected volatile URLStreamHandlerSetter realHandler;
-
- /**
- * Parse a URL using the <code>URLStreamHandlerSetter</code> object. This
- * method sets the <code>realHandler</code> field with the specified
- * <code>URLStreamHandlerSetter</code> object and then calls
- * <code>parseURL(URL,String,int,int)</code>.
- *
- * @param realHandler The object on which the <code>setURL</code> method
- * must be invoked for the specified URL.
- * @see "java.net.URLStreamHandler.parseURL"
- */
- public void parseURL(URLStreamHandlerSetter realHandler, URL u,
- String spec, int start, int limit) {
- this.realHandler = realHandler;
- parseURL(u, spec, start, limit);
- }
-
- /**
- * This method calls <code>super.toExternalForm</code>.
- *
- * @see "java.net.URLStreamHandler.toExternalForm"
- */
- public String toExternalForm(URL u) {
- return super.toExternalForm(u);
- }
-
- /**
- * This method calls <code>super.equals(URL,URL)</code>.
- *
- * @see "java.net.URLStreamHandler.equals(URL,URL)"
- */
- public boolean equals(URL u1, URL u2) {
- return super.equals(u1, u2);
- }
-
- /**
- * This method calls <code>super.getDefaultPort</code>.
- *
- * @see "java.net.URLStreamHandler.getDefaultPort"
- */
- public int getDefaultPort() {
- return super.getDefaultPort();
- }
-
- /**
- * This method calls <code>super.getHostAddress</code>.
- *
- * @see "java.net.URLStreamHandler.getHostAddress"
- */
- public InetAddress getHostAddress(URL u) {
- return super.getHostAddress(u);
- }
-
- /**
- * This method calls <code>super.hashCode(URL)</code>.
- *
- * @see "java.net.URLStreamHandler.hashCode(URL)"
- */
- public int hashCode(URL u) {
- return super.hashCode(u);
- }
-
- /**
- * This method calls <code>super.hostsEqual</code>.
- *
- * @see "java.net.URLStreamHandler.hostsEqual"
- */
- public boolean hostsEqual(URL u1, URL u2) {
- return super.hostsEqual(u1, u2);
- }
-
- /**
- * This method calls <code>super.sameFile</code>.
- *
- * @see "java.net.URLStreamHandler.sameFile"
- */
- public boolean sameFile(URL u1, URL u2) {
- return super.sameFile(u1, u2);
- }
-
- /**
- * This method calls
- * <code>realHandler.setURL(URL,String,String,int,String,String)</code>.
- *
- * @see "java.net.URLStreamHandler.setURL(URL,String,String,int,String,String)"
- * @deprecated This method is only for compatibility with handlers written
- * for JDK 1.1.
- */
- protected void setURL(URL u, String proto, String host, int port,
- String file, String ref) {
- realHandler.setURL(u, proto, host, port, file, ref);
- }
-
- /**
- * This method calls
- * <code>realHandler.setURL(URL,String,String,int,String,String,String,String)</code>.
- *
- * @see "java.net.URLStreamHandler.setURL(URL,String,String,int,String,String,String,String)"
- */
- protected void setURL(URL u, String proto, String host, int port,
- String auth, String user, String path, String query, String ref) {
- realHandler.setURL(u, proto, host, port, auth, user, path, query, ref);
- }
-}
diff --git a/org.osgi.core/src/main/java/org/osgi/service/url/URLConstants.java b/org.osgi.core/src/main/java/org/osgi/service/url/URLConstants.java
deleted file mode 100644
index ae95305..0000000
--- a/org.osgi.core/src/main/java/org/osgi/service/url/URLConstants.java
+++ /dev/null
@@ -1,44 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2002, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.osgi.service.url;
-
-/**
- * Defines standard names for property keys associated with
- * {@link URLStreamHandlerService} and <code>java.net.ContentHandler</code>
- * services.
- *
- * <p>
- * The values associated with these keys are of type
- * <code>java.lang.String[]</code> or <code>java.lang.String</code>, unless
- * otherwise indicated.
- *
- * @version $Revision: 5673 $
- */
-public interface URLConstants {
- /**
- * Service property naming the protocols serviced by a
- * URLStreamHandlerService. The property's value is a protocol name or an
- * array of protocol names.
- */
- public static final String URL_HANDLER_PROTOCOL = "url.handler.protocol";
- /**
- * Service property naming the MIME types serviced by a
- * java.net.ContentHandler. The property's value is a MIME type or an array
- * of MIME types.
- */
- public static final String URL_CONTENT_MIMETYPE = "url.content.mimetype";
-}
diff --git a/org.osgi.core/src/main/java/org/osgi/service/url/URLStreamHandlerService.java b/org.osgi.core/src/main/java/org/osgi/service/url/URLStreamHandlerService.java
deleted file mode 100644
index b1ff7d8..0000000
--- a/org.osgi.core/src/main/java/org/osgi/service/url/URLStreamHandlerService.java
+++ /dev/null
@@ -1,92 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2002, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.osgi.service.url;
-
-import java.net.*;
-
-/**
- * Service interface with public versions of the protected
- * <code>java.net.URLStreamHandler</code> methods.
- * <p>
- * The important differences between this interface and the
- * <code>URLStreamHandler</code> class are that the <code>setURL</code>
- * method is absent and the <code>parseURL</code> method takes a
- * {@link URLStreamHandlerSetter} object as the first argument. Classes
- * implementing this interface must call the <code>setURL</code> method on the
- * <code>URLStreamHandlerSetter</code> object received in the
- * <code>parseURL</code> method instead of
- * <code>URLStreamHandler.setURL</code> to avoid a
- * <code>SecurityException</code>.
- *
- * @see AbstractURLStreamHandlerService
- *
- * @ThreadSafe
- * @version $Revision: 5673 $
- */
-public interface URLStreamHandlerService {
- /**
- * @see "java.net.URLStreamHandler.openConnection"
- */
- public URLConnection openConnection(URL u) throws java.io.IOException;
-
- /**
- * Parse a URL. This method is called by the <code>URLStreamHandler</code>
- * proxy, instead of <code>java.net.URLStreamHandler.parseURL</code>,
- * passing a <code>URLStreamHandlerSetter</code> object.
- *
- * @param realHandler The object on which <code>setURL</code> must be
- * invoked for this URL.
- * @see "java.net.URLStreamHandler.parseURL"
- */
- public void parseURL(URLStreamHandlerSetter realHandler, URL u,
- String spec, int start, int limit);
-
- /**
- * @see "java.net.URLStreamHandler.toExternalForm"
- */
- public String toExternalForm(URL u);
-
- /**
- * @see "java.net.URLStreamHandler.equals(URL, URL)"
- */
- public boolean equals(URL u1, URL u2);
-
- /**
- * @see "java.net.URLStreamHandler.getDefaultPort"
- */
- public int getDefaultPort();
-
- /**
- * @see "java.net.URLStreamHandler.getHostAddress"
- */
- public InetAddress getHostAddress(URL u);
-
- /**
- * @see "java.net.URLStreamHandler.hashCode(URL)"
- */
- public int hashCode(URL u);
-
- /**
- * @see "java.net.URLStreamHandler.hostsEqual"
- */
- public boolean hostsEqual(URL u1, URL u2);
-
- /**
- * @see "java.net.URLStreamHandler.sameFile"
- */
- public boolean sameFile(URL u1, URL u2);
-}
diff --git a/org.osgi.core/src/main/java/org/osgi/service/url/URLStreamHandlerSetter.java b/org.osgi.core/src/main/java/org/osgi/service/url/URLStreamHandlerSetter.java
deleted file mode 100644
index 36bdce8..0000000
--- a/org.osgi.core/src/main/java/org/osgi/service/url/URLStreamHandlerSetter.java
+++ /dev/null
@@ -1,53 +0,0 @@
-/*
- * Copyright (c) OSGi Alliance (2002, 2008). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.osgi.service.url;
-
-import java.net.URL;
-
-/**
- * Interface used by <code>URLStreamHandlerService</code> objects to call the
- * <code>setURL</code> method on the proxy <code>URLStreamHandler</code>
- * object.
- *
- * <p>
- * Objects of this type are passed to the
- * {@link URLStreamHandlerService#parseURL} method. Invoking the
- * <code>setURL</code> method on the <code>URLStreamHandlerSetter</code>
- * object will invoke the <code>setURL</code> method on the proxy
- * <code>URLStreamHandler</code> object that is actually registered with
- * <code>java.net.URL</code> for the protocol.
- *
- * @ThreadSafe
- * @version $Revision: 5673 $
- */
-public interface URLStreamHandlerSetter {
- /**
- * @see "java.net.URLStreamHandler.setURL(URL,String,String,int,String,String)"
- *
- * @deprecated This method is only for compatibility with handlers written
- * for JDK 1.1.
- */
- public void setURL(URL u, String protocol, String host, int port,
- String file, String ref);
-
- /**
- * @see "java.net.URLStreamHandler.setURL(URL,String,String,int,String,String,String,String)"
- */
- public void setURL(URL u, String protocol, String host, int port,
- String authority, String userInfo, String path, String query,
- String ref);
-}
diff --git a/org.osgi.core/src/main/java/org/osgi/service/url/package.html b/org.osgi.core/src/main/java/org/osgi/service/url/package.html
deleted file mode 100644
index 4ed4d6e..0000000
--- a/org.osgi.core/src/main/java/org/osgi/service/url/package.html
+++ /dev/null
@@ -1,10 +0,0 @@
-<!-- $Revision: 6204 $ -->
-<BODY>
-<p>URL Stream and Content Handlers Package Version 1.0.
-<p>Bundles wishing to use this package must list the package
-in the Import-Package header of the bundle's manifest.
-For example:
-<pre>
-Import-Package: org.osgi.service.url; version="[1.0,2.0)"
-</pre>
-</BODY>
diff --git a/org.osgi.core/src/main/java/org/osgi/service/url/packageinfo b/org.osgi.core/src/main/java/org/osgi/service/url/packageinfo
deleted file mode 100644
index 7c8de03..0000000
--- a/org.osgi.core/src/main/java/org/osgi/service/url/packageinfo
+++ /dev/null
@@ -1 +0,0 @@
-version 1.0
diff --git a/org.osgi.core/src/main/resources/about.html b/org.osgi.core/src/main/resources/about.html
deleted file mode 100644
index 694d69a..0000000
--- a/org.osgi.core/src/main/resources/about.html
+++ /dev/null
@@ -1,38 +0,0 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN">
-<html>
-<head>
-<title>About</title>
-<meta http-equiv=Content-Type content="text/html; charset=UTF-8">
-</head>
-<body lang="EN-US">
-<h2>About This Content</h2>
-
-<h3>Copyright</h3>
-<p>Copyright © OSGi Alliance (2000, 2009). All Rights Reserved.</p>
-
-<p>OSGi Alliance<br/>
-Bishop Ranch 6<br/>
-2400 Camino Ramon, Suite 375<br/>
-San Ramon, CA 94583 USA
-</p>
-
-<h3>License</h3>
-<p>The OSGi Alliance makes available all content in this jar ("Work"). Unless otherwise indicated below, the Work is provided to you under the terms and conditions of the
-Apache License, Version 2.0 (the "License"). A copy of the License is available at <a href="http://www.apache.org/licenses/LICENSE-2.0">http://www.apache.org/licenses/LICENSE-2.0</a>.</p>
-
-<h3>Notices</h3>
-<p>Implementation of certain elements of the Content may be subject to third party
-intellectual property rights, including without limitation, patent rights (such a third party may
-or may not be a member of the OSGi Alliance). The OSGi Alliance and its members are not responsible
-and shall not be held responsible in any manner for identifying or failing to identify any or
-all such third party intellectual property rights.</p>
-
-<p>OSGi™ is a trademark, registered trademark, or service mark
-of The OSGi Alliance in the US and other countries. Java is a trademark,
-registered trademark, or service mark of Sun Microsystems, Inc. in the US
-and other countries. All other trademarks, registered trademarks, or
-service marks used in the Content are the property of their respective
-owners and are hereby recognized.</p>
-
-</body>
-</html>
diff --git a/org.osgi.core/src/main/resources/org/osgi/framework/hooks/service/package.html b/org.osgi.core/src/main/resources/org/osgi/framework/hooks/service/package.html
deleted file mode 100644
index 46d18ac..0000000
--- a/org.osgi.core/src/main/resources/org/osgi/framework/hooks/service/package.html
+++ /dev/null
@@ -1,11 +0,0 @@
-<!-- $Revision: 6211 $ -->
-<BODY>
-<p>Framework Service Hooks Package Version 1.0.
-<p>Bundles wishing to use this package must list the package
-in the Import-Package header of the bundle's manifest.
-For example:
-<pre>
-Import-Package: org.osgi.framework.hooks.service;version="[1.0,2.0)"
-</pre>
-</BODY>
-
diff --git a/org.osgi.core/src/main/resources/org/osgi/framework/hooks/service/packageinfo b/org.osgi.core/src/main/resources/org/osgi/framework/hooks/service/packageinfo
deleted file mode 100644
index 7c8de03..0000000
--- a/org.osgi.core/src/main/resources/org/osgi/framework/hooks/service/packageinfo
+++ /dev/null
@@ -1 +0,0 @@
-version 1.0
diff --git a/org.osgi.core/src/main/resources/org/osgi/framework/launch/package.html b/org.osgi.core/src/main/resources/org/osgi/framework/launch/package.html
deleted file mode 100644
index 6b0407b..0000000
--- a/org.osgi.core/src/main/resources/org/osgi/framework/launch/package.html
+++ /dev/null
@@ -1,11 +0,0 @@
-<!-- $Revision: 6204 $ -->
-<BODY>
-<p>Framework Launch Package Version 1.0.
-<p>Bundles wishing to use this package must list the package
-in the Import-Package header of the bundle's manifest.
-For example:
-<pre>
-Import-Package: org.osgi.framework.launch;version="[1.0,2.0)"
-</pre>
-</BODY>
-
diff --git a/org.osgi.core/src/main/resources/org/osgi/framework/launch/packageinfo b/org.osgi.core/src/main/resources/org/osgi/framework/launch/packageinfo
deleted file mode 100644
index 7c8de03..0000000
--- a/org.osgi.core/src/main/resources/org/osgi/framework/launch/packageinfo
+++ /dev/null
@@ -1 +0,0 @@
-version 1.0
diff --git a/org.osgi.core/src/main/resources/org/osgi/framework/package.html b/org.osgi.core/src/main/resources/org/osgi/framework/package.html
deleted file mode 100644
index 44d6c48..0000000
--- a/org.osgi.core/src/main/resources/org/osgi/framework/package.html
+++ /dev/null
@@ -1,11 +0,0 @@
-<!-- $Revision: 6204 $ -->
-<BODY>
-<p>Framework Package Version 1.5.
-<p>Bundles wishing to use this package must list the package
-in the Import-Package header of the bundle's manifest.
-For example:
-<pre>
-Import-Package: org.osgi.framework;version="[1.5,2.0)"
-</pre>
-</BODY>
-
diff --git a/org.osgi.core/src/main/resources/org/osgi/framework/packageinfo b/org.osgi.core/src/main/resources/org/osgi/framework/packageinfo
deleted file mode 100644
index ccee95e..0000000
--- a/org.osgi.core/src/main/resources/org/osgi/framework/packageinfo
+++ /dev/null
@@ -1 +0,0 @@
-version 1.5
diff --git a/org.osgi.core/src/main/resources/org/osgi/service/condpermadmin/package.html b/org.osgi.core/src/main/resources/org/osgi/service/condpermadmin/package.html
deleted file mode 100644
index 7930813..0000000
--- a/org.osgi.core/src/main/resources/org/osgi/service/condpermadmin/package.html
+++ /dev/null
@@ -1,10 +0,0 @@
-<!-- $Revision: 6204 $ -->
-<BODY>
-<p>Conditional Permission Admin Package Version 1.1.
-<p>Bundles wishing to use this package must list the package
-in the Import-Package header of the bundle's manifest.
-For example:
-<pre>
-Import-Package: org.osgi.service.condpermadmin; version="[1.1,2.0)"
-</pre>
-</BODY>
diff --git a/org.osgi.core/src/main/resources/org/osgi/service/condpermadmin/packageinfo b/org.osgi.core/src/main/resources/org/osgi/service/condpermadmin/packageinfo
deleted file mode 100644
index 3987f9c..0000000
--- a/org.osgi.core/src/main/resources/org/osgi/service/condpermadmin/packageinfo
+++ /dev/null
@@ -1 +0,0 @@
-version 1.1
diff --git a/org.osgi.core/src/main/resources/org/osgi/service/packageadmin/package.html b/org.osgi.core/src/main/resources/org/osgi/service/packageadmin/package.html
deleted file mode 100644
index 9fc9cab..0000000
--- a/org.osgi.core/src/main/resources/org/osgi/service/packageadmin/package.html
+++ /dev/null
@@ -1,11 +0,0 @@
-<!-- $Revision: 6204 $ -->
-<BODY>
-<p>Package Admin Package Version 1.2.
-<p>Bundles wishing to use this package must list the package
-in the Import-Package header of the bundle's manifest.
-For example:
-<pre>
-Import-Package: org.osgi.service.packageadmin; version="[1.2,2.0)"
-</pre>
-</BODY>
-
diff --git a/org.osgi.core/src/main/resources/org/osgi/service/packageadmin/packageinfo b/org.osgi.core/src/main/resources/org/osgi/service/packageadmin/packageinfo
deleted file mode 100644
index ef7df68..0000000
--- a/org.osgi.core/src/main/resources/org/osgi/service/packageadmin/packageinfo
+++ /dev/null
@@ -1 +0,0 @@
-version 1.2
diff --git a/org.osgi.core/src/main/resources/org/osgi/service/permissionadmin/package.html b/org.osgi.core/src/main/resources/org/osgi/service/permissionadmin/package.html
deleted file mode 100644
index 396264c..0000000
--- a/org.osgi.core/src/main/resources/org/osgi/service/permissionadmin/package.html
+++ /dev/null
@@ -1,11 +0,0 @@
-<!-- $Revision: 6204 $ -->
-<BODY>
-<p>Permission Admin Package Version 1.2.
-<p>Bundles wishing to use this package must list the package
-in the Import-Package header of the bundle's manifest.
-For example:
-<pre>
-Import-Package: org.osgi.service.permissionadmin; version="[1.2,2.0)"
-</pre>
-</BODY>
-
diff --git a/org.osgi.core/src/main/resources/org/osgi/service/permissionadmin/packageinfo b/org.osgi.core/src/main/resources/org/osgi/service/permissionadmin/packageinfo
deleted file mode 100644
index ef7df68..0000000
--- a/org.osgi.core/src/main/resources/org/osgi/service/permissionadmin/packageinfo
+++ /dev/null
@@ -1 +0,0 @@
-version 1.2
diff --git a/org.osgi.core/src/main/resources/org/osgi/service/startlevel/package.html b/org.osgi.core/src/main/resources/org/osgi/service/startlevel/package.html
deleted file mode 100644
index 4c27532..0000000
--- a/org.osgi.core/src/main/resources/org/osgi/service/startlevel/package.html
+++ /dev/null
@@ -1,11 +0,0 @@
-<!-- $Revision: 6204 $ -->
-<BODY>
-<p>Start Level Package Version 1.1.
-<p>Bundles wishing to use this package must list the package
-in the Import-Package header of the bundle's manifest.
-For example:
-<pre>
-Import-Package: org.osgi.service.startlevel; version="[1.1,2.0)"
-</pre>
-</BODY>
-
diff --git a/org.osgi.core/src/main/resources/org/osgi/service/startlevel/packageinfo b/org.osgi.core/src/main/resources/org/osgi/service/startlevel/packageinfo
deleted file mode 100644
index 3987f9c..0000000
--- a/org.osgi.core/src/main/resources/org/osgi/service/startlevel/packageinfo
+++ /dev/null
@@ -1 +0,0 @@
-version 1.1
diff --git a/org.osgi.core/src/main/resources/org/osgi/service/url/package.html b/org.osgi.core/src/main/resources/org/osgi/service/url/package.html
deleted file mode 100644
index 4ed4d6e..0000000
--- a/org.osgi.core/src/main/resources/org/osgi/service/url/package.html
+++ /dev/null
@@ -1,10 +0,0 @@
-<!-- $Revision: 6204 $ -->
-<BODY>
-<p>URL Stream and Content Handlers Package Version 1.0.
-<p>Bundles wishing to use this package must list the package
-in the Import-Package header of the bundle's manifest.
-For example:
-<pre>
-Import-Package: org.osgi.service.url; version="[1.0,2.0)"
-</pre>
-</BODY>
diff --git a/org.osgi.core/src/main/resources/org/osgi/service/url/packageinfo b/org.osgi.core/src/main/resources/org/osgi/service/url/packageinfo
deleted file mode 100644
index 7c8de03..0000000
--- a/org.osgi.core/src/main/resources/org/osgi/service/url/packageinfo
+++ /dev/null
@@ -1 +0,0 @@
-version 1.0
diff --git a/org.osgi.foundation/LICENSE b/org.osgi.foundation/LICENSE
deleted file mode 100644
index d645695..0000000
--- a/org.osgi.foundation/LICENSE
+++ /dev/null
@@ -1,202 +0,0 @@
-
- Apache License
- Version 2.0, January 2004
- http://www.apache.org/licenses/
-
- TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
-
- 1. Definitions.
-
- "License" shall mean the terms and conditions for use, reproduction,
- and distribution as defined by Sections 1 through 9 of this document.
-
- "Licensor" shall mean the copyright owner or entity authorized by
- the copyright owner that is granting the License.
-
- "Legal Entity" shall mean the union of the acting entity and all
- other entities that control, are controlled by, or are under common
- control with that entity. For the purposes of this definition,
- "control" means (i) the power, direct or indirect, to cause the
- direction or management of such entity, whether by contract or
- otherwise, or (ii) ownership of fifty percent (50%) or more of the
- outstanding shares, or (iii) beneficial ownership of such entity.
-
- "You" (or "Your") shall mean an individual or Legal Entity
- exercising permissions granted by this License.
-
- "Source" form shall mean the preferred form for making modifications,
- including but not limited to software source code, documentation
- source, and configuration files.
-
- "Object" form shall mean any form resulting from mechanical
- transformation or translation of a Source form, including but
- not limited to compiled object code, generated documentation,
- and conversions to other media types.
-
- "Work" shall mean the work of authorship, whether in Source or
- Object form, made available under the License, as indicated by a
- copyright notice that is included in or attached to the work
- (an example is provided in the Appendix below).
-
- "Derivative Works" shall mean any work, whether in Source or Object
- form, that is based on (or derived from) the Work and for which the
- editorial revisions, annotations, elaborations, or other modifications
- represent, as a whole, an original work of authorship. For the purposes
- of this License, Derivative Works shall not include works that remain
- separable from, or merely link (or bind by name) to the interfaces of,
- the Work and Derivative Works thereof.
-
- "Contribution" shall mean any work of authorship, including
- the original version of the Work and any modifications or additions
- to that Work or Derivative Works thereof, that is intentionally
- submitted to Licensor for inclusion in the Work by the copyright owner
- or by an individual or Legal Entity authorized to submit on behalf of
- the copyright owner. For the purposes of this definition, "submitted"
- means any form of electronic, verbal, or written communication sent
- to the Licensor or its representatives, including but not limited to
- communication on electronic mailing lists, source code control systems,
- and issue tracking systems that are managed by, or on behalf of, the
- Licensor for the purpose of discussing and improving the Work, but
- excluding communication that is conspicuously marked or otherwise
- designated in writing by the copyright owner as "Not a Contribution."
-
- "Contributor" shall mean Licensor and any individual or Legal Entity
- on behalf of whom a Contribution has been received by Licensor and
- subsequently incorporated within the Work.
-
- 2. Grant of Copyright License. Subject to the terms and conditions of
- this License, each Contributor hereby grants to You a perpetual,
- worldwide, non-exclusive, no-charge, royalty-free, irrevocable
- copyright license to reproduce, prepare Derivative Works of,
- publicly display, publicly perform, sublicense, and distribute the
- Work and such Derivative Works in Source or Object form.
-
- 3. Grant of Patent License. Subject to the terms and conditions of
- this License, each Contributor hereby grants to You a perpetual,
- worldwide, non-exclusive, no-charge, royalty-free, irrevocable
- (except as stated in this section) patent license to make, have made,
- use, offer to sell, sell, import, and otherwise transfer the Work,
- where such license applies only to those patent claims licensable
- by such Contributor that are necessarily infringed by their
- Contribution(s) alone or by combination of their Contribution(s)
- with the Work to which such Contribution(s) was submitted. If You
- institute patent litigation against any entity (including a
- cross-claim or counterclaim in a lawsuit) alleging that the Work
- or a Contribution incorporated within the Work constitutes direct
- or contributory patent infringement, then any patent licenses
- granted to You under this License for that Work shall terminate
- as of the date such litigation is filed.
-
- 4. Redistribution. You may reproduce and distribute copies of the
- Work or Derivative Works thereof in any medium, with or without
- modifications, and in Source or Object form, provided that You
- meet the following conditions:
-
- (a) You must give any other recipients of the Work or
- Derivative Works a copy of this License; and
-
- (b) You must cause any modified files to carry prominent notices
- stating that You changed the files; and
-
- (c) You must retain, in the Source form of any Derivative Works
- that You distribute, all copyright, patent, trademark, and
- attribution notices from the Source form of the Work,
- excluding those notices that do not pertain to any part of
- the Derivative Works; and
-
- (d) If the Work includes a "NOTICE" text file as part of its
- distribution, then any Derivative Works that You distribute must
- include a readable copy of the attribution notices contained
- within such NOTICE file, excluding those notices that do not
- pertain to any part of the Derivative Works, in at least one
- of the following places: within a NOTICE text file distributed
- as part of the Derivative Works; within the Source form or
- documentation, if provided along with the Derivative Works; or,
- within a display generated by the Derivative Works, if and
- wherever such third-party notices normally appear. The contents
- of the NOTICE file are for informational purposes only and
- do not modify the License. You may add Your own attribution
- notices within Derivative Works that You distribute, alongside
- or as an addendum to the NOTICE text from the Work, provided
- that such additional attribution notices cannot be construed
- as modifying the License.
-
- You may add Your own copyright statement to Your modifications and
- may provide additional or different license terms and conditions
- for use, reproduction, or distribution of Your modifications, or
- for any such Derivative Works as a whole, provided Your use,
- reproduction, and distribution of the Work otherwise complies with
- the conditions stated in this License.
-
- 5. Submission of Contributions. Unless You explicitly state otherwise,
- any Contribution intentionally submitted for inclusion in the Work
- by You to the Licensor shall be under the terms and conditions of
- this License, without any additional terms or conditions.
- Notwithstanding the above, nothing herein shall supersede or modify
- the terms of any separate license agreement you may have executed
- with Licensor regarding such Contributions.
-
- 6. Trademarks. This License does not grant permission to use the trade
- names, trademarks, service marks, or product names of the Licensor,
- except as required for reasonable and customary use in describing the
- origin of the Work and reproducing the content of the NOTICE file.
-
- 7. Disclaimer of Warranty. Unless required by applicable law or
- agreed to in writing, Licensor provides the Work (and each
- Contributor provides its Contributions) on an "AS IS" BASIS,
- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
- implied, including, without limitation, any warranties or conditions
- of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
- PARTICULAR PURPOSE. You are solely responsible for determining the
- appropriateness of using or redistributing the Work and assume any
- risks associated with Your exercise of permissions under this License.
-
- 8. Limitation of Liability. In no event and under no legal theory,
- whether in tort (including negligence), contract, or otherwise,
- unless required by applicable law (such as deliberate and grossly
- negligent acts) or agreed to in writing, shall any Contributor be
- liable to You for damages, including any direct, indirect, special,
- incidental, or consequential damages of any character arising as a
- result of this License or out of the use or inability to use the
- Work (including but not limited to damages for loss of goodwill,
- work stoppage, computer failure or malfunction, or any and all
- other commercial damages or losses), even if such Contributor
- has been advised of the possibility of such damages.
-
- 9. Accepting Warranty or Additional Liability. While redistributing
- the Work or Derivative Works thereof, You may choose to offer,
- and charge a fee for, acceptance of support, warranty, indemnity,
- or other liability obligations and/or rights consistent with this
- License. However, in accepting such obligations, You may act only
- on Your own behalf and on Your sole responsibility, not on behalf
- of any other Contributor, and only if You agree to indemnify,
- defend, and hold each Contributor harmless for any liability
- incurred by, or claims asserted against, such Contributor by reason
- of your accepting any such warranty or additional liability.
-
- END OF TERMS AND CONDITIONS
-
- APPENDIX: How to apply the Apache License to your work.
-
- To apply the Apache License to your work, attach the following
- boilerplate notice, with the fields enclosed by brackets "[]"
- replaced with your own identifying information. (Don't include
- the brackets!) The text should be enclosed in the appropriate
- comment syntax for the file format. We also recommend that a
- file or class name and description of purpose be included on the
- same "printed page" as the copyright notice for easier
- identification within third-party archives.
-
- Copyright [yyyy] [name of copyright owner]
-
- Licensed under the Apache License, Version 2.0 (the "License");
- you may not use this file except in compliance with the License.
- You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
- Unless required by applicable law or agreed to in writing, software
- distributed under the License is distributed on an "AS IS" BASIS,
- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- See the License for the specific language governing permissions and
- limitations under the License.
diff --git a/org.osgi.foundation/NOTICE b/org.osgi.foundation/NOTICE
deleted file mode 100644
index 7fc116b..0000000
--- a/org.osgi.foundation/NOTICE
+++ /dev/null
@@ -1,6 +0,0 @@
-OSGi Foundation EE Classes
-Copyright 2001 Sun Microsystems
-Copyright 2005 OSGi Alliance
-
-This product includes software developed at
-the OSGi Alliance and Sun Microsystems.
\ No newline at end of file
diff --git a/org.osgi.foundation/pom.xml b/org.osgi.foundation/pom.xml
deleted file mode 100644
index f469008..0000000
--- a/org.osgi.foundation/pom.xml
+++ /dev/null
@@ -1,34 +0,0 @@
-<!--
- Licensed to the Apache Software Foundation (ASF) under one
- or more contributor license agreements. See the NOTICE file
- distributed with this work for additional information
- regarding copyright ownership. The ASF licenses this file
- to you under the Apache License, Version 2.0 (the
- "License"); you may not use this file except in compliance
- with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
- Unless required by applicable law or agreed to in writing,
- software distributed under the License is distributed on an
- "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- KIND, either express or implied. See the License for the
- specific language governing permissions and limitations
- under the License.
--->
-<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
- <parent>
- <groupId>org.apache.felix</groupId>
- <artifactId>felix</artifactId>
- <version>1.0.4</version>
- <relativePath>../pom/pom.xml</relativePath>
- </parent>
- <organization>
- <name>OSGi Alliance</name>
- <url>http://www.osgi.org/</url>
- </organization>
- <modelVersion>4.0.0</modelVersion>
- <name>OSGi R4 Foundation EE</name>
- <artifactId>org.osgi.foundation</artifactId>
- <version>1.3.0-SNAPSHOT</version>
-</project>
diff --git a/org.osgi.foundation/src/main/java/java/io/BufferedInputStream.java b/org.osgi.foundation/src/main/java/java/io/BufferedInputStream.java
deleted file mode 100644
index d72cbfa..0000000
--- a/org.osgi.foundation/src/main/java/java/io/BufferedInputStream.java
+++ /dev/null
@@ -1,38 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/io/BufferedInputStream.java,v 1.6 2006/03/14 01:20:24 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.io;
-public class BufferedInputStream extends java.io.FilterInputStream {
- public BufferedInputStream(java.io.InputStream var0) { super((java.io.InputStream) null); }
- public BufferedInputStream(java.io.InputStream var0, int var1) { super((java.io.InputStream) null); }
- public int available() throws java.io.IOException { return 0; }
- public void close() throws java.io.IOException { }
- public void mark(int var0) { }
- public boolean markSupported() { return false; }
- public int read() throws java.io.IOException { return 0; }
- public int read(byte[] var0, int var1, int var2) throws java.io.IOException { return 0; }
- public void reset() throws java.io.IOException { }
- public long skip(long var0) throws java.io.IOException { return 0l; }
- protected byte[] buf;
- protected int count;
- protected int marklimit;
- protected int markpos;
- protected int pos;
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/io/BufferedOutputStream.java b/org.osgi.foundation/src/main/java/java/io/BufferedOutputStream.java
deleted file mode 100644
index abcccfc..0000000
--- a/org.osgi.foundation/src/main/java/java/io/BufferedOutputStream.java
+++ /dev/null
@@ -1,30 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/io/BufferedOutputStream.java,v 1.6 2006/03/14 01:20:23 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.io;
-public class BufferedOutputStream extends java.io.FilterOutputStream {
- public BufferedOutputStream(java.io.OutputStream var0) { super((java.io.OutputStream) null); }
- public BufferedOutputStream(java.io.OutputStream var0, int var1) { super((java.io.OutputStream) null); }
- public void flush() throws java.io.IOException { }
- public void write(byte[] var0, int var1, int var2) throws java.io.IOException { }
- public void write(int var0) throws java.io.IOException { }
- protected byte[] buf;
- protected int count;
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/io/BufferedReader.java b/org.osgi.foundation/src/main/java/java/io/BufferedReader.java
deleted file mode 100644
index 73404da..0000000
--- a/org.osgi.foundation/src/main/java/java/io/BufferedReader.java
+++ /dev/null
@@ -1,34 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/io/BufferedReader.java,v 1.6 2006/03/14 01:20:23 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.io;
-public class BufferedReader extends java.io.Reader {
- public BufferedReader(java.io.Reader var0) { }
- public BufferedReader(java.io.Reader var0, int var1) { }
- public void close() throws java.io.IOException { }
- public void mark(int var0) throws java.io.IOException { }
- public boolean markSupported() { return false; }
- public int read() throws java.io.IOException { return 0; }
- public int read(char[] var0, int var1, int var2) throws java.io.IOException { return 0; }
- public java.lang.String readLine() throws java.io.IOException { return null; }
- public boolean ready() throws java.io.IOException { return false; }
- public void reset() throws java.io.IOException { }
- public long skip(long var0) throws java.io.IOException { return 0l; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/io/BufferedWriter.java b/org.osgi.foundation/src/main/java/java/io/BufferedWriter.java
deleted file mode 100644
index 2115f2f..0000000
--- a/org.osgi.foundation/src/main/java/java/io/BufferedWriter.java
+++ /dev/null
@@ -1,31 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/io/BufferedWriter.java,v 1.6 2006/03/14 01:20:23 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.io;
-public class BufferedWriter extends java.io.Writer {
- public BufferedWriter(java.io.Writer var0) { }
- public BufferedWriter(java.io.Writer var0, int var1) { }
- public void close() throws java.io.IOException { }
- public void flush() throws java.io.IOException { }
- public void newLine() throws java.io.IOException { }
- public void write(char[] var0, int var1, int var2) throws java.io.IOException { }
- public void write(int var0) throws java.io.IOException { }
- public void write(java.lang.String var0, int var1, int var2) throws java.io.IOException { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/io/ByteArrayInputStream.java b/org.osgi.foundation/src/main/java/java/io/ByteArrayInputStream.java
deleted file mode 100644
index 7bd4bcd..0000000
--- a/org.osgi.foundation/src/main/java/java/io/ByteArrayInputStream.java
+++ /dev/null
@@ -1,37 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/io/ByteArrayInputStream.java,v 1.6 2006/03/14 01:20:24 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.io;
-public class ByteArrayInputStream extends java.io.InputStream {
- public ByteArrayInputStream(byte[] var0) { }
- public ByteArrayInputStream(byte[] var0, int var1, int var2) { }
- public int available() { return 0; }
- public void close() throws java.io.IOException { }
- public void mark(int var0) { }
- public boolean markSupported() { return false; }
- public int read() { return 0; }
- public int read(byte[] var0, int var1, int var2) { return 0; }
- public void reset() { }
- public long skip(long var0) { return 0l; }
- protected byte[] buf;
- protected int pos;
- protected int mark;
- protected int count;
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/io/ByteArrayOutputStream.java b/org.osgi.foundation/src/main/java/java/io/ByteArrayOutputStream.java
deleted file mode 100644
index 99d2425..0000000
--- a/org.osgi.foundation/src/main/java/java/io/ByteArrayOutputStream.java
+++ /dev/null
@@ -1,36 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/io/ByteArrayOutputStream.java,v 1.6 2006/03/14 01:20:23 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.io;
-public class ByteArrayOutputStream extends java.io.OutputStream {
- public ByteArrayOutputStream() { }
- public ByteArrayOutputStream(int var0) { }
- public void close() throws java.io.IOException { }
- public void reset() { }
- public int size() { return 0; }
- public byte[] toByteArray() { return null; }
- public java.lang.String toString() { return null; }
- public java.lang.String toString(java.lang.String var0) throws java.io.UnsupportedEncodingException { return null; }
- public void write(byte[] var0, int var1, int var2) { }
- public void write(int var0) { }
- public void writeTo(java.io.OutputStream var0) throws java.io.IOException { }
- protected byte[] buf;
- protected int count;
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/io/CharArrayReader.java b/org.osgi.foundation/src/main/java/java/io/CharArrayReader.java
deleted file mode 100644
index c4f3a26..0000000
--- a/org.osgi.foundation/src/main/java/java/io/CharArrayReader.java
+++ /dev/null
@@ -1,37 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/io/CharArrayReader.java,v 1.6 2006/03/14 01:20:24 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.io;
-public class CharArrayReader extends java.io.Reader {
- public CharArrayReader(char[] var0) { }
- public CharArrayReader(char[] var0, int var1, int var2) { }
- public void close() { }
- public void mark(int var0) throws java.io.IOException { }
- public boolean markSupported() { return false; }
- public int read() throws java.io.IOException { return 0; }
- public int read(char[] var0, int var1, int var2) throws java.io.IOException { return 0; }
- public boolean ready() throws java.io.IOException { return false; }
- public void reset() throws java.io.IOException { }
- public long skip(long var0) throws java.io.IOException { return 0l; }
- protected char[] buf;
- protected int pos;
- protected int markedPos;
- protected int count;
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/io/CharArrayWriter.java b/org.osgi.foundation/src/main/java/java/io/CharArrayWriter.java
deleted file mode 100644
index 5c8a2ea..0000000
--- a/org.osgi.foundation/src/main/java/java/io/CharArrayWriter.java
+++ /dev/null
@@ -1,37 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/io/CharArrayWriter.java,v 1.6 2006/03/14 01:20:23 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.io;
-public class CharArrayWriter extends java.io.Writer {
- public CharArrayWriter() { }
- public CharArrayWriter(int var0) { }
- public void close() { }
- public void flush() { }
- public void reset() { }
- public int size() { return 0; }
- public char[] toCharArray() { return null; }
- public java.lang.String toString() { return null; }
- public void write(char[] var0, int var1, int var2) { }
- public void write(int var0) { }
- public void write(java.lang.String var0, int var1, int var2) { }
- public void writeTo(java.io.Writer var0) throws java.io.IOException { }
- protected char[] buf;
- protected int count;
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/io/CharConversionException.java b/org.osgi.foundation/src/main/java/java/io/CharConversionException.java
deleted file mode 100644
index 28c90e2..0000000
--- a/org.osgi.foundation/src/main/java/java/io/CharConversionException.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/io/CharConversionException.java,v 1.6 2006/03/14 01:20:23 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.io;
-public class CharConversionException extends java.io.IOException {
- public CharConversionException() { }
- public CharConversionException(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/io/DataInput.java b/org.osgi.foundation/src/main/java/java/io/DataInput.java
deleted file mode 100644
index 9dee0e9..0000000
--- a/org.osgi.foundation/src/main/java/java/io/DataInput.java
+++ /dev/null
@@ -1,38 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/io/DataInput.java,v 1.6 2006/03/14 01:20:23 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.io;
-public abstract interface DataInput {
- public abstract boolean readBoolean() throws java.io.IOException;
- public abstract byte readByte() throws java.io.IOException;
- public abstract char readChar() throws java.io.IOException;
- public abstract double readDouble() throws java.io.IOException;
- public abstract float readFloat() throws java.io.IOException;
- public abstract void readFully(byte[] var0) throws java.io.IOException;
- public abstract void readFully(byte[] var0, int var1, int var2) throws java.io.IOException;
- public abstract int readInt() throws java.io.IOException;
- public abstract java.lang.String readLine() throws java.io.IOException;
- public abstract long readLong() throws java.io.IOException;
- public abstract short readShort() throws java.io.IOException;
- public abstract int readUnsignedByte() throws java.io.IOException;
- public abstract int readUnsignedShort() throws java.io.IOException;
- public abstract java.lang.String readUTF() throws java.io.IOException;
- public abstract int skipBytes(int var0) throws java.io.IOException;
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/io/DataInputStream.java b/org.osgi.foundation/src/main/java/java/io/DataInputStream.java
deleted file mode 100644
index 21d2b5f..0000000
--- a/org.osgi.foundation/src/main/java/java/io/DataInputStream.java
+++ /dev/null
@@ -1,42 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/io/DataInputStream.java,v 1.6 2006/03/14 01:20:24 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.io;
-public class DataInputStream extends java.io.FilterInputStream implements java.io.DataInput {
- public DataInputStream(java.io.InputStream var0) { super((java.io.InputStream) null); }
- public final int read(byte[] var0) throws java.io.IOException { return 0; }
- public final int read(byte[] var0, int var1, int var2) throws java.io.IOException { return 0; }
- public final boolean readBoolean() throws java.io.IOException { return false; }
- public final byte readByte() throws java.io.IOException { return 0; }
- public final char readChar() throws java.io.IOException { return 0; }
- public final double readDouble() throws java.io.IOException { return 0.0d; }
- public final float readFloat() throws java.io.IOException { return 0.0f; }
- public final void readFully(byte[] var0) throws java.io.IOException { }
- public final void readFully(byte[] var0, int var1, int var2) throws java.io.IOException { }
- public final int readInt() throws java.io.IOException { return 0; }
- public final java.lang.String readLine() throws java.io.IOException { return null; }
- public final long readLong() throws java.io.IOException { return 0l; }
- public final short readShort() throws java.io.IOException { return 0; }
- public final int readUnsignedByte() throws java.io.IOException { return 0; }
- public final int readUnsignedShort() throws java.io.IOException { return 0; }
- public final java.lang.String readUTF() throws java.io.IOException { return null; }
- public final static java.lang.String readUTF(java.io.DataInput var0) throws java.io.IOException { return null; }
- public final int skipBytes(int var0) throws java.io.IOException { return 0; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/io/DataOutput.java b/org.osgi.foundation/src/main/java/java/io/DataOutput.java
deleted file mode 100644
index 406d887..0000000
--- a/org.osgi.foundation/src/main/java/java/io/DataOutput.java
+++ /dev/null
@@ -1,37 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/io/DataOutput.java,v 1.6 2006/03/14 01:20:23 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.io;
-public abstract interface DataOutput {
- public abstract void write(byte[] var0) throws java.io.IOException;
- public abstract void write(byte[] var0, int var1, int var2) throws java.io.IOException;
- public abstract void write(int var0) throws java.io.IOException;
- public abstract void writeBoolean(boolean var0) throws java.io.IOException;
- public abstract void writeByte(int var0) throws java.io.IOException;
- public abstract void writeBytes(java.lang.String var0) throws java.io.IOException;
- public abstract void writeChar(int var0) throws java.io.IOException;
- public abstract void writeChars(java.lang.String var0) throws java.io.IOException;
- public abstract void writeDouble(double var0) throws java.io.IOException;
- public abstract void writeFloat(float var0) throws java.io.IOException;
- public abstract void writeInt(int var0) throws java.io.IOException;
- public abstract void writeLong(long var0) throws java.io.IOException;
- public abstract void writeShort(int var0) throws java.io.IOException;
- public abstract void writeUTF(java.lang.String var0) throws java.io.IOException;
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/io/DataOutputStream.java b/org.osgi.foundation/src/main/java/java/io/DataOutputStream.java
deleted file mode 100644
index 077ecdd..0000000
--- a/org.osgi.foundation/src/main/java/java/io/DataOutputStream.java
+++ /dev/null
@@ -1,40 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/io/DataOutputStream.java,v 1.6 2006/03/14 01:20:24 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.io;
-public class DataOutputStream extends java.io.FilterOutputStream implements java.io.DataOutput {
- public DataOutputStream(java.io.OutputStream var0) { super((java.io.OutputStream) null); }
- public void flush() throws java.io.IOException { }
- public final int size() { return 0; }
- public void write(byte[] var0, int var1, int var2) throws java.io.IOException { }
- public void write(int var0) throws java.io.IOException { }
- public final void writeBoolean(boolean var0) throws java.io.IOException { }
- public final void writeByte(int var0) throws java.io.IOException { }
- public final void writeBytes(java.lang.String var0) throws java.io.IOException { }
- public final void writeChar(int var0) throws java.io.IOException { }
- public final void writeChars(java.lang.String var0) throws java.io.IOException { }
- public final void writeDouble(double var0) throws java.io.IOException { }
- public final void writeFloat(float var0) throws java.io.IOException { }
- public final void writeInt(int var0) throws java.io.IOException { }
- public final void writeLong(long var0) throws java.io.IOException { }
- public final void writeShort(int var0) throws java.io.IOException { }
- public final void writeUTF(java.lang.String var0) throws java.io.IOException { }
- protected int written;
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/io/EOFException.java b/org.osgi.foundation/src/main/java/java/io/EOFException.java
deleted file mode 100644
index 7625cec..0000000
--- a/org.osgi.foundation/src/main/java/java/io/EOFException.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/io/EOFException.java,v 1.6 2006/03/14 01:20:24 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.io;
-public class EOFException extends java.io.IOException {
- public EOFException() { }
- public EOFException(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/io/Externalizable.java b/org.osgi.foundation/src/main/java/java/io/Externalizable.java
deleted file mode 100644
index e4bf5c9..0000000
--- a/org.osgi.foundation/src/main/java/java/io/Externalizable.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/io/Externalizable.java,v 1.6 2006/03/14 01:20:23 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.io;
-public abstract interface Externalizable extends java.io.Serializable {
- public abstract void readExternal(java.io.ObjectInput var0) throws java.io.IOException, java.lang.ClassNotFoundException;
- public abstract void writeExternal(java.io.ObjectOutput var0) throws java.io.IOException;
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/io/File.java b/org.osgi.foundation/src/main/java/java/io/File.java
deleted file mode 100644
index df134f1..0000000
--- a/org.osgi.foundation/src/main/java/java/io/File.java
+++ /dev/null
@@ -1,69 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/io/File.java,v 1.6 2006/03/14 01:20:24 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.io;
-public class File implements java.io.Serializable, java.lang.Comparable {
- public File(java.io.File var0, java.lang.String var1) { }
- public File(java.lang.String var0) { }
- public File(java.lang.String var0, java.lang.String var1) { }
- public static java.io.File[] listRoots() { return null; }
- public boolean canRead() { return false; }
- public boolean canWrite() { return false; }
- public int compareTo(java.lang.Object var0) { return 0; }
- public int compareTo(java.io.File var0) { return 0; }
- public boolean delete() { return false; }
- public void deleteOnExit() { }
- public boolean equals(java.lang.Object var0) { return false; }
- public boolean exists() { return false; }
- public java.lang.String getAbsolutePath() { return null; }
- public java.io.File getAbsoluteFile() { return null; }
- public java.lang.String getCanonicalPath() throws java.io.IOException { return null; }
- public java.io.File getCanonicalFile() throws java.io.IOException { return null; }
- public java.lang.String getName() { return null; }
- public java.lang.String getParent() { return null; }
- public java.io.File getParentFile() { return null; }
- public java.lang.String getPath() { return null; }
- public int hashCode() { return 0; }
- public boolean isAbsolute() { return false; }
- public boolean isDirectory() { return false; }
- public boolean isFile() { return false; }
- public boolean isHidden() { return false; }
- public long lastModified() { return 0l; }
- public boolean setLastModified(long var0) { return false; }
- public boolean setReadOnly() { return false; }
- public long length() { return 0l; }
- public java.lang.String[] list() { return null; }
- public java.io.File[] listFiles() { return null; }
- public java.io.File[] listFiles(java.io.FilenameFilter var0) { return null; }
- public java.io.File[] listFiles(java.io.FileFilter var0) { return null; }
- public java.lang.String[] list(java.io.FilenameFilter var0) { return null; }
- public boolean mkdir() { return false; }
- public boolean mkdirs() { return false; }
- public boolean createNewFile() throws java.io.IOException { return false; }
- public static java.io.File createTempFile(java.lang.String var0, java.lang.String var1) throws java.io.IOException { return null; }
- public static java.io.File createTempFile(java.lang.String var0, java.lang.String var1, java.io.File var2) throws java.io.IOException { return null; }
- public boolean renameTo(java.io.File var0) { return false; }
- public java.lang.String toString() { return null; }
- public java.net.URL toURL() throws java.net.MalformedURLException { return null; }
- public final static char separatorChar; static { separatorChar = 0; }
- public final static java.lang.String separator; static { separator = null; }
- public final static char pathSeparatorChar; static { pathSeparatorChar = 0; }
- public final static java.lang.String pathSeparator; static { pathSeparator = null; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/io/FileDescriptor.java b/org.osgi.foundation/src/main/java/java/io/FileDescriptor.java
deleted file mode 100644
index fdf1de3..0000000
--- a/org.osgi.foundation/src/main/java/java/io/FileDescriptor.java
+++ /dev/null
@@ -1,29 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/io/FileDescriptor.java,v 1.6 2006/03/14 01:20:23 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.io;
-public final class FileDescriptor {
- public FileDescriptor() { }
- public void sync() throws java.io.SyncFailedException { }
- public boolean valid() { return false; }
- public final static java.io.FileDescriptor in; static { in = null; }
- public final static java.io.FileDescriptor out; static { out = null; }
- public final static java.io.FileDescriptor err; static { err = null; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/io/FileFilter.java b/org.osgi.foundation/src/main/java/java/io/FileFilter.java
deleted file mode 100644
index 2120bc3..0000000
--- a/org.osgi.foundation/src/main/java/java/io/FileFilter.java
+++ /dev/null
@@ -1,24 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/io/FileFilter.java,v 1.6 2006/03/14 01:20:23 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.io;
-public abstract interface FileFilter {
- public abstract boolean accept(java.io.File var0);
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/io/FileInputStream.java b/org.osgi.foundation/src/main/java/java/io/FileInputStream.java
deleted file mode 100644
index 2f8c0cd..0000000
--- a/org.osgi.foundation/src/main/java/java/io/FileInputStream.java
+++ /dev/null
@@ -1,34 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/io/FileInputStream.java,v 1.6 2006/03/14 01:20:23 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.io;
-public class FileInputStream extends java.io.InputStream {
- public FileInputStream(java.io.File var0) throws java.io.FileNotFoundException { }
- public FileInputStream(java.io.FileDescriptor var0) { }
- public FileInputStream(java.lang.String var0) throws java.io.FileNotFoundException { }
- public int available() throws java.io.IOException { return 0; }
- public void close() throws java.io.IOException { }
- protected void finalize() throws java.io.IOException { }
- public final java.io.FileDescriptor getFD() throws java.io.IOException { return null; }
- public int read() throws java.io.IOException { return 0; }
- public int read(byte[] var0) throws java.io.IOException { return 0; }
- public int read(byte[] var0, int var1, int var2) throws java.io.IOException { return 0; }
- public long skip(long var0) throws java.io.IOException { return 0l; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/io/FileNotFoundException.java b/org.osgi.foundation/src/main/java/java/io/FileNotFoundException.java
deleted file mode 100644
index 56ec83e..0000000
--- a/org.osgi.foundation/src/main/java/java/io/FileNotFoundException.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/io/FileNotFoundException.java,v 1.6 2006/03/14 01:20:23 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.io;
-public class FileNotFoundException extends java.io.IOException {
- public FileNotFoundException() { }
- public FileNotFoundException(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/io/FileOutputStream.java b/org.osgi.foundation/src/main/java/java/io/FileOutputStream.java
deleted file mode 100644
index c7fa433..0000000
--- a/org.osgi.foundation/src/main/java/java/io/FileOutputStream.java
+++ /dev/null
@@ -1,33 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/io/FileOutputStream.java,v 1.6 2006/03/14 01:20:23 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.io;
-public class FileOutputStream extends java.io.OutputStream {
- public FileOutputStream(java.io.File var0) throws java.io.FileNotFoundException { }
- public FileOutputStream(java.io.FileDescriptor var0) { }
- public FileOutputStream(java.lang.String var0) throws java.io.FileNotFoundException { }
- public FileOutputStream(java.lang.String var0, boolean var1) throws java.io.FileNotFoundException { }
- public void close() throws java.io.IOException { }
- protected void finalize() throws java.io.IOException { }
- public final java.io.FileDescriptor getFD() throws java.io.IOException { return null; }
- public void write(byte[] var0) throws java.io.IOException { }
- public void write(byte[] var0, int var1, int var2) throws java.io.IOException { }
- public void write(int var0) throws java.io.IOException { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/io/FilePermission.java b/org.osgi.foundation/src/main/java/java/io/FilePermission.java
deleted file mode 100644
index f208497..0000000
--- a/org.osgi.foundation/src/main/java/java/io/FilePermission.java
+++ /dev/null
@@ -1,29 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/io/FilePermission.java,v 1.6 2006/03/14 01:20:23 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.io;
-public final class FilePermission extends java.security.Permission implements java.io.Serializable {
- public FilePermission(java.lang.String var0, java.lang.String var1) { super((java.lang.String) null); }
- public java.lang.String getActions() { return null; }
- public boolean equals(java.lang.Object var0) { return false; }
- public boolean implies(java.security.Permission var0) { return false; }
- public java.security.PermissionCollection newPermissionCollection() { return null; }
- public int hashCode() { return 0; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/io/FileReader.java b/org.osgi.foundation/src/main/java/java/io/FileReader.java
deleted file mode 100644
index bb1bd3f..0000000
--- a/org.osgi.foundation/src/main/java/java/io/FileReader.java
+++ /dev/null
@@ -1,26 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/io/FileReader.java,v 1.6 2006/03/14 01:20:23 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.io;
-public class FileReader extends java.io.InputStreamReader {
- public FileReader(java.io.File var0) throws java.io.FileNotFoundException { super((java.io.InputStream) null); }
- public FileReader(java.io.FileDescriptor var0) { super((java.io.InputStream) null); }
- public FileReader(java.lang.String var0) throws java.io.FileNotFoundException { super((java.io.InputStream) null); }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/io/FileWriter.java b/org.osgi.foundation/src/main/java/java/io/FileWriter.java
deleted file mode 100644
index 2f0adaa..0000000
--- a/org.osgi.foundation/src/main/java/java/io/FileWriter.java
+++ /dev/null
@@ -1,27 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/io/FileWriter.java,v 1.6 2006/03/14 01:20:23 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.io;
-public class FileWriter extends java.io.OutputStreamWriter {
- public FileWriter(java.io.File var0) throws java.io.IOException { super((java.io.OutputStream) null); }
- public FileWriter(java.io.FileDescriptor var0) { super((java.io.OutputStream) null); }
- public FileWriter(java.lang.String var0) throws java.io.IOException { super((java.io.OutputStream) null); }
- public FileWriter(java.lang.String var0, boolean var1) throws java.io.IOException { super((java.io.OutputStream) null); }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/io/FilenameFilter.java b/org.osgi.foundation/src/main/java/java/io/FilenameFilter.java
deleted file mode 100644
index ffc3886..0000000
--- a/org.osgi.foundation/src/main/java/java/io/FilenameFilter.java
+++ /dev/null
@@ -1,24 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/io/FilenameFilter.java,v 1.6 2006/03/14 01:20:24 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.io;
-public abstract interface FilenameFilter {
- public abstract boolean accept(java.io.File var0, java.lang.String var1);
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/io/FilterInputStream.java b/org.osgi.foundation/src/main/java/java/io/FilterInputStream.java
deleted file mode 100644
index 109183c..0000000
--- a/org.osgi.foundation/src/main/java/java/io/FilterInputStream.java
+++ /dev/null
@@ -1,34 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/io/FilterInputStream.java,v 1.6 2006/03/14 01:20:23 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.io;
-public class FilterInputStream extends java.io.InputStream {
- protected FilterInputStream(java.io.InputStream var0) { }
- public int available() throws java.io.IOException { return 0; }
- public void close() throws java.io.IOException { }
- public void mark(int var0) { }
- public boolean markSupported() { return false; }
- public int read() throws java.io.IOException { return 0; }
- public int read(byte[] var0) throws java.io.IOException { return 0; }
- public int read(byte[] var0, int var1, int var2) throws java.io.IOException { return 0; }
- public void reset() throws java.io.IOException { }
- public long skip(long var0) throws java.io.IOException { return 0l; }
- protected java.io.InputStream in;
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/io/FilterOutputStream.java b/org.osgi.foundation/src/main/java/java/io/FilterOutputStream.java
deleted file mode 100644
index cdd1af1..0000000
--- a/org.osgi.foundation/src/main/java/java/io/FilterOutputStream.java
+++ /dev/null
@@ -1,30 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/io/FilterOutputStream.java,v 1.6 2006/03/14 01:20:24 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.io;
-public class FilterOutputStream extends java.io.OutputStream {
- public FilterOutputStream(java.io.OutputStream var0) { }
- public void close() throws java.io.IOException { }
- public void flush() throws java.io.IOException { }
- public void write(byte[] var0) throws java.io.IOException { }
- public void write(byte[] var0, int var1, int var2) throws java.io.IOException { }
- public void write(int var0) throws java.io.IOException { }
- protected java.io.OutputStream out;
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/io/FilterReader.java b/org.osgi.foundation/src/main/java/java/io/FilterReader.java
deleted file mode 100644
index 5b5dd19..0000000
--- a/org.osgi.foundation/src/main/java/java/io/FilterReader.java
+++ /dev/null
@@ -1,33 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/io/FilterReader.java,v 1.6 2006/03/14 01:20:23 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.io;
-public abstract class FilterReader extends java.io.Reader {
- protected FilterReader(java.io.Reader var0) { }
- public void close() throws java.io.IOException { }
- public void mark(int var0) throws java.io.IOException { }
- public boolean markSupported() { return false; }
- public int read() throws java.io.IOException { return 0; }
- public int read(char[] var0, int var1, int var2) throws java.io.IOException { return 0; }
- public boolean ready() throws java.io.IOException { return false; }
- public void reset() throws java.io.IOException { }
- public long skip(long var0) throws java.io.IOException { return 0l; }
- protected java.io.Reader in;
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/io/FilterWriter.java b/org.osgi.foundation/src/main/java/java/io/FilterWriter.java
deleted file mode 100644
index eec7371..0000000
--- a/org.osgi.foundation/src/main/java/java/io/FilterWriter.java
+++ /dev/null
@@ -1,30 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/io/FilterWriter.java,v 1.6 2006/03/14 01:20:24 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.io;
-public abstract class FilterWriter extends java.io.Writer {
- protected FilterWriter(java.io.Writer var0) { }
- public void close() throws java.io.IOException { }
- public void flush() throws java.io.IOException { }
- public void write(char[] var0, int var1, int var2) throws java.io.IOException { }
- public void write(int var0) throws java.io.IOException { }
- public void write(java.lang.String var0, int var1, int var2) throws java.io.IOException { }
- protected java.io.Writer out;
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/io/IOException.java b/org.osgi.foundation/src/main/java/java/io/IOException.java
deleted file mode 100644
index 9af48e3..0000000
--- a/org.osgi.foundation/src/main/java/java/io/IOException.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/io/IOException.java,v 1.6 2006/03/14 01:20:24 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.io;
-public class IOException extends java.lang.Exception {
- public IOException() { }
- public IOException(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/io/InputStream.java b/org.osgi.foundation/src/main/java/java/io/InputStream.java
deleted file mode 100644
index 18c4b61..0000000
--- a/org.osgi.foundation/src/main/java/java/io/InputStream.java
+++ /dev/null
@@ -1,33 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/io/InputStream.java,v 1.6 2006/03/14 01:20:24 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.io;
-public abstract class InputStream {
- public InputStream() { }
- public int available() throws java.io.IOException { return 0; }
- public void close() throws java.io.IOException { }
- public void mark(int var0) { }
- public boolean markSupported() { return false; }
- public abstract int read() throws java.io.IOException;
- public int read(byte[] var0) throws java.io.IOException { return 0; }
- public int read(byte[] var0, int var1, int var2) throws java.io.IOException { return 0; }
- public void reset() throws java.io.IOException { }
- public long skip(long var0) throws java.io.IOException { return 0l; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/io/InputStreamReader.java b/org.osgi.foundation/src/main/java/java/io/InputStreamReader.java
deleted file mode 100644
index ef588d5..0000000
--- a/org.osgi.foundation/src/main/java/java/io/InputStreamReader.java
+++ /dev/null
@@ -1,30 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/io/InputStreamReader.java,v 1.6 2006/03/14 01:20:24 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.io;
-public class InputStreamReader extends java.io.Reader {
- public InputStreamReader(java.io.InputStream var0) { }
- public InputStreamReader(java.io.InputStream var0, java.lang.String var1) throws java.io.UnsupportedEncodingException { }
- public void close() throws java.io.IOException { }
- public java.lang.String getEncoding() { return null; }
- public int read() throws java.io.IOException { return 0; }
- public int read(char[] var0, int var1, int var2) throws java.io.IOException { return 0; }
- public boolean ready() throws java.io.IOException { return false; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/io/InterruptedIOException.java b/org.osgi.foundation/src/main/java/java/io/InterruptedIOException.java
deleted file mode 100644
index 2a89511..0000000
--- a/org.osgi.foundation/src/main/java/java/io/InterruptedIOException.java
+++ /dev/null
@@ -1,26 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/io/InterruptedIOException.java,v 1.6 2006/03/14 01:20:23 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.io;
-public class InterruptedIOException extends java.io.IOException {
- public InterruptedIOException() { }
- public InterruptedIOException(java.lang.String var0) { }
- public int bytesTransferred;
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/io/InvalidClassException.java b/org.osgi.foundation/src/main/java/java/io/InvalidClassException.java
deleted file mode 100644
index 1d2ad07..0000000
--- a/org.osgi.foundation/src/main/java/java/io/InvalidClassException.java
+++ /dev/null
@@ -1,27 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/io/InvalidClassException.java,v 1.6 2006/03/14 01:20:24 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.io;
-public class InvalidClassException extends java.io.ObjectStreamException {
- public InvalidClassException(java.lang.String var0) { }
- public InvalidClassException(java.lang.String var0, java.lang.String var1) { }
- public java.lang.String getMessage() { return null; }
- public java.lang.String classname;
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/io/InvalidObjectException.java b/org.osgi.foundation/src/main/java/java/io/InvalidObjectException.java
deleted file mode 100644
index 7bdc3ea..0000000
--- a/org.osgi.foundation/src/main/java/java/io/InvalidObjectException.java
+++ /dev/null
@@ -1,24 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/io/InvalidObjectException.java,v 1.6 2006/03/14 01:20:23 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.io;
-public class InvalidObjectException extends java.io.ObjectStreamException {
- public InvalidObjectException(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/io/LineNumberReader.java b/org.osgi.foundation/src/main/java/java/io/LineNumberReader.java
deleted file mode 100644
index 2ef7c39..0000000
--- a/org.osgi.foundation/src/main/java/java/io/LineNumberReader.java
+++ /dev/null
@@ -1,33 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/io/LineNumberReader.java,v 1.6 2006/03/14 01:20:23 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.io;
-public class LineNumberReader extends java.io.BufferedReader {
- public LineNumberReader(java.io.Reader var0) { super((java.io.Reader) null, 0); }
- public LineNumberReader(java.io.Reader var0, int var1) { super((java.io.Reader) null, 0); }
- public int getLineNumber() { return 0; }
- public void mark(int var0) throws java.io.IOException { }
- public int read() throws java.io.IOException { return 0; }
- public int read(char[] var0, int var1, int var2) throws java.io.IOException { return 0; }
- public java.lang.String readLine() throws java.io.IOException { return null; }
- public void reset() throws java.io.IOException { }
- public void setLineNumber(int var0) { }
- public long skip(long var0) throws java.io.IOException { return 0l; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/io/NotActiveException.java b/org.osgi.foundation/src/main/java/java/io/NotActiveException.java
deleted file mode 100644
index 50fc70a..0000000
--- a/org.osgi.foundation/src/main/java/java/io/NotActiveException.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/io/NotActiveException.java,v 1.6 2006/03/14 01:20:24 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.io;
-public class NotActiveException extends java.io.ObjectStreamException {
- public NotActiveException() { }
- public NotActiveException(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/io/NotSerializableException.java b/org.osgi.foundation/src/main/java/java/io/NotSerializableException.java
deleted file mode 100644
index f102db9..0000000
--- a/org.osgi.foundation/src/main/java/java/io/NotSerializableException.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/io/NotSerializableException.java,v 1.6 2006/03/14 01:20:24 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.io;
-public class NotSerializableException extends java.io.ObjectStreamException {
- public NotSerializableException() { }
- public NotSerializableException(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/io/ObjectInput.java b/org.osgi.foundation/src/main/java/java/io/ObjectInput.java
deleted file mode 100644
index 6bf0409..0000000
--- a/org.osgi.foundation/src/main/java/java/io/ObjectInput.java
+++ /dev/null
@@ -1,30 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/io/ObjectInput.java,v 1.6 2006/03/14 01:20:23 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.io;
-public abstract interface ObjectInput extends java.io.DataInput {
- public abstract int available() throws java.io.IOException;
- public abstract void close() throws java.io.IOException;
- public abstract int read() throws java.io.IOException;
- public abstract int read(byte[] var0) throws java.io.IOException;
- public abstract int read(byte[] var0, int var1, int var2) throws java.io.IOException;
- public abstract java.lang.Object readObject() throws java.lang.ClassNotFoundException, java.io.IOException;
- public abstract long skip(long var0) throws java.io.IOException;
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/io/ObjectInputStream.java b/org.osgi.foundation/src/main/java/java/io/ObjectInputStream.java
deleted file mode 100644
index 6729189..0000000
--- a/org.osgi.foundation/src/main/java/java/io/ObjectInputStream.java
+++ /dev/null
@@ -1,69 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/io/ObjectInputStream.java,v 1.6 2006/03/14 01:20:24 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.io;
-public class ObjectInputStream extends java.io.InputStream implements java.io.ObjectInput, java.io.ObjectStreamConstants {
- protected ObjectInputStream() throws java.io.IOException, java.lang.SecurityException { }
- public ObjectInputStream(java.io.InputStream var0) throws java.io.StreamCorruptedException, java.io.IOException { }
- public int available() throws java.io.IOException { return 0; }
- public void close() throws java.io.IOException { }
- public void defaultReadObject() throws java.io.IOException, java.lang.ClassNotFoundException, java.io.NotActiveException { }
- protected boolean enableResolveObject(boolean var0) throws java.lang.SecurityException { return false; }
- public int read() throws java.io.IOException { return 0; }
- public int read(byte[] var0, int var1, int var2) throws java.io.IOException { return 0; }
- public boolean readBoolean() throws java.io.IOException { return false; }
- public byte readByte() throws java.io.IOException { return 0; }
- public char readChar() throws java.io.IOException { return 0; }
- public double readDouble() throws java.io.IOException { return 0.0d; }
- public java.io.ObjectInputStream.GetField readFields() throws java.io.IOException, java.lang.ClassNotFoundException, java.io.NotActiveException { return null; }
- public float readFloat() throws java.io.IOException { return 0.0f; }
- public void readFully(byte[] var0) throws java.io.IOException { }
- public void readFully(byte[] var0, int var1, int var2) throws java.io.IOException { }
- public int readInt() throws java.io.IOException { return 0; }
- public java.lang.String readLine() throws java.io.IOException { return null; }
- public long readLong() throws java.io.IOException { return 0l; }
- protected java.io.ObjectStreamClass readClassDescriptor() throws java.io.IOException, java.lang.ClassNotFoundException { return null; }
- protected java.lang.Class resolveProxyClass(java.lang.String[] var0) throws java.io.IOException, java.lang.ClassNotFoundException { return null; }
- public final java.lang.Object readObject() throws java.io.OptionalDataException, java.lang.ClassNotFoundException, java.io.IOException { return null; }
- protected java.lang.Object readObjectOverride() throws java.io.OptionalDataException, java.lang.ClassNotFoundException, java.io.IOException { return null; }
- public short readShort() throws java.io.IOException { return 0; }
- protected void readStreamHeader() throws java.io.IOException, java.io.StreamCorruptedException { }
- public int readUnsignedByte() throws java.io.IOException { return 0; }
- public int readUnsignedShort() throws java.io.IOException { return 0; }
- public java.lang.String readUTF() throws java.io.IOException { return null; }
- public void registerValidation(java.io.ObjectInputValidation var0, int var1) throws java.io.NotActiveException, java.io.InvalidObjectException { }
- protected java.lang.Class resolveClass(java.io.ObjectStreamClass var0) throws java.io.IOException, java.lang.ClassNotFoundException { return null; }
- protected java.lang.Object resolveObject(java.lang.Object var0) throws java.io.IOException { return null; }
- public int skipBytes(int var0) throws java.io.IOException { return 0; }
- public static abstract class GetField {
- public GetField() { }
- public abstract java.io.ObjectStreamClass getObjectStreamClass();
- public abstract boolean defaulted(java.lang.String var0) throws java.io.IOException, java.lang.IllegalArgumentException;
- public abstract boolean get(java.lang.String var0, boolean var1) throws java.io.IOException, java.lang.IllegalArgumentException;
- public abstract char get(java.lang.String var0, char var1) throws java.io.IOException, java.lang.IllegalArgumentException;
- public abstract byte get(java.lang.String var0, byte var1) throws java.io.IOException, java.lang.IllegalArgumentException;
- public abstract short get(java.lang.String var0, short var1) throws java.io.IOException, java.lang.IllegalArgumentException;
- public abstract int get(java.lang.String var0, int var1) throws java.io.IOException, java.lang.IllegalArgumentException;
- public abstract long get(java.lang.String var0, long var1) throws java.io.IOException, java.lang.IllegalArgumentException;
- public abstract float get(java.lang.String var0, float var1) throws java.io.IOException, java.lang.IllegalArgumentException;
- public abstract double get(java.lang.String var0, double var1) throws java.io.IOException, java.lang.IllegalArgumentException;
- public abstract java.lang.Object get(java.lang.String var0, java.lang.Object var1) throws java.io.IOException, java.lang.IllegalArgumentException;
- }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/io/ObjectInputValidation.java b/org.osgi.foundation/src/main/java/java/io/ObjectInputValidation.java
deleted file mode 100644
index 4ed3df7..0000000
--- a/org.osgi.foundation/src/main/java/java/io/ObjectInputValidation.java
+++ /dev/null
@@ -1,24 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/io/ObjectInputValidation.java,v 1.6 2006/03/14 01:20:23 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.io;
-public abstract interface ObjectInputValidation {
- public abstract void validateObject() throws java.io.InvalidObjectException;
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/io/ObjectOutput.java b/org.osgi.foundation/src/main/java/java/io/ObjectOutput.java
deleted file mode 100644
index 6d730a4..0000000
--- a/org.osgi.foundation/src/main/java/java/io/ObjectOutput.java
+++ /dev/null
@@ -1,29 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/io/ObjectOutput.java,v 1.6 2006/03/14 01:20:24 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.io;
-public abstract interface ObjectOutput extends java.io.DataOutput {
- public abstract void close() throws java.io.IOException;
- public abstract void flush() throws java.io.IOException;
- public abstract void write(byte[] var0) throws java.io.IOException;
- public abstract void write(byte[] var0, int var1, int var2) throws java.io.IOException;
- public abstract void write(int var0) throws java.io.IOException;
- public abstract void writeObject(java.lang.Object var0) throws java.io.IOException;
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/io/ObjectOutputStream.java b/org.osgi.foundation/src/main/java/java/io/ObjectOutputStream.java
deleted file mode 100644
index 21511af..0000000
--- a/org.osgi.foundation/src/main/java/java/io/ObjectOutputStream.java
+++ /dev/null
@@ -1,68 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/io/ObjectOutputStream.java,v 1.6 2006/03/14 01:20:23 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.io;
-public class ObjectOutputStream extends java.io.OutputStream implements java.io.ObjectOutput, java.io.ObjectStreamConstants {
- protected ObjectOutputStream() throws java.io.IOException, java.lang.SecurityException { }
- public ObjectOutputStream(java.io.OutputStream var0) throws java.io.IOException { }
- protected void annotateClass(java.lang.Class var0) throws java.io.IOException { }
- protected void annotateProxyClass(java.lang.Class var0) throws java.io.IOException { }
- public void close() throws java.io.IOException { }
- public void defaultWriteObject() throws java.io.IOException { }
- protected void drain() throws java.io.IOException { }
- protected boolean enableReplaceObject(boolean var0) throws java.lang.SecurityException { return false; }
- public void flush() throws java.io.IOException { }
- public java.io.ObjectOutputStream.PutField putFields() throws java.io.IOException { return null; }
- protected java.lang.Object replaceObject(java.lang.Object var0) throws java.io.IOException { return null; }
- public void reset() throws java.io.IOException { }
- public void useProtocolVersion(int var0) throws java.io.IOException { }
- public void write(byte[] var0) throws java.io.IOException { }
- public void write(byte[] var0, int var1, int var2) throws java.io.IOException { }
- public void write(int var0) throws java.io.IOException { }
- public void writeBoolean(boolean var0) throws java.io.IOException { }
- public void writeByte(int var0) throws java.io.IOException { }
- public void writeBytes(java.lang.String var0) throws java.io.IOException { }
- public void writeChar(int var0) throws java.io.IOException { }
- public void writeChars(java.lang.String var0) throws java.io.IOException { }
- public void writeDouble(double var0) throws java.io.IOException { }
- public void writeFields() throws java.io.IOException { }
- public void writeFloat(float var0) throws java.io.IOException { }
- public void writeInt(int var0) throws java.io.IOException { }
- public void writeLong(long var0) throws java.io.IOException { }
- protected void writeClassDescriptor(java.io.ObjectStreamClass var0) throws java.io.IOException { }
- public final void writeObject(java.lang.Object var0) throws java.io.IOException { }
- protected void writeObjectOverride(java.lang.Object var0) throws java.io.IOException { }
- public void writeShort(int var0) throws java.io.IOException { }
- protected void writeStreamHeader() throws java.io.IOException { }
- public void writeUTF(java.lang.String var0) throws java.io.IOException { }
- public static abstract class PutField {
- public PutField() { }
- public abstract void put(java.lang.String var0, boolean var1);
- public abstract void put(java.lang.String var0, char var1);
- public abstract void put(java.lang.String var0, byte var1);
- public abstract void put(java.lang.String var0, short var1);
- public abstract void put(java.lang.String var0, int var1);
- public abstract void put(java.lang.String var0, long var1);
- public abstract void put(java.lang.String var0, float var1);
- public abstract void put(java.lang.String var0, double var1);
- public abstract void put(java.lang.String var0, java.lang.Object var1);
- public abstract void write(java.io.ObjectOutput var0) throws java.io.IOException;
- }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/io/ObjectStreamClass.java b/org.osgi.foundation/src/main/java/java/io/ObjectStreamClass.java
deleted file mode 100644
index a4f7a4a..0000000
--- a/org.osgi.foundation/src/main/java/java/io/ObjectStreamClass.java
+++ /dev/null
@@ -1,32 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/io/ObjectStreamClass.java,v 1.6 2006/03/14 01:20:23 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.io;
-public class ObjectStreamClass implements java.io.Serializable {
- public java.lang.Class forClass() { return null; }
- public java.io.ObjectStreamField getField(java.lang.String var0) { return null; }
- public java.io.ObjectStreamField[] getFields() { return null; }
- public java.lang.String getName() { return null; }
- public long getSerialVersionUID() { return 0l; }
- public static java.io.ObjectStreamClass lookup(java.lang.Class var0) { return null; }
- public java.lang.String toString() { return null; }
- public final static java.io.ObjectStreamField[] NO_FIELDS; static { NO_FIELDS = null; }
- private ObjectStreamClass() { } /* generated constructor to prevent compiler adding default public constructor */
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/io/ObjectStreamConstants.java b/org.osgi.foundation/src/main/java/java/io/ObjectStreamConstants.java
deleted file mode 100644
index a9d66f1..0000000
--- a/org.osgi.foundation/src/main/java/java/io/ObjectStreamConstants.java
+++ /dev/null
@@ -1,50 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/io/ObjectStreamConstants.java,v 1.6 2006/03/14 01:20:23 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.io;
-public abstract interface ObjectStreamConstants {
- public final static short STREAM_MAGIC = -21267;
- public final static short STREAM_VERSION = 5;
- public final static byte TC_BASE = 112;
- public final static byte TC_NULL = 112;
- public final static byte TC_REFERENCE = 113;
- public final static byte TC_CLASSDESC = 114;
- public final static byte TC_OBJECT = 115;
- public final static byte TC_STRING = 116;
- public final static byte TC_ARRAY = 117;
- public final static byte TC_CLASS = 118;
- public final static byte TC_BLOCKDATA = 119;
- public final static byte TC_ENDBLOCKDATA = 120;
- public final static byte TC_RESET = 121;
- public final static byte TC_BLOCKDATALONG = 122;
- public final static byte TC_EXCEPTION = 123;
- public final static byte TC_LONGSTRING = 124;
- public final static byte TC_PROXYCLASSDESC = 125;
- public final static byte TC_MAX = 125;
- public final static int baseWireHandle = 8257536;
- public final static int PROTOCOL_VERSION_1 = 1;
- public final static int PROTOCOL_VERSION_2 = 2;
- public final static java.io.SerializablePermission SUBCLASS_IMPLEMENTATION_PERMISSION = null;
- public final static java.io.SerializablePermission SUBSTITUTION_PERMISSION = null;
- public final static byte SC_WRITE_METHOD = 1;
- public final static byte SC_SERIALIZABLE = 2;
- public final static byte SC_EXTERNALIZABLE = 4;
- public final static byte SC_BLOCK_DATA = 8;
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/io/ObjectStreamException.java b/org.osgi.foundation/src/main/java/java/io/ObjectStreamException.java
deleted file mode 100644
index 4eaa5a5..0000000
--- a/org.osgi.foundation/src/main/java/java/io/ObjectStreamException.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/io/ObjectStreamException.java,v 1.6 2006/03/14 01:20:24 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.io;
-public abstract class ObjectStreamException extends java.io.IOException {
- protected ObjectStreamException() { }
- protected ObjectStreamException(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/io/ObjectStreamField.java b/org.osgi.foundation/src/main/java/java/io/ObjectStreamField.java
deleted file mode 100644
index 13e6442..0000000
--- a/org.osgi.foundation/src/main/java/java/io/ObjectStreamField.java
+++ /dev/null
@@ -1,33 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/io/ObjectStreamField.java,v 1.6 2006/03/14 01:20:23 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.io;
-public class ObjectStreamField implements java.lang.Comparable {
- public ObjectStreamField(java.lang.String var0, java.lang.Class var1) { }
- public int compareTo(java.lang.Object var0) { return 0; }
- public java.lang.String getName() { return null; }
- public int getOffset() { return 0; }
- public java.lang.Class getType() { return null; }
- public char getTypeCode() { return 0; }
- public java.lang.String getTypeString() { return null; }
- public boolean isPrimitive() { return false; }
- protected void setOffset(int var0) { }
- public java.lang.String toString() { return null; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/io/OptionalDataException.java b/org.osgi.foundation/src/main/java/java/io/OptionalDataException.java
deleted file mode 100644
index 5bd20c4..0000000
--- a/org.osgi.foundation/src/main/java/java/io/OptionalDataException.java
+++ /dev/null
@@ -1,26 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/io/OptionalDataException.java,v 1.6 2006/03/14 01:20:23 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.io;
-public class OptionalDataException extends java.io.ObjectStreamException {
- public boolean eof;
- public int length;
- private OptionalDataException() { } /* generated constructor to prevent compiler adding default public constructor */
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/io/OutputStream.java b/org.osgi.foundation/src/main/java/java/io/OutputStream.java
deleted file mode 100644
index 4025797..0000000
--- a/org.osgi.foundation/src/main/java/java/io/OutputStream.java
+++ /dev/null
@@ -1,29 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/io/OutputStream.java,v 1.6 2006/03/14 01:20:23 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.io;
-public abstract class OutputStream {
- public OutputStream() { }
- public void close() throws java.io.IOException { }
- public void flush() throws java.io.IOException { }
- public void write(byte[] var0) throws java.io.IOException { }
- public void write(byte[] var0, int var1, int var2) throws java.io.IOException { }
- public abstract void write(int var0) throws java.io.IOException;
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/io/OutputStreamWriter.java b/org.osgi.foundation/src/main/java/java/io/OutputStreamWriter.java
deleted file mode 100644
index 600cf50..0000000
--- a/org.osgi.foundation/src/main/java/java/io/OutputStreamWriter.java
+++ /dev/null
@@ -1,31 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/io/OutputStreamWriter.java,v 1.6 2006/03/14 01:20:23 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.io;
-public class OutputStreamWriter extends java.io.Writer {
- public OutputStreamWriter(java.io.OutputStream var0) { }
- public OutputStreamWriter(java.io.OutputStream var0, java.lang.String var1) throws java.io.UnsupportedEncodingException { }
- public void close() throws java.io.IOException { }
- public void flush() throws java.io.IOException { }
- public java.lang.String getEncoding() { return null; }
- public void write(char[] var0, int var1, int var2) throws java.io.IOException { }
- public void write(int var0) throws java.io.IOException { }
- public void write(java.lang.String var0, int var1, int var2) throws java.io.IOException { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/io/PipedInputStream.java b/org.osgi.foundation/src/main/java/java/io/PipedInputStream.java
deleted file mode 100644
index 51f5b8c..0000000
--- a/org.osgi.foundation/src/main/java/java/io/PipedInputStream.java
+++ /dev/null
@@ -1,35 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/io/PipedInputStream.java,v 1.6 2006/03/14 01:20:23 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.io;
-public class PipedInputStream extends java.io.InputStream {
- public PipedInputStream() { }
- public PipedInputStream(java.io.PipedOutputStream var0) throws java.io.IOException { }
- public int available() throws java.io.IOException { return 0; }
- public void close() throws java.io.IOException { }
- public void connect(java.io.PipedOutputStream var0) throws java.io.IOException { }
- public int read() throws java.io.IOException { return 0; }
- public int read(byte[] var0, int var1, int var2) throws java.io.IOException { return 0; }
- protected void receive(int var0) throws java.io.IOException { }
- protected byte[] buffer;
- protected int in;
- protected int out;
- protected final static int PIPE_SIZE = 1024;
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/io/PipedOutputStream.java b/org.osgi.foundation/src/main/java/java/io/PipedOutputStream.java
deleted file mode 100644
index 3068bfe..0000000
--- a/org.osgi.foundation/src/main/java/java/io/PipedOutputStream.java
+++ /dev/null
@@ -1,30 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/io/PipedOutputStream.java,v 1.6 2006/03/14 01:20:24 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.io;
-public class PipedOutputStream extends java.io.OutputStream {
- public PipedOutputStream() { }
- public PipedOutputStream(java.io.PipedInputStream var0) throws java.io.IOException { }
- public void close() throws java.io.IOException { }
- public void connect(java.io.PipedInputStream var0) throws java.io.IOException { }
- public void flush() throws java.io.IOException { }
- public void write(byte[] var0, int var1, int var2) throws java.io.IOException { }
- public void write(int var0) throws java.io.IOException { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/io/PipedReader.java b/org.osgi.foundation/src/main/java/java/io/PipedReader.java
deleted file mode 100644
index f089aad..0000000
--- a/org.osgi.foundation/src/main/java/java/io/PipedReader.java
+++ /dev/null
@@ -1,30 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/io/PipedReader.java,v 1.6 2006/03/14 01:20:23 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.io;
-public class PipedReader extends java.io.Reader {
- public PipedReader() { }
- public PipedReader(java.io.PipedWriter var0) throws java.io.IOException { }
- public void close() throws java.io.IOException { }
- public void connect(java.io.PipedWriter var0) throws java.io.IOException { }
- public int read() throws java.io.IOException { return 0; }
- public int read(char[] var0, int var1, int var2) throws java.io.IOException { return 0; }
- public boolean ready() throws java.io.IOException { return false; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/io/PipedWriter.java b/org.osgi.foundation/src/main/java/java/io/PipedWriter.java
deleted file mode 100644
index dd55864..0000000
--- a/org.osgi.foundation/src/main/java/java/io/PipedWriter.java
+++ /dev/null
@@ -1,30 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/io/PipedWriter.java,v 1.6 2006/03/14 01:20:24 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.io;
-public class PipedWriter extends java.io.Writer {
- public PipedWriter() { }
- public PipedWriter(java.io.PipedReader var0) throws java.io.IOException { }
- public void close() throws java.io.IOException { }
- public void connect(java.io.PipedReader var0) throws java.io.IOException { }
- public void flush() throws java.io.IOException { }
- public void write(char[] var0, int var1, int var2) throws java.io.IOException { }
- public void write(int var0) throws java.io.IOException { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/io/PrintStream.java b/org.osgi.foundation/src/main/java/java/io/PrintStream.java
deleted file mode 100644
index 44edd74..0000000
--- a/org.osgi.foundation/src/main/java/java/io/PrintStream.java
+++ /dev/null
@@ -1,50 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/io/PrintStream.java,v 1.6 2006/03/14 01:20:23 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.io;
-public class PrintStream extends java.io.FilterOutputStream {
- public PrintStream(java.io.OutputStream var0) { super((java.io.OutputStream) null); }
- public PrintStream(java.io.OutputStream var0, boolean var1) { super((java.io.OutputStream) null); }
- public boolean checkError() { return false; }
- public void close() { }
- public void flush() { }
- public void print(char[] var0) { }
- public void print(char var0) { }
- public void print(double var0) { }
- public void print(float var0) { }
- public void print(int var0) { }
- public void print(long var0) { }
- public void print(java.lang.Object var0) { }
- public void print(java.lang.String var0) { }
- public void print(boolean var0) { }
- public void println() { }
- public void println(char[] var0) { }
- public void println(char var0) { }
- public void println(double var0) { }
- public void println(float var0) { }
- public void println(int var0) { }
- public void println(long var0) { }
- public void println(java.lang.Object var0) { }
- public void println(java.lang.String var0) { }
- public void println(boolean var0) { }
- protected void setError() { }
- public void write(byte[] var0, int var1, int var2) { }
- public void write(int var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/io/PrintWriter.java b/org.osgi.foundation/src/main/java/java/io/PrintWriter.java
deleted file mode 100644
index 283adfc..0000000
--- a/org.osgi.foundation/src/main/java/java/io/PrintWriter.java
+++ /dev/null
@@ -1,56 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/io/PrintWriter.java,v 1.6 2006/03/14 01:20:23 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.io;
-public class PrintWriter extends java.io.Writer {
- public PrintWriter(java.io.OutputStream var0) { }
- public PrintWriter(java.io.OutputStream var0, boolean var1) { }
- public PrintWriter(java.io.Writer var0) { }
- public PrintWriter(java.io.Writer var0, boolean var1) { }
- public boolean checkError() { return false; }
- public void close() { }
- public void flush() { }
- public void print(char[] var0) { }
- public void print(char var0) { }
- public void print(double var0) { }
- public void print(float var0) { }
- public void print(int var0) { }
- public void print(long var0) { }
- public void print(java.lang.Object var0) { }
- public void print(java.lang.String var0) { }
- public void print(boolean var0) { }
- public void println() { }
- public void println(char[] var0) { }
- public void println(char var0) { }
- public void println(double var0) { }
- public void println(float var0) { }
- public void println(int var0) { }
- public void println(long var0) { }
- public void println(java.lang.Object var0) { }
- public void println(java.lang.String var0) { }
- public void println(boolean var0) { }
- protected void setError() { }
- public void write(char[] var0) { }
- public void write(char[] var0, int var1, int var2) { }
- public void write(int var0) { }
- public void write(java.lang.String var0) { }
- public void write(java.lang.String var0, int var1, int var2) { }
- protected java.io.Writer out;
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/io/PushbackInputStream.java b/org.osgi.foundation/src/main/java/java/io/PushbackInputStream.java
deleted file mode 100644
index d454f83..0000000
--- a/org.osgi.foundation/src/main/java/java/io/PushbackInputStream.java
+++ /dev/null
@@ -1,36 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/io/PushbackInputStream.java,v 1.6 2006/03/14 01:20:23 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.io;
-public class PushbackInputStream extends java.io.FilterInputStream {
- public PushbackInputStream(java.io.InputStream var0) { super((java.io.InputStream) null); }
- public PushbackInputStream(java.io.InputStream var0, int var1) { super((java.io.InputStream) null); }
- public int available() throws java.io.IOException { return 0; }
- public void close() throws java.io.IOException { }
- public boolean markSupported() { return false; }
- public int read() throws java.io.IOException { return 0; }
- public int read(byte[] var0, int var1, int var2) throws java.io.IOException { return 0; }
- public long skip(long var0) throws java.io.IOException { return 0l; }
- public void unread(byte[] var0) throws java.io.IOException { }
- public void unread(byte[] var0, int var1, int var2) throws java.io.IOException { }
- public void unread(int var0) throws java.io.IOException { }
- protected byte[] buf;
- protected int pos;
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/io/PushbackReader.java b/org.osgi.foundation/src/main/java/java/io/PushbackReader.java
deleted file mode 100644
index ce255df..0000000
--- a/org.osgi.foundation/src/main/java/java/io/PushbackReader.java
+++ /dev/null
@@ -1,35 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/io/PushbackReader.java,v 1.6 2006/03/14 01:20:24 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.io;
-public class PushbackReader extends java.io.FilterReader {
- public PushbackReader(java.io.Reader var0) { super((java.io.Reader) null); }
- public PushbackReader(java.io.Reader var0, int var1) { super((java.io.Reader) null); }
- public void close() throws java.io.IOException { }
- public void mark(int var0) throws java.io.IOException { }
- public boolean markSupported() { return false; }
- public int read() throws java.io.IOException { return 0; }
- public int read(char[] var0, int var1, int var2) throws java.io.IOException { return 0; }
- public boolean ready() throws java.io.IOException { return false; }
- public void reset() throws java.io.IOException { }
- public void unread(char[] var0) throws java.io.IOException { }
- public void unread(char[] var0, int var1, int var2) throws java.io.IOException { }
- public void unread(int var0) throws java.io.IOException { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/io/RandomAccessFile.java b/org.osgi.foundation/src/main/java/java/io/RandomAccessFile.java
deleted file mode 100644
index 855c027..0000000
--- a/org.osgi.foundation/src/main/java/java/io/RandomAccessFile.java
+++ /dev/null
@@ -1,63 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/io/RandomAccessFile.java,v 1.6 2006/03/14 01:20:23 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.io;
-public class RandomAccessFile implements java.io.DataInput, java.io.DataOutput {
- public RandomAccessFile(java.io.File var0, java.lang.String var1) throws java.io.FileNotFoundException { }
- public RandomAccessFile(java.lang.String var0, java.lang.String var1) throws java.io.FileNotFoundException { }
- public void close() throws java.io.IOException { }
- public final java.io.FileDescriptor getFD() throws java.io.IOException { return null; }
- public long getFilePointer() throws java.io.IOException { return 0l; }
- public long length() throws java.io.IOException { return 0l; }
- public int read() throws java.io.IOException { return 0; }
- public int read(byte[] var0) throws java.io.IOException { return 0; }
- public int read(byte[] var0, int var1, int var2) throws java.io.IOException { return 0; }
- public final boolean readBoolean() throws java.io.IOException { return false; }
- public final byte readByte() throws java.io.IOException { return 0; }
- public final char readChar() throws java.io.IOException { return 0; }
- public final double readDouble() throws java.io.IOException { return 0.0d; }
- public final float readFloat() throws java.io.IOException { return 0.0f; }
- public final void readFully(byte[] var0) throws java.io.IOException { }
- public final void readFully(byte[] var0, int var1, int var2) throws java.io.IOException { }
- public final int readInt() throws java.io.IOException { return 0; }
- public final java.lang.String readLine() throws java.io.IOException { return null; }
- public final long readLong() throws java.io.IOException { return 0l; }
- public final short readShort() throws java.io.IOException { return 0; }
- public final int readUnsignedByte() throws java.io.IOException { return 0; }
- public final int readUnsignedShort() throws java.io.IOException { return 0; }
- public final java.lang.String readUTF() throws java.io.IOException { return null; }
- public void seek(long var0) throws java.io.IOException { }
- public void setLength(long var0) throws java.io.IOException { }
- public int skipBytes(int var0) throws java.io.IOException { return 0; }
- public void write(byte[] var0) throws java.io.IOException { }
- public void write(byte[] var0, int var1, int var2) throws java.io.IOException { }
- public void write(int var0) throws java.io.IOException { }
- public final void writeBoolean(boolean var0) throws java.io.IOException { }
- public final void writeByte(int var0) throws java.io.IOException { }
- public final void writeBytes(java.lang.String var0) throws java.io.IOException { }
- public final void writeChar(int var0) throws java.io.IOException { }
- public final void writeChars(java.lang.String var0) throws java.io.IOException { }
- public final void writeDouble(double var0) throws java.io.IOException { }
- public final void writeFloat(float var0) throws java.io.IOException { }
- public final void writeInt(int var0) throws java.io.IOException { }
- public final void writeLong(long var0) throws java.io.IOException { }
- public final void writeShort(int var0) throws java.io.IOException { }
- public final void writeUTF(java.lang.String var0) throws java.io.IOException { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/io/Reader.java b/org.osgi.foundation/src/main/java/java/io/Reader.java
deleted file mode 100644
index 0b6eb0d..0000000
--- a/org.osgi.foundation/src/main/java/java/io/Reader.java
+++ /dev/null
@@ -1,35 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/io/Reader.java,v 1.6 2006/03/14 01:20:23 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.io;
-public abstract class Reader {
- protected Reader() { }
- protected Reader(java.lang.Object var0) { }
- public abstract void close() throws java.io.IOException;
- public void mark(int var0) throws java.io.IOException { }
- public boolean markSupported() { return false; }
- public int read() throws java.io.IOException { return 0; }
- public int read(char[] var0) throws java.io.IOException { return 0; }
- public abstract int read(char[] var0, int var1, int var2) throws java.io.IOException;
- public boolean ready() throws java.io.IOException { return false; }
- public void reset() throws java.io.IOException { }
- public long skip(long var0) throws java.io.IOException { return 0l; }
- protected java.lang.Object lock;
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/io/SequenceInputStream.java b/org.osgi.foundation/src/main/java/java/io/SequenceInputStream.java
deleted file mode 100644
index 0114050..0000000
--- a/org.osgi.foundation/src/main/java/java/io/SequenceInputStream.java
+++ /dev/null
@@ -1,29 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/io/SequenceInputStream.java,v 1.6 2006/03/14 01:20:23 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.io;
-public class SequenceInputStream extends java.io.InputStream {
- public SequenceInputStream(java.io.InputStream var0, java.io.InputStream var1) { }
- public SequenceInputStream(java.util.Enumeration var0) { }
- public int available() throws java.io.IOException { return 0; }
- public void close() throws java.io.IOException { }
- public int read() throws java.io.IOException { return 0; }
- public int read(byte[] var0, int var1, int var2) throws java.io.IOException { return 0; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/io/Serializable.java b/org.osgi.foundation/src/main/java/java/io/Serializable.java
deleted file mode 100644
index b793567..0000000
--- a/org.osgi.foundation/src/main/java/java/io/Serializable.java
+++ /dev/null
@@ -1,23 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/io/Serializable.java,v 1.6 2006/03/14 01:20:23 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.io;
-public abstract interface Serializable {
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/io/SerializablePermission.java b/org.osgi.foundation/src/main/java/java/io/SerializablePermission.java
deleted file mode 100644
index 3ad47e4..0000000
--- a/org.osgi.foundation/src/main/java/java/io/SerializablePermission.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/io/SerializablePermission.java,v 1.6 2006/03/14 01:20:23 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.io;
-public final class SerializablePermission extends java.security.BasicPermission {
- public SerializablePermission(java.lang.String var0) { super((java.lang.String) null, (java.lang.String) null); }
- public SerializablePermission(java.lang.String var0, java.lang.String var1) { super((java.lang.String) null, (java.lang.String) null); }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/io/StreamCorruptedException.java b/org.osgi.foundation/src/main/java/java/io/StreamCorruptedException.java
deleted file mode 100644
index ced6cc6..0000000
--- a/org.osgi.foundation/src/main/java/java/io/StreamCorruptedException.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/io/StreamCorruptedException.java,v 1.6 2006/03/14 01:20:23 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.io;
-public class StreamCorruptedException extends java.io.ObjectStreamException {
- public StreamCorruptedException() { }
- public StreamCorruptedException(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/io/StreamTokenizer.java b/org.osgi.foundation/src/main/java/java/io/StreamTokenizer.java
deleted file mode 100644
index 37cf7a3..0000000
--- a/org.osgi.foundation/src/main/java/java/io/StreamTokenizer.java
+++ /dev/null
@@ -1,47 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/io/StreamTokenizer.java,v 1.6 2006/03/14 01:20:23 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.io;
-public class StreamTokenizer {
- public StreamTokenizer(java.io.Reader var0) { }
- public void commentChar(int var0) { }
- public void eolIsSignificant(boolean var0) { }
- public int lineno() { return 0; }
- public void lowerCaseMode(boolean var0) { }
- public int nextToken() throws java.io.IOException { return 0; }
- public void ordinaryChar(int var0) { }
- public void ordinaryChars(int var0, int var1) { }
- public void parseNumbers() { }
- public void pushBack() { }
- public void quoteChar(int var0) { }
- public void resetSyntax() { }
- public void slashSlashComments(boolean var0) { }
- public void slashStarComments(boolean var0) { }
- public java.lang.String toString() { return null; }
- public void whitespaceChars(int var0, int var1) { }
- public void wordChars(int var0, int var1) { }
- public double nval;
- public java.lang.String sval;
- public final static int TT_EOF = -1;
- public final static int TT_EOL = 10;
- public final static int TT_NUMBER = -2;
- public final static int TT_WORD = -3;
- public int ttype;
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/io/StringReader.java b/org.osgi.foundation/src/main/java/java/io/StringReader.java
deleted file mode 100644
index 3ae77ec..0000000
--- a/org.osgi.foundation/src/main/java/java/io/StringReader.java
+++ /dev/null
@@ -1,32 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/io/StringReader.java,v 1.6 2006/03/14 01:20:24 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.io;
-public class StringReader extends java.io.Reader {
- public StringReader(java.lang.String var0) { }
- public void close() { }
- public void mark(int var0) throws java.io.IOException { }
- public boolean markSupported() { return false; }
- public int read() throws java.io.IOException { return 0; }
- public int read(char[] var0, int var1, int var2) throws java.io.IOException { return 0; }
- public boolean ready() throws java.io.IOException { return false; }
- public void reset() throws java.io.IOException { }
- public long skip(long var0) throws java.io.IOException { return 0l; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/io/StringWriter.java b/org.osgi.foundation/src/main/java/java/io/StringWriter.java
deleted file mode 100644
index 1ec1f7d..0000000
--- a/org.osgi.foundation/src/main/java/java/io/StringWriter.java
+++ /dev/null
@@ -1,33 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/io/StringWriter.java,v 1.6 2006/03/14 01:20:23 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.io;
-public class StringWriter extends java.io.Writer {
- public StringWriter() { }
- public StringWriter(int var0) { }
- public void close() throws java.io.IOException { }
- public void flush() { }
- public java.lang.StringBuffer getBuffer() { return null; }
- public java.lang.String toString() { return null; }
- public void write(char[] var0, int var1, int var2) { }
- public void write(int var0) { }
- public void write(java.lang.String var0) { }
- public void write(java.lang.String var0, int var1, int var2) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/io/SyncFailedException.java b/org.osgi.foundation/src/main/java/java/io/SyncFailedException.java
deleted file mode 100644
index f49894d..0000000
--- a/org.osgi.foundation/src/main/java/java/io/SyncFailedException.java
+++ /dev/null
@@ -1,24 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/io/SyncFailedException.java,v 1.6 2006/03/14 01:20:24 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.io;
-public class SyncFailedException extends java.io.IOException {
- public SyncFailedException(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/io/UTFDataFormatException.java b/org.osgi.foundation/src/main/java/java/io/UTFDataFormatException.java
deleted file mode 100644
index 69a1a70..0000000
--- a/org.osgi.foundation/src/main/java/java/io/UTFDataFormatException.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/io/UTFDataFormatException.java,v 1.6 2006/03/14 01:20:23 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.io;
-public class UTFDataFormatException extends java.io.IOException {
- public UTFDataFormatException() { }
- public UTFDataFormatException(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/io/UnsupportedEncodingException.java b/org.osgi.foundation/src/main/java/java/io/UnsupportedEncodingException.java
deleted file mode 100644
index 36d4088..0000000
--- a/org.osgi.foundation/src/main/java/java/io/UnsupportedEncodingException.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/io/UnsupportedEncodingException.java,v 1.6 2006/03/14 01:20:23 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.io;
-public class UnsupportedEncodingException extends java.io.IOException {
- public UnsupportedEncodingException() { }
- public UnsupportedEncodingException(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/io/WriteAbortedException.java b/org.osgi.foundation/src/main/java/java/io/WriteAbortedException.java
deleted file mode 100644
index beae4cb..0000000
--- a/org.osgi.foundation/src/main/java/java/io/WriteAbortedException.java
+++ /dev/null
@@ -1,26 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/io/WriteAbortedException.java,v 1.6 2006/03/14 01:20:24 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.io;
-public class WriteAbortedException extends java.io.ObjectStreamException {
- public WriteAbortedException(java.lang.String var0, java.lang.Exception var1) { }
- public java.lang.String getMessage() { return null; }
- public java.lang.Exception detail;
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/io/Writer.java b/org.osgi.foundation/src/main/java/java/io/Writer.java
deleted file mode 100644
index fb84a17..0000000
--- a/org.osgi.foundation/src/main/java/java/io/Writer.java
+++ /dev/null
@@ -1,33 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/io/Writer.java,v 1.6 2006/03/14 01:20:24 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.io;
-public abstract class Writer {
- protected Writer() { }
- protected Writer(java.lang.Object var0) { }
- public abstract void close() throws java.io.IOException;
- public abstract void flush() throws java.io.IOException;
- public void write(char[] var0) throws java.io.IOException { }
- public abstract void write(char[] var0, int var1, int var2) throws java.io.IOException;
- public void write(int var0) throws java.io.IOException { }
- public void write(java.lang.String var0) throws java.io.IOException { }
- public void write(java.lang.String var0, int var1, int var2) throws java.io.IOException { }
- protected java.lang.Object lock;
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/AbstractMethodError.java b/org.osgi.foundation/src/main/java/java/lang/AbstractMethodError.java
deleted file mode 100644
index 1fb1f40..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/AbstractMethodError.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/AbstractMethodError.java,v 1.6 2006/03/14 01:20:24 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang;
-public class AbstractMethodError extends java.lang.IncompatibleClassChangeError {
- public AbstractMethodError() { }
- public AbstractMethodError(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/ArithmeticException.java b/org.osgi.foundation/src/main/java/java/lang/ArithmeticException.java
deleted file mode 100644
index e2d09eb..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/ArithmeticException.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/ArithmeticException.java,v 1.6 2006/03/14 01:20:25 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang;
-public class ArithmeticException extends java.lang.RuntimeException {
- public ArithmeticException() { }
- public ArithmeticException(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/ArrayIndexOutOfBoundsException.java b/org.osgi.foundation/src/main/java/java/lang/ArrayIndexOutOfBoundsException.java
deleted file mode 100644
index c321d91..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/ArrayIndexOutOfBoundsException.java
+++ /dev/null
@@ -1,26 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/ArrayIndexOutOfBoundsException.java,v 1.6 2006/03/14 01:20:25 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang;
-public class ArrayIndexOutOfBoundsException extends java.lang.IndexOutOfBoundsException {
- public ArrayIndexOutOfBoundsException() { }
- public ArrayIndexOutOfBoundsException(int var0) { }
- public ArrayIndexOutOfBoundsException(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/ArrayStoreException.java b/org.osgi.foundation/src/main/java/java/lang/ArrayStoreException.java
deleted file mode 100644
index b63d6f1..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/ArrayStoreException.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/ArrayStoreException.java,v 1.6 2006/03/14 01:20:25 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang;
-public class ArrayStoreException extends java.lang.RuntimeException {
- public ArrayStoreException() { }
- public ArrayStoreException(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/Boolean.java b/org.osgi.foundation/src/main/java/java/lang/Boolean.java
deleted file mode 100644
index 927ce56..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/Boolean.java
+++ /dev/null
@@ -1,34 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/Boolean.java,v 1.6 2006/03/14 01:20:24 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang;
-public final class Boolean implements java.io.Serializable {
- public Boolean(java.lang.String var0) { }
- public Boolean(boolean var0) { }
- public boolean booleanValue() { return false; }
- public boolean equals(java.lang.Object var0) { return false; }
- public static boolean getBoolean(java.lang.String var0) { return false; }
- public int hashCode() { return 0; }
- public java.lang.String toString() { return null; }
- public static java.lang.Boolean valueOf(java.lang.String var0) { return null; }
- public final static java.lang.Class TYPE; static { TYPE = null; }
- public final static java.lang.Boolean TRUE; static { TRUE = null; }
- public final static java.lang.Boolean FALSE; static { FALSE = null; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/Byte.java b/org.osgi.foundation/src/main/java/java/lang/Byte.java
deleted file mode 100644
index 839e5bc..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/Byte.java
+++ /dev/null
@@ -1,45 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/Byte.java,v 1.6 2006/03/14 01:20:25 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang;
-public final class Byte extends java.lang.Number implements java.lang.Comparable {
- public Byte(byte var0) { }
- public Byte(java.lang.String var0) throws java.lang.NumberFormatException { }
- public byte byteValue() { return 0; }
- public int compareTo(java.lang.Byte var0) { return 0; }
- public int compareTo(java.lang.Object var0) { return 0; }
- public static java.lang.Byte decode(java.lang.String var0) throws java.lang.NumberFormatException { return null; }
- public double doubleValue() { return 0.0d; }
- public boolean equals(java.lang.Object var0) { return false; }
- public float floatValue() { return 0.0f; }
- public int hashCode() { return 0; }
- public int intValue() { return 0; }
- public long longValue() { return 0l; }
- public static byte parseByte(java.lang.String var0) throws java.lang.NumberFormatException { return 0; }
- public static byte parseByte(java.lang.String var0, int var1) throws java.lang.NumberFormatException { return 0; }
- public short shortValue() { return 0; }
- public java.lang.String toString() { return null; }
- public static java.lang.String toString(byte var0) { return null; }
- public static java.lang.Byte valueOf(java.lang.String var0) throws java.lang.NumberFormatException { return null; }
- public static java.lang.Byte valueOf(java.lang.String var0, int var1) throws java.lang.NumberFormatException { return null; }
- public final static byte MAX_VALUE = 127;
- public final static byte MIN_VALUE = -128;
- public final static java.lang.Class TYPE; static { TYPE = null; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/Character.java b/org.osgi.foundation/src/main/java/java/lang/Character.java
deleted file mode 100644
index ae4b76d..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/Character.java
+++ /dev/null
@@ -1,161 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/Character.java,v 1.6 2006/03/14 01:20:24 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang;
-public final class Character implements java.io.Serializable, java.lang.Comparable {
- public Character(char var0) { }
- public char charValue() { return 0; }
- public int compareTo(java.lang.Character var0) { return 0; }
- public int compareTo(java.lang.Object var0) { return 0; }
- public static int digit(char var0, int var1) { return 0; }
- public boolean equals(java.lang.Object var0) { return false; }
- public static char forDigit(int var0, int var1) { return 0; }
- public static int getNumericValue(char var0) { return 0; }
- public static int getType(char var0) { return 0; }
- public int hashCode() { return 0; }
- public static boolean isDefined(char var0) { return false; }
- public static boolean isDigit(char var0) { return false; }
- public static boolean isIdentifierIgnorable(char var0) { return false; }
- public static boolean isISOControl(char var0) { return false; }
- public static boolean isJavaIdentifierPart(char var0) { return false; }
- public static boolean isJavaIdentifierStart(char var0) { return false; }
- public static boolean isLetter(char var0) { return false; }
- public static boolean isLetterOrDigit(char var0) { return false; }
- public static boolean isLowerCase(char var0) { return false; }
- public static boolean isSpaceChar(char var0) { return false; }
- public static boolean isTitleCase(char var0) { return false; }
- public static boolean isUnicodeIdentifierPart(char var0) { return false; }
- public static boolean isUnicodeIdentifierStart(char var0) { return false; }
- public static boolean isUpperCase(char var0) { return false; }
- public static boolean isWhitespace(char var0) { return false; }
- public static char toLowerCase(char var0) { return 0; }
- public java.lang.String toString() { return null; }
- public static char toTitleCase(char var0) { return 0; }
- public static char toUpperCase(char var0) { return 0; }
- public final static char MIN_VALUE = 0;
- public final static char MAX_VALUE = 65535;
- public final static int MIN_RADIX = 2;
- public final static int MAX_RADIX = 36;
- public final static java.lang.Class TYPE; static { TYPE = null; }
- public final static byte UNASSIGNED = 0;
- public final static byte UPPERCASE_LETTER = 1;
- public final static byte LOWERCASE_LETTER = 2;
- public final static byte TITLECASE_LETTER = 3;
- public final static byte MODIFIER_LETTER = 4;
- public final static byte OTHER_LETTER = 5;
- public final static byte NON_SPACING_MARK = 6;
- public final static byte ENCLOSING_MARK = 7;
- public final static byte COMBINING_SPACING_MARK = 8;
- public final static byte DECIMAL_DIGIT_NUMBER = 9;
- public final static byte LETTER_NUMBER = 10;
- public final static byte OTHER_NUMBER = 11;
- public final static byte SPACE_SEPARATOR = 12;
- public final static byte LINE_SEPARATOR = 13;
- public final static byte PARAGRAPH_SEPARATOR = 14;
- public final static byte CONTROL = 15;
- public final static byte FORMAT = 16;
- public final static byte PRIVATE_USE = 18;
- public final static byte SURROGATE = 19;
- public final static byte DASH_PUNCTUATION = 20;
- public final static byte START_PUNCTUATION = 21;
- public final static byte END_PUNCTUATION = 22;
- public final static byte CONNECTOR_PUNCTUATION = 23;
- public final static byte OTHER_PUNCTUATION = 24;
- public final static byte MATH_SYMBOL = 25;
- public final static byte CURRENCY_SYMBOL = 26;
- public final static byte MODIFIER_SYMBOL = 27;
- public final static byte OTHER_SYMBOL = 28;
- public static class Subset {
- protected Subset(java.lang.String var0) { }
- public final boolean equals(java.lang.Object var0) { return false; }
- public final int hashCode() { return 0; }
- public final java.lang.String toString() { return null; }
- }
- public static final class UnicodeBlock extends java.lang.Character.Subset {
- public static java.lang.Character.UnicodeBlock of(char var0) { return null; }
- public final static java.lang.Character.UnicodeBlock ALPHABETIC_PRESENTATION_FORMS; static { ALPHABETIC_PRESENTATION_FORMS = null; }
- public final static java.lang.Character.UnicodeBlock ARABIC; static { ARABIC = null; }
- public final static java.lang.Character.UnicodeBlock ARABIC_PRESENTATION_FORMS_A; static { ARABIC_PRESENTATION_FORMS_A = null; }
- public final static java.lang.Character.UnicodeBlock ARABIC_PRESENTATION_FORMS_B; static { ARABIC_PRESENTATION_FORMS_B = null; }
- public final static java.lang.Character.UnicodeBlock ARMENIAN; static { ARMENIAN = null; }
- public final static java.lang.Character.UnicodeBlock ARROWS; static { ARROWS = null; }
- public final static java.lang.Character.UnicodeBlock BASIC_LATIN; static { BASIC_LATIN = null; }
- public final static java.lang.Character.UnicodeBlock BENGALI; static { BENGALI = null; }
- public final static java.lang.Character.UnicodeBlock BLOCK_ELEMENTS; static { BLOCK_ELEMENTS = null; }
- public final static java.lang.Character.UnicodeBlock BOPOMOFO; static { BOPOMOFO = null; }
- public final static java.lang.Character.UnicodeBlock BOX_DRAWING; static { BOX_DRAWING = null; }
- public final static java.lang.Character.UnicodeBlock CJK_COMPATIBILITY; static { CJK_COMPATIBILITY = null; }
- public final static java.lang.Character.UnicodeBlock CJK_COMPATIBILITY_FORMS; static { CJK_COMPATIBILITY_FORMS = null; }
- public final static java.lang.Character.UnicodeBlock CJK_COMPATIBILITY_IDEOGRAPHS; static { CJK_COMPATIBILITY_IDEOGRAPHS = null; }
- public final static java.lang.Character.UnicodeBlock CJK_SYMBOLS_AND_PUNCTUATION; static { CJK_SYMBOLS_AND_PUNCTUATION = null; }
- public final static java.lang.Character.UnicodeBlock CJK_UNIFIED_IDEOGRAPHS; static { CJK_UNIFIED_IDEOGRAPHS = null; }
- public final static java.lang.Character.UnicodeBlock COMBINING_DIACRITICAL_MARKS; static { COMBINING_DIACRITICAL_MARKS = null; }
- public final static java.lang.Character.UnicodeBlock COMBINING_HALF_MARKS; static { COMBINING_HALF_MARKS = null; }
- public final static java.lang.Character.UnicodeBlock COMBINING_MARKS_FOR_SYMBOLS; static { COMBINING_MARKS_FOR_SYMBOLS = null; }
- public final static java.lang.Character.UnicodeBlock CONTROL_PICTURES; static { CONTROL_PICTURES = null; }
- public final static java.lang.Character.UnicodeBlock CURRENCY_SYMBOLS; static { CURRENCY_SYMBOLS = null; }
- public final static java.lang.Character.UnicodeBlock CYRILLIC; static { CYRILLIC = null; }
- public final static java.lang.Character.UnicodeBlock DEVANAGARI; static { DEVANAGARI = null; }
- public final static java.lang.Character.UnicodeBlock DINGBATS; static { DINGBATS = null; }
- public final static java.lang.Character.UnicodeBlock ENCLOSED_ALPHANUMERICS; static { ENCLOSED_ALPHANUMERICS = null; }
- public final static java.lang.Character.UnicodeBlock ENCLOSED_CJK_LETTERS_AND_MONTHS; static { ENCLOSED_CJK_LETTERS_AND_MONTHS = null; }
- public final static java.lang.Character.UnicodeBlock GENERAL_PUNCTUATION; static { GENERAL_PUNCTUATION = null; }
- public final static java.lang.Character.UnicodeBlock GEOMETRIC_SHAPES; static { GEOMETRIC_SHAPES = null; }
- public final static java.lang.Character.UnicodeBlock GEORGIAN; static { GEORGIAN = null; }
- public final static java.lang.Character.UnicodeBlock GREEK; static { GREEK = null; }
- public final static java.lang.Character.UnicodeBlock GREEK_EXTENDED; static { GREEK_EXTENDED = null; }
- public final static java.lang.Character.UnicodeBlock GUJARATI; static { GUJARATI = null; }
- public final static java.lang.Character.UnicodeBlock GURMUKHI; static { GURMUKHI = null; }
- public final static java.lang.Character.UnicodeBlock HALFWIDTH_AND_FULLWIDTH_FORMS; static { HALFWIDTH_AND_FULLWIDTH_FORMS = null; }
- public final static java.lang.Character.UnicodeBlock HANGUL_COMPATIBILITY_JAMO; static { HANGUL_COMPATIBILITY_JAMO = null; }
- public final static java.lang.Character.UnicodeBlock HANGUL_JAMO; static { HANGUL_JAMO = null; }
- public final static java.lang.Character.UnicodeBlock HANGUL_SYLLABLES; static { HANGUL_SYLLABLES = null; }
- public final static java.lang.Character.UnicodeBlock HEBREW; static { HEBREW = null; }
- public final static java.lang.Character.UnicodeBlock HIRAGANA; static { HIRAGANA = null; }
- public final static java.lang.Character.UnicodeBlock IPA_EXTENSIONS; static { IPA_EXTENSIONS = null; }
- public final static java.lang.Character.UnicodeBlock KANBUN; static { KANBUN = null; }
- public final static java.lang.Character.UnicodeBlock KANNADA; static { KANNADA = null; }
- public final static java.lang.Character.UnicodeBlock KATAKANA; static { KATAKANA = null; }
- public final static java.lang.Character.UnicodeBlock LAO; static { LAO = null; }
- public final static java.lang.Character.UnicodeBlock LATIN_1_SUPPLEMENT; static { LATIN_1_SUPPLEMENT = null; }
- public final static java.lang.Character.UnicodeBlock LATIN_EXTENDED_A; static { LATIN_EXTENDED_A = null; }
- public final static java.lang.Character.UnicodeBlock LATIN_EXTENDED_ADDITIONAL; static { LATIN_EXTENDED_ADDITIONAL = null; }
- public final static java.lang.Character.UnicodeBlock LATIN_EXTENDED_B; static { LATIN_EXTENDED_B = null; }
- public final static java.lang.Character.UnicodeBlock LETTERLIKE_SYMBOLS; static { LETTERLIKE_SYMBOLS = null; }
- public final static java.lang.Character.UnicodeBlock MALAYALAM; static { MALAYALAM = null; }
- public final static java.lang.Character.UnicodeBlock MATHEMATICAL_OPERATORS; static { MATHEMATICAL_OPERATORS = null; }
- public final static java.lang.Character.UnicodeBlock MISCELLANEOUS_SYMBOLS; static { MISCELLANEOUS_SYMBOLS = null; }
- public final static java.lang.Character.UnicodeBlock MISCELLANEOUS_TECHNICAL; static { MISCELLANEOUS_TECHNICAL = null; }
- public final static java.lang.Character.UnicodeBlock NUMBER_FORMS; static { NUMBER_FORMS = null; }
- public final static java.lang.Character.UnicodeBlock OPTICAL_CHARACTER_RECOGNITION; static { OPTICAL_CHARACTER_RECOGNITION = null; }
- public final static java.lang.Character.UnicodeBlock ORIYA; static { ORIYA = null; }
- public final static java.lang.Character.UnicodeBlock PRIVATE_USE_AREA; static { PRIVATE_USE_AREA = null; }
- public final static java.lang.Character.UnicodeBlock SMALL_FORM_VARIANTS; static { SMALL_FORM_VARIANTS = null; }
- public final static java.lang.Character.UnicodeBlock SPACING_MODIFIER_LETTERS; static { SPACING_MODIFIER_LETTERS = null; }
- public final static java.lang.Character.UnicodeBlock SPECIALS; static { SPECIALS = null; }
- public final static java.lang.Character.UnicodeBlock SUPERSCRIPTS_AND_SUBSCRIPTS; static { SUPERSCRIPTS_AND_SUBSCRIPTS = null; }
- public final static java.lang.Character.UnicodeBlock SURROGATES_AREA; static { SURROGATES_AREA = null; }
- public final static java.lang.Character.UnicodeBlock TAMIL; static { TAMIL = null; }
- public final static java.lang.Character.UnicodeBlock TELUGU; static { TELUGU = null; }
- public final static java.lang.Character.UnicodeBlock THAI; static { THAI = null; }
- public final static java.lang.Character.UnicodeBlock TIBETAN; static { TIBETAN = null; }
- private UnicodeBlock() { super((java.lang.String) null); } /* generated constructor to prevent compiler adding default public constructor */
- }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/Class.java b/org.osgi.foundation/src/main/java/java/lang/Class.java
deleted file mode 100644
index 24a673a..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/Class.java
+++ /dev/null
@@ -1,59 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/Class.java,v 1.6 2006/03/14 01:20:25 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang;
-public final class Class implements java.io.Serializable {
- public static java.lang.Class forName(java.lang.String var0) throws java.lang.ClassNotFoundException { return null; }
- public static java.lang.Class forName(java.lang.String var0, boolean var1, java.lang.ClassLoader var2) throws java.lang.ClassNotFoundException { return null; }
- public java.lang.Class[] getClasses() { return null; }
- public java.lang.ClassLoader getClassLoader() { return null; }
- public java.lang.Class getComponentType() { return null; }
- public java.lang.reflect.Constructor getConstructor(java.lang.Class[] var0) throws java.lang.NoSuchMethodException, java.lang.SecurityException { return null; }
- public java.lang.reflect.Constructor[] getConstructors() throws java.lang.SecurityException { return null; }
- public java.lang.Class[] getDeclaredClasses() throws java.lang.SecurityException { return null; }
- public java.lang.reflect.Constructor getDeclaredConstructor(java.lang.Class[] var0) throws java.lang.NoSuchMethodException, java.lang.SecurityException { return null; }
- public java.lang.reflect.Constructor[] getDeclaredConstructors() throws java.lang.SecurityException { return null; }
- public java.lang.reflect.Field getDeclaredField(java.lang.String var0) throws java.lang.NoSuchFieldException, java.lang.SecurityException { return null; }
- public java.lang.reflect.Field[] getDeclaredFields() throws java.lang.SecurityException { return null; }
- public java.lang.reflect.Method getDeclaredMethod(java.lang.String var0, java.lang.Class[] var1) throws java.lang.NoSuchMethodException, java.lang.SecurityException { return null; }
- public java.lang.reflect.Method[] getDeclaredMethods() throws java.lang.SecurityException { return null; }
- public java.lang.Class getDeclaringClass() { return null; }
- public java.lang.reflect.Field getField(java.lang.String var0) throws java.lang.NoSuchFieldException, java.lang.SecurityException { return null; }
- public java.lang.reflect.Field[] getFields() throws java.lang.SecurityException { return null; }
- public java.lang.Class[] getInterfaces() { return null; }
- public java.lang.reflect.Method getMethod(java.lang.String var0, java.lang.Class[] var1) throws java.lang.NoSuchMethodException, java.lang.SecurityException { return null; }
- public java.lang.reflect.Method[] getMethods() throws java.lang.SecurityException { return null; }
- public int getModifiers() { return 0; }
- public java.lang.String getName() { return null; }
- public java.security.ProtectionDomain getProtectionDomain() { return null; }
- public java.net.URL getResource(java.lang.String var0) { return null; }
- public java.io.InputStream getResourceAsStream(java.lang.String var0) { return null; }
- public java.lang.Object[] getSigners() { return null; }
- public java.lang.Class getSuperclass() { return null; }
- public boolean isArray() { return false; }
- public boolean isAssignableFrom(java.lang.Class var0) { return false; }
- public boolean isInstance(java.lang.Object var0) { return false; }
- public boolean isInterface() { return false; }
- public boolean isPrimitive() { return false; }
- public java.lang.Object newInstance() throws java.lang.IllegalAccessException, java.lang.InstantiationException { return null; }
- public java.lang.String toString() { return null; }
- public java.lang.Package getPackage() { return null; }
- private Class() { } /* generated constructor to prevent compiler adding default public constructor */
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/ClassCastException.java b/org.osgi.foundation/src/main/java/java/lang/ClassCastException.java
deleted file mode 100644
index d6659e8..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/ClassCastException.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/ClassCastException.java,v 1.6 2006/03/14 01:20:25 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang;
-public class ClassCastException extends java.lang.RuntimeException {
- public ClassCastException() { }
- public ClassCastException(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/ClassCircularityError.java b/org.osgi.foundation/src/main/java/java/lang/ClassCircularityError.java
deleted file mode 100644
index 3f78885..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/ClassCircularityError.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/ClassCircularityError.java,v 1.6 2006/03/14 01:20:24 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang;
-public class ClassCircularityError extends java.lang.LinkageError {
- public ClassCircularityError() { }
- public ClassCircularityError(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/ClassFormatError.java b/org.osgi.foundation/src/main/java/java/lang/ClassFormatError.java
deleted file mode 100644
index e52b55b..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/ClassFormatError.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/ClassFormatError.java,v 1.6 2006/03/14 01:20:24 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang;
-public class ClassFormatError extends java.lang.LinkageError {
- public ClassFormatError() { }
- public ClassFormatError(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/ClassLoader.java b/org.osgi.foundation/src/main/java/java/lang/ClassLoader.java
deleted file mode 100644
index f420882..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/ClassLoader.java
+++ /dev/null
@@ -1,48 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/ClassLoader.java,v 1.6 2006/03/14 01:20:24 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang;
-public abstract class ClassLoader {
- protected ClassLoader() { }
- protected ClassLoader(java.lang.ClassLoader var0) { }
- protected final java.lang.Class defineClass(java.lang.String var0, byte[] var1, int var2, int var3) throws java.lang.ClassFormatError { return null; }
- protected final java.lang.Class defineClass(java.lang.String var0, byte[] var1, int var2, int var3, java.security.ProtectionDomain var4) throws java.lang.ClassFormatError { return null; }
- protected java.lang.Class findClass(java.lang.String var0) throws java.lang.ClassNotFoundException { return null; }
- protected final java.lang.Class findLoadedClass(java.lang.String var0) { return null; }
- protected final java.lang.Class findSystemClass(java.lang.String var0) throws java.lang.ClassNotFoundException { return null; }
- public final java.lang.ClassLoader getParent() { return null; }
- public java.net.URL getResource(java.lang.String var0) { return null; }
- public final java.util.Enumeration getResources(java.lang.String var0) throws java.io.IOException { return null; }
- public java.io.InputStream getResourceAsStream(java.lang.String var0) { return null; }
- public static java.lang.ClassLoader getSystemClassLoader() { return null; }
- public static java.net.URL getSystemResource(java.lang.String var0) { return null; }
- public static java.util.Enumeration getSystemResources(java.lang.String var0) throws java.io.IOException { return null; }
- public static java.io.InputStream getSystemResourceAsStream(java.lang.String var0) { return null; }
- public java.lang.Class loadClass(java.lang.String var0) throws java.lang.ClassNotFoundException { return null; }
- protected java.lang.Class loadClass(java.lang.String var0, boolean var1) throws java.lang.ClassNotFoundException { return null; }
- protected final void resolveClass(java.lang.Class var0) { }
- protected java.net.URL findResource(java.lang.String var0) { return null; }
- protected java.util.Enumeration findResources(java.lang.String var0) throws java.io.IOException { return null; }
- protected java.lang.String findLibrary(java.lang.String var0) { return null; }
- protected java.lang.Package getPackage(java.lang.String var0) { return null; }
- protected java.lang.Package[] getPackages() { return null; }
- protected java.lang.Package definePackage(java.lang.String var0, java.lang.String var1, java.lang.String var2, java.lang.String var3, java.lang.String var4, java.lang.String var5, java.lang.String var6, java.net.URL var7) throws java.lang.IllegalArgumentException { return null; }
- protected final void setSigners(java.lang.Class var0, java.lang.Object[] var1) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/ClassNotFoundException.java b/org.osgi.foundation/src/main/java/java/lang/ClassNotFoundException.java
deleted file mode 100644
index b65b005..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/ClassNotFoundException.java
+++ /dev/null
@@ -1,30 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/ClassNotFoundException.java,v 1.6 2006/03/14 01:20:25 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang;
-public class ClassNotFoundException extends java.lang.Exception {
- public ClassNotFoundException() { }
- public ClassNotFoundException(java.lang.String var0) { }
- public ClassNotFoundException(java.lang.String var0, java.lang.Throwable var1) { }
- public java.lang.Throwable getException() { return null; }
- public void printStackTrace() { }
- public void printStackTrace(java.io.PrintStream var0) { }
- public void printStackTrace(java.io.PrintWriter var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/CloneNotSupportedException.java b/org.osgi.foundation/src/main/java/java/lang/CloneNotSupportedException.java
deleted file mode 100644
index b311495..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/CloneNotSupportedException.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/CloneNotSupportedException.java,v 1.6 2006/03/14 01:20:25 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang;
-public class CloneNotSupportedException extends java.lang.Exception {
- public CloneNotSupportedException() { }
- public CloneNotSupportedException(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/Cloneable.java b/org.osgi.foundation/src/main/java/java/lang/Cloneable.java
deleted file mode 100644
index f95435b..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/Cloneable.java
+++ /dev/null
@@ -1,23 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/Cloneable.java,v 1.6 2006/03/14 01:20:25 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang;
-public abstract interface Cloneable {
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/Comparable.java b/org.osgi.foundation/src/main/java/java/lang/Comparable.java
deleted file mode 100644
index 209ab97..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/Comparable.java
+++ /dev/null
@@ -1,24 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/Comparable.java,v 1.6 2006/03/14 01:20:24 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang;
-public abstract interface Comparable {
- public abstract int compareTo(java.lang.Object var0);
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/Compiler.java b/org.osgi.foundation/src/main/java/java/lang/Compiler.java
deleted file mode 100644
index 1675617..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/Compiler.java
+++ /dev/null
@@ -1,29 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/Compiler.java,v 1.6 2006/03/14 01:20:25 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang;
-public final class Compiler {
- public static java.lang.Object command(java.lang.Object var0) { return null; }
- public static boolean compileClass(java.lang.Class var0) { return false; }
- public static boolean compileClasses(java.lang.String var0) { return false; }
- public static void disable() { }
- public static void enable() { }
- private Compiler() { } /* generated constructor to prevent compiler adding default public constructor */
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/Double.java b/org.osgi.foundation/src/main/java/java/lang/Double.java
deleted file mode 100644
index 7bc7e69..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/Double.java
+++ /dev/null
@@ -1,52 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/Double.java,v 1.6 2006/03/14 01:20:24 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang;
-public final class Double extends java.lang.Number implements java.lang.Comparable {
- public Double(double var0) { }
- public Double(java.lang.String var0) throws java.lang.NumberFormatException { }
- public int compareTo(java.lang.Double var0) { return 0; }
- public int compareTo(java.lang.Object var0) { return 0; }
- public byte byteValue() { return 0; }
- public static long doubleToLongBits(double var0) { return 0l; }
- public static long doubleToRawLongBits(double var0) { return 0l; }
- public double doubleValue() { return 0.0d; }
- public boolean equals(java.lang.Object var0) { return false; }
- public float floatValue() { return 0.0f; }
- public int hashCode() { return 0; }
- public int intValue() { return 0; }
- public boolean isInfinite() { return false; }
- public static boolean isInfinite(double var0) { return false; }
- public boolean isNaN() { return false; }
- public static boolean isNaN(double var0) { return false; }
- public static double longBitsToDouble(long var0) { return 0.0d; }
- public long longValue() { return 0l; }
- public static double parseDouble(java.lang.String var0) throws java.lang.NumberFormatException { return 0.0d; }
- public short shortValue() { return 0; }
- public java.lang.String toString() { return null; }
- public static java.lang.String toString(double var0) { return null; }
- public static java.lang.Double valueOf(java.lang.String var0) throws java.lang.NumberFormatException { return null; }
- public final static double MAX_VALUE = 1.7976931348623157E308d;
- public final static double MIN_VALUE = 4.9E-324d;
- public final static double NaN = 0.0d / 0.0d;
- public final static double POSITIVE_INFINITY = 1.0d / 0.0d;
- public final static double NEGATIVE_INFINITY = -1.0d / 0.0d;
- public final static java.lang.Class TYPE; static { TYPE = null; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/Error.java b/org.osgi.foundation/src/main/java/java/lang/Error.java
deleted file mode 100644
index 8b53843..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/Error.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/Error.java,v 1.6 2006/03/14 01:20:25 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang;
-public class Error extends java.lang.Throwable {
- public Error() { }
- public Error(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/Exception.java b/org.osgi.foundation/src/main/java/java/lang/Exception.java
deleted file mode 100644
index 5ad69de..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/Exception.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/Exception.java,v 1.6 2006/03/14 01:20:25 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang;
-public class Exception extends java.lang.Throwable {
- public Exception() { }
- public Exception(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/ExceptionInInitializerError.java b/org.osgi.foundation/src/main/java/java/lang/ExceptionInInitializerError.java
deleted file mode 100644
index e7fd6e7..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/ExceptionInInitializerError.java
+++ /dev/null
@@ -1,30 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/ExceptionInInitializerError.java,v 1.6 2006/03/14 01:20:25 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang;
-public class ExceptionInInitializerError extends java.lang.LinkageError {
- public ExceptionInInitializerError() { }
- public ExceptionInInitializerError(java.lang.String var0) { }
- public ExceptionInInitializerError(java.lang.Throwable var0) { }
- public java.lang.Throwable getException() { return null; }
- public void printStackTrace() { }
- public void printStackTrace(java.io.PrintStream var0) { }
- public void printStackTrace(java.io.PrintWriter var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/Float.java b/org.osgi.foundation/src/main/java/java/lang/Float.java
deleted file mode 100644
index 7652973..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/Float.java
+++ /dev/null
@@ -1,53 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/Float.java,v 1.6 2006/03/14 01:20:25 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang;
-public final class Float extends java.lang.Number implements java.lang.Comparable {
- public Float(float var0) { }
- public Float(double var0) { }
- public Float(java.lang.String var0) throws java.lang.NumberFormatException { }
- public int compareTo(java.lang.Float var0) { return 0; }
- public int compareTo(java.lang.Object var0) { return 0; }
- public byte byteValue() { return 0; }
- public double doubleValue() { return 0.0d; }
- public boolean equals(java.lang.Object var0) { return false; }
- public static int floatToIntBits(float var0) { return 0; }
- public static int floatToRawIntBits(float var0) { return 0; }
- public float floatValue() { return 0.0f; }
- public int hashCode() { return 0; }
- public static float intBitsToFloat(int var0) { return 0.0f; }
- public int intValue() { return 0; }
- public boolean isInfinite() { return false; }
- public static boolean isInfinite(float var0) { return false; }
- public boolean isNaN() { return false; }
- public static boolean isNaN(float var0) { return false; }
- public long longValue() { return 0l; }
- public static float parseFloat(java.lang.String var0) throws java.lang.NumberFormatException { return 0.0f; }
- public short shortValue() { return 0; }
- public java.lang.String toString() { return null; }
- public static java.lang.String toString(float var0) { return null; }
- public static java.lang.Float valueOf(java.lang.String var0) throws java.lang.NumberFormatException { return null; }
- public final static float MAX_VALUE = 3.4028235E38f;
- public final static float MIN_VALUE = 1.4E-45f;
- public final static float NaN = 0.0f / 0.0f;
- public final static float POSITIVE_INFINITY = 1.0f / 0.0f;
- public final static float NEGATIVE_INFINITY = -1.0f / 0.0f;
- public final static java.lang.Class TYPE; static { TYPE = null; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/IllegalAccessError.java b/org.osgi.foundation/src/main/java/java/lang/IllegalAccessError.java
deleted file mode 100644
index ea0b8d9..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/IllegalAccessError.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/IllegalAccessError.java,v 1.6 2006/03/14 01:20:25 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang;
-public class IllegalAccessError extends java.lang.IncompatibleClassChangeError {
- public IllegalAccessError() { }
- public IllegalAccessError(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/IllegalAccessException.java b/org.osgi.foundation/src/main/java/java/lang/IllegalAccessException.java
deleted file mode 100644
index 9e81896..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/IllegalAccessException.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/IllegalAccessException.java,v 1.6 2006/03/14 01:20:24 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang;
-public class IllegalAccessException extends java.lang.Exception {
- public IllegalAccessException() { }
- public IllegalAccessException(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/IllegalArgumentException.java b/org.osgi.foundation/src/main/java/java/lang/IllegalArgumentException.java
deleted file mode 100644
index 473a6ba..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/IllegalArgumentException.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/IllegalArgumentException.java,v 1.6 2006/03/14 01:20:24 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang;
-public class IllegalArgumentException extends java.lang.RuntimeException {
- public IllegalArgumentException() { }
- public IllegalArgumentException(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/IllegalMonitorStateException.java b/org.osgi.foundation/src/main/java/java/lang/IllegalMonitorStateException.java
deleted file mode 100644
index 15cb05e..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/IllegalMonitorStateException.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/IllegalMonitorStateException.java,v 1.6 2006/03/14 01:20:24 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang;
-public class IllegalMonitorStateException extends java.lang.RuntimeException {
- public IllegalMonitorStateException() { }
- public IllegalMonitorStateException(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/IllegalStateException.java b/org.osgi.foundation/src/main/java/java/lang/IllegalStateException.java
deleted file mode 100644
index 7b7dcfe..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/IllegalStateException.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/IllegalStateException.java,v 1.6 2006/03/14 01:20:25 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang;
-public class IllegalStateException extends java.lang.RuntimeException {
- public IllegalStateException() { }
- public IllegalStateException(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/IllegalThreadStateException.java b/org.osgi.foundation/src/main/java/java/lang/IllegalThreadStateException.java
deleted file mode 100644
index 24c7b2a..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/IllegalThreadStateException.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/IllegalThreadStateException.java,v 1.6 2006/03/14 01:20:25 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang;
-public class IllegalThreadStateException extends java.lang.IllegalArgumentException {
- public IllegalThreadStateException() { }
- public IllegalThreadStateException(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/IncompatibleClassChangeError.java b/org.osgi.foundation/src/main/java/java/lang/IncompatibleClassChangeError.java
deleted file mode 100644
index 3a29bca..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/IncompatibleClassChangeError.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/IncompatibleClassChangeError.java,v 1.6 2006/03/14 01:20:24 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang;
-public class IncompatibleClassChangeError extends java.lang.LinkageError {
- public IncompatibleClassChangeError() { }
- public IncompatibleClassChangeError(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/IndexOutOfBoundsException.java b/org.osgi.foundation/src/main/java/java/lang/IndexOutOfBoundsException.java
deleted file mode 100644
index 228b036..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/IndexOutOfBoundsException.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/IndexOutOfBoundsException.java,v 1.6 2006/03/14 01:20:24 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang;
-public class IndexOutOfBoundsException extends java.lang.RuntimeException {
- public IndexOutOfBoundsException() { }
- public IndexOutOfBoundsException(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/InheritableThreadLocal.java b/org.osgi.foundation/src/main/java/java/lang/InheritableThreadLocal.java
deleted file mode 100644
index 6ab4888..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/InheritableThreadLocal.java
+++ /dev/null
@@ -1,27 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/InheritableThreadLocal.java,v 1.6 2006/03/14 01:20:25 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang;
-public class InheritableThreadLocal extends java.lang.ThreadLocal {
- public InheritableThreadLocal() { }
- protected java.lang.Object childValue(java.lang.Object var0) { return null; }
- public java.lang.Object get() { return null; }
- public void set(java.lang.Object var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/InstantiationError.java b/org.osgi.foundation/src/main/java/java/lang/InstantiationError.java
deleted file mode 100644
index 7cb480b..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/InstantiationError.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/InstantiationError.java,v 1.6 2006/03/14 01:20:24 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang;
-public class InstantiationError extends java.lang.IncompatibleClassChangeError {
- public InstantiationError() { }
- public InstantiationError(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/InstantiationException.java b/org.osgi.foundation/src/main/java/java/lang/InstantiationException.java
deleted file mode 100644
index ebb032f..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/InstantiationException.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/InstantiationException.java,v 1.6 2006/03/14 01:20:25 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang;
-public class InstantiationException extends java.lang.Exception {
- public InstantiationException() { }
- public InstantiationException(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/Integer.java b/org.osgi.foundation/src/main/java/java/lang/Integer.java
deleted file mode 100644
index 0c79e09..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/Integer.java
+++ /dev/null
@@ -1,52 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/Integer.java,v 1.6 2006/03/14 01:20:24 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang;
-public final class Integer extends java.lang.Number implements java.lang.Comparable {
- public Integer(int var0) { }
- public Integer(java.lang.String var0) throws java.lang.NumberFormatException { }
- public byte byteValue() { return 0; }
- public int compareTo(java.lang.Integer var0) { return 0; }
- public int compareTo(java.lang.Object var0) { return 0; }
- public static java.lang.Integer decode(java.lang.String var0) throws java.lang.NumberFormatException { return null; }
- public double doubleValue() { return 0.0d; }
- public boolean equals(java.lang.Object var0) { return false; }
- public float floatValue() { return 0.0f; }
- public static java.lang.Integer getInteger(java.lang.String var0) { return null; }
- public static java.lang.Integer getInteger(java.lang.String var0, int var1) { return null; }
- public static java.lang.Integer getInteger(java.lang.String var0, java.lang.Integer var1) { return null; }
- public int hashCode() { return 0; }
- public int intValue() { return 0; }
- public long longValue() { return 0l; }
- public static int parseInt(java.lang.String var0) throws java.lang.NumberFormatException { return 0; }
- public static int parseInt(java.lang.String var0, int var1) throws java.lang.NumberFormatException { return 0; }
- public short shortValue() { return 0; }
- public static java.lang.String toBinaryString(int var0) { return null; }
- public static java.lang.String toHexString(int var0) { return null; }
- public static java.lang.String toOctalString(int var0) { return null; }
- public java.lang.String toString() { return null; }
- public static java.lang.String toString(int var0) { return null; }
- public static java.lang.String toString(int var0, int var1) { return null; }
- public static java.lang.Integer valueOf(java.lang.String var0) throws java.lang.NumberFormatException { return null; }
- public static java.lang.Integer valueOf(java.lang.String var0, int var1) throws java.lang.NumberFormatException { return null; }
- public final static int MAX_VALUE = 2147483647;
- public final static int MIN_VALUE = -2147483648;
- public final static java.lang.Class TYPE; static { TYPE = null; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/InternalError.java b/org.osgi.foundation/src/main/java/java/lang/InternalError.java
deleted file mode 100644
index 97b55f5..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/InternalError.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/InternalError.java,v 1.6 2006/03/14 01:20:24 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang;
-public class InternalError extends java.lang.VirtualMachineError {
- public InternalError() { }
- public InternalError(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/InterruptedException.java b/org.osgi.foundation/src/main/java/java/lang/InterruptedException.java
deleted file mode 100644
index ec15575..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/InterruptedException.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/InterruptedException.java,v 1.6 2006/03/14 01:20:24 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang;
-public class InterruptedException extends java.lang.Exception {
- public InterruptedException() { }
- public InterruptedException(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/LinkageError.java b/org.osgi.foundation/src/main/java/java/lang/LinkageError.java
deleted file mode 100644
index 1057feb..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/LinkageError.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/LinkageError.java,v 1.6 2006/03/14 01:20:24 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang;
-public class LinkageError extends java.lang.Error {
- public LinkageError() { }
- public LinkageError(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/Long.java b/org.osgi.foundation/src/main/java/java/lang/Long.java
deleted file mode 100644
index 4613e43..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/Long.java
+++ /dev/null
@@ -1,52 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/Long.java,v 1.6 2006/03/14 01:20:24 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang;
-public final class Long extends java.lang.Number implements java.lang.Comparable {
- public Long(long var0) { }
- public Long(java.lang.String var0) throws java.lang.NumberFormatException { }
- public byte byteValue() { return 0; }
- public int compareTo(java.lang.Long var0) { return 0; }
- public int compareTo(java.lang.Object var0) { return 0; }
- public static java.lang.Long decode(java.lang.String var0) throws java.lang.NumberFormatException { return null; }
- public double doubleValue() { return 0.0d; }
- public boolean equals(java.lang.Object var0) { return false; }
- public float floatValue() { return 0.0f; }
- public static java.lang.Long getLong(java.lang.String var0) { return null; }
- public static java.lang.Long getLong(java.lang.String var0, long var1) { return null; }
- public static java.lang.Long getLong(java.lang.String var0, java.lang.Long var1) { return null; }
- public int hashCode() { return 0; }
- public int intValue() { return 0; }
- public long longValue() { return 0l; }
- public static long parseLong(java.lang.String var0) throws java.lang.NumberFormatException { return 0l; }
- public static long parseLong(java.lang.String var0, int var1) throws java.lang.NumberFormatException { return 0l; }
- public short shortValue() { return 0; }
- public static java.lang.String toBinaryString(long var0) { return null; }
- public static java.lang.String toHexString(long var0) { return null; }
- public static java.lang.String toOctalString(long var0) { return null; }
- public java.lang.String toString() { return null; }
- public static java.lang.String toString(long var0) { return null; }
- public static java.lang.String toString(long var0, int var1) { return null; }
- public static java.lang.Long valueOf(java.lang.String var0) throws java.lang.NumberFormatException { return null; }
- public static java.lang.Long valueOf(java.lang.String var0, int var1) throws java.lang.NumberFormatException { return null; }
- public final static long MAX_VALUE = 9223372036854775807l;
- public final static long MIN_VALUE = -9223372036854775808l;
- public final static java.lang.Class TYPE; static { TYPE = null; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/Math.java b/org.osgi.foundation/src/main/java/java/lang/Math.java
deleted file mode 100644
index 26014ef..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/Math.java
+++ /dev/null
@@ -1,58 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/Math.java,v 1.6 2006/03/14 01:20:25 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang;
-public final class Math {
- public static double abs(double var0) { return 0.0d; }
- public static float abs(float var0) { return 0.0f; }
- public static int abs(int var0) { return 0; }
- public static long abs(long var0) { return 0l; }
- public static double acos(double var0) { return 0.0d; }
- public static double asin(double var0) { return 0.0d; }
- public static double atan(double var0) { return 0.0d; }
- public static double atan2(double var0, double var1) { return 0.0d; }
- public static double ceil(double var0) { return 0.0d; }
- public static double cos(double var0) { return 0.0d; }
- public static double exp(double var0) { return 0.0d; }
- public static double floor(double var0) { return 0.0d; }
- public static double IEEEremainder(double var0, double var1) { return 0.0d; }
- public static double log(double var0) { return 0.0d; }
- public static double max(double var0, double var1) { return 0.0d; }
- public static float max(float var0, float var1) { return 0.0f; }
- public static int max(int var0, int var1) { return 0; }
- public static long max(long var0, long var1) { return 0l; }
- public static double min(double var0, double var1) { return 0.0d; }
- public static float min(float var0, float var1) { return 0.0f; }
- public static int min(int var0, int var1) { return 0; }
- public static long min(long var0, long var1) { return 0l; }
- public static double pow(double var0, double var1) { return 0.0d; }
- public static double rint(double var0) { return 0.0d; }
- public static long round(double var0) { return 0l; }
- public static int round(float var0) { return 0; }
- public static double sin(double var0) { return 0.0d; }
- public static double sqrt(double var0) { return 0.0d; }
- public static double tan(double var0) { return 0.0d; }
- public static double random() { return 0.0d; }
- public static double toRadians(double var0) { return 0.0d; }
- public static double toDegrees(double var0) { return 0.0d; }
- public final static double E; static { E = 0.0d; }
- public final static double PI; static { PI = 0.0d; }
- private Math() { } /* generated constructor to prevent compiler adding default public constructor */
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/NegativeArraySizeException.java b/org.osgi.foundation/src/main/java/java/lang/NegativeArraySizeException.java
deleted file mode 100644
index 2cec3f1..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/NegativeArraySizeException.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/NegativeArraySizeException.java,v 1.6 2006/03/14 01:20:24 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang;
-public class NegativeArraySizeException extends java.lang.RuntimeException {
- public NegativeArraySizeException() { }
- public NegativeArraySizeException(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/NoClassDefFoundError.java b/org.osgi.foundation/src/main/java/java/lang/NoClassDefFoundError.java
deleted file mode 100644
index 66b5399..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/NoClassDefFoundError.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/NoClassDefFoundError.java,v 1.6 2006/03/14 01:20:25 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang;
-public class NoClassDefFoundError extends java.lang.LinkageError {
- public NoClassDefFoundError() { }
- public NoClassDefFoundError(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/NoSuchFieldError.java b/org.osgi.foundation/src/main/java/java/lang/NoSuchFieldError.java
deleted file mode 100644
index 60e59b0..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/NoSuchFieldError.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/NoSuchFieldError.java,v 1.6 2006/03/14 01:20:25 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang;
-public class NoSuchFieldError extends java.lang.IncompatibleClassChangeError {
- public NoSuchFieldError() { }
- public NoSuchFieldError(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/NoSuchFieldException.java b/org.osgi.foundation/src/main/java/java/lang/NoSuchFieldException.java
deleted file mode 100644
index 21c50c6..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/NoSuchFieldException.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/NoSuchFieldException.java,v 1.6 2006/03/14 01:20:24 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang;
-public class NoSuchFieldException extends java.lang.Exception {
- public NoSuchFieldException() { }
- public NoSuchFieldException(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/NoSuchMethodError.java b/org.osgi.foundation/src/main/java/java/lang/NoSuchMethodError.java
deleted file mode 100644
index 6efa059..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/NoSuchMethodError.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/NoSuchMethodError.java,v 1.6 2006/03/14 01:20:24 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang;
-public class NoSuchMethodError extends java.lang.IncompatibleClassChangeError {
- public NoSuchMethodError() { }
- public NoSuchMethodError(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/NoSuchMethodException.java b/org.osgi.foundation/src/main/java/java/lang/NoSuchMethodException.java
deleted file mode 100644
index 3e5eca5..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/NoSuchMethodException.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/NoSuchMethodException.java,v 1.6 2006/03/14 01:20:25 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang;
-public class NoSuchMethodException extends java.lang.Exception {
- public NoSuchMethodException() { }
- public NoSuchMethodException(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/NullPointerException.java b/org.osgi.foundation/src/main/java/java/lang/NullPointerException.java
deleted file mode 100644
index 6a3da9b..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/NullPointerException.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/NullPointerException.java,v 1.6 2006/03/14 01:20:25 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang;
-public class NullPointerException extends java.lang.RuntimeException {
- public NullPointerException() { }
- public NullPointerException(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/Number.java b/org.osgi.foundation/src/main/java/java/lang/Number.java
deleted file mode 100644
index 059bdf1..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/Number.java
+++ /dev/null
@@ -1,30 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/Number.java,v 1.6 2006/03/14 01:20:24 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang;
-public abstract class Number implements java.io.Serializable {
- public Number() { }
- public byte byteValue() { return 0; }
- public abstract double doubleValue();
- public abstract float floatValue();
- public abstract int intValue();
- public abstract long longValue();
- public short shortValue() { return 0; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/NumberFormatException.java b/org.osgi.foundation/src/main/java/java/lang/NumberFormatException.java
deleted file mode 100644
index 4e70131..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/NumberFormatException.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/NumberFormatException.java,v 1.6 2006/03/14 01:20:25 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang;
-public class NumberFormatException extends java.lang.IllegalArgumentException {
- public NumberFormatException() { }
- public NumberFormatException(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/Object.java b/org.osgi.foundation/src/main/java/java/lang/Object.java
deleted file mode 100644
index c7ed57b..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/Object.java
+++ /dev/null
@@ -1,35 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/Object.java,v 1.6 2006/03/14 01:20:24 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang;
-public class Object {
- public Object() { }
- protected java.lang.Object clone() throws java.lang.CloneNotSupportedException { return null; }
- public boolean equals(java.lang.Object var0) { return false; }
- protected void finalize() throws java.lang.Throwable { }
- public final java.lang.Class getClass() { return null; }
- public int hashCode() { return 0; }
- public final void notify() { }
- public final void notifyAll() { }
- public java.lang.String toString() { return null; }
- public final void wait() throws java.lang.InterruptedException { }
- public final void wait(long var0) throws java.lang.InterruptedException { }
- public final void wait(long var0, int var1) throws java.lang.InterruptedException { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/OutOfMemoryError.java b/org.osgi.foundation/src/main/java/java/lang/OutOfMemoryError.java
deleted file mode 100644
index a87ced3..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/OutOfMemoryError.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/OutOfMemoryError.java,v 1.6 2006/03/14 01:20:25 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang;
-public class OutOfMemoryError extends java.lang.VirtualMachineError {
- public OutOfMemoryError() { }
- public OutOfMemoryError(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/Package.java b/org.osgi.foundation/src/main/java/java/lang/Package.java
deleted file mode 100644
index 967f9f2..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/Package.java
+++ /dev/null
@@ -1,38 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/Package.java,v 1.6 2006/03/14 01:20:25 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang;
-public class Package {
- public java.lang.String getImplementationTitle() { return null; }
- public java.lang.String getImplementationVendor() { return null; }
- public java.lang.String getImplementationVersion() { return null; }
- public java.lang.String getName() { return null; }
- public static java.lang.Package getPackage(java.lang.String var0) { return null; }
- public static java.lang.Package[] getPackages() { return null; }
- public java.lang.String getSpecificationTitle() { return null; }
- public java.lang.String getSpecificationVendor() { return null; }
- public java.lang.String getSpecificationVersion() { return null; }
- public int hashCode() { return 0; }
- public boolean isCompatibleWith(java.lang.String var0) throws java.lang.NumberFormatException { return false; }
- public boolean isSealed() { return false; }
- public boolean isSealed(java.net.URL var0) { return false; }
- public java.lang.String toString() { return null; }
- private Package() { } /* generated constructor to prevent compiler adding default public constructor */
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/Process.java b/org.osgi.foundation/src/main/java/java/lang/Process.java
deleted file mode 100644
index 5d48882..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/Process.java
+++ /dev/null
@@ -1,30 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/Process.java,v 1.6 2006/03/14 01:20:25 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang;
-public abstract class Process {
- public Process() { }
- public abstract void destroy();
- public abstract int exitValue();
- public abstract java.io.InputStream getErrorStream();
- public abstract java.io.InputStream getInputStream();
- public abstract java.io.OutputStream getOutputStream();
- public abstract int waitFor() throws java.lang.InterruptedException;
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/Runnable.java b/org.osgi.foundation/src/main/java/java/lang/Runnable.java
deleted file mode 100644
index de431a7..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/Runnable.java
+++ /dev/null
@@ -1,24 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/Runnable.java,v 1.6 2006/03/14 01:20:25 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang;
-public abstract interface Runnable {
- public abstract void run();
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/Runtime.java b/org.osgi.foundation/src/main/java/java/lang/Runtime.java
deleted file mode 100644
index 024de45..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/Runtime.java
+++ /dev/null
@@ -1,43 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/Runtime.java,v 1.6 2006/03/14 01:20:24 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang;
-public class Runtime {
- public java.lang.Process exec(java.lang.String[] var0) throws java.io.IOException { return null; }
- public java.lang.Process exec(java.lang.String[] var0, java.lang.String[] var1) throws java.io.IOException { return null; }
- public java.lang.Process exec(java.lang.String[] var0, java.lang.String[] var1, java.io.File var2) throws java.io.IOException { return null; }
- public java.lang.Process exec(java.lang.String var0) throws java.io.IOException { return null; }
- public java.lang.Process exec(java.lang.String var0, java.lang.String[] var1) throws java.io.IOException { return null; }
- public java.lang.Process exec(java.lang.String var0, java.lang.String[] var1, java.io.File var2) throws java.io.IOException { return null; }
- public void exit(int var0) { }
- public long freeMemory() { return 0l; }
- public void gc() { }
- public static java.lang.Runtime getRuntime() { return null; }
- public void load(java.lang.String var0) { }
- public void loadLibrary(java.lang.String var0) { }
- public void runFinalization() { }
- public long totalMemory() { return 0l; }
- public void traceInstructions(boolean var0) { }
- public void traceMethodCalls(boolean var0) { }
- public void addShutdownHook(java.lang.Thread var0) { }
- public boolean removeShutdownHook(java.lang.Thread var0) { return false; }
- public void halt(int var0) { }
- private Runtime() { } /* generated constructor to prevent compiler adding default public constructor */
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/RuntimeException.java b/org.osgi.foundation/src/main/java/java/lang/RuntimeException.java
deleted file mode 100644
index 32b5cee..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/RuntimeException.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/RuntimeException.java,v 1.6 2006/03/14 01:20:24 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang;
-public class RuntimeException extends java.lang.Exception {
- public RuntimeException() { }
- public RuntimeException(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/RuntimePermission.java b/org.osgi.foundation/src/main/java/java/lang/RuntimePermission.java
deleted file mode 100644
index f18b729..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/RuntimePermission.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/RuntimePermission.java,v 1.6 2006/03/14 01:20:24 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang;
-public final class RuntimePermission extends java.security.BasicPermission {
- public RuntimePermission(java.lang.String var0) { super((java.lang.String) null, (java.lang.String) null); }
- public RuntimePermission(java.lang.String var0, java.lang.String var1) { super((java.lang.String) null, (java.lang.String) null); }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/SecurityException.java b/org.osgi.foundation/src/main/java/java/lang/SecurityException.java
deleted file mode 100644
index dd86639..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/SecurityException.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/SecurityException.java,v 1.6 2006/03/14 01:20:25 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang;
-public class SecurityException extends java.lang.RuntimeException {
- public SecurityException() { }
- public SecurityException(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/SecurityManager.java b/org.osgi.foundation/src/main/java/java/lang/SecurityManager.java
deleted file mode 100644
index 62ff9b8..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/SecurityManager.java
+++ /dev/null
@@ -1,58 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/SecurityManager.java,v 1.6 2006/03/14 01:20:24 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang;
-public class SecurityManager {
- public SecurityManager() { }
- public void checkAccept(java.lang.String var0, int var1) { }
- public void checkAccess(java.lang.Thread var0) { }
- public void checkAccess(java.lang.ThreadGroup var0) { }
- public void checkConnect(java.lang.String var0, int var1) { }
- public void checkConnect(java.lang.String var0, int var1, java.lang.Object var2) { }
- public void checkCreateClassLoader() { }
- public void checkDelete(java.lang.String var0) { }
- public void checkExec(java.lang.String var0) { }
- public void checkExit(int var0) { }
- public void checkLink(java.lang.String var0) { }
- public void checkListen(int var0) { }
- public void checkMemberAccess(java.lang.Class var0, int var1) { }
- public void checkMulticast(java.net.InetAddress var0) { }
- public void checkMulticast(java.net.InetAddress var0, byte var1) { }
- public void checkPackageAccess(java.lang.String var0) { }
- public void checkPackageDefinition(java.lang.String var0) { }
- public void checkPropertiesAccess() { }
- public void checkPropertyAccess(java.lang.String var0) { }
- public void checkRead(java.io.FileDescriptor var0) { }
- public void checkRead(java.lang.String var0) { }
- public void checkRead(java.lang.String var0, java.lang.Object var1) { }
- public void checkSecurityAccess(java.lang.String var0) { }
- public void checkSetFactory() { }
- public boolean checkTopLevelWindow(java.lang.Object var0) { return false; }
- public void checkSystemClipboardAccess() { }
- public void checkAwtEventQueueAccess() { }
- public void checkPrintJobAccess() { }
- public void checkWrite(java.io.FileDescriptor var0) { }
- public void checkWrite(java.lang.String var0) { }
- protected java.lang.Class[] getClassContext() { return null; }
- public java.lang.ThreadGroup getThreadGroup() { return null; }
- public java.lang.Object getSecurityContext() { return null; }
- public void checkPermission(java.security.Permission var0) { }
- public void checkPermission(java.security.Permission var0, java.lang.Object var1) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/Short.java b/org.osgi.foundation/src/main/java/java/lang/Short.java
deleted file mode 100644
index e568fed..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/Short.java
+++ /dev/null
@@ -1,45 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/Short.java,v 1.6 2006/03/14 01:20:25 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang;
-public final class Short extends java.lang.Number implements java.lang.Comparable {
- public Short(java.lang.String var0) throws java.lang.NumberFormatException { }
- public Short(short var0) { }
- public byte byteValue() { return 0; }
- public int compareTo(java.lang.Object var0) { return 0; }
- public int compareTo(java.lang.Short var0) { return 0; }
- public static java.lang.Short decode(java.lang.String var0) throws java.lang.NumberFormatException { return null; }
- public double doubleValue() { return 0.0d; }
- public boolean equals(java.lang.Object var0) { return false; }
- public float floatValue() { return 0.0f; }
- public int hashCode() { return 0; }
- public int intValue() { return 0; }
- public long longValue() { return 0l; }
- public static short parseShort(java.lang.String var0) throws java.lang.NumberFormatException { return 0; }
- public static short parseShort(java.lang.String var0, int var1) throws java.lang.NumberFormatException { return 0; }
- public short shortValue() { return 0; }
- public java.lang.String toString() { return null; }
- public static java.lang.String toString(short var0) { return null; }
- public static java.lang.Short valueOf(java.lang.String var0) throws java.lang.NumberFormatException { return null; }
- public static java.lang.Short valueOf(java.lang.String var0, int var1) throws java.lang.NumberFormatException { return null; }
- public final static short MAX_VALUE = 32767;
- public final static short MIN_VALUE = -32768;
- public final static java.lang.Class TYPE; static { TYPE = null; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/StackOverflowError.java b/org.osgi.foundation/src/main/java/java/lang/StackOverflowError.java
deleted file mode 100644
index 20072b2..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/StackOverflowError.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/StackOverflowError.java,v 1.6 2006/03/14 01:20:25 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang;
-public class StackOverflowError extends java.lang.VirtualMachineError {
- public StackOverflowError() { }
- public StackOverflowError(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/StrictMath.java b/org.osgi.foundation/src/main/java/java/lang/StrictMath.java
deleted file mode 100644
index 17a0ea7..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/StrictMath.java
+++ /dev/null
@@ -1,58 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/StrictMath.java,v 1.6 2006/03/14 01:20:24 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang;
-public final class StrictMath {
- public static double abs(double var0) { return 0.0d; }
- public static float abs(float var0) { return 0.0f; }
- public static int abs(int var0) { return 0; }
- public static long abs(long var0) { return 0l; }
- public static double acos(double var0) { return 0.0d; }
- public static double asin(double var0) { return 0.0d; }
- public static double atan(double var0) { return 0.0d; }
- public static double atan2(double var0, double var1) { return 0.0d; }
- public static double ceil(double var0) { return 0.0d; }
- public static double cos(double var0) { return 0.0d; }
- public static double exp(double var0) { return 0.0d; }
- public static double floor(double var0) { return 0.0d; }
- public static double IEEEremainder(double var0, double var1) { return 0.0d; }
- public static double log(double var0) { return 0.0d; }
- public static double max(double var0, double var1) { return 0.0d; }
- public static float max(float var0, float var1) { return 0.0f; }
- public static int max(int var0, int var1) { return 0; }
- public static long max(long var0, long var1) { return 0l; }
- public static double min(double var0, double var1) { return 0.0d; }
- public static float min(float var0, float var1) { return 0.0f; }
- public static int min(int var0, int var1) { return 0; }
- public static long min(long var0, long var1) { return 0l; }
- public static double pow(double var0, double var1) { return 0.0d; }
- public static double random() { return 0.0d; }
- public static double rint(double var0) { return 0.0d; }
- public static long round(double var0) { return 0l; }
- public static int round(float var0) { return 0; }
- public static double sin(double var0) { return 0.0d; }
- public static double sqrt(double var0) { return 0.0d; }
- public static double tan(double var0) { return 0.0d; }
- public static double toDegrees(double var0) { return 0.0d; }
- public static double toRadians(double var0) { return 0.0d; }
- public final static double E; static { E = 0.0d; }
- public final static double PI; static { PI = 0.0d; }
- private StrictMath() { } /* generated constructor to prevent compiler adding default public constructor */
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/String.java b/org.osgi.foundation/src/main/java/java/lang/String.java
deleted file mode 100644
index f740e18..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/String.java
+++ /dev/null
@@ -1,80 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/String.java,v 1.6 2006/03/14 01:20:25 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang;
-public final class String implements java.io.Serializable, java.lang.Comparable {
- public String() { }
- public String(byte[] var0) { }
- public String(byte[] var0, int var1, int var2) { }
- public String(byte[] var0, int var1, int var2, java.lang.String var3) throws java.io.UnsupportedEncodingException { }
- public String(byte[] var0, java.lang.String var1) throws java.io.UnsupportedEncodingException { }
- public String(char[] var0) { }
- public String(char[] var0, int var1, int var2) { }
- public String(java.lang.String var0) { }
- public String(java.lang.StringBuffer var0) { }
- public char charAt(int var0) { return 0; }
- public int compareTo(java.lang.Object var0) { return 0; }
- public int compareTo(java.lang.String var0) { return 0; }
- public int compareToIgnoreCase(java.lang.String var0) { return 0; }
- public java.lang.String concat(java.lang.String var0) { return null; }
- public static java.lang.String copyValueOf(char[] var0) { return null; }
- public static java.lang.String copyValueOf(char[] var0, int var1, int var2) { return null; }
- public boolean endsWith(java.lang.String var0) { return false; }
- public boolean equals(java.lang.Object var0) { return false; }
- public boolean equalsIgnoreCase(java.lang.String var0) { return false; }
- public byte[] getBytes() { return null; }
- public byte[] getBytes(java.lang.String var0) throws java.io.UnsupportedEncodingException { return null; }
- public void getChars(int var0, int var1, char[] var2, int var3) { }
- public int hashCode() { return 0; }
- public int indexOf(int var0) { return 0; }
- public int indexOf(int var0, int var1) { return 0; }
- public int indexOf(java.lang.String var0) { return 0; }
- public int indexOf(java.lang.String var0, int var1) { return 0; }
- public java.lang.String intern() { return null; }
- public int lastIndexOf(int var0) { return 0; }
- public int lastIndexOf(int var0, int var1) { return 0; }
- public int lastIndexOf(java.lang.String var0) { return 0; }
- public int lastIndexOf(java.lang.String var0, int var1) { return 0; }
- public int length() { return 0; }
- public boolean regionMatches(int var0, java.lang.String var1, int var2, int var3) { return false; }
- public boolean regionMatches(boolean var0, int var1, java.lang.String var2, int var3, int var4) { return false; }
- public java.lang.String replace(char var0, char var1) { return null; }
- public boolean startsWith(java.lang.String var0) { return false; }
- public boolean startsWith(java.lang.String var0, int var1) { return false; }
- public java.lang.String substring(int var0) { return null; }
- public java.lang.String substring(int var0, int var1) { return null; }
- public char[] toCharArray() { return null; }
- public java.lang.String toLowerCase() { return null; }
- public java.lang.String toLowerCase(java.util.Locale var0) { return null; }
- public java.lang.String toString() { return null; }
- public java.lang.String toUpperCase() { return null; }
- public java.lang.String toUpperCase(java.util.Locale var0) { return null; }
- public java.lang.String trim() { return null; }
- public static java.lang.String valueOf(char[] var0) { return null; }
- public static java.lang.String valueOf(char[] var0, int var1, int var2) { return null; }
- public static java.lang.String valueOf(char var0) { return null; }
- public static java.lang.String valueOf(double var0) { return null; }
- public static java.lang.String valueOf(float var0) { return null; }
- public static java.lang.String valueOf(int var0) { return null; }
- public static java.lang.String valueOf(long var0) { return null; }
- public static java.lang.String valueOf(java.lang.Object var0) { return null; }
- public static java.lang.String valueOf(boolean var0) { return null; }
- public final static java.util.Comparator CASE_INSENSITIVE_ORDER; static { CASE_INSENSITIVE_ORDER = null; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/StringBuffer.java b/org.osgi.foundation/src/main/java/java/lang/StringBuffer.java
deleted file mode 100644
index 22c0f63..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/StringBuffer.java
+++ /dev/null
@@ -1,60 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/StringBuffer.java,v 1.6 2006/03/14 01:20:25 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang;
-public final class StringBuffer implements java.io.Serializable {
- public StringBuffer() { }
- public StringBuffer(int var0) { }
- public StringBuffer(java.lang.String var0) { }
- public java.lang.StringBuffer append(char[] var0) { return null; }
- public java.lang.StringBuffer append(char[] var0, int var1, int var2) { return null; }
- public java.lang.StringBuffer append(char var0) { return null; }
- public java.lang.StringBuffer append(double var0) { return null; }
- public java.lang.StringBuffer append(float var0) { return null; }
- public java.lang.StringBuffer append(int var0) { return null; }
- public java.lang.StringBuffer append(long var0) { return null; }
- public java.lang.StringBuffer append(java.lang.Object var0) { return null; }
- public java.lang.StringBuffer append(java.lang.String var0) { return null; }
- public java.lang.StringBuffer append(boolean var0) { return null; }
- public int capacity() { return 0; }
- public char charAt(int var0) { return 0; }
- public java.lang.StringBuffer delete(int var0, int var1) { return null; }
- public java.lang.StringBuffer deleteCharAt(int var0) { return null; }
- public void ensureCapacity(int var0) { }
- public void getChars(int var0, int var1, char[] var2, int var3) { }
- public java.lang.StringBuffer insert(int var0, char[] var1) { return null; }
- public java.lang.StringBuffer insert(int var0, char[] var1, int var2, int var3) { return null; }
- public java.lang.StringBuffer insert(int var0, char var1) { return null; }
- public java.lang.StringBuffer insert(int var0, double var1) { return null; }
- public java.lang.StringBuffer insert(int var0, float var1) { return null; }
- public java.lang.StringBuffer insert(int var0, int var1) { return null; }
- public java.lang.StringBuffer insert(int var0, long var1) { return null; }
- public java.lang.StringBuffer insert(int var0, java.lang.Object var1) { return null; }
- public java.lang.StringBuffer insert(int var0, java.lang.String var1) { return null; }
- public java.lang.StringBuffer insert(int var0, boolean var1) { return null; }
- public int length() { return 0; }
- public java.lang.StringBuffer replace(int var0, int var1, java.lang.String var2) { return null; }
- public java.lang.StringBuffer reverse() { return null; }
- public void setCharAt(int var0, char var1) { }
- public void setLength(int var0) { }
- public java.lang.String substring(int var0) { return null; }
- public java.lang.String substring(int var0, int var1) { return null; }
- public java.lang.String toString() { return null; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/StringIndexOutOfBoundsException.java b/org.osgi.foundation/src/main/java/java/lang/StringIndexOutOfBoundsException.java
deleted file mode 100644
index e44fd8b..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/StringIndexOutOfBoundsException.java
+++ /dev/null
@@ -1,26 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/StringIndexOutOfBoundsException.java,v 1.6 2006/03/14 01:20:25 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang;
-public class StringIndexOutOfBoundsException extends java.lang.IndexOutOfBoundsException {
- public StringIndexOutOfBoundsException() { }
- public StringIndexOutOfBoundsException(int var0) { }
- public StringIndexOutOfBoundsException(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/System.java b/org.osgi.foundation/src/main/java/java/lang/System.java
deleted file mode 100644
index ecb773f..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/System.java
+++ /dev/null
@@ -1,46 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/System.java,v 1.6 2006/03/14 01:20:25 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang;
-public final class System {
- public static void setIn(java.io.InputStream var0) { }
- public static void setOut(java.io.PrintStream var0) { }
- public static void setErr(java.io.PrintStream var0) { }
- public static void arraycopy(java.lang.Object var0, int var1, java.lang.Object var2, int var3, int var4) { }
- public static long currentTimeMillis() { return 0l; }
- public static void exit(int var0) { }
- public static void gc() { }
- public static java.util.Properties getProperties() { return null; }
- public static java.lang.String getProperty(java.lang.String var0) { return null; }
- public static java.lang.String getProperty(java.lang.String var0, java.lang.String var1) { return null; }
- public static java.lang.String setProperty(java.lang.String var0, java.lang.String var1) { return null; }
- public static java.lang.SecurityManager getSecurityManager() { return null; }
- public static int identityHashCode(java.lang.Object var0) { return 0; }
- public static void load(java.lang.String var0) { }
- public static void loadLibrary(java.lang.String var0) { }
- public static void runFinalization() { }
- public static void setProperties(java.util.Properties var0) { }
- public static void setSecurityManager(java.lang.SecurityManager var0) { }
- public static java.lang.String mapLibraryName(java.lang.String var0) { return null; }
- public final static java.io.InputStream in; static { in = null; }
- public final static java.io.PrintStream out; static { out = null; }
- public final static java.io.PrintStream err; static { err = null; }
- private System() { } /* generated constructor to prevent compiler adding default public constructor */
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/Thread.java b/org.osgi.foundation/src/main/java/java/lang/Thread.java
deleted file mode 100644
index 5d31f76..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/Thread.java
+++ /dev/null
@@ -1,61 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/Thread.java,v 1.6 2006/03/14 01:20:24 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang;
-public class Thread implements java.lang.Runnable {
- public Thread() { }
- public Thread(java.lang.Runnable var0) { }
- public Thread(java.lang.Runnable var0, java.lang.String var1) { }
- public Thread(java.lang.String var0) { }
- public Thread(java.lang.ThreadGroup var0, java.lang.Runnable var1) { }
- public Thread(java.lang.ThreadGroup var0, java.lang.Runnable var1, java.lang.String var2) { }
- public Thread(java.lang.ThreadGroup var0, java.lang.String var1) { }
- public static int activeCount() { return 0; }
- public final void checkAccess() { }
- public static java.lang.Thread currentThread() { return null; }
- public void destroy() { }
- public static void dumpStack() { }
- public static int enumerate(java.lang.Thread[] var0) { return 0; }
- public java.lang.ClassLoader getContextClassLoader() { return null; }
- public final java.lang.String getName() { return null; }
- public final int getPriority() { return 0; }
- public final java.lang.ThreadGroup getThreadGroup() { return null; }
- public void interrupt() { }
- public static boolean interrupted() { return false; }
- public final boolean isAlive() { return false; }
- public final boolean isDaemon() { return false; }
- public boolean isInterrupted() { return false; }
- public final void join() throws java.lang.InterruptedException { }
- public final void join(long var0) throws java.lang.InterruptedException { }
- public final void join(long var0, int var1) throws java.lang.InterruptedException { }
- public void run() { }
- public void setContextClassLoader(java.lang.ClassLoader var0) { }
- public final void setDaemon(boolean var0) { }
- public final void setName(java.lang.String var0) { }
- public final void setPriority(int var0) { }
- public static void sleep(long var0) throws java.lang.InterruptedException { }
- public static void sleep(long var0, int var1) throws java.lang.InterruptedException { }
- public void start() { }
- public java.lang.String toString() { return null; }
- public static void yield() { }
- public final static int MAX_PRIORITY = 10;
- public final static int MIN_PRIORITY = 1;
- public final static int NORM_PRIORITY = 5;
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/ThreadDeath.java b/org.osgi.foundation/src/main/java/java/lang/ThreadDeath.java
deleted file mode 100644
index f4554f4..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/ThreadDeath.java
+++ /dev/null
@@ -1,24 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/ThreadDeath.java,v 1.6 2006/03/14 01:20:24 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang;
-public class ThreadDeath extends java.lang.Error {
- public ThreadDeath() { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/ThreadGroup.java b/org.osgi.foundation/src/main/java/java/lang/ThreadGroup.java
deleted file mode 100644
index 8ff62f5..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/ThreadGroup.java
+++ /dev/null
@@ -1,45 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/ThreadGroup.java,v 1.6 2006/03/14 01:20:24 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang;
-public class ThreadGroup {
- public ThreadGroup(java.lang.String var0) { }
- public ThreadGroup(java.lang.ThreadGroup var0, java.lang.String var1) { }
- public int activeCount() { return 0; }
- public int activeGroupCount() { return 0; }
- public final void checkAccess() { }
- public final void destroy() { }
- public int enumerate(java.lang.Thread[] var0) { return 0; }
- public int enumerate(java.lang.Thread[] var0, boolean var1) { return 0; }
- public int enumerate(java.lang.ThreadGroup[] var0) { return 0; }
- public int enumerate(java.lang.ThreadGroup[] var0, boolean var1) { return 0; }
- public final int getMaxPriority() { return 0; }
- public final java.lang.String getName() { return null; }
- public final java.lang.ThreadGroup getParent() { return null; }
- public final void interrupt() { }
- public final boolean isDaemon() { return false; }
- public boolean isDestroyed() { return false; }
- public void list() { }
- public final boolean parentOf(java.lang.ThreadGroup var0) { return false; }
- public final void setDaemon(boolean var0) { }
- public final void setMaxPriority(int var0) { }
- public java.lang.String toString() { return null; }
- public void uncaughtException(java.lang.Thread var0, java.lang.Throwable var1) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/ThreadLocal.java b/org.osgi.foundation/src/main/java/java/lang/ThreadLocal.java
deleted file mode 100644
index 436322c..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/ThreadLocal.java
+++ /dev/null
@@ -1,27 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/ThreadLocal.java,v 1.6 2006/03/14 01:20:24 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang;
-public class ThreadLocal {
- public ThreadLocal() { }
- public java.lang.Object get() { return null; }
- protected java.lang.Object initialValue() { return null; }
- public void set(java.lang.Object var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/Throwable.java b/org.osgi.foundation/src/main/java/java/lang/Throwable.java
deleted file mode 100644
index 3ba6ce0..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/Throwable.java
+++ /dev/null
@@ -1,32 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/Throwable.java,v 1.6 2006/03/14 01:20:24 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang;
-public class Throwable implements java.io.Serializable {
- public Throwable() { }
- public Throwable(java.lang.String var0) { }
- public java.lang.Throwable fillInStackTrace() { return null; }
- public java.lang.String getMessage() { return null; }
- public java.lang.String getLocalizedMessage() { return null; }
- public void printStackTrace() { }
- public void printStackTrace(java.io.PrintStream var0) { }
- public void printStackTrace(java.io.PrintWriter var0) { }
- public java.lang.String toString() { return null; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/UnknownError.java b/org.osgi.foundation/src/main/java/java/lang/UnknownError.java
deleted file mode 100644
index 5448e13..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/UnknownError.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/UnknownError.java,v 1.6 2006/03/14 01:20:25 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang;
-public class UnknownError extends java.lang.VirtualMachineError {
- public UnknownError() { }
- public UnknownError(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/UnsatisfiedLinkError.java b/org.osgi.foundation/src/main/java/java/lang/UnsatisfiedLinkError.java
deleted file mode 100644
index 0d080d7..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/UnsatisfiedLinkError.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/UnsatisfiedLinkError.java,v 1.6 2006/03/14 01:20:25 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang;
-public class UnsatisfiedLinkError extends java.lang.LinkageError {
- public UnsatisfiedLinkError() { }
- public UnsatisfiedLinkError(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/UnsupportedClassVersionError.java b/org.osgi.foundation/src/main/java/java/lang/UnsupportedClassVersionError.java
deleted file mode 100644
index 51af5b2..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/UnsupportedClassVersionError.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/UnsupportedClassVersionError.java,v 1.6 2006/03/14 01:20:25 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang;
-public class UnsupportedClassVersionError extends java.lang.ClassFormatError {
- public UnsupportedClassVersionError() { }
- public UnsupportedClassVersionError(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/UnsupportedOperationException.java b/org.osgi.foundation/src/main/java/java/lang/UnsupportedOperationException.java
deleted file mode 100644
index bdeb33a..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/UnsupportedOperationException.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/UnsupportedOperationException.java,v 1.6 2006/03/14 01:20:25 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang;
-public class UnsupportedOperationException extends java.lang.RuntimeException {
- public UnsupportedOperationException() { }
- public UnsupportedOperationException(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/VerifyError.java b/org.osgi.foundation/src/main/java/java/lang/VerifyError.java
deleted file mode 100644
index 7aeeb16..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/VerifyError.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/VerifyError.java,v 1.6 2006/03/14 01:20:25 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang;
-public class VerifyError extends java.lang.LinkageError {
- public VerifyError() { }
- public VerifyError(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/VirtualMachineError.java b/org.osgi.foundation/src/main/java/java/lang/VirtualMachineError.java
deleted file mode 100644
index a9aead0..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/VirtualMachineError.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/VirtualMachineError.java,v 1.6 2006/03/14 01:20:25 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang;
-public abstract class VirtualMachineError extends java.lang.Error {
- public VirtualMachineError() { }
- public VirtualMachineError(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/Void.java b/org.osgi.foundation/src/main/java/java/lang/Void.java
deleted file mode 100644
index 6cac9d2..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/Void.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/Void.java,v 1.6 2006/03/14 01:20:25 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang;
-public final class Void {
- public final static java.lang.Class TYPE; static { TYPE = null; }
- private Void() { } /* generated constructor to prevent compiler adding default public constructor */
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/ref/PhantomReference.java b/org.osgi.foundation/src/main/java/java/lang/ref/PhantomReference.java
deleted file mode 100644
index 8e93a24..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/ref/PhantomReference.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/ref/PhantomReference.java,v 1.6 2006/03/14 01:20:26 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang.ref;
-public class PhantomReference extends java.lang.ref.Reference {
- public java.lang.Object get() { return null; }
- public PhantomReference(java.lang.Object var0, java.lang.ref.ReferenceQueue var1) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/ref/Reference.java b/org.osgi.foundation/src/main/java/java/lang/ref/Reference.java
deleted file mode 100644
index 72e586c..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/ref/Reference.java
+++ /dev/null
@@ -1,28 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/ref/Reference.java,v 1.6 2006/03/14 01:20:26 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang.ref;
-public abstract class Reference {
- public void clear() { }
- public boolean enqueue() { return false; }
- public java.lang.Object get() { return null; }
- public boolean isEnqueued() { return false; }
- Reference() { } /* generated constructor to prevent compiler adding default public constructor */
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/ref/ReferenceQueue.java b/org.osgi.foundation/src/main/java/java/lang/ref/ReferenceQueue.java
deleted file mode 100644
index 4c6cc80..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/ref/ReferenceQueue.java
+++ /dev/null
@@ -1,27 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/ref/ReferenceQueue.java,v 1.6 2006/03/14 01:20:26 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang.ref;
-public class ReferenceQueue {
- public java.lang.ref.Reference poll() { return null; }
- public java.lang.ref.Reference remove() throws java.lang.InterruptedException { return null; }
- public java.lang.ref.Reference remove(long var0) throws java.lang.IllegalArgumentException, java.lang.InterruptedException { return null; }
- public ReferenceQueue() { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/ref/SoftReference.java b/org.osgi.foundation/src/main/java/java/lang/ref/SoftReference.java
deleted file mode 100644
index a4292bd..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/ref/SoftReference.java
+++ /dev/null
@@ -1,26 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/ref/SoftReference.java,v 1.6 2006/03/14 01:20:26 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang.ref;
-public class SoftReference extends java.lang.ref.Reference {
- public SoftReference(java.lang.Object var0, java.lang.ref.ReferenceQueue var1) { }
- public SoftReference(java.lang.Object var0) { }
- public java.lang.Object get() { return null; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/ref/WeakReference.java b/org.osgi.foundation/src/main/java/java/lang/ref/WeakReference.java
deleted file mode 100644
index e7944cf..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/ref/WeakReference.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/ref/WeakReference.java,v 1.6 2006/03/14 01:20:26 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang.ref;
-public class WeakReference extends java.lang.ref.Reference {
- public WeakReference(java.lang.Object var0, java.lang.ref.ReferenceQueue var1) { }
- public WeakReference(java.lang.Object var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/reflect/AccessibleObject.java b/org.osgi.foundation/src/main/java/java/lang/reflect/AccessibleObject.java
deleted file mode 100644
index 3053042..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/reflect/AccessibleObject.java
+++ /dev/null
@@ -1,27 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/reflect/AccessibleObject.java,v 1.6 2006/03/14 01:20:30 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang.reflect;
-public class AccessibleObject {
- protected AccessibleObject() { }
- public boolean isAccessible() { return false; }
- public static void setAccessible(java.lang.reflect.AccessibleObject[] var0, boolean var1) throws java.lang.SecurityException { }
- public void setAccessible(boolean var0) throws java.lang.SecurityException { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/reflect/Array.java b/org.osgi.foundation/src/main/java/java/lang/reflect/Array.java
deleted file mode 100644
index d54b1e2..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/reflect/Array.java
+++ /dev/null
@@ -1,45 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/reflect/Array.java,v 1.6 2006/03/14 01:20:30 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang.reflect;
-public final class Array {
- public static java.lang.Object get(java.lang.Object var0, int var1) throws java.lang.IllegalArgumentException, java.lang.ArrayIndexOutOfBoundsException { return null; }
- public static boolean getBoolean(java.lang.Object var0, int var1) throws java.lang.IllegalArgumentException, java.lang.ArrayIndexOutOfBoundsException { return false; }
- public static byte getByte(java.lang.Object var0, int var1) throws java.lang.IllegalArgumentException, java.lang.ArrayIndexOutOfBoundsException { return 0; }
- public static char getChar(java.lang.Object var0, int var1) throws java.lang.IllegalArgumentException, java.lang.ArrayIndexOutOfBoundsException { return 0; }
- public static double getDouble(java.lang.Object var0, int var1) throws java.lang.IllegalArgumentException, java.lang.ArrayIndexOutOfBoundsException { return 0.0d; }
- public static float getFloat(java.lang.Object var0, int var1) throws java.lang.IllegalArgumentException, java.lang.ArrayIndexOutOfBoundsException { return 0.0f; }
- public static int getInt(java.lang.Object var0, int var1) throws java.lang.IllegalArgumentException, java.lang.ArrayIndexOutOfBoundsException { return 0; }
- public static int getLength(java.lang.Object var0) throws java.lang.IllegalArgumentException { return 0; }
- public static long getLong(java.lang.Object var0, int var1) throws java.lang.IllegalArgumentException, java.lang.ArrayIndexOutOfBoundsException { return 0l; }
- public static short getShort(java.lang.Object var0, int var1) throws java.lang.IllegalArgumentException, java.lang.ArrayIndexOutOfBoundsException { return 0; }
- public static java.lang.Object newInstance(java.lang.Class var0, int[] var1) throws java.lang.NegativeArraySizeException, java.lang.IllegalArgumentException { return null; }
- public static java.lang.Object newInstance(java.lang.Class var0, int var1) throws java.lang.NegativeArraySizeException { return null; }
- public static void set(java.lang.Object var0, int var1, java.lang.Object var2) throws java.lang.IllegalArgumentException, java.lang.ArrayIndexOutOfBoundsException { }
- public static void setBoolean(java.lang.Object var0, int var1, boolean var2) throws java.lang.IllegalArgumentException, java.lang.ArrayIndexOutOfBoundsException { }
- public static void setByte(java.lang.Object var0, int var1, byte var2) throws java.lang.IllegalArgumentException, java.lang.ArrayIndexOutOfBoundsException { }
- public static void setChar(java.lang.Object var0, int var1, char var2) throws java.lang.IllegalArgumentException, java.lang.ArrayIndexOutOfBoundsException { }
- public static void setDouble(java.lang.Object var0, int var1, double var2) throws java.lang.IllegalArgumentException, java.lang.ArrayIndexOutOfBoundsException { }
- public static void setFloat(java.lang.Object var0, int var1, float var2) throws java.lang.IllegalArgumentException, java.lang.ArrayIndexOutOfBoundsException { }
- public static void setInt(java.lang.Object var0, int var1, int var2) throws java.lang.IllegalArgumentException, java.lang.ArrayIndexOutOfBoundsException { }
- public static void setLong(java.lang.Object var0, int var1, long var2) throws java.lang.IllegalArgumentException, java.lang.ArrayIndexOutOfBoundsException { }
- public static void setShort(java.lang.Object var0, int var1, short var2) throws java.lang.IllegalArgumentException, java.lang.ArrayIndexOutOfBoundsException { }
- private Array() { } /* generated constructor to prevent compiler adding default public constructor */
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/reflect/Constructor.java b/org.osgi.foundation/src/main/java/java/lang/reflect/Constructor.java
deleted file mode 100644
index e1ce9bf..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/reflect/Constructor.java
+++ /dev/null
@@ -1,33 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/reflect/Constructor.java,v 1.6 2006/03/14 01:20:30 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang.reflect;
-public final class Constructor extends java.lang.reflect.AccessibleObject implements java.lang.reflect.Member {
- public boolean equals(java.lang.Object var0) { return false; }
- public java.lang.Class getDeclaringClass() { return null; }
- public java.lang.Class[] getExceptionTypes() { return null; }
- public int getModifiers() { return 0; }
- public java.lang.String getName() { return null; }
- public java.lang.Class[] getParameterTypes() { return null; }
- public int hashCode() { return 0; }
- public java.lang.Object newInstance(java.lang.Object[] var0) throws java.lang.InstantiationException, java.lang.IllegalAccessException, java.lang.IllegalArgumentException, java.lang.reflect.InvocationTargetException { return null; }
- public java.lang.String toString() { return null; }
- private Constructor() { } /* generated constructor to prevent compiler adding default public constructor */
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/reflect/Field.java b/org.osgi.foundation/src/main/java/java/lang/reflect/Field.java
deleted file mode 100644
index c307f90..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/reflect/Field.java
+++ /dev/null
@@ -1,49 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/reflect/Field.java,v 1.6 2006/03/14 01:20:30 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang.reflect;
-public final class Field extends java.lang.reflect.AccessibleObject implements java.lang.reflect.Member {
- public boolean equals(java.lang.Object var0) { return false; }
- public java.lang.Object get(java.lang.Object var0) throws java.lang.IllegalAccessException, java.lang.IllegalArgumentException { return null; }
- public boolean getBoolean(java.lang.Object var0) throws java.lang.IllegalAccessException, java.lang.IllegalArgumentException { return false; }
- public byte getByte(java.lang.Object var0) throws java.lang.IllegalAccessException, java.lang.IllegalArgumentException { return 0; }
- public char getChar(java.lang.Object var0) throws java.lang.IllegalAccessException, java.lang.IllegalArgumentException { return 0; }
- public java.lang.Class getDeclaringClass() { return null; }
- public double getDouble(java.lang.Object var0) throws java.lang.IllegalAccessException, java.lang.IllegalArgumentException { return 0.0d; }
- public float getFloat(java.lang.Object var0) throws java.lang.IllegalAccessException, java.lang.IllegalArgumentException { return 0.0f; }
- public int getInt(java.lang.Object var0) throws java.lang.IllegalAccessException, java.lang.IllegalArgumentException { return 0; }
- public long getLong(java.lang.Object var0) throws java.lang.IllegalAccessException, java.lang.IllegalArgumentException { return 0l; }
- public int getModifiers() { return 0; }
- public java.lang.String getName() { return null; }
- public short getShort(java.lang.Object var0) throws java.lang.IllegalAccessException, java.lang.IllegalArgumentException { return 0; }
- public java.lang.Class getType() { return null; }
- public int hashCode() { return 0; }
- public void set(java.lang.Object var0, java.lang.Object var1) throws java.lang.IllegalAccessException, java.lang.IllegalArgumentException { }
- public void setBoolean(java.lang.Object var0, boolean var1) throws java.lang.IllegalAccessException, java.lang.IllegalArgumentException { }
- public void setByte(java.lang.Object var0, byte var1) throws java.lang.IllegalAccessException, java.lang.IllegalArgumentException { }
- public void setChar(java.lang.Object var0, char var1) throws java.lang.IllegalAccessException, java.lang.IllegalArgumentException { }
- public void setDouble(java.lang.Object var0, double var1) throws java.lang.IllegalAccessException, java.lang.IllegalArgumentException { }
- public void setFloat(java.lang.Object var0, float var1) throws java.lang.IllegalAccessException, java.lang.IllegalArgumentException { }
- public void setInt(java.lang.Object var0, int var1) throws java.lang.IllegalAccessException, java.lang.IllegalArgumentException { }
- public void setLong(java.lang.Object var0, long var1) throws java.lang.IllegalAccessException, java.lang.IllegalArgumentException { }
- public void setShort(java.lang.Object var0, short var1) throws java.lang.IllegalAccessException, java.lang.IllegalArgumentException { }
- public java.lang.String toString() { return null; }
- private Field() { } /* generated constructor to prevent compiler adding default public constructor */
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/reflect/InvocationHandler.java b/org.osgi.foundation/src/main/java/java/lang/reflect/InvocationHandler.java
deleted file mode 100644
index ded5134..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/reflect/InvocationHandler.java
+++ /dev/null
@@ -1,24 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/reflect/InvocationHandler.java,v 1.6 2006/03/14 01:20:30 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang.reflect;
-public abstract interface InvocationHandler {
- public abstract java.lang.Object invoke(java.lang.Object var0, java.lang.reflect.Method var1, java.lang.Object[] var2) throws java.lang.Throwable;
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/reflect/InvocationTargetException.java b/org.osgi.foundation/src/main/java/java/lang/reflect/InvocationTargetException.java
deleted file mode 100644
index b78019d..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/reflect/InvocationTargetException.java
+++ /dev/null
@@ -1,30 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/reflect/InvocationTargetException.java,v 1.6 2006/03/14 01:20:30 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang.reflect;
-public class InvocationTargetException extends java.lang.Exception {
- protected InvocationTargetException() { }
- public InvocationTargetException(java.lang.Throwable var0) { }
- public InvocationTargetException(java.lang.Throwable var0, java.lang.String var1) { }
- public java.lang.Throwable getTargetException() { return null; }
- public void printStackTrace() { }
- public void printStackTrace(java.io.PrintStream var0) { }
- public void printStackTrace(java.io.PrintWriter var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/reflect/Member.java b/org.osgi.foundation/src/main/java/java/lang/reflect/Member.java
deleted file mode 100644
index 7f79e35..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/reflect/Member.java
+++ /dev/null
@@ -1,28 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/reflect/Member.java,v 1.6 2006/03/14 01:20:30 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang.reflect;
-public abstract interface Member {
- public abstract java.lang.Class getDeclaringClass();
- public abstract int getModifiers();
- public abstract java.lang.String getName();
- public final static int PUBLIC = 0;
- public final static int DECLARED = 1;
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/reflect/Method.java b/org.osgi.foundation/src/main/java/java/lang/reflect/Method.java
deleted file mode 100644
index ba6fe1e..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/reflect/Method.java
+++ /dev/null
@@ -1,34 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/reflect/Method.java,v 1.6 2006/03/14 01:20:30 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang.reflect;
-public final class Method extends java.lang.reflect.AccessibleObject implements java.lang.reflect.Member {
- public boolean equals(java.lang.Object var0) { return false; }
- public java.lang.Class getDeclaringClass() { return null; }
- public java.lang.Class[] getExceptionTypes() { return null; }
- public int getModifiers() { return 0; }
- public java.lang.String getName() { return null; }
- public java.lang.Class[] getParameterTypes() { return null; }
- public java.lang.Class getReturnType() { return null; }
- public int hashCode() { return 0; }
- public java.lang.Object invoke(java.lang.Object var0, java.lang.Object[] var1) throws java.lang.IllegalAccessException, java.lang.IllegalArgumentException, java.lang.reflect.InvocationTargetException { return null; }
- public java.lang.String toString() { return null; }
- private Method() { } /* generated constructor to prevent compiler adding default public constructor */
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/reflect/Modifier.java b/org.osgi.foundation/src/main/java/java/lang/reflect/Modifier.java
deleted file mode 100644
index b2941ad..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/reflect/Modifier.java
+++ /dev/null
@@ -1,49 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/reflect/Modifier.java,v 1.6 2006/03/14 01:20:30 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang.reflect;
-public class Modifier {
- public Modifier() { }
- public static boolean isAbstract(int var0) { return false; }
- public static boolean isFinal(int var0) { return false; }
- public static boolean isInterface(int var0) { return false; }
- public static boolean isNative(int var0) { return false; }
- public static boolean isPrivate(int var0) { return false; }
- public static boolean isProtected(int var0) { return false; }
- public static boolean isPublic(int var0) { return false; }
- public static boolean isStatic(int var0) { return false; }
- public static boolean isStrict(int var0) { return false; }
- public static boolean isSynchronized(int var0) { return false; }
- public static boolean isTransient(int var0) { return false; }
- public static boolean isVolatile(int var0) { return false; }
- public static java.lang.String toString(int var0) { return null; }
- public final static int PUBLIC = 1;
- public final static int PRIVATE = 2;
- public final static int PROTECTED = 4;
- public final static int STATIC = 8;
- public final static int FINAL = 16;
- public final static int SYNCHRONIZED = 32;
- public final static int VOLATILE = 64;
- public final static int TRANSIENT = 128;
- public final static int NATIVE = 256;
- public final static int INTERFACE = 512;
- public final static int ABSTRACT = 1024;
- public final static int STRICT = 2048;
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/reflect/Proxy.java b/org.osgi.foundation/src/main/java/java/lang/reflect/Proxy.java
deleted file mode 100644
index d6409a9..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/reflect/Proxy.java
+++ /dev/null
@@ -1,29 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/reflect/Proxy.java,v 1.6 2006/03/14 01:20:30 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang.reflect;
-public class Proxy implements java.io.Serializable {
- protected Proxy(java.lang.reflect.InvocationHandler var0) { }
- public static java.lang.Class getProxyClass(java.lang.ClassLoader var0, java.lang.Class[] var1) throws java.lang.IllegalArgumentException { return null; }
- public static java.lang.Object newProxyInstance(java.lang.ClassLoader var0, java.lang.Class[] var1, java.lang.reflect.InvocationHandler var2) throws java.lang.IllegalArgumentException { return null; }
- public static boolean isProxyClass(java.lang.Class var0) { return false; }
- public static java.lang.reflect.InvocationHandler getInvocationHandler(java.lang.Object var0) throws java.lang.IllegalArgumentException { return null; }
- protected java.lang.reflect.InvocationHandler h;
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/reflect/ReflectPermission.java b/org.osgi.foundation/src/main/java/java/lang/reflect/ReflectPermission.java
deleted file mode 100644
index 9c51e2c..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/reflect/ReflectPermission.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/reflect/ReflectPermission.java,v 1.6 2006/03/14 01:20:30 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang.reflect;
-public final class ReflectPermission extends java.security.BasicPermission {
- public ReflectPermission(java.lang.String var0) { super((java.lang.String) null, (java.lang.String) null); }
- public ReflectPermission(java.lang.String var0, java.lang.String var1) { super((java.lang.String) null, (java.lang.String) null); }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/lang/reflect/UndeclaredThrowableException.java b/org.osgi.foundation/src/main/java/java/lang/reflect/UndeclaredThrowableException.java
deleted file mode 100644
index e4b4c88..0000000
--- a/org.osgi.foundation/src/main/java/java/lang/reflect/UndeclaredThrowableException.java
+++ /dev/null
@@ -1,29 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/lang/reflect/UndeclaredThrowableException.java,v 1.6 2006/03/14 01:20:30 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.lang.reflect;
-public class UndeclaredThrowableException extends java.lang.RuntimeException {
- public UndeclaredThrowableException(java.lang.Throwable var0) { }
- public UndeclaredThrowableException(java.lang.Throwable var0, java.lang.String var1) { }
- public java.lang.Throwable getUndeclaredThrowable() { return null; }
- public void printStackTrace() { }
- public void printStackTrace(java.io.PrintStream var0) { }
- public void printStackTrace(java.io.PrintWriter var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/math/BigInteger.java b/org.osgi.foundation/src/main/java/java/math/BigInteger.java
deleted file mode 100644
index 8a804de..0000000
--- a/org.osgi.foundation/src/main/java/java/math/BigInteger.java
+++ /dev/null
@@ -1,74 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/math/BigInteger.java,v 1.6 2006/03/14 01:20:30 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.math;
-public class BigInteger extends java.lang.Number implements java.lang.Comparable {
- public BigInteger(int var0, java.util.Random var1) { }
- public BigInteger(int var0, int var1, java.util.Random var2) { }
- public BigInteger(byte[] var0) { }
- public BigInteger(int var0, byte[] var1) { }
- public byte[] toByteArray() { return null; }
- public boolean isProbablePrime(int var0) { return false; }
- public boolean equals(java.lang.Object var0) { return false; }
- public int compareTo(java.math.BigInteger var0) { return 0; }
- public int compareTo(java.lang.Object var0) { return 0; }
- public int intValue() { return 0; }
- public long longValue() { return 0l; }
- public static java.math.BigInteger valueOf(long var0) { return null; }
- public java.math.BigInteger add(java.math.BigInteger var0) { return null; }
- public java.math.BigInteger negate() { return null; }
- public int signum() { return 0; }
- public java.math.BigInteger abs() { return null; }
- public java.math.BigInteger pow(int var0) { return null; }
- public java.math.BigInteger modPow(java.math.BigInteger var0, java.math.BigInteger var1) { return null; }
- public java.math.BigInteger gcd(java.math.BigInteger var0) { return null; }
- public java.math.BigInteger modInverse(java.math.BigInteger var0) { return null; }
- public int getLowestSetBit() { return 0; }
- public java.math.BigInteger shiftRight(int var0) { return null; }
- public java.math.BigInteger shiftLeft(int var0) { return null; }
- public java.math.BigInteger subtract(java.math.BigInteger var0) { return null; }
- public java.math.BigInteger multiply(java.math.BigInteger var0) { return null; }
- public java.math.BigInteger divide(java.math.BigInteger var0) { return null; }
- public java.math.BigInteger remainder(java.math.BigInteger var0) { return null; }
- public java.math.BigInteger mod(java.math.BigInteger var0) { return null; }
- public java.math.BigInteger[] divideAndRemainder(java.math.BigInteger var0) { return null; }
- public BigInteger(java.lang.String var0) { }
- public BigInteger(java.lang.String var0, int var1) { }
- public java.lang.String toString() { return null; }
- public java.lang.String toString(int var0) { return null; }
- public java.math.BigInteger max(java.math.BigInteger var0) { return null; }
- public java.math.BigInteger min(java.math.BigInteger var0) { return null; }
- public int hashCode() { return 0; }
- public boolean testBit(int var0) { return false; }
- public java.math.BigInteger setBit(int var0) { return null; }
- public java.math.BigInteger clearBit(int var0) { return null; }
- public java.math.BigInteger flipBit(int var0) { return null; }
- public java.math.BigInteger and(java.math.BigInteger var0) { return null; }
- public java.math.BigInteger or(java.math.BigInteger var0) { return null; }
- public java.math.BigInteger xor(java.math.BigInteger var0) { return null; }
- public java.math.BigInteger not() { return null; }
- public java.math.BigInteger andNot(java.math.BigInteger var0) { return null; }
- public int bitLength() { return 0; }
- public int bitCount() { return 0; }
- public double doubleValue() { return 0.0d; }
- public float floatValue() { return 0.0f; }
- public final static java.math.BigInteger ZERO; static { ZERO = null; }
- public final static java.math.BigInteger ONE; static { ONE = null; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/net/Authenticator.java b/org.osgi.foundation/src/main/java/java/net/Authenticator.java
deleted file mode 100644
index 18e4967..0000000
--- a/org.osgi.foundation/src/main/java/java/net/Authenticator.java
+++ /dev/null
@@ -1,32 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/net/Authenticator.java,v 1.6 2006/03/14 01:20:23 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.net;
-public abstract class Authenticator {
- public Authenticator() { }
- protected java.net.PasswordAuthentication getPasswordAuthentication() { return null; }
- protected final int getRequestingPort() { return 0; }
- protected final java.net.InetAddress getRequestingSite() { return null; }
- protected final java.lang.String getRequestingPrompt() { return null; }
- protected final java.lang.String getRequestingProtocol() { return null; }
- protected final java.lang.String getRequestingScheme() { return null; }
- public static java.net.PasswordAuthentication requestPasswordAuthentication(java.net.InetAddress var0, int var1, java.lang.String var2, java.lang.String var3, java.lang.String var4) { return null; }
- public static void setDefault(java.net.Authenticator var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/net/BindException.java b/org.osgi.foundation/src/main/java/java/net/BindException.java
deleted file mode 100644
index f8b462e..0000000
--- a/org.osgi.foundation/src/main/java/java/net/BindException.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/net/BindException.java,v 1.6 2006/03/14 01:20:23 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.net;
-public class BindException extends java.net.SocketException {
- public BindException() { }
- public BindException(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/net/ConnectException.java b/org.osgi.foundation/src/main/java/java/net/ConnectException.java
deleted file mode 100644
index 6a4f0b3..0000000
--- a/org.osgi.foundation/src/main/java/java/net/ConnectException.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/net/ConnectException.java,v 1.6 2006/03/14 01:20:23 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.net;
-public class ConnectException extends java.net.SocketException {
- public ConnectException() { }
- public ConnectException(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/net/ContentHandler.java b/org.osgi.foundation/src/main/java/java/net/ContentHandler.java
deleted file mode 100644
index bdb8ea9..0000000
--- a/org.osgi.foundation/src/main/java/java/net/ContentHandler.java
+++ /dev/null
@@ -1,26 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/net/ContentHandler.java,v 1.6 2006/03/14 01:20:23 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.net;
-public abstract class ContentHandler {
- public ContentHandler() { }
- public abstract java.lang.Object getContent(java.net.URLConnection var0) throws java.io.IOException;
- public java.lang.Object getContent(java.net.URLConnection var0, java.lang.Class[] var1) throws java.io.IOException { return null; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/net/ContentHandlerFactory.java b/org.osgi.foundation/src/main/java/java/net/ContentHandlerFactory.java
deleted file mode 100644
index 9187dc0..0000000
--- a/org.osgi.foundation/src/main/java/java/net/ContentHandlerFactory.java
+++ /dev/null
@@ -1,24 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/net/ContentHandlerFactory.java,v 1.6 2006/03/14 01:20:23 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.net;
-public abstract interface ContentHandlerFactory {
- public abstract java.net.ContentHandler createContentHandler(java.lang.String var0);
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/net/DatagramPacket.java b/org.osgi.foundation/src/main/java/java/net/DatagramPacket.java
deleted file mode 100644
index f372777..0000000
--- a/org.osgi.foundation/src/main/java/java/net/DatagramPacket.java
+++ /dev/null
@@ -1,37 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/net/DatagramPacket.java,v 1.6 2006/03/14 01:20:23 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.net;
-public final class DatagramPacket {
- public DatagramPacket(byte[] var0, int var1) { }
- public DatagramPacket(byte[] var0, int var1, int var2) { }
- public DatagramPacket(byte[] var0, int var1, int var2, java.net.InetAddress var3, int var4) { }
- public DatagramPacket(byte[] var0, int var1, java.net.InetAddress var2, int var3) { }
- public java.net.InetAddress getAddress() { return null; }
- public byte[] getData() { return null; }
- public int getLength() { return 0; }
- public int getOffset() { return 0; }
- public int getPort() { return 0; }
- public void setAddress(java.net.InetAddress var0) { }
- public void setData(byte[] var0, int var1, int var2) { }
- public void setData(byte[] var0) { }
- public void setLength(int var0) { }
- public void setPort(int var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/net/DatagramSocket.java b/org.osgi.foundation/src/main/java/java/net/DatagramSocket.java
deleted file mode 100644
index 882be3f..0000000
--- a/org.osgi.foundation/src/main/java/java/net/DatagramSocket.java
+++ /dev/null
@@ -1,42 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/net/DatagramSocket.java,v 1.6 2006/03/14 01:20:23 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.net;
-public class DatagramSocket {
- public DatagramSocket() throws java.net.SocketException { }
- public DatagramSocket(int var0) throws java.net.SocketException { }
- public DatagramSocket(int var0, java.net.InetAddress var1) throws java.net.SocketException { }
- public void close() { }
- public void connect(java.net.InetAddress var0, int var1) { }
- public void disconnect() { }
- public java.net.InetAddress getInetAddress() { return null; }
- public java.net.InetAddress getLocalAddress() { return null; }
- public int getLocalPort() { return 0; }
- public int getPort() { return 0; }
- public int getReceiveBufferSize() throws java.net.SocketException { return 0; }
- public int getSendBufferSize() throws java.net.SocketException { return 0; }
- public int getSoTimeout() throws java.net.SocketException { return 0; }
- public void receive(java.net.DatagramPacket var0) throws java.io.IOException { }
- public void send(java.net.DatagramPacket var0) throws java.io.IOException { }
- public void setSendBufferSize(int var0) throws java.net.SocketException { }
- public void setReceiveBufferSize(int var0) throws java.net.SocketException { }
- public void setSoTimeout(int var0) throws java.net.SocketException { }
- public static void setDatagramSocketImplFactory(java.net.DatagramSocketImplFactory var0) throws java.io.IOException { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/net/DatagramSocketImpl.java b/org.osgi.foundation/src/main/java/java/net/DatagramSocketImpl.java
deleted file mode 100644
index 02d40af..0000000
--- a/org.osgi.foundation/src/main/java/java/net/DatagramSocketImpl.java
+++ /dev/null
@@ -1,40 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/net/DatagramSocketImpl.java,v 1.6 2006/03/14 01:20:23 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.net;
-public abstract class DatagramSocketImpl implements java.net.SocketOptions {
- public DatagramSocketImpl() { }
- protected abstract void bind(int var0, java.net.InetAddress var1) throws java.net.SocketException;
- protected abstract void close();
- protected abstract void create() throws java.net.SocketException;
- protected java.io.FileDescriptor getFileDescriptor() { return null; }
- protected int getLocalPort() { return 0; }
- public abstract java.lang.Object getOption(int var0) throws java.net.SocketException;
- protected abstract int getTimeToLive() throws java.io.IOException;
- protected abstract void join(java.net.InetAddress var0) throws java.io.IOException;
- protected abstract void leave(java.net.InetAddress var0) throws java.io.IOException;
- protected abstract int peek(java.net.InetAddress var0) throws java.io.IOException;
- protected abstract void receive(java.net.DatagramPacket var0) throws java.io.IOException;
- protected abstract void send(java.net.DatagramPacket var0) throws java.io.IOException;
- public abstract void setOption(int var0, java.lang.Object var1) throws java.net.SocketException;
- protected abstract void setTimeToLive(int var0) throws java.io.IOException;
- protected java.io.FileDescriptor fd;
- protected int localPort;
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/net/DatagramSocketImplFactory.java b/org.osgi.foundation/src/main/java/java/net/DatagramSocketImplFactory.java
deleted file mode 100644
index 55fa9cf..0000000
--- a/org.osgi.foundation/src/main/java/java/net/DatagramSocketImplFactory.java
+++ /dev/null
@@ -1,24 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/net/DatagramSocketImplFactory.java,v 1.6 2006/03/14 01:20:23 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.net;
-public abstract interface DatagramSocketImplFactory {
- public abstract java.net.DatagramSocketImpl createDatagramSocketImpl();
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/net/FileNameMap.java b/org.osgi.foundation/src/main/java/java/net/FileNameMap.java
deleted file mode 100644
index b7c1d39..0000000
--- a/org.osgi.foundation/src/main/java/java/net/FileNameMap.java
+++ /dev/null
@@ -1,24 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/net/FileNameMap.java,v 1.6 2006/03/14 01:20:23 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.net;
-public abstract interface FileNameMap {
- public abstract java.lang.String getContentTypeFor(java.lang.String var0);
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/net/HttpURLConnection.java b/org.osgi.foundation/src/main/java/java/net/HttpURLConnection.java
deleted file mode 100644
index 437ba99..0000000
--- a/org.osgi.foundation/src/main/java/java/net/HttpURLConnection.java
+++ /dev/null
@@ -1,76 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/net/HttpURLConnection.java,v 1.6 2006/03/14 01:20:23 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.net;
-public abstract class HttpURLConnection extends java.net.URLConnection {
- protected HttpURLConnection(java.net.URL var0) { super((java.net.URL) null); }
- public abstract void disconnect();
- public java.io.InputStream getErrorStream() { return null; }
- public static boolean getFollowRedirects() { return false; }
- public java.security.Permission getPermission() throws java.io.IOException { return null; }
- public java.lang.String getRequestMethod() { return null; }
- public int getResponseCode() throws java.io.IOException { return 0; }
- public java.lang.String getResponseMessage() throws java.io.IOException { return null; }
- public static void setFollowRedirects(boolean var0) { }
- public void setRequestMethod(java.lang.String var0) throws java.net.ProtocolException { }
- public abstract boolean usingProxy();
- public boolean getInstanceFollowRedirects() { return false; }
- public void setInstanceFollowRedirects(boolean var0) { }
- public long getHeaderFieldDate(java.lang.String var0, long var1) { return 0l; }
- protected java.lang.String method;
- protected int responseCode;
- protected java.lang.String responseMessage;
- protected boolean instanceFollowRedirects;
- public final static int HTTP_ACCEPTED = 202;
- public final static int HTTP_BAD_GATEWAY = 502;
- public final static int HTTP_BAD_METHOD = 405;
- public final static int HTTP_BAD_REQUEST = 400;
- public final static int HTTP_CLIENT_TIMEOUT = 408;
- public final static int HTTP_CONFLICT = 409;
- public final static int HTTP_CREATED = 201;
- public final static int HTTP_ENTITY_TOO_LARGE = 413;
- public final static int HTTP_FORBIDDEN = 403;
- public final static int HTTP_GATEWAY_TIMEOUT = 504;
- public final static int HTTP_GONE = 410;
- public final static int HTTP_INTERNAL_ERROR = 500;
- public final static int HTTP_LENGTH_REQUIRED = 411;
- public final static int HTTP_MOVED_PERM = 301;
- public final static int HTTP_MOVED_TEMP = 302;
- public final static int HTTP_MULT_CHOICE = 300;
- public final static int HTTP_NO_CONTENT = 204;
- public final static int HTTP_NOT_ACCEPTABLE = 406;
- public final static int HTTP_NOT_AUTHORITATIVE = 203;
- public final static int HTTP_NOT_FOUND = 404;
- public final static int HTTP_NOT_IMPLEMENTED = 501;
- public final static int HTTP_NOT_MODIFIED = 304;
- public final static int HTTP_OK = 200;
- public final static int HTTP_PARTIAL = 206;
- public final static int HTTP_PAYMENT_REQUIRED = 402;
- public final static int HTTP_PRECON_FAILED = 412;
- public final static int HTTP_PROXY_AUTH = 407;
- public final static int HTTP_REQ_TOO_LONG = 414;
- public final static int HTTP_RESET = 205;
- public final static int HTTP_SEE_OTHER = 303;
- public final static int HTTP_USE_PROXY = 305;
- public final static int HTTP_UNAUTHORIZED = 401;
- public final static int HTTP_UNSUPPORTED_TYPE = 415;
- public final static int HTTP_UNAVAILABLE = 503;
- public final static int HTTP_VERSION = 505;
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/net/InetAddress.java b/org.osgi.foundation/src/main/java/java/net/InetAddress.java
deleted file mode 100644
index 3fada7f..0000000
--- a/org.osgi.foundation/src/main/java/java/net/InetAddress.java
+++ /dev/null
@@ -1,34 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/net/InetAddress.java,v 1.6 2006/03/14 01:20:23 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.net;
-public final class InetAddress implements java.io.Serializable {
- public boolean equals(java.lang.Object var0) { return false; }
- public byte[] getAddress() { return null; }
- public static java.net.InetAddress[] getAllByName(java.lang.String var0) throws java.net.UnknownHostException { return null; }
- public static java.net.InetAddress getByName(java.lang.String var0) throws java.net.UnknownHostException { return null; }
- public java.lang.String getHostAddress() { return null; }
- public java.lang.String getHostName() { return null; }
- public static java.net.InetAddress getLocalHost() throws java.net.UnknownHostException { return null; }
- public int hashCode() { return 0; }
- public boolean isMulticastAddress() { return false; }
- public java.lang.String toString() { return null; }
- private InetAddress() { } /* generated constructor to prevent compiler adding default public constructor */
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/net/JarURLConnection.java b/org.osgi.foundation/src/main/java/java/net/JarURLConnection.java
deleted file mode 100644
index 4569ecc..0000000
--- a/org.osgi.foundation/src/main/java/java/net/JarURLConnection.java
+++ /dev/null
@@ -1,33 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/net/JarURLConnection.java,v 1.6 2006/03/14 01:20:23 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.net;
-public abstract class JarURLConnection extends java.net.URLConnection {
- protected JarURLConnection(java.net.URL var0) throws java.net.MalformedURLException { super((java.net.URL) null); }
- public java.util.jar.Attributes getAttributes() throws java.io.IOException { return null; }
- public java.security.cert.Certificate[] getCertificates() throws java.io.IOException { return null; }
- public java.lang.String getEntryName() { return null; }
- public java.util.jar.JarEntry getJarEntry() throws java.io.IOException { return null; }
- public java.util.jar.Manifest getManifest() throws java.io.IOException { return null; }
- public abstract java.util.jar.JarFile getJarFile() throws java.io.IOException;
- public java.net.URL getJarFileURL() { return null; }
- public java.util.jar.Attributes getMainAttributes() throws java.io.IOException { return null; }
- protected java.net.URLConnection jarFileURLConnection;
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/net/MalformedURLException.java b/org.osgi.foundation/src/main/java/java/net/MalformedURLException.java
deleted file mode 100644
index dd346de..0000000
--- a/org.osgi.foundation/src/main/java/java/net/MalformedURLException.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/net/MalformedURLException.java,v 1.6 2006/03/14 01:20:23 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.net;
-public class MalformedURLException extends java.io.IOException {
- public MalformedURLException() { }
- public MalformedURLException(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/net/MulticastSocket.java b/org.osgi.foundation/src/main/java/java/net/MulticastSocket.java
deleted file mode 100644
index 0684c74..0000000
--- a/org.osgi.foundation/src/main/java/java/net/MulticastSocket.java
+++ /dev/null
@@ -1,32 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/net/MulticastSocket.java,v 1.6 2006/03/14 01:20:23 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.net;
-public class MulticastSocket extends java.net.DatagramSocket {
- public MulticastSocket() throws java.io.IOException { }
- public MulticastSocket(int var0) throws java.io.IOException { }
- public java.net.InetAddress getInterface() throws java.net.SocketException { return null; }
- public int getTimeToLive() throws java.io.IOException { return 0; }
- public void joinGroup(java.net.InetAddress var0) throws java.io.IOException { }
- public void leaveGroup(java.net.InetAddress var0) throws java.io.IOException { }
- public void send(java.net.DatagramPacket var0, byte var1) throws java.io.IOException { }
- public void setInterface(java.net.InetAddress var0) throws java.net.SocketException { }
- public void setTimeToLive(int var0) throws java.io.IOException { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/net/NetPermission.java b/org.osgi.foundation/src/main/java/java/net/NetPermission.java
deleted file mode 100644
index 06c224a..0000000
--- a/org.osgi.foundation/src/main/java/java/net/NetPermission.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/net/NetPermission.java,v 1.6 2006/03/14 01:20:23 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.net;
-public final class NetPermission extends java.security.BasicPermission {
- public NetPermission(java.lang.String var0) { super((java.lang.String) null, (java.lang.String) null); }
- public NetPermission(java.lang.String var0, java.lang.String var1) { super((java.lang.String) null, (java.lang.String) null); }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/net/NoRouteToHostException.java b/org.osgi.foundation/src/main/java/java/net/NoRouteToHostException.java
deleted file mode 100644
index d25129c..0000000
--- a/org.osgi.foundation/src/main/java/java/net/NoRouteToHostException.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/net/NoRouteToHostException.java,v 1.6 2006/03/14 01:20:23 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.net;
-public class NoRouteToHostException extends java.net.SocketException {
- public NoRouteToHostException() { }
- public NoRouteToHostException(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/net/PasswordAuthentication.java b/org.osgi.foundation/src/main/java/java/net/PasswordAuthentication.java
deleted file mode 100644
index 74105b0..0000000
--- a/org.osgi.foundation/src/main/java/java/net/PasswordAuthentication.java
+++ /dev/null
@@ -1,26 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/net/PasswordAuthentication.java,v 1.6 2006/03/14 01:20:23 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.net;
-public final class PasswordAuthentication {
- public PasswordAuthentication(java.lang.String var0, char[] var1) { }
- public char[] getPassword() { return null; }
- public java.lang.String getUserName() { return null; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/net/ProtocolException.java b/org.osgi.foundation/src/main/java/java/net/ProtocolException.java
deleted file mode 100644
index 8585cc2..0000000
--- a/org.osgi.foundation/src/main/java/java/net/ProtocolException.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/net/ProtocolException.java,v 1.6 2006/03/14 01:20:23 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.net;
-public class ProtocolException extends java.io.IOException {
- public ProtocolException() { }
- public ProtocolException(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/net/ServerSocket.java b/org.osgi.foundation/src/main/java/java/net/ServerSocket.java
deleted file mode 100644
index fcc1c58..0000000
--- a/org.osgi.foundation/src/main/java/java/net/ServerSocket.java
+++ /dev/null
@@ -1,35 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/net/ServerSocket.java,v 1.6 2006/03/14 01:20:23 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.net;
-public class ServerSocket {
- public ServerSocket(int var0) throws java.io.IOException { }
- public ServerSocket(int var0, int var1) throws java.io.IOException { }
- public ServerSocket(int var0, int var1, java.net.InetAddress var2) throws java.io.IOException { }
- public java.net.Socket accept() throws java.io.IOException { return null; }
- public void close() throws java.io.IOException { }
- public java.net.InetAddress getInetAddress() { return null; }
- public int getLocalPort() { return 0; }
- public int getSoTimeout() throws java.io.IOException { return 0; }
- protected final void implAccept(java.net.Socket var0) throws java.io.IOException { }
- public static void setSocketFactory(java.net.SocketImplFactory var0) throws java.io.IOException { }
- public void setSoTimeout(int var0) throws java.net.SocketException { }
- public java.lang.String toString() { return null; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/net/Socket.java b/org.osgi.foundation/src/main/java/java/net/Socket.java
deleted file mode 100644
index 2203466..0000000
--- a/org.osgi.foundation/src/main/java/java/net/Socket.java
+++ /dev/null
@@ -1,52 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/net/Socket.java,v 1.6 2006/03/14 01:20:23 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.net;
-public class Socket {
- protected Socket() { }
- public Socket(java.lang.String var0, int var1) throws java.net.UnknownHostException, java.io.IOException { }
- public Socket(java.lang.String var0, int var1, java.net.InetAddress var2, int var3) throws java.io.IOException { }
- public Socket(java.net.InetAddress var0, int var1) throws java.io.IOException { }
- public Socket(java.net.InetAddress var0, int var1, java.net.InetAddress var2, int var3) throws java.io.IOException { }
- protected Socket(java.net.SocketImpl var0) throws java.net.SocketException { }
- public void close() throws java.io.IOException { }
- public java.net.InetAddress getInetAddress() { return null; }
- public java.io.InputStream getInputStream() throws java.io.IOException { return null; }
- public boolean getKeepAlive() throws java.net.SocketException { return false; }
- public java.net.InetAddress getLocalAddress() { return null; }
- public int getLocalPort() { return 0; }
- public java.io.OutputStream getOutputStream() throws java.io.IOException { return null; }
- public int getPort() { return 0; }
- public int getSoLinger() throws java.net.SocketException { return 0; }
- public int getReceiveBufferSize() throws java.net.SocketException { return 0; }
- public int getSendBufferSize() throws java.net.SocketException { return 0; }
- public int getSoTimeout() throws java.net.SocketException { return 0; }
- public boolean getTcpNoDelay() throws java.net.SocketException { return false; }
- public void setKeepAlive(boolean var0) throws java.net.SocketException { }
- public static void setSocketImplFactory(java.net.SocketImplFactory var0) throws java.io.IOException { }
- public void setSendBufferSize(int var0) throws java.net.SocketException { }
- public void setReceiveBufferSize(int var0) throws java.net.SocketException { }
- public void setSoLinger(boolean var0, int var1) throws java.net.SocketException { }
- public void setSoTimeout(int var0) throws java.net.SocketException { }
- public void setTcpNoDelay(boolean var0) throws java.net.SocketException { }
- public java.lang.String toString() { return null; }
- public void shutdownInput() throws java.io.IOException { }
- public void shutdownOutput() throws java.io.IOException { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/net/SocketException.java b/org.osgi.foundation/src/main/java/java/net/SocketException.java
deleted file mode 100644
index 1f86187..0000000
--- a/org.osgi.foundation/src/main/java/java/net/SocketException.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/net/SocketException.java,v 1.6 2006/03/14 01:20:23 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.net;
-public class SocketException extends java.io.IOException {
- public SocketException() { }
- public SocketException(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/net/SocketImpl.java b/org.osgi.foundation/src/main/java/java/net/SocketImpl.java
deleted file mode 100644
index 97ec92f..0000000
--- a/org.osgi.foundation/src/main/java/java/net/SocketImpl.java
+++ /dev/null
@@ -1,47 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/net/SocketImpl.java,v 1.6 2006/03/14 01:20:23 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.net;
-public abstract class SocketImpl implements java.net.SocketOptions {
- public SocketImpl() { }
- protected abstract void accept(java.net.SocketImpl var0) throws java.io.IOException;
- protected abstract int available() throws java.io.IOException;
- protected abstract void bind(java.net.InetAddress var0, int var1) throws java.io.IOException;
- protected abstract void close() throws java.io.IOException;
- protected abstract void connect(java.lang.String var0, int var1) throws java.io.IOException;
- protected abstract void connect(java.net.InetAddress var0, int var1) throws java.io.IOException;
- protected abstract void create(boolean var0) throws java.io.IOException;
- protected java.io.FileDescriptor getFileDescriptor() { return null; }
- protected java.net.InetAddress getInetAddress() { return null; }
- protected abstract java.io.InputStream getInputStream() throws java.io.IOException;
- protected int getLocalPort() { return 0; }
- public abstract java.lang.Object getOption(int var0) throws java.net.SocketException;
- protected abstract java.io.OutputStream getOutputStream() throws java.io.IOException;
- protected int getPort() { return 0; }
- protected abstract void listen(int var0) throws java.io.IOException;
- public abstract void setOption(int var0, java.lang.Object var1) throws java.net.SocketException;
- public java.lang.String toString() { return null; }
- protected void shutdownInput() throws java.io.IOException { }
- protected void shutdownOutput() throws java.io.IOException { }
- protected java.net.InetAddress address;
- protected int port;
- protected java.io.FileDescriptor fd;
- protected int localport;
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/net/SocketImplFactory.java b/org.osgi.foundation/src/main/java/java/net/SocketImplFactory.java
deleted file mode 100644
index ef69d72..0000000
--- a/org.osgi.foundation/src/main/java/java/net/SocketImplFactory.java
+++ /dev/null
@@ -1,24 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/net/SocketImplFactory.java,v 1.6 2006/03/14 01:20:23 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.net;
-public abstract interface SocketImplFactory {
- public abstract java.net.SocketImpl createSocketImpl();
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/net/SocketOptions.java b/org.osgi.foundation/src/main/java/java/net/SocketOptions.java
deleted file mode 100644
index 62cba5e..0000000
--- a/org.osgi.foundation/src/main/java/java/net/SocketOptions.java
+++ /dev/null
@@ -1,34 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/net/SocketOptions.java,v 1.6 2006/03/14 01:20:23 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.net;
-public abstract interface SocketOptions {
- public abstract java.lang.Object getOption(int var0) throws java.net.SocketException;
- public abstract void setOption(int var0, java.lang.Object var1) throws java.net.SocketException;
- public final static int SO_LINGER = 128;
- public final static int SO_TIMEOUT = 4102;
- public final static int TCP_NODELAY = 1;
- public final static int IP_MULTICAST_IF = 16;
- public final static int SO_BINDADDR = 15;
- public final static int SO_REUSEADDR = 4;
- public final static int SO_SNDBUF = 4097;
- public final static int SO_RCVBUF = 4098;
- public final static int SO_KEEPALIVE = 8;
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/net/SocketPermission.java b/org.osgi.foundation/src/main/java/java/net/SocketPermission.java
deleted file mode 100644
index c06c19f..0000000
--- a/org.osgi.foundation/src/main/java/java/net/SocketPermission.java
+++ /dev/null
@@ -1,29 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/net/SocketPermission.java,v 1.6 2006/03/14 01:20:23 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.net;
-public final class SocketPermission extends java.security.Permission implements java.io.Serializable {
- public SocketPermission(java.lang.String var0, java.lang.String var1) { super((java.lang.String) null); }
- public boolean equals(java.lang.Object var0) { return false; }
- public int hashCode() { return 0; }
- public java.lang.String getActions() { return null; }
- public boolean implies(java.security.Permission var0) { return false; }
- public java.security.PermissionCollection newPermissionCollection() { return null; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/net/URL.java b/org.osgi.foundation/src/main/java/java/net/URL.java
deleted file mode 100644
index ca144b6..0000000
--- a/org.osgi.foundation/src/main/java/java/net/URL.java
+++ /dev/null
@@ -1,50 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/net/URL.java,v 1.6 2006/03/14 01:20:23 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.net;
-public final class URL implements java.io.Serializable {
- public static void setURLStreamHandlerFactory(java.net.URLStreamHandlerFactory var0) { }
- public URL(java.lang.String var0) throws java.net.MalformedURLException { }
- public URL(java.net.URL var0, java.lang.String var1) throws java.net.MalformedURLException { }
- public URL(java.net.URL var0, java.lang.String var1, java.net.URLStreamHandler var2) throws java.net.MalformedURLException { }
- public URL(java.lang.String var0, java.lang.String var1, java.lang.String var2) throws java.net.MalformedURLException { }
- public URL(java.lang.String var0, java.lang.String var1, int var2, java.lang.String var3) throws java.net.MalformedURLException { }
- public URL(java.lang.String var0, java.lang.String var1, int var2, java.lang.String var3, java.net.URLStreamHandler var4) throws java.net.MalformedURLException { }
- protected void set(java.lang.String var0, java.lang.String var1, int var2, java.lang.String var3, java.lang.String var4) { }
- public boolean equals(java.lang.Object var0) { return false; }
- public boolean sameFile(java.net.URL var0) { return false; }
- public int hashCode() { return 0; }
- public final java.lang.Object getContent() throws java.io.IOException { return null; }
- public final java.lang.Object getContent(java.lang.Class[] var0) throws java.io.IOException { return null; }
- public final java.io.InputStream openStream() throws java.io.IOException { return null; }
- public java.net.URLConnection openConnection() throws java.io.IOException { return null; }
- public java.lang.String toString() { return null; }
- public java.lang.String toExternalForm() { return null; }
- public java.lang.String getFile() { return null; }
- public java.lang.String getHost() { return null; }
- public int getPort() { return 0; }
- public java.lang.String getProtocol() { return null; }
- public java.lang.String getRef() { return null; }
- public java.lang.String getQuery() { return null; }
- public java.lang.String getPath() { return null; }
- public java.lang.String getUserInfo() { return null; }
- public java.lang.String getAuthority() { return null; }
- protected void set(java.lang.String var0, java.lang.String var1, int var2, java.lang.String var3, java.lang.String var4, java.lang.String var5, java.lang.String var6, java.lang.String var7) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/net/URLClassLoader.java b/org.osgi.foundation/src/main/java/java/net/URLClassLoader.java
deleted file mode 100644
index 1ea5874..0000000
--- a/org.osgi.foundation/src/main/java/java/net/URLClassLoader.java
+++ /dev/null
@@ -1,35 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/net/URLClassLoader.java,v 1.6 2006/03/14 01:20:23 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.net;
-public class URLClassLoader extends java.security.SecureClassLoader {
- public URLClassLoader(java.net.URL[] var0) { }
- public URLClassLoader(java.net.URL[] var0, java.lang.ClassLoader var1) { }
- protected void addURL(java.net.URL var0) { }
- public java.util.Enumeration findResources(java.lang.String var0) throws java.io.IOException { return null; }
- protected java.security.PermissionCollection getPermissions(java.security.CodeSource var0) { return null; }
- public java.net.URL[] getURLs() { return null; }
- public static java.net.URLClassLoader newInstance(java.net.URL[] var0) { return null; }
- public static java.net.URLClassLoader newInstance(java.net.URL[] var0, java.lang.ClassLoader var1) { return null; }
- public URLClassLoader(java.net.URL[] var0, java.lang.ClassLoader var1, java.net.URLStreamHandlerFactory var2) { }
- protected java.lang.Class findClass(java.lang.String var0) throws java.lang.ClassNotFoundException { return null; }
- public java.net.URL findResource(java.lang.String var0) { return null; }
- protected java.lang.Package definePackage(java.lang.String var0, java.util.jar.Manifest var1, java.net.URL var2) throws java.lang.IllegalArgumentException { return null; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/net/URLConnection.java b/org.osgi.foundation/src/main/java/java/net/URLConnection.java
deleted file mode 100644
index 40b2b10..0000000
--- a/org.osgi.foundation/src/main/java/java/net/URLConnection.java
+++ /dev/null
@@ -1,71 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/net/URLConnection.java,v 1.6 2006/03/14 01:20:23 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.net;
-public abstract class URLConnection {
- protected URLConnection(java.net.URL var0) { }
- public abstract void connect() throws java.io.IOException;
- public boolean getAllowUserInteraction() { return false; }
- public java.lang.Object getContent() throws java.io.IOException { return null; }
- public java.lang.Object getContent(java.lang.Class[] var0) throws java.io.IOException { return null; }
- public java.lang.String getContentEncoding() { return null; }
- public int getContentLength() { return 0; }
- public java.lang.String getContentType() { return null; }
- public long getDate() { return 0l; }
- public static boolean getDefaultAllowUserInteraction() { return false; }
- public boolean getDefaultUseCaches() { return false; }
- public boolean getDoInput() { return false; }
- public boolean getDoOutput() { return false; }
- public long getExpiration() { return 0l; }
- public static java.net.FileNameMap getFileNameMap() { return null; }
- public java.lang.String getHeaderField(int var0) { return null; }
- public java.lang.String getHeaderField(java.lang.String var0) { return null; }
- public long getHeaderFieldDate(java.lang.String var0, long var1) { return 0l; }
- public int getHeaderFieldInt(java.lang.String var0, int var1) { return 0; }
- public java.lang.String getHeaderFieldKey(int var0) { return null; }
- public long getIfModifiedSince() { return 0l; }
- public java.io.InputStream getInputStream() throws java.io.IOException { return null; }
- public long getLastModified() { return 0l; }
- public java.io.OutputStream getOutputStream() throws java.io.IOException { return null; }
- public java.security.Permission getPermission() throws java.io.IOException { return null; }
- public java.lang.String getRequestProperty(java.lang.String var0) { return null; }
- public java.net.URL getURL() { return null; }
- public boolean getUseCaches() { return false; }
- protected static java.lang.String guessContentTypeFromName(java.lang.String var0) { return null; }
- public static java.lang.String guessContentTypeFromStream(java.io.InputStream var0) throws java.io.IOException { return null; }
- public void setAllowUserInteraction(boolean var0) { }
- public static void setContentHandlerFactory(java.net.ContentHandlerFactory var0) { }
- public static void setDefaultAllowUserInteraction(boolean var0) { }
- public void setDefaultUseCaches(boolean var0) { }
- public void setDoInput(boolean var0) { }
- public void setDoOutput(boolean var0) { }
- public static void setFileNameMap(java.net.FileNameMap var0) { }
- public void setIfModifiedSince(long var0) { }
- public void setRequestProperty(java.lang.String var0, java.lang.String var1) { }
- public void setUseCaches(boolean var0) { }
- public java.lang.String toString() { return null; }
- protected java.net.URL url;
- protected long ifModifiedSince;
- protected boolean useCaches;
- protected boolean connected;
- protected boolean doOutput;
- protected boolean doInput;
- protected boolean allowUserInteraction;
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/net/URLDecoder.java b/org.osgi.foundation/src/main/java/java/net/URLDecoder.java
deleted file mode 100644
index d611abf..0000000
--- a/org.osgi.foundation/src/main/java/java/net/URLDecoder.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/net/URLDecoder.java,v 1.6 2006/03/14 01:20:23 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.net;
-public class URLDecoder {
- public URLDecoder() { }
- public static java.lang.String decode(java.lang.String var0) { return null; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/net/URLEncoder.java b/org.osgi.foundation/src/main/java/java/net/URLEncoder.java
deleted file mode 100644
index 7cb927a..0000000
--- a/org.osgi.foundation/src/main/java/java/net/URLEncoder.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/net/URLEncoder.java,v 1.6 2006/03/14 01:20:23 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.net;
-public class URLEncoder {
- public static java.lang.String encode(java.lang.String var0) { return null; }
- private URLEncoder() { } /* generated constructor to prevent compiler adding default public constructor */
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/net/URLStreamHandler.java b/org.osgi.foundation/src/main/java/java/net/URLStreamHandler.java
deleted file mode 100644
index ffaa072..0000000
--- a/org.osgi.foundation/src/main/java/java/net/URLStreamHandler.java
+++ /dev/null
@@ -1,34 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/net/URLStreamHandler.java,v 1.6 2006/03/14 01:20:23 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.net;
-public abstract class URLStreamHandler {
- public URLStreamHandler() { }
- protected abstract java.net.URLConnection openConnection(java.net.URL var0) throws java.io.IOException;
- protected void parseURL(java.net.URL var0, java.lang.String var1, int var2, int var3) { }
- protected void setURL(java.net.URL var0, java.lang.String var1, java.lang.String var2, int var3, java.lang.String var4, java.lang.String var5, java.lang.String var6, java.lang.String var7, java.lang.String var8) { }
- protected java.lang.String toExternalForm(java.net.URL var0) { return null; }
- protected boolean equals(java.net.URL var0, java.net.URL var1) { return false; }
- protected int getDefaultPort() { return 0; }
- protected java.net.InetAddress getHostAddress(java.net.URL var0) { return null; }
- protected int hashCode(java.net.URL var0) { return 0; }
- protected boolean hostsEqual(java.net.URL var0, java.net.URL var1) { return false; }
- protected boolean sameFile(java.net.URL var0, java.net.URL var1) { return false; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/net/URLStreamHandlerFactory.java b/org.osgi.foundation/src/main/java/java/net/URLStreamHandlerFactory.java
deleted file mode 100644
index 269c334..0000000
--- a/org.osgi.foundation/src/main/java/java/net/URLStreamHandlerFactory.java
+++ /dev/null
@@ -1,24 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/net/URLStreamHandlerFactory.java,v 1.6 2006/03/14 01:20:23 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.net;
-public abstract interface URLStreamHandlerFactory {
- public abstract java.net.URLStreamHandler createURLStreamHandler(java.lang.String var0);
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/net/UnknownHostException.java b/org.osgi.foundation/src/main/java/java/net/UnknownHostException.java
deleted file mode 100644
index 6f0467a..0000000
--- a/org.osgi.foundation/src/main/java/java/net/UnknownHostException.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/net/UnknownHostException.java,v 1.6 2006/03/14 01:20:23 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.net;
-public class UnknownHostException extends java.io.IOException {
- public UnknownHostException() { }
- public UnknownHostException(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/net/UnknownServiceException.java b/org.osgi.foundation/src/main/java/java/net/UnknownServiceException.java
deleted file mode 100644
index 6be769e..0000000
--- a/org.osgi.foundation/src/main/java/java/net/UnknownServiceException.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/net/UnknownServiceException.java,v 1.6 2006/03/14 01:20:23 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.net;
-public class UnknownServiceException extends java.io.IOException {
- public UnknownServiceException() { }
- public UnknownServiceException(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/AccessControlContext.java b/org.osgi.foundation/src/main/java/java/security/AccessControlContext.java
deleted file mode 100644
index b6dcfa3..0000000
--- a/org.osgi.foundation/src/main/java/java/security/AccessControlContext.java
+++ /dev/null
@@ -1,29 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/AccessControlContext.java,v 1.6 2006/03/14 01:20:26 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security;
-public final class AccessControlContext {
- public AccessControlContext(java.security.ProtectionDomain[] var0) { }
- public AccessControlContext(java.security.AccessControlContext var0, java.security.DomainCombiner var1) { }
- public void checkPermission(java.security.Permission var0) throws java.security.AccessControlException { }
- public boolean equals(java.lang.Object var0) { return false; }
- public int hashCode() { return 0; }
- public java.security.DomainCombiner getDomainCombiner() { return null; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/AccessControlException.java b/org.osgi.foundation/src/main/java/java/security/AccessControlException.java
deleted file mode 100644
index 5e1eb7d..0000000
--- a/org.osgi.foundation/src/main/java/java/security/AccessControlException.java
+++ /dev/null
@@ -1,26 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/AccessControlException.java,v 1.6 2006/03/14 01:20:27 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security;
-public class AccessControlException extends java.lang.SecurityException {
- public AccessControlException(java.lang.String var0) { }
- public AccessControlException(java.lang.String var0, java.security.Permission var1) { }
- public java.security.Permission getPermission() { return null; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/AccessController.java b/org.osgi.foundation/src/main/java/java/security/AccessController.java
deleted file mode 100644
index b997eab..0000000
--- a/org.osgi.foundation/src/main/java/java/security/AccessController.java
+++ /dev/null
@@ -1,30 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/AccessController.java,v 1.6 2006/03/14 01:20:27 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security;
-public final class AccessController {
- public static void checkPermission(java.security.Permission var0) throws java.security.AccessControlException { }
- public static java.security.AccessControlContext getContext() { return null; }
- public static java.lang.Object doPrivileged(java.security.PrivilegedAction var0) { return null; }
- public static java.lang.Object doPrivileged(java.security.PrivilegedAction var0, java.security.AccessControlContext var1) { return null; }
- public static java.lang.Object doPrivileged(java.security.PrivilegedExceptionAction var0) throws java.security.PrivilegedActionException { return null; }
- public static java.lang.Object doPrivileged(java.security.PrivilegedExceptionAction var0, java.security.AccessControlContext var1) throws java.security.PrivilegedActionException { return null; }
- private AccessController() { } /* generated constructor to prevent compiler adding default public constructor */
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/AlgorithmParameterGenerator.java b/org.osgi.foundation/src/main/java/java/security/AlgorithmParameterGenerator.java
deleted file mode 100644
index 2b3bf5f..0000000
--- a/org.osgi.foundation/src/main/java/java/security/AlgorithmParameterGenerator.java
+++ /dev/null
@@ -1,33 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/AlgorithmParameterGenerator.java,v 1.6 2006/03/14 01:20:27 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security;
-public class AlgorithmParameterGenerator {
- protected AlgorithmParameterGenerator(java.security.AlgorithmParameterGeneratorSpi var0, java.security.Provider var1, java.lang.String var2) { }
- public final java.security.AlgorithmParameters generateParameters() { return null; }
- public final java.lang.String getAlgorithm() { return null; }
- public static java.security.AlgorithmParameterGenerator getInstance(java.lang.String var0) throws java.security.NoSuchAlgorithmException { return null; }
- public static java.security.AlgorithmParameterGenerator getInstance(java.lang.String var0, java.lang.String var1) throws java.security.NoSuchAlgorithmException, java.security.NoSuchProviderException { return null; }
- public final java.security.Provider getProvider() { return null; }
- public final void init(int var0) { }
- public final void init(int var0, java.security.SecureRandom var1) { }
- public final void init(java.security.spec.AlgorithmParameterSpec var0) throws java.security.InvalidAlgorithmParameterException { }
- public final void init(java.security.spec.AlgorithmParameterSpec var0, java.security.SecureRandom var1) throws java.security.InvalidAlgorithmParameterException { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/AlgorithmParameterGeneratorSpi.java b/org.osgi.foundation/src/main/java/java/security/AlgorithmParameterGeneratorSpi.java
deleted file mode 100644
index 9a4d387..0000000
--- a/org.osgi.foundation/src/main/java/java/security/AlgorithmParameterGeneratorSpi.java
+++ /dev/null
@@ -1,27 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/AlgorithmParameterGeneratorSpi.java,v 1.6 2006/03/14 01:20:27 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security;
-public abstract class AlgorithmParameterGeneratorSpi {
- public AlgorithmParameterGeneratorSpi() { }
- protected abstract java.security.AlgorithmParameters engineGenerateParameters();
- protected abstract void engineInit(int var0, java.security.SecureRandom var1);
- protected abstract void engineInit(java.security.spec.AlgorithmParameterSpec var0, java.security.SecureRandom var1) throws java.security.InvalidAlgorithmParameterException;
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/AlgorithmParameters.java b/org.osgi.foundation/src/main/java/java/security/AlgorithmParameters.java
deleted file mode 100644
index abcd560..0000000
--- a/org.osgi.foundation/src/main/java/java/security/AlgorithmParameters.java
+++ /dev/null
@@ -1,35 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/AlgorithmParameters.java,v 1.6 2006/03/14 01:20:26 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security;
-public class AlgorithmParameters {
- protected AlgorithmParameters(java.security.AlgorithmParametersSpi var0, java.security.Provider var1, java.lang.String var2) { }
- public final java.lang.String getAlgorithm() { return null; }
- public final byte[] getEncoded() throws java.io.IOException { return null; }
- public final byte[] getEncoded(java.lang.String var0) throws java.io.IOException { return null; }
- public static java.security.AlgorithmParameters getInstance(java.lang.String var0) throws java.security.NoSuchAlgorithmException { return null; }
- public static java.security.AlgorithmParameters getInstance(java.lang.String var0, java.lang.String var1) throws java.security.NoSuchAlgorithmException, java.security.NoSuchProviderException { return null; }
- public final java.security.spec.AlgorithmParameterSpec getParameterSpec(java.lang.Class var0) throws java.security.spec.InvalidParameterSpecException { return null; }
- public final java.security.Provider getProvider() { return null; }
- public final void init(byte[] var0) throws java.io.IOException { }
- public final void init(byte[] var0, java.lang.String var1) throws java.io.IOException { }
- public final void init(java.security.spec.AlgorithmParameterSpec var0) throws java.security.spec.InvalidParameterSpecException { }
- public final java.lang.String toString() { return null; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/AlgorithmParametersSpi.java b/org.osgi.foundation/src/main/java/java/security/AlgorithmParametersSpi.java
deleted file mode 100644
index 16f3eb9..0000000
--- a/org.osgi.foundation/src/main/java/java/security/AlgorithmParametersSpi.java
+++ /dev/null
@@ -1,31 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/AlgorithmParametersSpi.java,v 1.6 2006/03/14 01:20:27 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security;
-public abstract class AlgorithmParametersSpi {
- public AlgorithmParametersSpi() { }
- protected abstract byte[] engineGetEncoded() throws java.io.IOException;
- protected abstract byte[] engineGetEncoded(java.lang.String var0) throws java.io.IOException;
- protected abstract java.security.spec.AlgorithmParameterSpec engineGetParameterSpec(java.lang.Class var0) throws java.security.spec.InvalidParameterSpecException;
- protected abstract void engineInit(byte[] var0) throws java.io.IOException;
- protected abstract void engineInit(byte[] var0, java.lang.String var1) throws java.io.IOException;
- protected abstract void engineInit(java.security.spec.AlgorithmParameterSpec var0) throws java.security.spec.InvalidParameterSpecException;
- protected abstract java.lang.String engineToString();
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/AllPermission.java b/org.osgi.foundation/src/main/java/java/security/AllPermission.java
deleted file mode 100644
index 0e3b690..0000000
--- a/org.osgi.foundation/src/main/java/java/security/AllPermission.java
+++ /dev/null
@@ -1,30 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/AllPermission.java,v 1.6 2006/03/14 01:20:27 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security;
-public final class AllPermission extends java.security.Permission {
- public AllPermission() { super((java.lang.String) null); }
- public AllPermission(java.lang.String var0, java.lang.String var1) { super((java.lang.String) null); }
- public boolean equals(java.lang.Object var0) { return false; }
- public java.lang.String getActions() { return null; }
- public int hashCode() { return 0; }
- public boolean implies(java.security.Permission var0) { return false; }
- public java.security.PermissionCollection newPermissionCollection() { return null; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/BasicPermission.java b/org.osgi.foundation/src/main/java/java/security/BasicPermission.java
deleted file mode 100644
index 5147d11..0000000
--- a/org.osgi.foundation/src/main/java/java/security/BasicPermission.java
+++ /dev/null
@@ -1,30 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/BasicPermission.java,v 1.6 2006/03/14 01:20:26 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security;
-public abstract class BasicPermission extends java.security.Permission implements java.io.Serializable {
- public BasicPermission(java.lang.String var0) { super((java.lang.String) null); }
- public BasicPermission(java.lang.String var0, java.lang.String var1) { super((java.lang.String) null); }
- public boolean equals(java.lang.Object var0) { return false; }
- public java.lang.String getActions() { return null; }
- public int hashCode() { return 0; }
- public boolean implies(java.security.Permission var0) { return false; }
- public java.security.PermissionCollection newPermissionCollection() { return null; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/Certificate.java b/org.osgi.foundation/src/main/java/java/security/Certificate.java
deleted file mode 100644
index 62f299c..0000000
--- a/org.osgi.foundation/src/main/java/java/security/Certificate.java
+++ /dev/null
@@ -1,30 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/Certificate.java,v 1.6 2006/03/14 01:20:26 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security;
-public abstract interface Certificate {
- public abstract void decode(java.io.InputStream var0) throws java.security.KeyException, java.io.IOException;
- public abstract void encode(java.io.OutputStream var0) throws java.security.KeyException, java.io.IOException;
- public abstract java.lang.String getFormat();
- public abstract java.security.Principal getGuarantor();
- public abstract java.security.Principal getPrincipal();
- public abstract java.security.PublicKey getPublicKey();
- public abstract java.lang.String toString(boolean var0);
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/CodeSource.java b/org.osgi.foundation/src/main/java/java/security/CodeSource.java
deleted file mode 100644
index f659a2b..0000000
--- a/org.osgi.foundation/src/main/java/java/security/CodeSource.java
+++ /dev/null
@@ -1,30 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/CodeSource.java,v 1.6 2006/03/14 01:20:27 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security;
-public class CodeSource implements java.io.Serializable {
- public CodeSource(java.net.URL var0, java.security.cert.Certificate[] var1) { }
- public boolean equals(java.lang.Object var0) { return false; }
- public int hashCode() { return 0; }
- public final java.security.cert.Certificate[] getCertificates() { return null; }
- public final java.net.URL getLocation() { return null; }
- public boolean implies(java.security.CodeSource var0) { return false; }
- public java.lang.String toString() { return null; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/DigestException.java b/org.osgi.foundation/src/main/java/java/security/DigestException.java
deleted file mode 100644
index 54058b9..0000000
--- a/org.osgi.foundation/src/main/java/java/security/DigestException.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/DigestException.java,v 1.6 2006/03/14 01:20:27 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security;
-public class DigestException extends java.security.GeneralSecurityException {
- public DigestException() { }
- public DigestException(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/DigestInputStream.java b/org.osgi.foundation/src/main/java/java/security/DigestInputStream.java
deleted file mode 100644
index d348246..0000000
--- a/org.osgi.foundation/src/main/java/java/security/DigestInputStream.java
+++ /dev/null
@@ -1,31 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/DigestInputStream.java,v 1.6 2006/03/14 01:20:27 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security;
-public class DigestInputStream extends java.io.FilterInputStream {
- public DigestInputStream(java.io.InputStream var0, java.security.MessageDigest var1) { super((java.io.InputStream) null); }
- public java.security.MessageDigest getMessageDigest() { return null; }
- public void on(boolean var0) { }
- public int read() throws java.io.IOException { return 0; }
- public int read(byte[] var0, int var1, int var2) throws java.io.IOException { return 0; }
- public void setMessageDigest(java.security.MessageDigest var0) { }
- public java.lang.String toString() { return null; }
- protected java.security.MessageDigest digest;
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/DigestOutputStream.java b/org.osgi.foundation/src/main/java/java/security/DigestOutputStream.java
deleted file mode 100644
index cd267c2..0000000
--- a/org.osgi.foundation/src/main/java/java/security/DigestOutputStream.java
+++ /dev/null
@@ -1,31 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/DigestOutputStream.java,v 1.6 2006/03/14 01:20:27 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security;
-public class DigestOutputStream extends java.io.FilterOutputStream {
- public DigestOutputStream(java.io.OutputStream var0, java.security.MessageDigest var1) { super((java.io.OutputStream) null); }
- public java.security.MessageDigest getMessageDigest() { return null; }
- public void on(boolean var0) { }
- public void setMessageDigest(java.security.MessageDigest var0) { }
- public java.lang.String toString() { return null; }
- public void write(byte[] var0, int var1, int var2) throws java.io.IOException { }
- public void write(int var0) throws java.io.IOException { }
- protected java.security.MessageDigest digest;
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/DomainCombiner.java b/org.osgi.foundation/src/main/java/java/security/DomainCombiner.java
deleted file mode 100644
index c959f22..0000000
--- a/org.osgi.foundation/src/main/java/java/security/DomainCombiner.java
+++ /dev/null
@@ -1,24 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/DomainCombiner.java,v 1.6 2006/03/14 01:20:27 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security;
-public abstract interface DomainCombiner {
- public abstract java.security.ProtectionDomain[] combine(java.security.ProtectionDomain[] var0, java.security.ProtectionDomain[] var1);
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/GeneralSecurityException.java b/org.osgi.foundation/src/main/java/java/security/GeneralSecurityException.java
deleted file mode 100644
index 21b778c..0000000
--- a/org.osgi.foundation/src/main/java/java/security/GeneralSecurityException.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/GeneralSecurityException.java,v 1.6 2006/03/14 01:20:27 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security;
-public class GeneralSecurityException extends java.lang.Exception {
- public GeneralSecurityException() { }
- public GeneralSecurityException(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/Guard.java b/org.osgi.foundation/src/main/java/java/security/Guard.java
deleted file mode 100644
index 00cf9ef..0000000
--- a/org.osgi.foundation/src/main/java/java/security/Guard.java
+++ /dev/null
@@ -1,24 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/Guard.java,v 1.6 2006/03/14 01:20:27 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security;
-public abstract interface Guard {
- public abstract void checkGuard(java.lang.Object var0) throws java.lang.SecurityException;
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/GuardedObject.java b/org.osgi.foundation/src/main/java/java/security/GuardedObject.java
deleted file mode 100644
index c846965..0000000
--- a/org.osgi.foundation/src/main/java/java/security/GuardedObject.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/GuardedObject.java,v 1.6 2006/03/14 01:20:27 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security;
-public class GuardedObject implements java.io.Serializable {
- public GuardedObject(java.lang.Object var0, java.security.Guard var1) { }
- public java.lang.Object getObject() throws java.lang.SecurityException { return null; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/Identity.java b/org.osgi.foundation/src/main/java/java/security/Identity.java
deleted file mode 100644
index f6a6d65..0000000
--- a/org.osgi.foundation/src/main/java/java/security/Identity.java
+++ /dev/null
@@ -1,40 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/Identity.java,v 1.6 2006/03/14 01:20:27 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security;
-public abstract class Identity implements java.security.Principal, java.io.Serializable {
- protected Identity() { }
- public Identity(java.lang.String var0) { }
- public Identity(java.lang.String var0, java.security.IdentityScope var1) throws java.security.KeyManagementException { }
- public final java.security.IdentityScope getScope() { return null; }
- public java.security.PublicKey getPublicKey() { return null; }
- public void setPublicKey(java.security.PublicKey var0) throws java.security.KeyManagementException { }
- public final java.lang.String getName() { return null; }
- public java.lang.String getInfo() { return null; }
- public void setInfo(java.lang.String var0) { }
- public java.security.Certificate[] certificates() { return null; }
- public void addCertificate(java.security.Certificate var0) throws java.security.KeyManagementException { }
- public void removeCertificate(java.security.Certificate var0) throws java.security.KeyManagementException { }
- public final boolean equals(java.lang.Object var0) { return false; }
- protected boolean identityEquals(java.security.Identity var0) { return false; }
- public java.lang.String toString() { return null; }
- public java.lang.String toString(boolean var0) { return null; }
- public int hashCode() { return 0; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/IdentityScope.java b/org.osgi.foundation/src/main/java/java/security/IdentityScope.java
deleted file mode 100644
index 69e8e6c..0000000
--- a/org.osgi.foundation/src/main/java/java/security/IdentityScope.java
+++ /dev/null
@@ -1,36 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/IdentityScope.java,v 1.6 2006/03/14 01:20:26 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security;
-public abstract class IdentityScope extends java.security.Identity {
- protected IdentityScope() { }
- public IdentityScope(java.lang.String var0) { }
- public IdentityScope(java.lang.String var0, java.security.IdentityScope var1) throws java.security.KeyManagementException { }
- public abstract void addIdentity(java.security.Identity var0) throws java.security.KeyManagementException;
- public abstract void removeIdentity(java.security.Identity var0) throws java.security.KeyManagementException;
- public abstract java.util.Enumeration identities();
- public java.security.Identity getIdentity(java.security.Principal var0) { return null; }
- public abstract java.security.Identity getIdentity(java.security.PublicKey var0);
- public abstract java.security.Identity getIdentity(java.lang.String var0);
- protected static void setSystemScope(java.security.IdentityScope var0) { }
- public abstract int size();
- public java.lang.String toString() { return null; }
- public static java.security.IdentityScope getSystemScope() { return null; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/InvalidAlgorithmParameterException.java b/org.osgi.foundation/src/main/java/java/security/InvalidAlgorithmParameterException.java
deleted file mode 100644
index c89a071..0000000
--- a/org.osgi.foundation/src/main/java/java/security/InvalidAlgorithmParameterException.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/InvalidAlgorithmParameterException.java,v 1.6 2006/03/14 01:20:27 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security;
-public class InvalidAlgorithmParameterException extends java.security.GeneralSecurityException {
- public InvalidAlgorithmParameterException() { }
- public InvalidAlgorithmParameterException(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/InvalidKeyException.java b/org.osgi.foundation/src/main/java/java/security/InvalidKeyException.java
deleted file mode 100644
index d3ba36b..0000000
--- a/org.osgi.foundation/src/main/java/java/security/InvalidKeyException.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/InvalidKeyException.java,v 1.6 2006/03/14 01:20:26 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security;
-public class InvalidKeyException extends java.security.KeyException {
- public InvalidKeyException() { }
- public InvalidKeyException(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/InvalidParameterException.java b/org.osgi.foundation/src/main/java/java/security/InvalidParameterException.java
deleted file mode 100644
index 772d88e..0000000
--- a/org.osgi.foundation/src/main/java/java/security/InvalidParameterException.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/InvalidParameterException.java,v 1.6 2006/03/14 01:20:27 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security;
-public class InvalidParameterException extends java.lang.IllegalArgumentException {
- public InvalidParameterException() { }
- public InvalidParameterException(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/Key.java b/org.osgi.foundation/src/main/java/java/security/Key.java
deleted file mode 100644
index 0ac1385..0000000
--- a/org.osgi.foundation/src/main/java/java/security/Key.java
+++ /dev/null
@@ -1,27 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/Key.java,v 1.6 2006/03/14 01:20:27 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security;
-public abstract interface Key extends java.io.Serializable {
- public abstract java.lang.String getAlgorithm();
- public abstract byte[] getEncoded();
- public abstract java.lang.String getFormat();
- public final static long serialVersionUID = 6603384152749567654l;
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/KeyException.java b/org.osgi.foundation/src/main/java/java/security/KeyException.java
deleted file mode 100644
index 7a96ec9..0000000
--- a/org.osgi.foundation/src/main/java/java/security/KeyException.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/KeyException.java,v 1.6 2006/03/14 01:20:27 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security;
-public class KeyException extends java.security.GeneralSecurityException {
- public KeyException() { }
- public KeyException(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/KeyFactory.java b/org.osgi.foundation/src/main/java/java/security/KeyFactory.java
deleted file mode 100644
index 1fcbb99..0000000
--- a/org.osgi.foundation/src/main/java/java/security/KeyFactory.java
+++ /dev/null
@@ -1,32 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/KeyFactory.java,v 1.6 2006/03/14 01:20:27 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security;
-public class KeyFactory {
- protected KeyFactory(java.security.KeyFactorySpi var0, java.security.Provider var1, java.lang.String var2) { }
- public final java.security.PrivateKey generatePrivate(java.security.spec.KeySpec var0) throws java.security.spec.InvalidKeySpecException { return null; }
- public final java.security.PublicKey generatePublic(java.security.spec.KeySpec var0) throws java.security.spec.InvalidKeySpecException { return null; }
- public final java.lang.String getAlgorithm() { return null; }
- public static java.security.KeyFactory getInstance(java.lang.String var0) throws java.security.NoSuchAlgorithmException { return null; }
- public static java.security.KeyFactory getInstance(java.lang.String var0, java.lang.String var1) throws java.security.NoSuchAlgorithmException, java.security.NoSuchProviderException { return null; }
- public final java.security.spec.KeySpec getKeySpec(java.security.Key var0, java.lang.Class var1) throws java.security.spec.InvalidKeySpecException { return null; }
- public final java.security.Provider getProvider() { return null; }
- public final java.security.Key translateKey(java.security.Key var0) throws java.security.InvalidKeyException { return null; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/KeyFactorySpi.java b/org.osgi.foundation/src/main/java/java/security/KeyFactorySpi.java
deleted file mode 100644
index dfa8e30..0000000
--- a/org.osgi.foundation/src/main/java/java/security/KeyFactorySpi.java
+++ /dev/null
@@ -1,28 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/KeyFactorySpi.java,v 1.6 2006/03/14 01:20:27 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security;
-public abstract class KeyFactorySpi {
- public KeyFactorySpi() { }
- protected abstract java.security.PrivateKey engineGeneratePrivate(java.security.spec.KeySpec var0) throws java.security.spec.InvalidKeySpecException;
- protected abstract java.security.PublicKey engineGeneratePublic(java.security.spec.KeySpec var0) throws java.security.spec.InvalidKeySpecException;
- protected abstract java.security.spec.KeySpec engineGetKeySpec(java.security.Key var0, java.lang.Class var1) throws java.security.spec.InvalidKeySpecException;
- protected abstract java.security.Key engineTranslateKey(java.security.Key var0) throws java.security.InvalidKeyException;
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/KeyManagementException.java b/org.osgi.foundation/src/main/java/java/security/KeyManagementException.java
deleted file mode 100644
index 61ee50e..0000000
--- a/org.osgi.foundation/src/main/java/java/security/KeyManagementException.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/KeyManagementException.java,v 1.6 2006/03/14 01:20:27 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security;
-public class KeyManagementException extends java.security.KeyException {
- public KeyManagementException() { }
- public KeyManagementException(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/KeyPair.java b/org.osgi.foundation/src/main/java/java/security/KeyPair.java
deleted file mode 100644
index a1dfb1a..0000000
--- a/org.osgi.foundation/src/main/java/java/security/KeyPair.java
+++ /dev/null
@@ -1,26 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/KeyPair.java,v 1.6 2006/03/14 01:20:26 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security;
-public final class KeyPair implements java.io.Serializable {
- public KeyPair(java.security.PublicKey var0, java.security.PrivateKey var1) { }
- public java.security.PrivateKey getPrivate() { return null; }
- public java.security.PublicKey getPublic() { return null; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/KeyPairGenerator.java b/org.osgi.foundation/src/main/java/java/security/KeyPairGenerator.java
deleted file mode 100644
index 09da699..0000000
--- a/org.osgi.foundation/src/main/java/java/security/KeyPairGenerator.java
+++ /dev/null
@@ -1,34 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/KeyPairGenerator.java,v 1.6 2006/03/14 01:20:27 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security;
-public abstract class KeyPairGenerator extends java.security.KeyPairGeneratorSpi {
- protected KeyPairGenerator(java.lang.String var0) { }
- public final java.security.KeyPair genKeyPair() { return null; }
- public java.lang.String getAlgorithm() { return null; }
- public static java.security.KeyPairGenerator getInstance(java.lang.String var0) throws java.security.NoSuchAlgorithmException { return null; }
- public static java.security.KeyPairGenerator getInstance(java.lang.String var0, java.lang.String var1) throws java.security.NoSuchAlgorithmException, java.security.NoSuchProviderException { return null; }
- public final java.security.Provider getProvider() { return null; }
- public void initialize(int var0) { }
- public void initialize(int var0, java.security.SecureRandom var1) { }
- public void initialize(java.security.spec.AlgorithmParameterSpec var0) throws java.security.InvalidAlgorithmParameterException { }
- public void initialize(java.security.spec.AlgorithmParameterSpec var0, java.security.SecureRandom var1) throws java.security.InvalidAlgorithmParameterException { }
- public java.security.KeyPair generateKeyPair() { return null; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/KeyPairGeneratorSpi.java b/org.osgi.foundation/src/main/java/java/security/KeyPairGeneratorSpi.java
deleted file mode 100644
index 610b287..0000000
--- a/org.osgi.foundation/src/main/java/java/security/KeyPairGeneratorSpi.java
+++ /dev/null
@@ -1,27 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/KeyPairGeneratorSpi.java,v 1.6 2006/03/14 01:20:27 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security;
-public abstract class KeyPairGeneratorSpi {
- public KeyPairGeneratorSpi() { }
- public abstract java.security.KeyPair generateKeyPair();
- public abstract void initialize(int var0, java.security.SecureRandom var1);
- public void initialize(java.security.spec.AlgorithmParameterSpec var0, java.security.SecureRandom var1) throws java.security.InvalidAlgorithmParameterException { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/KeyStore.java b/org.osgi.foundation/src/main/java/java/security/KeyStore.java
deleted file mode 100644
index bfecf27..0000000
--- a/org.osgi.foundation/src/main/java/java/security/KeyStore.java
+++ /dev/null
@@ -1,45 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/KeyStore.java,v 1.6 2006/03/14 01:20:27 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security;
-public class KeyStore {
- protected KeyStore(java.security.KeyStoreSpi var0, java.security.Provider var1, java.lang.String var2) { }
- public final java.util.Enumeration aliases() throws java.security.KeyStoreException { return null; }
- public final boolean containsAlias(java.lang.String var0) throws java.security.KeyStoreException { return false; }
- public final void deleteEntry(java.lang.String var0) throws java.security.KeyStoreException { }
- public final java.security.cert.Certificate getCertificate(java.lang.String var0) throws java.security.KeyStoreException { return null; }
- public final java.lang.String getCertificateAlias(java.security.cert.Certificate var0) throws java.security.KeyStoreException { return null; }
- public final java.security.cert.Certificate[] getCertificateChain(java.lang.String var0) throws java.security.KeyStoreException { return null; }
- public final java.util.Date getCreationDate(java.lang.String var0) throws java.security.KeyStoreException { return null; }
- public static java.security.KeyStore getInstance(java.lang.String var0) throws java.security.KeyStoreException { return null; }
- public static java.security.KeyStore getInstance(java.lang.String var0, java.lang.String var1) throws java.security.KeyStoreException, java.security.NoSuchProviderException { return null; }
- public final java.security.Key getKey(java.lang.String var0, char[] var1) throws java.security.KeyStoreException, java.security.NoSuchAlgorithmException, java.security.UnrecoverableKeyException { return null; }
- public final java.security.Provider getProvider() { return null; }
- public final java.lang.String getType() { return null; }
- public final boolean isCertificateEntry(java.lang.String var0) throws java.security.KeyStoreException { return false; }
- public final boolean isKeyEntry(java.lang.String var0) throws java.security.KeyStoreException { return false; }
- public final void load(java.io.InputStream var0, char[] var1) throws java.io.IOException, java.security.NoSuchAlgorithmException, java.security.cert.CertificateException { }
- public final void setCertificateEntry(java.lang.String var0, java.security.cert.Certificate var1) throws java.security.KeyStoreException { }
- public final void setKeyEntry(java.lang.String var0, byte[] var1, java.security.cert.Certificate[] var2) throws java.security.KeyStoreException { }
- public final void setKeyEntry(java.lang.String var0, java.security.Key var1, char[] var2, java.security.cert.Certificate[] var3) throws java.security.KeyStoreException { }
- public final int size() throws java.security.KeyStoreException { return 0; }
- public final void store(java.io.OutputStream var0, char[] var1) throws java.security.KeyStoreException, java.io.IOException, java.security.NoSuchAlgorithmException, java.security.cert.CertificateException { }
- public final static java.lang.String getDefaultType() { return null; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/KeyStoreException.java b/org.osgi.foundation/src/main/java/java/security/KeyStoreException.java
deleted file mode 100644
index cbcebbd..0000000
--- a/org.osgi.foundation/src/main/java/java/security/KeyStoreException.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/KeyStoreException.java,v 1.6 2006/03/14 01:20:27 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security;
-public class KeyStoreException extends java.security.GeneralSecurityException {
- public KeyStoreException() { }
- public KeyStoreException(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/KeyStoreSpi.java b/org.osgi.foundation/src/main/java/java/security/KeyStoreSpi.java
deleted file mode 100644
index 8270d0e..0000000
--- a/org.osgi.foundation/src/main/java/java/security/KeyStoreSpi.java
+++ /dev/null
@@ -1,40 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/KeyStoreSpi.java,v 1.6 2006/03/14 01:20:26 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security;
-public abstract class KeyStoreSpi {
- public KeyStoreSpi() { }
- public abstract java.util.Enumeration engineAliases();
- public abstract boolean engineContainsAlias(java.lang.String var0);
- public abstract void engineDeleteEntry(java.lang.String var0) throws java.security.KeyStoreException;
- public abstract java.security.cert.Certificate engineGetCertificate(java.lang.String var0);
- public abstract java.lang.String engineGetCertificateAlias(java.security.cert.Certificate var0);
- public abstract java.security.cert.Certificate[] engineGetCertificateChain(java.lang.String var0);
- public abstract java.util.Date engineGetCreationDate(java.lang.String var0);
- public abstract java.security.Key engineGetKey(java.lang.String var0, char[] var1) throws java.security.NoSuchAlgorithmException, java.security.UnrecoverableKeyException;
- public abstract boolean engineIsCertificateEntry(java.lang.String var0);
- public abstract boolean engineIsKeyEntry(java.lang.String var0);
- public abstract void engineLoad(java.io.InputStream var0, char[] var1) throws java.io.IOException, java.security.NoSuchAlgorithmException, java.security.cert.CertificateException;
- public abstract void engineSetCertificateEntry(java.lang.String var0, java.security.cert.Certificate var1) throws java.security.KeyStoreException;
- public abstract void engineSetKeyEntry(java.lang.String var0, byte[] var1, java.security.cert.Certificate[] var2) throws java.security.KeyStoreException;
- public abstract void engineSetKeyEntry(java.lang.String var0, java.security.Key var1, char[] var2, java.security.cert.Certificate[] var3) throws java.security.KeyStoreException;
- public abstract int engineSize();
- public abstract void engineStore(java.io.OutputStream var0, char[] var1) throws java.io.IOException, java.security.NoSuchAlgorithmException, java.security.cert.CertificateException;
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/MessageDigest.java b/org.osgi.foundation/src/main/java/java/security/MessageDigest.java
deleted file mode 100644
index ed8d2ac..0000000
--- a/org.osgi.foundation/src/main/java/java/security/MessageDigest.java
+++ /dev/null
@@ -1,39 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/MessageDigest.java,v 1.6 2006/03/14 01:20:26 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security;
-public abstract class MessageDigest extends java.security.MessageDigestSpi {
- protected MessageDigest(java.lang.String var0) { }
- public java.lang.Object clone() throws java.lang.CloneNotSupportedException { return null; }
- public byte[] digest() { return null; }
- public byte[] digest(byte[] var0) { return null; }
- public int digest(byte[] var0, int var1, int var2) throws java.security.DigestException { return 0; }
- public final java.lang.String getAlgorithm() { return null; }
- public final int getDigestLength() { return 0; }
- public static java.security.MessageDigest getInstance(java.lang.String var0) throws java.security.NoSuchAlgorithmException { return null; }
- public static java.security.MessageDigest getInstance(java.lang.String var0, java.lang.String var1) throws java.security.NoSuchAlgorithmException, java.security.NoSuchProviderException { return null; }
- public final java.security.Provider getProvider() { return null; }
- public static boolean isEqual(byte[] var0, byte[] var1) { return false; }
- public void reset() { }
- public java.lang.String toString() { return null; }
- public void update(byte[] var0) { }
- public void update(byte[] var0, int var1, int var2) { }
- public void update(byte var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/MessageDigestSpi.java b/org.osgi.foundation/src/main/java/java/security/MessageDigestSpi.java
deleted file mode 100644
index 0f42170..0000000
--- a/org.osgi.foundation/src/main/java/java/security/MessageDigestSpi.java
+++ /dev/null
@@ -1,31 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/MessageDigestSpi.java,v 1.6 2006/03/14 01:20:26 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security;
-public abstract class MessageDigestSpi {
- public MessageDigestSpi() { }
- public java.lang.Object clone() throws java.lang.CloneNotSupportedException { return null; }
- protected abstract byte[] engineDigest();
- protected int engineDigest(byte[] var0, int var1, int var2) throws java.security.DigestException { return 0; }
- protected int engineGetDigestLength() { return 0; }
- protected abstract void engineReset();
- protected abstract void engineUpdate(byte[] var0, int var1, int var2);
- protected abstract void engineUpdate(byte var0);
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/NoSuchAlgorithmException.java b/org.osgi.foundation/src/main/java/java/security/NoSuchAlgorithmException.java
deleted file mode 100644
index 112f5e3..0000000
--- a/org.osgi.foundation/src/main/java/java/security/NoSuchAlgorithmException.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/NoSuchAlgorithmException.java,v 1.6 2006/03/14 01:20:27 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security;
-public class NoSuchAlgorithmException extends java.security.GeneralSecurityException {
- public NoSuchAlgorithmException() { }
- public NoSuchAlgorithmException(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/NoSuchProviderException.java b/org.osgi.foundation/src/main/java/java/security/NoSuchProviderException.java
deleted file mode 100644
index df6b3ce..0000000
--- a/org.osgi.foundation/src/main/java/java/security/NoSuchProviderException.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/NoSuchProviderException.java,v 1.6 2006/03/14 01:20:26 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security;
-public class NoSuchProviderException extends java.security.GeneralSecurityException {
- public NoSuchProviderException() { }
- public NoSuchProviderException(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/Permission.java b/org.osgi.foundation/src/main/java/java/security/Permission.java
deleted file mode 100644
index 3b0be65..0000000
--- a/org.osgi.foundation/src/main/java/java/security/Permission.java
+++ /dev/null
@@ -1,32 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/Permission.java,v 1.6 2006/03/14 01:20:26 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security;
-public abstract class Permission implements java.security.Guard, java.io.Serializable {
- public Permission(java.lang.String var0) { }
- public abstract boolean equals(java.lang.Object var0);
- public abstract int hashCode();
- public void checkGuard(java.lang.Object var0) throws java.lang.SecurityException { }
- public abstract java.lang.String getActions();
- public final java.lang.String getName() { return null; }
- public abstract boolean implies(java.security.Permission var0);
- public java.security.PermissionCollection newPermissionCollection() { return null; }
- public java.lang.String toString() { return null; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/PermissionCollection.java b/org.osgi.foundation/src/main/java/java/security/PermissionCollection.java
deleted file mode 100644
index d5771e7..0000000
--- a/org.osgi.foundation/src/main/java/java/security/PermissionCollection.java
+++ /dev/null
@@ -1,30 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/PermissionCollection.java,v 1.6 2006/03/14 01:20:27 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security;
-public abstract class PermissionCollection implements java.io.Serializable {
- public PermissionCollection() { }
- public abstract void add(java.security.Permission var0);
- public abstract java.util.Enumeration elements();
- public abstract boolean implies(java.security.Permission var0);
- public boolean isReadOnly() { return false; }
- public void setReadOnly() { }
- public java.lang.String toString() { return null; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/Permissions.java b/org.osgi.foundation/src/main/java/java/security/Permissions.java
deleted file mode 100644
index 3601e7f..0000000
--- a/org.osgi.foundation/src/main/java/java/security/Permissions.java
+++ /dev/null
@@ -1,27 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/Permissions.java,v 1.6 2006/03/14 01:20:26 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security;
-public final class Permissions extends java.security.PermissionCollection implements java.io.Serializable {
- public Permissions() { }
- public void add(java.security.Permission var0) { }
- public java.util.Enumeration elements() { return null; }
- public boolean implies(java.security.Permission var0) { return false; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/Policy.java b/org.osgi.foundation/src/main/java/java/security/Policy.java
deleted file mode 100644
index b5a5708..0000000
--- a/org.osgi.foundation/src/main/java/java/security/Policy.java
+++ /dev/null
@@ -1,28 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/Policy.java,v 1.6 2006/03/14 01:20:27 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security;
-public abstract class Policy {
- public Policy() { }
- public static java.security.Policy getPolicy() { return null; }
- public static void setPolicy(java.security.Policy var0) { }
- public abstract java.security.PermissionCollection getPermissions(java.security.CodeSource var0);
- public abstract void refresh();
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/Principal.java b/org.osgi.foundation/src/main/java/java/security/Principal.java
deleted file mode 100644
index 67f4d75..0000000
--- a/org.osgi.foundation/src/main/java/java/security/Principal.java
+++ /dev/null
@@ -1,27 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/Principal.java,v 1.6 2006/03/14 01:20:27 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security;
-public abstract interface Principal {
- public abstract boolean equals(java.lang.Object var0);
- public abstract java.lang.String getName();
- public abstract int hashCode();
- public abstract java.lang.String toString();
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/PrivateKey.java b/org.osgi.foundation/src/main/java/java/security/PrivateKey.java
deleted file mode 100644
index efe5113..0000000
--- a/org.osgi.foundation/src/main/java/java/security/PrivateKey.java
+++ /dev/null
@@ -1,24 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/PrivateKey.java,v 1.6 2006/03/14 01:20:26 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security;
-public abstract interface PrivateKey extends java.security.Key {
- public final static long serialVersionUID = 6034044314589513430l;
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/PrivilegedAction.java b/org.osgi.foundation/src/main/java/java/security/PrivilegedAction.java
deleted file mode 100644
index 87a4bcf..0000000
--- a/org.osgi.foundation/src/main/java/java/security/PrivilegedAction.java
+++ /dev/null
@@ -1,24 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/PrivilegedAction.java,v 1.6 2006/03/14 01:20:26 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security;
-public abstract interface PrivilegedAction {
- public abstract java.lang.Object run();
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/PrivilegedActionException.java b/org.osgi.foundation/src/main/java/java/security/PrivilegedActionException.java
deleted file mode 100644
index 47fe550..0000000
--- a/org.osgi.foundation/src/main/java/java/security/PrivilegedActionException.java
+++ /dev/null
@@ -1,29 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/PrivilegedActionException.java,v 1.6 2006/03/14 01:20:26 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security;
-public class PrivilegedActionException extends java.lang.Exception {
- public PrivilegedActionException(java.lang.Exception var0) { }
- public java.lang.Exception getException() { return null; }
- public void printStackTrace() { }
- public void printStackTrace(java.io.PrintStream var0) { }
- public void printStackTrace(java.io.PrintWriter var0) { }
- public java.lang.String toString() { return null; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/PrivilegedExceptionAction.java b/org.osgi.foundation/src/main/java/java/security/PrivilegedExceptionAction.java
deleted file mode 100644
index 22ae908..0000000
--- a/org.osgi.foundation/src/main/java/java/security/PrivilegedExceptionAction.java
+++ /dev/null
@@ -1,24 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/PrivilegedExceptionAction.java,v 1.6 2006/03/14 01:20:27 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security;
-public abstract interface PrivilegedExceptionAction {
- public abstract java.lang.Object run() throws java.lang.Exception;
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/ProtectionDomain.java b/org.osgi.foundation/src/main/java/java/security/ProtectionDomain.java
deleted file mode 100644
index 6c11640..0000000
--- a/org.osgi.foundation/src/main/java/java/security/ProtectionDomain.java
+++ /dev/null
@@ -1,28 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/ProtectionDomain.java,v 1.6 2006/03/14 01:20:27 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security;
-public class ProtectionDomain {
- public ProtectionDomain(java.security.CodeSource var0, java.security.PermissionCollection var1) { }
- public final java.security.CodeSource getCodeSource() { return null; }
- public final java.security.PermissionCollection getPermissions() { return null; }
- public boolean implies(java.security.Permission var0) { return false; }
- public java.lang.String toString() { return null; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/Provider.java b/org.osgi.foundation/src/main/java/java/security/Provider.java
deleted file mode 100644
index 516b525..0000000
--- a/org.osgi.foundation/src/main/java/java/security/Provider.java
+++ /dev/null
@@ -1,36 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/Provider.java,v 1.6 2006/03/14 01:20:27 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security;
-public abstract class Provider extends java.util.Properties {
- protected Provider(java.lang.String var0, double var1, java.lang.String var2) { }
- public void clear() { }
- public java.util.Set entrySet() { return null; }
- public java.lang.String getInfo() { return null; }
- public java.lang.String getName() { return null; }
- public double getVersion() { return 0.0d; }
- public java.util.Set keySet() { return null; }
- public void load(java.io.InputStream var0) throws java.io.IOException { }
- public java.lang.Object put(java.lang.Object var0, java.lang.Object var1) { return null; }
- public void putAll(java.util.Map var0) { }
- public java.lang.Object remove(java.lang.Object var0) { return null; }
- public java.lang.String toString() { return null; }
- public java.util.Collection values() { return null; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/ProviderException.java b/org.osgi.foundation/src/main/java/java/security/ProviderException.java
deleted file mode 100644
index d7636dd..0000000
--- a/org.osgi.foundation/src/main/java/java/security/ProviderException.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/ProviderException.java,v 1.6 2006/03/14 01:20:27 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security;
-public class ProviderException extends java.lang.RuntimeException {
- public ProviderException() { }
- public ProviderException(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/PublicKey.java b/org.osgi.foundation/src/main/java/java/security/PublicKey.java
deleted file mode 100644
index ba0ae2a..0000000
--- a/org.osgi.foundation/src/main/java/java/security/PublicKey.java
+++ /dev/null
@@ -1,24 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/PublicKey.java,v 1.6 2006/03/14 01:20:27 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security;
-public abstract interface PublicKey extends java.security.Key {
- public final static long serialVersionUID = 7187392471159151072l;
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/SecureClassLoader.java b/org.osgi.foundation/src/main/java/java/security/SecureClassLoader.java
deleted file mode 100644
index 370542c..0000000
--- a/org.osgi.foundation/src/main/java/java/security/SecureClassLoader.java
+++ /dev/null
@@ -1,27 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/SecureClassLoader.java,v 1.6 2006/03/14 01:20:27 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security;
-public class SecureClassLoader extends java.lang.ClassLoader {
- protected SecureClassLoader() { }
- protected SecureClassLoader(java.lang.ClassLoader var0) { }
- protected final java.lang.Class defineClass(java.lang.String var0, byte[] var1, int var2, int var3, java.security.CodeSource var4) { return null; }
- protected java.security.PermissionCollection getPermissions(java.security.CodeSource var0) { return null; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/SecureRandom.java b/org.osgi.foundation/src/main/java/java/security/SecureRandom.java
deleted file mode 100644
index 4e62650..0000000
--- a/org.osgi.foundation/src/main/java/java/security/SecureRandom.java
+++ /dev/null
@@ -1,35 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/SecureRandom.java,v 1.6 2006/03/14 01:20:27 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security;
-public class SecureRandom extends java.util.Random {
- public SecureRandom() { }
- public SecureRandom(byte[] var0) { }
- protected SecureRandom(java.security.SecureRandomSpi var0, java.security.Provider var1) { }
- public byte[] generateSeed(int var0) { return null; }
- public static java.security.SecureRandom getInstance(java.lang.String var0) throws java.security.NoSuchAlgorithmException { return null; }
- public static java.security.SecureRandom getInstance(java.lang.String var0, java.lang.String var1) throws java.security.NoSuchAlgorithmException, java.security.NoSuchProviderException { return null; }
- public final java.security.Provider getProvider() { return null; }
- public static byte[] getSeed(int var0) { return null; }
- protected final int next(int var0) { return 0; }
- public void nextBytes(byte[] var0) { }
- public void setSeed(byte[] var0) { }
- public void setSeed(long var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/SecureRandomSpi.java b/org.osgi.foundation/src/main/java/java/security/SecureRandomSpi.java
deleted file mode 100644
index b207112..0000000
--- a/org.osgi.foundation/src/main/java/java/security/SecureRandomSpi.java
+++ /dev/null
@@ -1,27 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/SecureRandomSpi.java,v 1.6 2006/03/14 01:20:26 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security;
-public abstract class SecureRandomSpi implements java.io.Serializable {
- public SecureRandomSpi() { }
- protected abstract byte[] engineGenerateSeed(int var0);
- protected abstract void engineNextBytes(byte[] var0);
- protected abstract void engineSetSeed(byte[] var0);
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/Security.java b/org.osgi.foundation/src/main/java/java/security/Security.java
deleted file mode 100644
index 3b2f121..0000000
--- a/org.osgi.foundation/src/main/java/java/security/Security.java
+++ /dev/null
@@ -1,33 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/Security.java,v 1.6 2006/03/14 01:20:27 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security;
-public final class Security {
- public static java.lang.String getProperty(java.lang.String var0) { return null; }
- public static void setProperty(java.lang.String var0, java.lang.String var1) { }
- public static int addProvider(java.security.Provider var0) { return 0; }
- public static java.security.Provider getProvider(java.lang.String var0) { return null; }
- public static java.security.Provider[] getProviders() { return null; }
- public static java.security.Provider[] getProviders(java.lang.String var0) { return null; }
- public static java.security.Provider[] getProviders(java.util.Map var0) { return null; }
- public static int insertProviderAt(java.security.Provider var0, int var1) { return 0; }
- public static void removeProvider(java.lang.String var0) { }
- private Security() { } /* generated constructor to prevent compiler adding default public constructor */
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/SecurityPermission.java b/org.osgi.foundation/src/main/java/java/security/SecurityPermission.java
deleted file mode 100644
index c3d0193..0000000
--- a/org.osgi.foundation/src/main/java/java/security/SecurityPermission.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/SecurityPermission.java,v 1.6 2006/03/14 01:20:26 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security;
-public final class SecurityPermission extends java.security.BasicPermission {
- public SecurityPermission(java.lang.String var0) { super((java.lang.String) null, (java.lang.String) null); }
- public SecurityPermission(java.lang.String var0, java.lang.String var1) { super((java.lang.String) null, (java.lang.String) null); }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/Signature.java b/org.osgi.foundation/src/main/java/java/security/Signature.java
deleted file mode 100644
index 3f9d222..0000000
--- a/org.osgi.foundation/src/main/java/java/security/Signature.java
+++ /dev/null
@@ -1,45 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/Signature.java,v 1.6 2006/03/14 01:20:27 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security;
-public abstract class Signature extends java.security.SignatureSpi {
- protected Signature(java.lang.String var0) { }
- public java.lang.Object clone() throws java.lang.CloneNotSupportedException { return null; }
- public final java.lang.String getAlgorithm() { return null; }
- public static java.security.Signature getInstance(java.lang.String var0) throws java.security.NoSuchAlgorithmException { return null; }
- public static java.security.Signature getInstance(java.lang.String var0, java.lang.String var1) throws java.security.NoSuchAlgorithmException, java.security.NoSuchProviderException { return null; }
- public final java.security.Provider getProvider() { return null; }
- public final void initSign(java.security.PrivateKey var0) throws java.security.InvalidKeyException { }
- public final void initSign(java.security.PrivateKey var0, java.security.SecureRandom var1) throws java.security.InvalidKeyException { }
- public final void initVerify(java.security.PublicKey var0) throws java.security.InvalidKeyException { }
- public final void initVerify(java.security.cert.Certificate var0) throws java.security.InvalidKeyException { }
- public final void setParameter(java.security.spec.AlgorithmParameterSpec var0) throws java.security.InvalidAlgorithmParameterException { }
- public final byte[] sign() throws java.security.SignatureException { return null; }
- public final int sign(byte[] var0, int var1, int var2) throws java.security.SignatureException { return 0; }
- public java.lang.String toString() { return null; }
- public final void update(byte[] var0) throws java.security.SignatureException { }
- public final void update(byte[] var0, int var1, int var2) throws java.security.SignatureException { }
- public final void update(byte var0) throws java.security.SignatureException { }
- public final boolean verify(byte[] var0) throws java.security.SignatureException { return false; }
- protected final static int UNINITIALIZED = 0;
- protected final static int SIGN = 2;
- protected final static int VERIFY = 3;
- protected int state;
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/SignatureException.java b/org.osgi.foundation/src/main/java/java/security/SignatureException.java
deleted file mode 100644
index 370edda..0000000
--- a/org.osgi.foundation/src/main/java/java/security/SignatureException.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/SignatureException.java,v 1.6 2006/03/14 01:20:27 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security;
-public class SignatureException extends java.security.GeneralSecurityException {
- public SignatureException() { }
- public SignatureException(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/SignatureSpi.java b/org.osgi.foundation/src/main/java/java/security/SignatureSpi.java
deleted file mode 100644
index d812ddb..0000000
--- a/org.osgi.foundation/src/main/java/java/security/SignatureSpi.java
+++ /dev/null
@@ -1,35 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/SignatureSpi.java,v 1.6 2006/03/14 01:20:27 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security;
-public abstract class SignatureSpi {
- public SignatureSpi() { }
- public java.lang.Object clone() throws java.lang.CloneNotSupportedException { return null; }
- protected abstract void engineInitSign(java.security.PrivateKey var0) throws java.security.InvalidKeyException;
- protected void engineInitSign(java.security.PrivateKey var0, java.security.SecureRandom var1) throws java.security.InvalidKeyException { }
- protected abstract void engineInitVerify(java.security.PublicKey var0) throws java.security.InvalidKeyException;
- protected void engineSetParameter(java.security.spec.AlgorithmParameterSpec var0) throws java.security.InvalidAlgorithmParameterException { }
- protected abstract byte[] engineSign() throws java.security.SignatureException;
- protected int engineSign(byte[] var0, int var1, int var2) throws java.security.SignatureException { return 0; }
- protected abstract void engineUpdate(byte[] var0, int var1, int var2) throws java.security.SignatureException;
- protected abstract void engineUpdate(byte var0) throws java.security.SignatureException;
- protected abstract boolean engineVerify(byte[] var0) throws java.security.SignatureException;
- protected java.security.SecureRandom appRandom;
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/SignedObject.java b/org.osgi.foundation/src/main/java/java/security/SignedObject.java
deleted file mode 100644
index 4e724c2..0000000
--- a/org.osgi.foundation/src/main/java/java/security/SignedObject.java
+++ /dev/null
@@ -1,28 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/SignedObject.java,v 1.6 2006/03/14 01:20:26 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security;
-public final class SignedObject implements java.io.Serializable {
- public SignedObject(java.io.Serializable var0, java.security.PrivateKey var1, java.security.Signature var2) throws java.io.IOException, java.security.InvalidKeyException, java.security.SignatureException { }
- public java.lang.String getAlgorithm() { return null; }
- public byte[] getSignature() { return null; }
- public boolean verify(java.security.PublicKey var0, java.security.Signature var1) throws java.security.InvalidKeyException, java.security.SignatureException { return false; }
- public java.lang.Object getObject() throws java.io.IOException, java.lang.ClassNotFoundException { return null; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/Signer.java b/org.osgi.foundation/src/main/java/java/security/Signer.java
deleted file mode 100644
index aa73f3f..0000000
--- a/org.osgi.foundation/src/main/java/java/security/Signer.java
+++ /dev/null
@@ -1,29 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/Signer.java,v 1.6 2006/03/14 01:20:27 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security;
-public abstract class Signer extends java.security.Identity {
- protected Signer() { }
- public Signer(java.lang.String var0) { }
- public Signer(java.lang.String var0, java.security.IdentityScope var1) throws java.security.KeyManagementException { }
- public java.security.PrivateKey getPrivateKey() { return null; }
- public final void setKeyPair(java.security.KeyPair var0) throws java.security.InvalidParameterException, java.security.KeyException { }
- public java.lang.String toString() { return null; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/UnrecoverableKeyException.java b/org.osgi.foundation/src/main/java/java/security/UnrecoverableKeyException.java
deleted file mode 100644
index 44fc42e..0000000
--- a/org.osgi.foundation/src/main/java/java/security/UnrecoverableKeyException.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/UnrecoverableKeyException.java,v 1.6 2006/03/14 01:20:27 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security;
-public class UnrecoverableKeyException extends java.security.GeneralSecurityException {
- public UnrecoverableKeyException() { }
- public UnrecoverableKeyException(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/UnresolvedPermission.java b/org.osgi.foundation/src/main/java/java/security/UnresolvedPermission.java
deleted file mode 100644
index 651127b..0000000
--- a/org.osgi.foundation/src/main/java/java/security/UnresolvedPermission.java
+++ /dev/null
@@ -1,30 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/UnresolvedPermission.java,v 1.6 2006/03/14 01:20:26 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security;
-public final class UnresolvedPermission extends java.security.Permission implements java.io.Serializable {
- public UnresolvedPermission(java.lang.String var0, java.lang.String var1, java.lang.String var2, java.security.cert.Certificate[] var3) { super((java.lang.String) null); }
- public boolean equals(java.lang.Object var0) { return false; }
- public boolean implies(java.security.Permission var0) { return false; }
- public java.security.PermissionCollection newPermissionCollection() { return null; }
- public java.lang.String getActions() { return null; }
- public int hashCode() { return 0; }
- public java.lang.String toString() { return null; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/acl/Acl.java b/org.osgi.foundation/src/main/java/java/security/acl/Acl.java
deleted file mode 100644
index 0b2c742..0000000
--- a/org.osgi.foundation/src/main/java/java/security/acl/Acl.java
+++ /dev/null
@@ -1,31 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/acl/Acl.java,v 1.6 2006/03/14 01:20:29 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security.acl;
-public abstract interface Acl extends java.security.acl.Owner {
- public abstract boolean addEntry(java.security.Principal var0, java.security.acl.AclEntry var1) throws java.security.acl.NotOwnerException;
- public abstract boolean checkPermission(java.security.Principal var0, java.security.acl.Permission var1);
- public abstract java.util.Enumeration entries();
- public abstract java.lang.String getName();
- public abstract java.util.Enumeration getPermissions(java.security.Principal var0);
- public abstract boolean removeEntry(java.security.Principal var0, java.security.acl.AclEntry var1) throws java.security.acl.NotOwnerException;
- public abstract void setName(java.security.Principal var0, java.lang.String var1) throws java.security.acl.NotOwnerException;
- public abstract java.lang.String toString();
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/acl/AclEntry.java b/org.osgi.foundation/src/main/java/java/security/acl/AclEntry.java
deleted file mode 100644
index c26a642..0000000
--- a/org.osgi.foundation/src/main/java/java/security/acl/AclEntry.java
+++ /dev/null
@@ -1,33 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/acl/AclEntry.java,v 1.6 2006/03/14 01:20:29 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security.acl;
-public abstract interface AclEntry extends java.lang.Cloneable {
- public abstract boolean addPermission(java.security.acl.Permission var0);
- public abstract boolean checkPermission(java.security.acl.Permission var0);
- public abstract java.lang.Object clone();
- public abstract java.security.Principal getPrincipal();
- public abstract boolean isNegative();
- public abstract java.util.Enumeration permissions();
- public abstract boolean removePermission(java.security.acl.Permission var0);
- public abstract void setNegativePermissions();
- public abstract boolean setPrincipal(java.security.Principal var0);
- public abstract java.lang.String toString();
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/acl/AclNotFoundException.java b/org.osgi.foundation/src/main/java/java/security/acl/AclNotFoundException.java
deleted file mode 100644
index e98e73c..0000000
--- a/org.osgi.foundation/src/main/java/java/security/acl/AclNotFoundException.java
+++ /dev/null
@@ -1,24 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/acl/AclNotFoundException.java,v 1.6 2006/03/14 01:20:29 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security.acl;
-public class AclNotFoundException extends java.lang.Exception {
- public AclNotFoundException() { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/acl/Group.java b/org.osgi.foundation/src/main/java/java/security/acl/Group.java
deleted file mode 100644
index 4439a75..0000000
--- a/org.osgi.foundation/src/main/java/java/security/acl/Group.java
+++ /dev/null
@@ -1,27 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/acl/Group.java,v 1.6 2006/03/14 01:20:29 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security.acl;
-public abstract interface Group extends java.security.Principal {
- public abstract boolean addMember(java.security.Principal var0);
- public abstract boolean isMember(java.security.Principal var0);
- public abstract java.util.Enumeration members();
- public abstract boolean removeMember(java.security.Principal var0);
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/acl/LastOwnerException.java b/org.osgi.foundation/src/main/java/java/security/acl/LastOwnerException.java
deleted file mode 100644
index aad5f71..0000000
--- a/org.osgi.foundation/src/main/java/java/security/acl/LastOwnerException.java
+++ /dev/null
@@ -1,24 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/acl/LastOwnerException.java,v 1.6 2006/03/14 01:20:29 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security.acl;
-public class LastOwnerException extends java.lang.Exception {
- public LastOwnerException() { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/acl/NotOwnerException.java b/org.osgi.foundation/src/main/java/java/security/acl/NotOwnerException.java
deleted file mode 100644
index 7b81f24..0000000
--- a/org.osgi.foundation/src/main/java/java/security/acl/NotOwnerException.java
+++ /dev/null
@@ -1,24 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/acl/NotOwnerException.java,v 1.6 2006/03/14 01:20:29 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security.acl;
-public class NotOwnerException extends java.lang.Exception {
- public NotOwnerException() { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/acl/Owner.java b/org.osgi.foundation/src/main/java/java/security/acl/Owner.java
deleted file mode 100644
index 9ab63df..0000000
--- a/org.osgi.foundation/src/main/java/java/security/acl/Owner.java
+++ /dev/null
@@ -1,26 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/acl/Owner.java,v 1.6 2006/03/14 01:20:29 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security.acl;
-public abstract interface Owner {
- public abstract boolean addOwner(java.security.Principal var0, java.security.Principal var1) throws java.security.acl.NotOwnerException;
- public abstract boolean deleteOwner(java.security.Principal var0, java.security.Principal var1) throws java.security.acl.NotOwnerException, java.security.acl.LastOwnerException;
- public abstract boolean isOwner(java.security.Principal var0);
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/acl/Permission.java b/org.osgi.foundation/src/main/java/java/security/acl/Permission.java
deleted file mode 100644
index fcb642b..0000000
--- a/org.osgi.foundation/src/main/java/java/security/acl/Permission.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/acl/Permission.java,v 1.6 2006/03/14 01:20:29 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security.acl;
-public abstract interface Permission {
- public abstract boolean equals(java.lang.Object var0);
- public abstract java.lang.String toString();
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/cert/CRL.java b/org.osgi.foundation/src/main/java/java/security/cert/CRL.java
deleted file mode 100644
index 7bfb137..0000000
--- a/org.osgi.foundation/src/main/java/java/security/cert/CRL.java
+++ /dev/null
@@ -1,27 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/cert/CRL.java,v 1.6 2006/03/14 01:20:29 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security.cert;
-public abstract class CRL {
- protected CRL(java.lang.String var0) { }
- public final java.lang.String getType() { return null; }
- public abstract boolean isRevoked(java.security.cert.Certificate var0);
- public abstract java.lang.String toString();
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/cert/CRLException.java b/org.osgi.foundation/src/main/java/java/security/cert/CRLException.java
deleted file mode 100644
index 3dcb33c..0000000
--- a/org.osgi.foundation/src/main/java/java/security/cert/CRLException.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/cert/CRLException.java,v 1.6 2006/03/14 01:20:29 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security.cert;
-public class CRLException extends java.security.GeneralSecurityException {
- public CRLException() { }
- public CRLException(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/cert/Certificate.java b/org.osgi.foundation/src/main/java/java/security/cert/Certificate.java
deleted file mode 100644
index c04a636..0000000
--- a/org.osgi.foundation/src/main/java/java/security/cert/Certificate.java
+++ /dev/null
@@ -1,37 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/cert/Certificate.java,v 1.6 2006/03/14 01:20:29 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security.cert;
-public abstract class Certificate implements java.io.Serializable {
- protected Certificate(java.lang.String var0) { }
- public boolean equals(java.lang.Object var0) { return false; }
- public abstract byte[] getEncoded() throws java.security.cert.CertificateEncodingException;
- public abstract java.security.PublicKey getPublicKey();
- public final java.lang.String getType() { return null; }
- public int hashCode() { return 0; }
- public abstract java.lang.String toString();
- public abstract void verify(java.security.PublicKey var0) throws java.security.cert.CertificateException, java.security.NoSuchAlgorithmException, java.security.InvalidKeyException, java.security.NoSuchProviderException, java.security.SignatureException;
- public abstract void verify(java.security.PublicKey var0, java.lang.String var1) throws java.security.cert.CertificateException, java.security.NoSuchAlgorithmException, java.security.InvalidKeyException, java.security.NoSuchProviderException, java.security.SignatureException;
- protected java.lang.Object writeReplace() throws java.io.ObjectStreamException { return null; }
- protected static class CertificateRep implements java.io.Serializable {
- protected CertificateRep(java.lang.String var0, byte[] var1) { }
- protected java.lang.Object readResolve() throws java.io.ObjectStreamException { return null; }
- }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/cert/CertificateEncodingException.java b/org.osgi.foundation/src/main/java/java/security/cert/CertificateEncodingException.java
deleted file mode 100644
index 2825771..0000000
--- a/org.osgi.foundation/src/main/java/java/security/cert/CertificateEncodingException.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/cert/CertificateEncodingException.java,v 1.6 2006/03/14 01:20:29 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security.cert;
-public class CertificateEncodingException extends java.security.cert.CertificateException {
- public CertificateEncodingException() { }
- public CertificateEncodingException(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/cert/CertificateException.java b/org.osgi.foundation/src/main/java/java/security/cert/CertificateException.java
deleted file mode 100644
index a02b96c..0000000
--- a/org.osgi.foundation/src/main/java/java/security/cert/CertificateException.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/cert/CertificateException.java,v 1.6 2006/03/14 01:20:29 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security.cert;
-public class CertificateException extends java.security.GeneralSecurityException {
- public CertificateException() { }
- public CertificateException(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/cert/CertificateExpiredException.java b/org.osgi.foundation/src/main/java/java/security/cert/CertificateExpiredException.java
deleted file mode 100644
index 7370e1e..0000000
--- a/org.osgi.foundation/src/main/java/java/security/cert/CertificateExpiredException.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/cert/CertificateExpiredException.java,v 1.6 2006/03/14 01:20:29 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security.cert;
-public class CertificateExpiredException extends java.security.cert.CertificateException {
- public CertificateExpiredException() { }
- public CertificateExpiredException(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/cert/CertificateFactory.java b/org.osgi.foundation/src/main/java/java/security/cert/CertificateFactory.java
deleted file mode 100644
index 8f63c39..0000000
--- a/org.osgi.foundation/src/main/java/java/security/cert/CertificateFactory.java
+++ /dev/null
@@ -1,32 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/cert/CertificateFactory.java,v 1.6 2006/03/14 01:20:29 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security.cert;
-public class CertificateFactory {
- protected CertificateFactory(java.security.cert.CertificateFactorySpi var0, java.security.Provider var1, java.lang.String var2) { }
- public final java.security.cert.Certificate generateCertificate(java.io.InputStream var0) throws java.security.cert.CertificateException { return null; }
- public final java.util.Collection generateCertificates(java.io.InputStream var0) throws java.security.cert.CertificateException { return null; }
- public final java.security.cert.CRL generateCRL(java.io.InputStream var0) throws java.security.cert.CRLException { return null; }
- public final java.util.Collection generateCRLs(java.io.InputStream var0) throws java.security.cert.CRLException { return null; }
- public final static java.security.cert.CertificateFactory getInstance(java.lang.String var0) throws java.security.cert.CertificateException { return null; }
- public final static java.security.cert.CertificateFactory getInstance(java.lang.String var0, java.lang.String var1) throws java.security.cert.CertificateException, java.security.NoSuchProviderException { return null; }
- public final java.security.Provider getProvider() { return null; }
- public final java.lang.String getType() { return null; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/cert/CertificateFactorySpi.java b/org.osgi.foundation/src/main/java/java/security/cert/CertificateFactorySpi.java
deleted file mode 100644
index f7ea0fe..0000000
--- a/org.osgi.foundation/src/main/java/java/security/cert/CertificateFactorySpi.java
+++ /dev/null
@@ -1,28 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/cert/CertificateFactorySpi.java,v 1.6 2006/03/14 01:20:29 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security.cert;
-public abstract class CertificateFactorySpi {
- public CertificateFactorySpi() { }
- public abstract java.security.cert.Certificate engineGenerateCertificate(java.io.InputStream var0) throws java.security.cert.CertificateException;
- public abstract java.util.Collection engineGenerateCertificates(java.io.InputStream var0) throws java.security.cert.CertificateException;
- public abstract java.security.cert.CRL engineGenerateCRL(java.io.InputStream var0) throws java.security.cert.CRLException;
- public abstract java.util.Collection engineGenerateCRLs(java.io.InputStream var0) throws java.security.cert.CRLException;
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/cert/CertificateNotYetValidException.java b/org.osgi.foundation/src/main/java/java/security/cert/CertificateNotYetValidException.java
deleted file mode 100644
index ae90fdf..0000000
--- a/org.osgi.foundation/src/main/java/java/security/cert/CertificateNotYetValidException.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/cert/CertificateNotYetValidException.java,v 1.6 2006/03/14 01:20:29 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security.cert;
-public class CertificateNotYetValidException extends java.security.cert.CertificateException {
- public CertificateNotYetValidException() { }
- public CertificateNotYetValidException(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/cert/CertificateParsingException.java b/org.osgi.foundation/src/main/java/java/security/cert/CertificateParsingException.java
deleted file mode 100644
index 8f8881d..0000000
--- a/org.osgi.foundation/src/main/java/java/security/cert/CertificateParsingException.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/cert/CertificateParsingException.java,v 1.6 2006/03/14 01:20:29 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security.cert;
-public class CertificateParsingException extends java.security.cert.CertificateException {
- public CertificateParsingException() { }
- public CertificateParsingException(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/cert/X509CRL.java b/org.osgi.foundation/src/main/java/java/security/cert/X509CRL.java
deleted file mode 100644
index f8787fd..0000000
--- a/org.osgi.foundation/src/main/java/java/security/cert/X509CRL.java
+++ /dev/null
@@ -1,44 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/cert/X509CRL.java,v 1.6 2006/03/14 01:20:29 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security.cert;
-public abstract class X509CRL extends java.security.cert.CRL implements java.security.cert.X509Extension {
- protected X509CRL() { super((java.lang.String) null); }
- public abstract byte[] getEncoded() throws java.security.cert.CRLException;
- public abstract java.security.Principal getIssuerDN();
- public abstract java.util.Date getNextUpdate();
- public abstract java.security.cert.X509CRLEntry getRevokedCertificate(java.math.BigInteger var0);
- public abstract java.util.Set getRevokedCertificates();
- public abstract java.lang.String getSigAlgName();
- public abstract java.lang.String getSigAlgOID();
- public abstract byte[] getSigAlgParams();
- public abstract byte[] getSignature();
- public abstract byte[] getTBSCertList() throws java.security.cert.CRLException;
- public abstract java.util.Date getThisUpdate();
- public abstract int getVersion();
- public abstract void verify(java.security.PublicKey var0) throws java.security.cert.CRLException, java.security.NoSuchAlgorithmException, java.security.InvalidKeyException, java.security.NoSuchProviderException, java.security.SignatureException;
- public abstract void verify(java.security.PublicKey var0, java.lang.String var1) throws java.security.cert.CRLException, java.security.NoSuchAlgorithmException, java.security.InvalidKeyException, java.security.NoSuchProviderException, java.security.SignatureException;
- public boolean equals(java.lang.Object var0) { return false; }
- public int hashCode() { return 0; }
- public abstract boolean hasUnsupportedCriticalExtension();
- public abstract java.util.Set getCriticalExtensionOIDs();
- public abstract java.util.Set getNonCriticalExtensionOIDs();
- public abstract byte[] getExtensionValue(java.lang.String var0);
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/cert/X509CRLEntry.java b/org.osgi.foundation/src/main/java/java/security/cert/X509CRLEntry.java
deleted file mode 100644
index eb6c3e8..0000000
--- a/org.osgi.foundation/src/main/java/java/security/cert/X509CRLEntry.java
+++ /dev/null
@@ -1,35 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/cert/X509CRLEntry.java,v 1.6 2006/03/14 01:20:29 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security.cert;
-public abstract class X509CRLEntry implements java.security.cert.X509Extension {
- public X509CRLEntry() { }
- public boolean equals(java.lang.Object var0) { return false; }
- public abstract byte[] getEncoded() throws java.security.cert.CRLException;
- public abstract java.math.BigInteger getSerialNumber();
- public abstract java.util.Date getRevocationDate();
- public abstract boolean hasExtensions();
- public int hashCode() { return 0; }
- public abstract java.lang.String toString();
- public abstract boolean hasUnsupportedCriticalExtension();
- public abstract java.util.Set getCriticalExtensionOIDs();
- public abstract java.util.Set getNonCriticalExtensionOIDs();
- public abstract byte[] getExtensionValue(java.lang.String var0);
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/cert/X509Certificate.java b/org.osgi.foundation/src/main/java/java/security/cert/X509Certificate.java
deleted file mode 100644
index 816aeb6..0000000
--- a/org.osgi.foundation/src/main/java/java/security/cert/X509Certificate.java
+++ /dev/null
@@ -1,45 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/cert/X509Certificate.java,v 1.6 2006/03/14 01:20:29 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security.cert;
-public abstract class X509Certificate extends java.security.cert.Certificate implements java.security.cert.X509Extension {
- protected X509Certificate() { super((java.lang.String) null); }
- public abstract void checkValidity() throws java.security.cert.CertificateExpiredException, java.security.cert.CertificateNotYetValidException;
- public abstract void checkValidity(java.util.Date var0) throws java.security.cert.CertificateExpiredException, java.security.cert.CertificateNotYetValidException;
- public abstract int getBasicConstraints();
- public abstract java.security.Principal getIssuerDN();
- public abstract boolean[] getIssuerUniqueID();
- public abstract boolean[] getKeyUsage();
- public abstract java.util.Date getNotAfter();
- public abstract java.util.Date getNotBefore();
- public abstract java.math.BigInteger getSerialNumber();
- public abstract java.lang.String getSigAlgName();
- public abstract java.lang.String getSigAlgOID();
- public abstract byte[] getSigAlgParams();
- public abstract byte[] getSignature();
- public abstract java.security.Principal getSubjectDN();
- public abstract boolean[] getSubjectUniqueID();
- public abstract byte[] getTBSCertificate() throws java.security.cert.CertificateEncodingException;
- public abstract int getVersion();
- public abstract boolean hasUnsupportedCriticalExtension();
- public abstract java.util.Set getCriticalExtensionOIDs();
- public abstract java.util.Set getNonCriticalExtensionOIDs();
- public abstract byte[] getExtensionValue(java.lang.String var0);
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/cert/X509Extension.java b/org.osgi.foundation/src/main/java/java/security/cert/X509Extension.java
deleted file mode 100644
index 1eb0eda..0000000
--- a/org.osgi.foundation/src/main/java/java/security/cert/X509Extension.java
+++ /dev/null
@@ -1,27 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/cert/X509Extension.java,v 1.6 2006/03/14 01:20:29 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security.cert;
-public abstract interface X509Extension {
- public abstract boolean hasUnsupportedCriticalExtension();
- public abstract java.util.Set getCriticalExtensionOIDs();
- public abstract java.util.Set getNonCriticalExtensionOIDs();
- public abstract byte[] getExtensionValue(java.lang.String var0);
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/interfaces/DSAKey.java b/org.osgi.foundation/src/main/java/java/security/interfaces/DSAKey.java
deleted file mode 100644
index 62babe1..0000000
--- a/org.osgi.foundation/src/main/java/java/security/interfaces/DSAKey.java
+++ /dev/null
@@ -1,24 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/interfaces/DSAKey.java,v 1.6 2006/03/14 01:20:30 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security.interfaces;
-public abstract interface DSAKey {
- public abstract java.security.interfaces.DSAParams getParams();
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/interfaces/DSAKeyPairGenerator.java b/org.osgi.foundation/src/main/java/java/security/interfaces/DSAKeyPairGenerator.java
deleted file mode 100644
index beabee9..0000000
--- a/org.osgi.foundation/src/main/java/java/security/interfaces/DSAKeyPairGenerator.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/interfaces/DSAKeyPairGenerator.java,v 1.6 2006/03/14 01:20:30 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security.interfaces;
-public abstract interface DSAKeyPairGenerator {
- public abstract void initialize(java.security.interfaces.DSAParams var0, java.security.SecureRandom var1) throws java.security.InvalidParameterException;
- public abstract void initialize(int var0, boolean var1, java.security.SecureRandom var2) throws java.security.InvalidParameterException;
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/interfaces/DSAParams.java b/org.osgi.foundation/src/main/java/java/security/interfaces/DSAParams.java
deleted file mode 100644
index 4655785..0000000
--- a/org.osgi.foundation/src/main/java/java/security/interfaces/DSAParams.java
+++ /dev/null
@@ -1,26 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/interfaces/DSAParams.java,v 1.6 2006/03/14 01:20:30 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security.interfaces;
-public abstract interface DSAParams {
- public abstract java.math.BigInteger getP();
- public abstract java.math.BigInteger getQ();
- public abstract java.math.BigInteger getG();
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/interfaces/DSAPrivateKey.java b/org.osgi.foundation/src/main/java/java/security/interfaces/DSAPrivateKey.java
deleted file mode 100644
index 408486e4..0000000
--- a/org.osgi.foundation/src/main/java/java/security/interfaces/DSAPrivateKey.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/interfaces/DSAPrivateKey.java,v 1.6 2006/03/14 01:20:30 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security.interfaces;
-public abstract interface DSAPrivateKey extends java.security.interfaces.DSAKey, java.security.PrivateKey {
- public abstract java.math.BigInteger getX();
- public final static long serialVersionUID = 7776497482533790279l;
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/interfaces/DSAPublicKey.java b/org.osgi.foundation/src/main/java/java/security/interfaces/DSAPublicKey.java
deleted file mode 100644
index 53aab62..0000000
--- a/org.osgi.foundation/src/main/java/java/security/interfaces/DSAPublicKey.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/interfaces/DSAPublicKey.java,v 1.6 2006/03/14 01:20:30 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security.interfaces;
-public abstract interface DSAPublicKey extends java.security.interfaces.DSAKey, java.security.PublicKey {
- public abstract java.math.BigInteger getY();
- public final static long serialVersionUID = 1234526332779022332l;
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/interfaces/RSAKey.java b/org.osgi.foundation/src/main/java/java/security/interfaces/RSAKey.java
deleted file mode 100644
index 457b856..0000000
--- a/org.osgi.foundation/src/main/java/java/security/interfaces/RSAKey.java
+++ /dev/null
@@ -1,24 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/interfaces/RSAKey.java,v 1.6 2006/03/14 01:20:30 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security.interfaces;
-public abstract interface RSAKey {
- public abstract java.math.BigInteger getModulus();
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/interfaces/RSAPrivateCrtKey.java b/org.osgi.foundation/src/main/java/java/security/interfaces/RSAPrivateCrtKey.java
deleted file mode 100644
index 058cc5d..0000000
--- a/org.osgi.foundation/src/main/java/java/security/interfaces/RSAPrivateCrtKey.java
+++ /dev/null
@@ -1,29 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/interfaces/RSAPrivateCrtKey.java,v 1.6 2006/03/14 01:20:30 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security.interfaces;
-public abstract interface RSAPrivateCrtKey extends java.security.interfaces.RSAPrivateKey {
- public abstract java.math.BigInteger getPublicExponent();
- public abstract java.math.BigInteger getPrimeP();
- public abstract java.math.BigInteger getPrimeQ();
- public abstract java.math.BigInteger getPrimeExponentP();
- public abstract java.math.BigInteger getPrimeExponentQ();
- public abstract java.math.BigInteger getCrtCoefficient();
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/interfaces/RSAPrivateKey.java b/org.osgi.foundation/src/main/java/java/security/interfaces/RSAPrivateKey.java
deleted file mode 100644
index 0f80684..0000000
--- a/org.osgi.foundation/src/main/java/java/security/interfaces/RSAPrivateKey.java
+++ /dev/null
@@ -1,24 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/interfaces/RSAPrivateKey.java,v 1.6 2006/03/14 01:20:30 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security.interfaces;
-public abstract interface RSAPrivateKey extends java.security.PrivateKey, java.security.interfaces.RSAKey {
- public abstract java.math.BigInteger getPrivateExponent();
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/interfaces/RSAPublicKey.java b/org.osgi.foundation/src/main/java/java/security/interfaces/RSAPublicKey.java
deleted file mode 100644
index 5cc26a0..0000000
--- a/org.osgi.foundation/src/main/java/java/security/interfaces/RSAPublicKey.java
+++ /dev/null
@@ -1,24 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/interfaces/RSAPublicKey.java,v 1.6 2006/03/14 01:20:30 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security.interfaces;
-public abstract interface RSAPublicKey extends java.security.PublicKey, java.security.interfaces.RSAKey {
- public abstract java.math.BigInteger getPublicExponent();
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/spec/AlgorithmParameterSpec.java b/org.osgi.foundation/src/main/java/java/security/spec/AlgorithmParameterSpec.java
deleted file mode 100644
index f589318..0000000
--- a/org.osgi.foundation/src/main/java/java/security/spec/AlgorithmParameterSpec.java
+++ /dev/null
@@ -1,23 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/spec/AlgorithmParameterSpec.java,v 1.6 2006/03/14 01:20:30 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security.spec;
-public abstract interface AlgorithmParameterSpec {
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/spec/DSAParameterSpec.java b/org.osgi.foundation/src/main/java/java/security/spec/DSAParameterSpec.java
deleted file mode 100644
index 891cb81..0000000
--- a/org.osgi.foundation/src/main/java/java/security/spec/DSAParameterSpec.java
+++ /dev/null
@@ -1,27 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/spec/DSAParameterSpec.java,v 1.6 2006/03/14 01:20:30 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security.spec;
-public class DSAParameterSpec implements java.security.spec.AlgorithmParameterSpec, java.security.interfaces.DSAParams {
- public java.math.BigInteger getG() { return null; }
- public java.math.BigInteger getP() { return null; }
- public java.math.BigInteger getQ() { return null; }
- public DSAParameterSpec(java.math.BigInteger var0, java.math.BigInteger var1, java.math.BigInteger var2) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/spec/DSAPrivateKeySpec.java b/org.osgi.foundation/src/main/java/java/security/spec/DSAPrivateKeySpec.java
deleted file mode 100644
index 0614f0b..0000000
--- a/org.osgi.foundation/src/main/java/java/security/spec/DSAPrivateKeySpec.java
+++ /dev/null
@@ -1,28 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/spec/DSAPrivateKeySpec.java,v 1.6 2006/03/14 01:20:30 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security.spec;
-public class DSAPrivateKeySpec implements java.security.spec.KeySpec {
- public java.math.BigInteger getG() { return null; }
- public java.math.BigInteger getP() { return null; }
- public java.math.BigInteger getQ() { return null; }
- public java.math.BigInteger getX() { return null; }
- public DSAPrivateKeySpec(java.math.BigInteger var0, java.math.BigInteger var1, java.math.BigInteger var2, java.math.BigInteger var3) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/spec/DSAPublicKeySpec.java b/org.osgi.foundation/src/main/java/java/security/spec/DSAPublicKeySpec.java
deleted file mode 100644
index ccd7a0f..0000000
--- a/org.osgi.foundation/src/main/java/java/security/spec/DSAPublicKeySpec.java
+++ /dev/null
@@ -1,28 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/spec/DSAPublicKeySpec.java,v 1.6 2006/03/14 01:20:30 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security.spec;
-public class DSAPublicKeySpec implements java.security.spec.KeySpec {
- public java.math.BigInteger getG() { return null; }
- public java.math.BigInteger getP() { return null; }
- public java.math.BigInteger getQ() { return null; }
- public java.math.BigInteger getY() { return null; }
- public DSAPublicKeySpec(java.math.BigInteger var0, java.math.BigInteger var1, java.math.BigInteger var2, java.math.BigInteger var3) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/spec/EncodedKeySpec.java b/org.osgi.foundation/src/main/java/java/security/spec/EncodedKeySpec.java
deleted file mode 100644
index 630dc4b..0000000
--- a/org.osgi.foundation/src/main/java/java/security/spec/EncodedKeySpec.java
+++ /dev/null
@@ -1,26 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/spec/EncodedKeySpec.java,v 1.6 2006/03/14 01:20:30 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security.spec;
-public abstract class EncodedKeySpec implements java.security.spec.KeySpec {
- public EncodedKeySpec(byte[] var0) { }
- public byte[] getEncoded() { return null; }
- public abstract java.lang.String getFormat();
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/spec/InvalidKeySpecException.java b/org.osgi.foundation/src/main/java/java/security/spec/InvalidKeySpecException.java
deleted file mode 100644
index 4aff286..0000000
--- a/org.osgi.foundation/src/main/java/java/security/spec/InvalidKeySpecException.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/spec/InvalidKeySpecException.java,v 1.6 2006/03/14 01:20:30 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security.spec;
-public class InvalidKeySpecException extends java.security.GeneralSecurityException {
- public InvalidKeySpecException() { }
- public InvalidKeySpecException(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/spec/InvalidParameterSpecException.java b/org.osgi.foundation/src/main/java/java/security/spec/InvalidParameterSpecException.java
deleted file mode 100644
index d751f65..0000000
--- a/org.osgi.foundation/src/main/java/java/security/spec/InvalidParameterSpecException.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/spec/InvalidParameterSpecException.java,v 1.6 2006/03/14 01:20:30 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security.spec;
-public class InvalidParameterSpecException extends java.security.GeneralSecurityException {
- public InvalidParameterSpecException() { }
- public InvalidParameterSpecException(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/spec/KeySpec.java b/org.osgi.foundation/src/main/java/java/security/spec/KeySpec.java
deleted file mode 100644
index 0514804..0000000
--- a/org.osgi.foundation/src/main/java/java/security/spec/KeySpec.java
+++ /dev/null
@@ -1,23 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/spec/KeySpec.java,v 1.6 2006/03/14 01:20:30 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security.spec;
-public abstract interface KeySpec {
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/spec/PKCS8EncodedKeySpec.java b/org.osgi.foundation/src/main/java/java/security/spec/PKCS8EncodedKeySpec.java
deleted file mode 100644
index 55d4b41..0000000
--- a/org.osgi.foundation/src/main/java/java/security/spec/PKCS8EncodedKeySpec.java
+++ /dev/null
@@ -1,26 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/spec/PKCS8EncodedKeySpec.java,v 1.6 2006/03/14 01:20:30 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security.spec;
-public class PKCS8EncodedKeySpec extends java.security.spec.EncodedKeySpec {
- public PKCS8EncodedKeySpec(byte[] var0) { super((byte[]) null); }
- public byte[] getEncoded() { return null; }
- public final java.lang.String getFormat() { return null; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/spec/RSAKeyGenParameterSpec.java b/org.osgi.foundation/src/main/java/java/security/spec/RSAKeyGenParameterSpec.java
deleted file mode 100644
index 05d844d..0000000
--- a/org.osgi.foundation/src/main/java/java/security/spec/RSAKeyGenParameterSpec.java
+++ /dev/null
@@ -1,28 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/spec/RSAKeyGenParameterSpec.java,v 1.6 2006/03/14 01:20:30 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security.spec;
-public class RSAKeyGenParameterSpec implements java.security.spec.AlgorithmParameterSpec {
- public RSAKeyGenParameterSpec(int var0, java.math.BigInteger var1) { }
- public java.math.BigInteger getPublicExponent() { return null; }
- public int getKeysize() { return 0; }
- public final static java.math.BigInteger F0; static { F0 = null; }
- public final static java.math.BigInteger F4; static { F4 = null; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/spec/RSAPrivateCrtKeySpec.java b/org.osgi.foundation/src/main/java/java/security/spec/RSAPrivateCrtKeySpec.java
deleted file mode 100644
index 5d4bf35..0000000
--- a/org.osgi.foundation/src/main/java/java/security/spec/RSAPrivateCrtKeySpec.java
+++ /dev/null
@@ -1,30 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/spec/RSAPrivateCrtKeySpec.java,v 1.6 2006/03/14 01:20:30 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security.spec;
-public class RSAPrivateCrtKeySpec extends java.security.spec.RSAPrivateKeySpec {
- public RSAPrivateCrtKeySpec(java.math.BigInteger var0, java.math.BigInteger var1, java.math.BigInteger var2, java.math.BigInteger var3, java.math.BigInteger var4, java.math.BigInteger var5, java.math.BigInteger var6, java.math.BigInteger var7) { super((java.math.BigInteger) null, (java.math.BigInteger) null); }
- public java.math.BigInteger getPublicExponent() { return null; }
- public java.math.BigInteger getCrtCoefficient() { return null; }
- public java.math.BigInteger getPrimeP() { return null; }
- public java.math.BigInteger getPrimeQ() { return null; }
- public java.math.BigInteger getPrimeExponentP() { return null; }
- public java.math.BigInteger getPrimeExponentQ() { return null; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/spec/RSAPrivateKeySpec.java b/org.osgi.foundation/src/main/java/java/security/spec/RSAPrivateKeySpec.java
deleted file mode 100644
index 8d2e4f4..0000000
--- a/org.osgi.foundation/src/main/java/java/security/spec/RSAPrivateKeySpec.java
+++ /dev/null
@@ -1,26 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/spec/RSAPrivateKeySpec.java,v 1.6 2006/03/14 01:20:30 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security.spec;
-public class RSAPrivateKeySpec implements java.security.spec.KeySpec {
- public RSAPrivateKeySpec(java.math.BigInteger var0, java.math.BigInteger var1) { }
- public java.math.BigInteger getModulus() { return null; }
- public java.math.BigInteger getPrivateExponent() { return null; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/spec/RSAPublicKeySpec.java b/org.osgi.foundation/src/main/java/java/security/spec/RSAPublicKeySpec.java
deleted file mode 100644
index af689e9..0000000
--- a/org.osgi.foundation/src/main/java/java/security/spec/RSAPublicKeySpec.java
+++ /dev/null
@@ -1,26 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/spec/RSAPublicKeySpec.java,v 1.6 2006/03/14 01:20:30 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security.spec;
-public class RSAPublicKeySpec implements java.security.spec.KeySpec {
- public RSAPublicKeySpec(java.math.BigInteger var0, java.math.BigInteger var1) { }
- public java.math.BigInteger getModulus() { return null; }
- public java.math.BigInteger getPublicExponent() { return null; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/security/spec/X509EncodedKeySpec.java b/org.osgi.foundation/src/main/java/java/security/spec/X509EncodedKeySpec.java
deleted file mode 100644
index 7c327aa..0000000
--- a/org.osgi.foundation/src/main/java/java/security/spec/X509EncodedKeySpec.java
+++ /dev/null
@@ -1,26 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/security/spec/X509EncodedKeySpec.java,v 1.6 2006/03/14 01:20:30 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.security.spec;
-public class X509EncodedKeySpec extends java.security.spec.EncodedKeySpec {
- public X509EncodedKeySpec(byte[] var0) { super((byte[]) null); }
- public byte[] getEncoded() { return null; }
- public final java.lang.String getFormat() { return null; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/text/Annotation.java b/org.osgi.foundation/src/main/java/java/text/Annotation.java
deleted file mode 100644
index c747ee3..0000000
--- a/org.osgi.foundation/src/main/java/java/text/Annotation.java
+++ /dev/null
@@ -1,26 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/text/Annotation.java,v 1.6 2006/03/14 01:20:30 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.text;
-public class Annotation {
- public Annotation(java.lang.Object var0) { }
- public java.lang.Object getValue() { return null; }
- public java.lang.String toString() { return null; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/text/AttributedCharacterIterator.java b/org.osgi.foundation/src/main/java/java/text/AttributedCharacterIterator.java
deleted file mode 100644
index 6942250..0000000
--- a/org.osgi.foundation/src/main/java/java/text/AttributedCharacterIterator.java
+++ /dev/null
@@ -1,43 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/text/AttributedCharacterIterator.java,v 1.6 2006/03/14 01:20:30 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.text;
-public abstract interface AttributedCharacterIterator extends java.text.CharacterIterator {
- public abstract java.util.Set getAllAttributeKeys();
- public abstract java.lang.Object getAttribute(java.text.AttributedCharacterIterator.Attribute var0);
- public abstract java.util.Map getAttributes();
- public abstract int getRunLimit();
- public abstract int getRunLimit(java.text.AttributedCharacterIterator.Attribute var0);
- public abstract int getRunLimit(java.util.Set var0);
- public abstract int getRunStart();
- public abstract int getRunStart(java.text.AttributedCharacterIterator.Attribute var0);
- public abstract int getRunStart(java.util.Set var0);
- public static class Attribute implements java.io.Serializable {
- protected Attribute(java.lang.String var0) { }
- public final boolean equals(java.lang.Object var0) { return false; }
- protected java.lang.String getName() { return null; }
- public final int hashCode() { return 0; }
- protected java.lang.Object readResolve() throws java.io.InvalidObjectException { return null; }
- public java.lang.String toString() { return null; }
- public final static java.text.AttributedCharacterIterator.Attribute INPUT_METHOD_SEGMENT; static { INPUT_METHOD_SEGMENT = null; }
- public final static java.text.AttributedCharacterIterator.Attribute LANGUAGE; static { LANGUAGE = null; }
- public final static java.text.AttributedCharacterIterator.Attribute READING; static { READING = null; }
- }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/text/AttributedString.java b/org.osgi.foundation/src/main/java/java/text/AttributedString.java
deleted file mode 100644
index 7651623..0000000
--- a/org.osgi.foundation/src/main/java/java/text/AttributedString.java
+++ /dev/null
@@ -1,34 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/text/AttributedString.java,v 1.6 2006/03/14 01:20:30 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.text;
-public class AttributedString {
- public AttributedString(java.text.AttributedCharacterIterator var0) { }
- public AttributedString(java.text.AttributedCharacterIterator var0, int var1, int var2) { }
- public AttributedString(java.text.AttributedCharacterIterator var0, int var1, int var2, java.text.AttributedCharacterIterator.Attribute[] var3) { }
- public AttributedString(java.lang.String var0) { }
- public AttributedString(java.lang.String var0, java.util.Map var1) { }
- public void addAttribute(java.text.AttributedCharacterIterator.Attribute var0, java.lang.Object var1) { }
- public void addAttribute(java.text.AttributedCharacterIterator.Attribute var0, java.lang.Object var1, int var2, int var3) { }
- public void addAttributes(java.util.Map var0, int var1, int var2) { }
- public java.text.AttributedCharacterIterator getIterator() { return null; }
- public java.text.AttributedCharacterIterator getIterator(java.text.AttributedCharacterIterator.Attribute[] var0) { return null; }
- public java.text.AttributedCharacterIterator getIterator(java.text.AttributedCharacterIterator.Attribute[] var0, int var1, int var2) { return null; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/text/BreakIterator.java b/org.osgi.foundation/src/main/java/java/text/BreakIterator.java
deleted file mode 100644
index 8756f09..0000000
--- a/org.osgi.foundation/src/main/java/java/text/BreakIterator.java
+++ /dev/null
@@ -1,47 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/text/BreakIterator.java,v 1.6 2006/03/14 01:20:30 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.text;
-public abstract class BreakIterator implements java.lang.Cloneable {
- protected BreakIterator() { }
- public java.lang.Object clone() { return null; }
- public abstract int first();
- public abstract int last();
- public abstract int next(int var0);
- public abstract int next();
- public abstract int previous();
- public abstract int following(int var0);
- public int preceding(int var0) { return 0; }
- public boolean isBoundary(int var0) { return false; }
- public abstract int current();
- public abstract java.text.CharacterIterator getText();
- public void setText(java.lang.String var0) { }
- public abstract void setText(java.text.CharacterIterator var0);
- public static java.text.BreakIterator getWordInstance() { return null; }
- public static java.text.BreakIterator getWordInstance(java.util.Locale var0) { return null; }
- public static java.text.BreakIterator getLineInstance() { return null; }
- public static java.text.BreakIterator getLineInstance(java.util.Locale var0) { return null; }
- public static java.text.BreakIterator getCharacterInstance() { return null; }
- public static java.text.BreakIterator getCharacterInstance(java.util.Locale var0) { return null; }
- public static java.text.BreakIterator getSentenceInstance() { return null; }
- public static java.text.BreakIterator getSentenceInstance(java.util.Locale var0) { return null; }
- public static java.util.Locale[] getAvailableLocales() { return null; }
- public final static int DONE = -1;
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/text/CharacterIterator.java b/org.osgi.foundation/src/main/java/java/text/CharacterIterator.java
deleted file mode 100644
index 3173e6b..0000000
--- a/org.osgi.foundation/src/main/java/java/text/CharacterIterator.java
+++ /dev/null
@@ -1,34 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/text/CharacterIterator.java,v 1.6 2006/03/14 01:20:30 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.text;
-public abstract interface CharacterIterator extends java.lang.Cloneable {
- public abstract java.lang.Object clone();
- public abstract char current();
- public abstract char first();
- public abstract int getBeginIndex();
- public abstract int getEndIndex();
- public abstract int getIndex();
- public abstract char last();
- public abstract char next();
- public abstract char previous();
- public abstract char setIndex(int var0);
- public final static char DONE = 65535;
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/text/ChoiceFormat.java b/org.osgi.foundation/src/main/java/java/text/ChoiceFormat.java
deleted file mode 100644
index 8302b37..0000000
--- a/org.osgi.foundation/src/main/java/java/text/ChoiceFormat.java
+++ /dev/null
@@ -1,39 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/text/ChoiceFormat.java,v 1.6 2006/03/14 01:20:30 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.text;
-public class ChoiceFormat extends java.text.NumberFormat {
- public ChoiceFormat(double[] var0, java.lang.String[] var1) { }
- public ChoiceFormat(java.lang.String var0) { }
- public void applyPattern(java.lang.String var0) { }
- public java.lang.Object clone() { return null; }
- public boolean equals(java.lang.Object var0) { return false; }
- public java.lang.StringBuffer format(double var0, java.lang.StringBuffer var1, java.text.FieldPosition var2) { return null; }
- public java.lang.StringBuffer format(long var0, java.lang.StringBuffer var1, java.text.FieldPosition var2) { return null; }
- public java.lang.Object[] getFormats() { return null; }
- public double[] getLimits() { return null; }
- public int hashCode() { return 0; }
- public final static double nextDouble(double var0) { return 0.0d; }
- public static double nextDouble(double var0, boolean var1) { return 0.0d; }
- public java.lang.Number parse(java.lang.String var0, java.text.ParsePosition var1) { return null; }
- public final static double previousDouble(double var0) { return 0.0d; }
- public void setChoices(double[] var0, java.lang.String[] var1) { }
- public java.lang.String toPattern() { return null; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/text/CollationElementIterator.java b/org.osgi.foundation/src/main/java/java/text/CollationElementIterator.java
deleted file mode 100644
index 499ac37..0000000
--- a/org.osgi.foundation/src/main/java/java/text/CollationElementIterator.java
+++ /dev/null
@@ -1,36 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/text/CollationElementIterator.java,v 1.6 2006/03/14 01:20:30 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.text;
-public final class CollationElementIterator {
- public void reset() { }
- public int next() { return 0; }
- public int previous() { return 0; }
- public final static int primaryOrder(int var0) { return 0; }
- public final static short secondaryOrder(int var0) { return 0; }
- public final static short tertiaryOrder(int var0) { return 0; }
- public void setOffset(int var0) { }
- public int getOffset() { return 0; }
- public int getMaxExpansion(int var0) { return 0; }
- public void setText(java.lang.String var0) { }
- public void setText(java.text.CharacterIterator var0) { }
- public final static int NULLORDER = -1;
- private CollationElementIterator() { } /* generated constructor to prevent compiler adding default public constructor */
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/text/CollationKey.java b/org.osgi.foundation/src/main/java/java/text/CollationKey.java
deleted file mode 100644
index 6f13434..0000000
--- a/org.osgi.foundation/src/main/java/java/text/CollationKey.java
+++ /dev/null
@@ -1,30 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/text/CollationKey.java,v 1.6 2006/03/14 01:20:30 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.text;
-public final class CollationKey implements java.lang.Comparable {
- public int compareTo(java.text.CollationKey var0) { return 0; }
- public int compareTo(java.lang.Object var0) { return 0; }
- public boolean equals(java.lang.Object var0) { return false; }
- public java.lang.String getSourceString() { return null; }
- public int hashCode() { return 0; }
- public byte[] toByteArray() { return null; }
- private CollationKey() { } /* generated constructor to prevent compiler adding default public constructor */
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/text/Collator.java b/org.osgi.foundation/src/main/java/java/text/Collator.java
deleted file mode 100644
index 132482b..0000000
--- a/org.osgi.foundation/src/main/java/java/text/Collator.java
+++ /dev/null
@@ -1,45 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/text/Collator.java,v 1.6 2006/03/14 01:20:30 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.text;
-public abstract class Collator implements java.util.Comparator, java.lang.Cloneable {
- protected Collator() { }
- public java.lang.Object clone() { return null; }
- public int compare(java.lang.Object var0, java.lang.Object var1) { return 0; }
- public abstract int compare(java.lang.String var0, java.lang.String var1);
- public boolean equals(java.lang.Object var0) { return false; }
- public boolean equals(java.lang.String var0, java.lang.String var1) { return false; }
- public static java.util.Locale[] getAvailableLocales() { return null; }
- public abstract java.text.CollationKey getCollationKey(java.lang.String var0);
- public int getDecomposition() { return 0; }
- public static java.text.Collator getInstance() { return null; }
- public static java.text.Collator getInstance(java.util.Locale var0) { return null; }
- public int getStrength() { return 0; }
- public abstract int hashCode();
- public void setDecomposition(int var0) { }
- public void setStrength(int var0) { }
- public final static int NO_DECOMPOSITION = 0;
- public final static int CANONICAL_DECOMPOSITION = 1;
- public final static int FULL_DECOMPOSITION = 2;
- public final static int PRIMARY = 0;
- public final static int SECONDARY = 1;
- public final static int TERTIARY = 2;
- public final static int IDENTICAL = 3;
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/text/DateFormat.java b/org.osgi.foundation/src/main/java/java/text/DateFormat.java
deleted file mode 100644
index 660edbd..0000000
--- a/org.osgi.foundation/src/main/java/java/text/DateFormat.java
+++ /dev/null
@@ -1,77 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/text/DateFormat.java,v 1.6 2006/03/14 01:20:30 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.text;
-public abstract class DateFormat extends java.text.Format {
- protected DateFormat() { }
- public java.lang.Object clone() { return null; }
- public boolean equals(java.lang.Object var0) { return false; }
- public final java.lang.StringBuffer format(java.lang.Object var0, java.lang.StringBuffer var1, java.text.FieldPosition var2) { return null; }
- public final java.lang.String format(java.util.Date var0) { return null; }
- public abstract java.lang.StringBuffer format(java.util.Date var0, java.lang.StringBuffer var1, java.text.FieldPosition var2);
- public static java.util.Locale[] getAvailableLocales() { return null; }
- public java.util.Calendar getCalendar() { return null; }
- public final static java.text.DateFormat getDateInstance() { return null; }
- public final static java.text.DateFormat getDateInstance(int var0) { return null; }
- public final static java.text.DateFormat getDateInstance(int var0, java.util.Locale var1) { return null; }
- public final static java.text.DateFormat getDateTimeInstance() { return null; }
- public final static java.text.DateFormat getDateTimeInstance(int var0, int var1) { return null; }
- public final static java.text.DateFormat getDateTimeInstance(int var0, int var1, java.util.Locale var2) { return null; }
- public final static java.text.DateFormat getInstance() { return null; }
- public java.text.NumberFormat getNumberFormat() { return null; }
- public final static java.text.DateFormat getTimeInstance() { return null; }
- public final static java.text.DateFormat getTimeInstance(int var0) { return null; }
- public final static java.text.DateFormat getTimeInstance(int var0, java.util.Locale var1) { return null; }
- public java.util.TimeZone getTimeZone() { return null; }
- public int hashCode() { return 0; }
- public boolean isLenient() { return false; }
- public java.util.Date parse(java.lang.String var0) throws java.text.ParseException { return null; }
- public abstract java.util.Date parse(java.lang.String var0, java.text.ParsePosition var1);
- public java.lang.Object parseObject(java.lang.String var0, java.text.ParsePosition var1) { return null; }
- public void setCalendar(java.util.Calendar var0) { }
- public void setLenient(boolean var0) { }
- public void setNumberFormat(java.text.NumberFormat var0) { }
- public void setTimeZone(java.util.TimeZone var0) { }
- protected java.util.Calendar calendar;
- protected java.text.NumberFormat numberFormat;
- public final static int DEFAULT = 2;
- public final static int FULL = 0;
- public final static int LONG = 1;
- public final static int MEDIUM = 2;
- public final static int SHORT = 3;
- public final static int ERA_FIELD = 0;
- public final static int YEAR_FIELD = 1;
- public final static int MONTH_FIELD = 2;
- public final static int DATE_FIELD = 3;
- public final static int HOUR_OF_DAY1_FIELD = 4;
- public final static int HOUR_OF_DAY0_FIELD = 5;
- public final static int MINUTE_FIELD = 6;
- public final static int SECOND_FIELD = 7;
- public final static int MILLISECOND_FIELD = 8;
- public final static int DAY_OF_WEEK_FIELD = 9;
- public final static int DAY_OF_YEAR_FIELD = 10;
- public final static int DAY_OF_WEEK_IN_MONTH_FIELD = 11;
- public final static int WEEK_OF_YEAR_FIELD = 12;
- public final static int WEEK_OF_MONTH_FIELD = 13;
- public final static int AM_PM_FIELD = 14;
- public final static int HOUR1_FIELD = 15;
- public final static int HOUR0_FIELD = 16;
- public final static int TIMEZONE_FIELD = 17;
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/text/DateFormatSymbols.java b/org.osgi.foundation/src/main/java/java/text/DateFormatSymbols.java
deleted file mode 100644
index ba3fbc2..0000000
--- a/org.osgi.foundation/src/main/java/java/text/DateFormatSymbols.java
+++ /dev/null
@@ -1,44 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/text/DateFormatSymbols.java,v 1.6 2006/03/14 01:20:30 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.text;
-public class DateFormatSymbols implements java.io.Serializable, java.lang.Cloneable {
- public DateFormatSymbols() { }
- public DateFormatSymbols(java.util.Locale var0) { }
- public java.lang.Object clone() { return null; }
- public boolean equals(java.lang.Object var0) { return false; }
- public java.lang.String[] getAmPmStrings() { return null; }
- public java.lang.String[] getEras() { return null; }
- public java.lang.String getLocalPatternChars() { return null; }
- public java.lang.String[] getMonths() { return null; }
- public java.lang.String[] getShortMonths() { return null; }
- public java.lang.String[] getShortWeekdays() { return null; }
- public java.lang.String[] getWeekdays() { return null; }
- public java.lang.String[][] getZoneStrings() { return null; }
- public int hashCode() { return 0; }
- public void setAmPmStrings(java.lang.String[] var0) { }
- public void setEras(java.lang.String[] var0) { }
- public void setLocalPatternChars(java.lang.String var0) { }
- public void setMonths(java.lang.String[] var0) { }
- public void setShortMonths(java.lang.String[] var0) { }
- public void setShortWeekdays(java.lang.String[] var0) { }
- public void setWeekdays(java.lang.String[] var0) { }
- public void setZoneStrings(java.lang.String[][] var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/text/DecimalFormat.java b/org.osgi.foundation/src/main/java/java/text/DecimalFormat.java
deleted file mode 100644
index 2488596..0000000
--- a/org.osgi.foundation/src/main/java/java/text/DecimalFormat.java
+++ /dev/null
@@ -1,56 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/text/DecimalFormat.java,v 1.6 2006/03/14 01:20:30 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.text;
-public class DecimalFormat extends java.text.NumberFormat {
- public DecimalFormat() { }
- public DecimalFormat(java.lang.String var0) { }
- public DecimalFormat(java.lang.String var0, java.text.DecimalFormatSymbols var1) { }
- public void applyLocalizedPattern(java.lang.String var0) { }
- public void applyPattern(java.lang.String var0) { }
- public java.lang.Object clone() { return null; }
- public boolean equals(java.lang.Object var0) { return false; }
- public java.lang.StringBuffer format(double var0, java.lang.StringBuffer var1, java.text.FieldPosition var2) { return null; }
- public java.lang.StringBuffer format(long var0, java.lang.StringBuffer var1, java.text.FieldPosition var2) { return null; }
- public java.text.DecimalFormatSymbols getDecimalFormatSymbols() { return null; }
- public int getGroupingSize() { return 0; }
- public int getMultiplier() { return 0; }
- public java.lang.String getNegativePrefix() { return null; }
- public java.lang.String getNegativeSuffix() { return null; }
- public java.lang.String getPositivePrefix() { return null; }
- public java.lang.String getPositiveSuffix() { return null; }
- public int hashCode() { return 0; }
- public boolean isDecimalSeparatorAlwaysShown() { return false; }
- public java.lang.Number parse(java.lang.String var0, java.text.ParsePosition var1) { return null; }
- public void setDecimalFormatSymbols(java.text.DecimalFormatSymbols var0) { }
- public void setDecimalSeparatorAlwaysShown(boolean var0) { }
- public void setGroupingSize(int var0) { }
- public void setMaximumFractionDigits(int var0) { }
- public void setMaximumIntegerDigits(int var0) { }
- public void setMinimumFractionDigits(int var0) { }
- public void setMinimumIntegerDigits(int var0) { }
- public void setMultiplier(int var0) { }
- public void setNegativePrefix(java.lang.String var0) { }
- public void setNegativeSuffix(java.lang.String var0) { }
- public void setPositivePrefix(java.lang.String var0) { }
- public void setPositiveSuffix(java.lang.String var0) { }
- public java.lang.String toLocalizedPattern() { return null; }
- public java.lang.String toPattern() { return null; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/text/DecimalFormatSymbols.java b/org.osgi.foundation/src/main/java/java/text/DecimalFormatSymbols.java
deleted file mode 100644
index 88d9762..0000000
--- a/org.osgi.foundation/src/main/java/java/text/DecimalFormatSymbols.java
+++ /dev/null
@@ -1,54 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/text/DecimalFormatSymbols.java,v 1.6 2006/03/14 01:20:30 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.text;
-public final class DecimalFormatSymbols implements java.lang.Cloneable, java.io.Serializable {
- public DecimalFormatSymbols() { }
- public DecimalFormatSymbols(java.util.Locale var0) { }
- public java.lang.Object clone() { return null; }
- public boolean equals(java.lang.Object var0) { return false; }
- public java.lang.String getCurrencySymbol() { return null; }
- public char getDecimalSeparator() { return 0; }
- public char getDigit() { return 0; }
- public char getGroupingSeparator() { return 0; }
- public java.lang.String getInfinity() { return null; }
- public java.lang.String getInternationalCurrencySymbol() { return null; }
- public char getMinusSign() { return 0; }
- public char getMonetaryDecimalSeparator() { return 0; }
- public java.lang.String getNaN() { return null; }
- public char getPatternSeparator() { return 0; }
- public char getPercent() { return 0; }
- public char getPerMill() { return 0; }
- public char getZeroDigit() { return 0; }
- public int hashCode() { return 0; }
- public void setCurrencySymbol(java.lang.String var0) { }
- public void setDecimalSeparator(char var0) { }
- public void setDigit(char var0) { }
- public void setGroupingSeparator(char var0) { }
- public void setInfinity(java.lang.String var0) { }
- public void setInternationalCurrencySymbol(java.lang.String var0) { }
- public void setMinusSign(char var0) { }
- public void setMonetaryDecimalSeparator(char var0) { }
- public void setNaN(java.lang.String var0) { }
- public void setPatternSeparator(char var0) { }
- public void setPercent(char var0) { }
- public void setPerMill(char var0) { }
- public void setZeroDigit(char var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/text/FieldPosition.java b/org.osgi.foundation/src/main/java/java/text/FieldPosition.java
deleted file mode 100644
index 29a3f9b..0000000
--- a/org.osgi.foundation/src/main/java/java/text/FieldPosition.java
+++ /dev/null
@@ -1,32 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/text/FieldPosition.java,v 1.6 2006/03/14 01:20:30 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.text;
-public class FieldPosition {
- public FieldPosition(int var0) { }
- public boolean equals(java.lang.Object var0) { return false; }
- public int getBeginIndex() { return 0; }
- public int getEndIndex() { return 0; }
- public int getField() { return 0; }
- public int hashCode() { return 0; }
- public void setBeginIndex(int var0) { }
- public void setEndIndex(int var0) { }
- public java.lang.String toString() { return null; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/text/Format.java b/org.osgi.foundation/src/main/java/java/text/Format.java
deleted file mode 100644
index 176d8a9..0000000
--- a/org.osgi.foundation/src/main/java/java/text/Format.java
+++ /dev/null
@@ -1,29 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/text/Format.java,v 1.6 2006/03/14 01:20:30 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.text;
-public abstract class Format implements java.io.Serializable, java.lang.Cloneable {
- public Format() { }
- public java.lang.Object clone() { return null; }
- public final java.lang.String format(java.lang.Object var0) { return null; }
- public abstract java.lang.StringBuffer format(java.lang.Object var0, java.lang.StringBuffer var1, java.text.FieldPosition var2);
- public java.lang.Object parseObject(java.lang.String var0) throws java.text.ParseException { return null; }
- public abstract java.lang.Object parseObject(java.lang.String var0, java.text.ParsePosition var1);
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/text/MessageFormat.java b/org.osgi.foundation/src/main/java/java/text/MessageFormat.java
deleted file mode 100644
index 8de8621..0000000
--- a/org.osgi.foundation/src/main/java/java/text/MessageFormat.java
+++ /dev/null
@@ -1,40 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/text/MessageFormat.java,v 1.6 2006/03/14 01:20:30 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.text;
-public class MessageFormat extends java.text.Format {
- public MessageFormat(java.lang.String var0) { }
- public void applyPattern(java.lang.String var0) { }
- public java.lang.Object clone() { return null; }
- public boolean equals(java.lang.Object var0) { return false; }
- public final java.lang.StringBuffer format(java.lang.Object[] var0, java.lang.StringBuffer var1, java.text.FieldPosition var2) { return null; }
- public final java.lang.StringBuffer format(java.lang.Object var0, java.lang.StringBuffer var1, java.text.FieldPosition var2) { return null; }
- public static java.lang.String format(java.lang.String var0, java.lang.Object[] var1) { return null; }
- public java.text.Format[] getFormats() { return null; }
- public java.util.Locale getLocale() { return null; }
- public int hashCode() { return 0; }
- public java.lang.Object[] parse(java.lang.String var0) throws java.text.ParseException { return null; }
- public java.lang.Object[] parse(java.lang.String var0, java.text.ParsePosition var1) { return null; }
- public java.lang.Object parseObject(java.lang.String var0, java.text.ParsePosition var1) { return null; }
- public void setFormat(int var0, java.text.Format var1) { }
- public void setFormats(java.text.Format[] var0) { }
- public void setLocale(java.util.Locale var0) { }
- public java.lang.String toPattern() { return null; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/text/NumberFormat.java b/org.osgi.foundation/src/main/java/java/text/NumberFormat.java
deleted file mode 100644
index 7df89be..0000000
--- a/org.osgi.foundation/src/main/java/java/text/NumberFormat.java
+++ /dev/null
@@ -1,58 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/text/NumberFormat.java,v 1.6 2006/03/14 01:20:30 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.text;
-public abstract class NumberFormat extends java.text.Format {
- public NumberFormat() { }
- public java.lang.Object clone() { return null; }
- public boolean equals(java.lang.Object var0) { return false; }
- public final java.lang.String format(double var0) { return null; }
- public abstract java.lang.StringBuffer format(double var0, java.lang.StringBuffer var1, java.text.FieldPosition var2);
- public final java.lang.String format(long var0) { return null; }
- public abstract java.lang.StringBuffer format(long var0, java.lang.StringBuffer var1, java.text.FieldPosition var2);
- public final java.lang.StringBuffer format(java.lang.Object var0, java.lang.StringBuffer var1, java.text.FieldPosition var2) { return null; }
- public static java.util.Locale[] getAvailableLocales() { return null; }
- public final static java.text.NumberFormat getCurrencyInstance() { return null; }
- public static java.text.NumberFormat getCurrencyInstance(java.util.Locale var0) { return null; }
- public final static java.text.NumberFormat getInstance() { return null; }
- public static java.text.NumberFormat getInstance(java.util.Locale var0) { return null; }
- public int getMaximumFractionDigits() { return 0; }
- public int getMaximumIntegerDigits() { return 0; }
- public int getMinimumFractionDigits() { return 0; }
- public int getMinimumIntegerDigits() { return 0; }
- public final static java.text.NumberFormat getNumberInstance() { return null; }
- public static java.text.NumberFormat getNumberInstance(java.util.Locale var0) { return null; }
- public final static java.text.NumberFormat getPercentInstance() { return null; }
- public static java.text.NumberFormat getPercentInstance(java.util.Locale var0) { return null; }
- public int hashCode() { return 0; }
- public boolean isGroupingUsed() { return false; }
- public boolean isParseIntegerOnly() { return false; }
- public java.lang.Number parse(java.lang.String var0) throws java.text.ParseException { return null; }
- public abstract java.lang.Number parse(java.lang.String var0, java.text.ParsePosition var1);
- public final java.lang.Object parseObject(java.lang.String var0, java.text.ParsePosition var1) { return null; }
- public void setGroupingUsed(boolean var0) { }
- public void setMaximumFractionDigits(int var0) { }
- public void setMaximumIntegerDigits(int var0) { }
- public void setMinimumFractionDigits(int var0) { }
- public void setMinimumIntegerDigits(int var0) { }
- public void setParseIntegerOnly(boolean var0) { }
- public final static int INTEGER_FIELD = 0;
- public final static int FRACTION_FIELD = 1;
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/text/ParseException.java b/org.osgi.foundation/src/main/java/java/text/ParseException.java
deleted file mode 100644
index 968a838..0000000
--- a/org.osgi.foundation/src/main/java/java/text/ParseException.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/text/ParseException.java,v 1.6 2006/03/14 01:20:30 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.text;
-public class ParseException extends java.lang.Exception {
- public ParseException(java.lang.String var0, int var1) { }
- public int getErrorOffset() { return 0; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/text/ParsePosition.java b/org.osgi.foundation/src/main/java/java/text/ParsePosition.java
deleted file mode 100644
index 349c6cc..0000000
--- a/org.osgi.foundation/src/main/java/java/text/ParsePosition.java
+++ /dev/null
@@ -1,31 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/text/ParsePosition.java,v 1.6 2006/03/14 01:20:30 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.text;
-public class ParsePosition {
- public ParsePosition(int var0) { }
- public boolean equals(java.lang.Object var0) { return false; }
- public int getErrorIndex() { return 0; }
- public int getIndex() { return 0; }
- public int hashCode() { return 0; }
- public void setErrorIndex(int var0) { }
- public void setIndex(int var0) { }
- public java.lang.String toString() { return null; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/text/RuleBasedCollator.java b/org.osgi.foundation/src/main/java/java/text/RuleBasedCollator.java
deleted file mode 100644
index 649f1b0..0000000
--- a/org.osgi.foundation/src/main/java/java/text/RuleBasedCollator.java
+++ /dev/null
@@ -1,32 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/text/RuleBasedCollator.java,v 1.6 2006/03/14 01:20:30 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.text;
-public class RuleBasedCollator extends java.text.Collator {
- public RuleBasedCollator(java.lang.String var0) throws java.text.ParseException { }
- public java.lang.String getRules() { return null; }
- public java.text.CollationElementIterator getCollationElementIterator(java.lang.String var0) { return null; }
- public java.text.CollationElementIterator getCollationElementIterator(java.text.CharacterIterator var0) { return null; }
- public int compare(java.lang.String var0, java.lang.String var1) { return 0; }
- public java.text.CollationKey getCollationKey(java.lang.String var0) { return null; }
- public java.lang.Object clone() { return null; }
- public boolean equals(java.lang.Object var0) { return false; }
- public int hashCode() { return 0; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/text/SimpleDateFormat.java b/org.osgi.foundation/src/main/java/java/text/SimpleDateFormat.java
deleted file mode 100644
index 14419ab..0000000
--- a/org.osgi.foundation/src/main/java/java/text/SimpleDateFormat.java
+++ /dev/null
@@ -1,40 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/text/SimpleDateFormat.java,v 1.6 2006/03/14 01:20:30 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.text;
-public class SimpleDateFormat extends java.text.DateFormat {
- public SimpleDateFormat() { }
- public SimpleDateFormat(java.lang.String var0) { }
- public SimpleDateFormat(java.lang.String var0, java.text.DateFormatSymbols var1) { }
- public SimpleDateFormat(java.lang.String var0, java.util.Locale var1) { }
- public void applyLocalizedPattern(java.lang.String var0) { }
- public void applyPattern(java.lang.String var0) { }
- public java.lang.Object clone() { return null; }
- public boolean equals(java.lang.Object var0) { return false; }
- public java.lang.StringBuffer format(java.util.Date var0, java.lang.StringBuffer var1, java.text.FieldPosition var2) { return null; }
- public java.util.Date get2DigitYearStart() { return null; }
- public java.text.DateFormatSymbols getDateFormatSymbols() { return null; }
- public int hashCode() { return 0; }
- public java.util.Date parse(java.lang.String var0, java.text.ParsePosition var1) { return null; }
- public void set2DigitYearStart(java.util.Date var0) { }
- public void setDateFormatSymbols(java.text.DateFormatSymbols var0) { }
- public java.lang.String toLocalizedPattern() { return null; }
- public java.lang.String toPattern() { return null; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/text/StringCharacterIterator.java b/org.osgi.foundation/src/main/java/java/text/StringCharacterIterator.java
deleted file mode 100644
index 4d36734..0000000
--- a/org.osgi.foundation/src/main/java/java/text/StringCharacterIterator.java
+++ /dev/null
@@ -1,39 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/text/StringCharacterIterator.java,v 1.6 2006/03/14 01:20:30 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.text;
-public final class StringCharacterIterator implements java.text.CharacterIterator {
- public StringCharacterIterator(java.lang.String var0) { }
- public StringCharacterIterator(java.lang.String var0, int var1) { }
- public StringCharacterIterator(java.lang.String var0, int var1, int var2, int var3) { }
- public java.lang.Object clone() { return null; }
- public char current() { return 0; }
- public boolean equals(java.lang.Object var0) { return false; }
- public char first() { return 0; }
- public int getBeginIndex() { return 0; }
- public int getEndIndex() { return 0; }
- public int getIndex() { return 0; }
- public int hashCode() { return 0; }
- public char last() { return 0; }
- public char next() { return 0; }
- public char previous() { return 0; }
- public char setIndex(int var0) { return 0; }
- public void setText(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/text/resources/BreakIteratorRules.java b/org.osgi.foundation/src/main/java/java/text/resources/BreakIteratorRules.java
deleted file mode 100644
index fa7d495..0000000
--- a/org.osgi.foundation/src/main/java/java/text/resources/BreakIteratorRules.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/text/resources/BreakIteratorRules.java,v 1.6 2006/03/14 01:20:30 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.text.resources;
-public class BreakIteratorRules extends java.util.ListResourceBundle {
- public BreakIteratorRules() { }
- public java.lang.Object[][] getContents() { return null; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/text/resources/BreakIteratorRules_th.java b/org.osgi.foundation/src/main/java/java/text/resources/BreakIteratorRules_th.java
deleted file mode 100644
index affcc5e..0000000
--- a/org.osgi.foundation/src/main/java/java/text/resources/BreakIteratorRules_th.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/text/resources/BreakIteratorRules_th.java,v 1.6 2006/03/14 01:20:30 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.text.resources;
-public class BreakIteratorRules_th extends java.util.ListResourceBundle {
- public BreakIteratorRules_th() { }
- public java.lang.Object[][] getContents() { return null; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/util/AbstractCollection.java b/org.osgi.foundation/src/main/java/java/util/AbstractCollection.java
deleted file mode 100644
index 6febd18..0000000
--- a/org.osgi.foundation/src/main/java/java/util/AbstractCollection.java
+++ /dev/null
@@ -1,38 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/util/AbstractCollection.java,v 1.6 2006/03/14 01:20:25 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.util;
-public abstract class AbstractCollection implements java.util.Collection {
- protected AbstractCollection() { }
- public boolean add(java.lang.Object var0) { return false; }
- public boolean addAll(java.util.Collection var0) { return false; }
- public void clear() { }
- public boolean contains(java.lang.Object var0) { return false; }
- public boolean containsAll(java.util.Collection var0) { return false; }
- public boolean isEmpty() { return false; }
- public abstract java.util.Iterator iterator();
- public boolean remove(java.lang.Object var0) { return false; }
- public boolean removeAll(java.util.Collection var0) { return false; }
- public boolean retainAll(java.util.Collection var0) { return false; }
- public abstract int size();
- public java.lang.Object[] toArray() { return null; }
- public java.lang.Object[] toArray(java.lang.Object[] var0) { return null; }
- public java.lang.String toString() { return null; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/util/AbstractList.java b/org.osgi.foundation/src/main/java/java/util/AbstractList.java
deleted file mode 100644
index 2727ab1..0000000
--- a/org.osgi.foundation/src/main/java/java/util/AbstractList.java
+++ /dev/null
@@ -1,41 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/util/AbstractList.java,v 1.6 2006/03/14 01:20:25 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.util;
-public abstract class AbstractList extends java.util.AbstractCollection implements java.util.List {
- protected AbstractList() { }
- public void add(int var0, java.lang.Object var1) { }
- public boolean add(java.lang.Object var0) { return false; }
- public boolean addAll(int var0, java.util.Collection var1) { return false; }
- public void clear() { }
- public boolean equals(java.lang.Object var0) { return false; }
- public abstract java.lang.Object get(int var0);
- public int hashCode() { return 0; }
- public int indexOf(java.lang.Object var0) { return 0; }
- public java.util.Iterator iterator() { return null; }
- public int lastIndexOf(java.lang.Object var0) { return 0; }
- public java.util.ListIterator listIterator() { return null; }
- public java.util.ListIterator listIterator(int var0) { return null; }
- public java.lang.Object remove(int var0) { return null; }
- protected void removeRange(int var0, int var1) { }
- public java.lang.Object set(int var0, java.lang.Object var1) { return null; }
- public java.util.List subList(int var0, int var1) { return null; }
- protected int modCount;
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/util/AbstractMap.java b/org.osgi.foundation/src/main/java/java/util/AbstractMap.java
deleted file mode 100644
index 29ec433..0000000
--- a/org.osgi.foundation/src/main/java/java/util/AbstractMap.java
+++ /dev/null
@@ -1,39 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/util/AbstractMap.java,v 1.6 2006/03/14 01:20:26 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.util;
-public abstract class AbstractMap implements java.util.Map {
- protected AbstractMap() { }
- public void clear() { }
- public boolean containsKey(java.lang.Object var0) { return false; }
- public boolean containsValue(java.lang.Object var0) { return false; }
- public abstract java.util.Set entrySet();
- public boolean equals(java.lang.Object var0) { return false; }
- public java.lang.Object get(java.lang.Object var0) { return null; }
- public int hashCode() { return 0; }
- public boolean isEmpty() { return false; }
- public java.util.Set keySet() { return null; }
- public java.lang.Object put(java.lang.Object var0, java.lang.Object var1) { return null; }
- public void putAll(java.util.Map var0) { }
- public java.lang.Object remove(java.lang.Object var0) { return null; }
- public int size() { return 0; }
- public java.lang.String toString() { return null; }
- public java.util.Collection values() { return null; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/util/AbstractSequentialList.java b/org.osgi.foundation/src/main/java/java/util/AbstractSequentialList.java
deleted file mode 100644
index a437dc8..0000000
--- a/org.osgi.foundation/src/main/java/java/util/AbstractSequentialList.java
+++ /dev/null
@@ -1,31 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/util/AbstractSequentialList.java,v 1.6 2006/03/14 01:20:26 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.util;
-public abstract class AbstractSequentialList extends java.util.AbstractList {
- protected AbstractSequentialList() { }
- public void add(int var0, java.lang.Object var1) { }
- public boolean addAll(int var0, java.util.Collection var1) { return false; }
- public java.lang.Object get(int var0) { return null; }
- public java.util.Iterator iterator() { return null; }
- public abstract java.util.ListIterator listIterator(int var0);
- public java.lang.Object remove(int var0) { return null; }
- public java.lang.Object set(int var0, java.lang.Object var1) { return null; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/util/AbstractSet.java b/org.osgi.foundation/src/main/java/java/util/AbstractSet.java
deleted file mode 100644
index 8448786..0000000
--- a/org.osgi.foundation/src/main/java/java/util/AbstractSet.java
+++ /dev/null
@@ -1,27 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/util/AbstractSet.java,v 1.6 2006/03/14 01:20:26 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.util;
-public abstract class AbstractSet extends java.util.AbstractCollection implements java.util.Set {
- protected AbstractSet() { }
- public boolean equals(java.lang.Object var0) { return false; }
- public int hashCode() { return 0; }
- public boolean removeAll(java.util.Collection var0) { return false; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/util/ArrayList.java b/org.osgi.foundation/src/main/java/java/util/ArrayList.java
deleted file mode 100644
index 2af8e50..0000000
--- a/org.osgi.foundation/src/main/java/java/util/ArrayList.java
+++ /dev/null
@@ -1,45 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/util/ArrayList.java,v 1.6 2006/03/14 01:20:26 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.util;
-public class ArrayList extends java.util.AbstractList implements java.util.List, java.lang.Cloneable, java.io.Serializable {
- public ArrayList() { }
- public ArrayList(int var0) { }
- public ArrayList(java.util.Collection var0) { }
- public void add(int var0, java.lang.Object var1) { }
- public boolean add(java.lang.Object var0) { return false; }
- public boolean addAll(int var0, java.util.Collection var1) { return false; }
- public boolean addAll(java.util.Collection var0) { return false; }
- public void clear() { }
- public java.lang.Object clone() { return null; }
- public boolean contains(java.lang.Object var0) { return false; }
- public void ensureCapacity(int var0) { }
- public java.lang.Object get(int var0) { return null; }
- public int indexOf(java.lang.Object var0) { return 0; }
- public boolean isEmpty() { return false; }
- public int lastIndexOf(java.lang.Object var0) { return 0; }
- public java.lang.Object remove(int var0) { return null; }
- protected void removeRange(int var0, int var1) { }
- public java.lang.Object set(int var0, java.lang.Object var1) { return null; }
- public int size() { return 0; }
- public java.lang.Object[] toArray() { return null; }
- public java.lang.Object[] toArray(java.lang.Object[] var0) { return null; }
- public void trimToSize() { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/util/Arrays.java b/org.osgi.foundation/src/main/java/java/util/Arrays.java
deleted file mode 100644
index 9d5c4ff..0000000
--- a/org.osgi.foundation/src/main/java/java/util/Arrays.java
+++ /dev/null
@@ -1,79 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/util/Arrays.java,v 1.6 2006/03/14 01:20:25 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.util;
-public class Arrays {
- public static java.util.List asList(java.lang.Object[] var0) { return null; }
- public static int binarySearch(byte[] var0, byte var1) { return 0; }
- public static int binarySearch(char[] var0, char var1) { return 0; }
- public static int binarySearch(double[] var0, double var1) { return 0; }
- public static int binarySearch(float[] var0, float var1) { return 0; }
- public static int binarySearch(int[] var0, int var1) { return 0; }
- public static int binarySearch(long[] var0, long var1) { return 0; }
- public static int binarySearch(java.lang.Object[] var0, java.lang.Object var1) { return 0; }
- public static int binarySearch(java.lang.Object[] var0, java.lang.Object var1, java.util.Comparator var2) { return 0; }
- public static int binarySearch(short[] var0, short var1) { return 0; }
- public static void fill(byte[] var0, byte var1) { }
- public static void fill(byte[] var0, int var1, int var2, byte var3) { }
- public static void fill(short[] var0, short var1) { }
- public static void fill(short[] var0, int var1, int var2, short var3) { }
- public static void fill(char[] var0, char var1) { }
- public static void fill(char[] var0, int var1, int var2, char var3) { }
- public static void fill(int[] var0, int var1) { }
- public static void fill(int[] var0, int var1, int var2, int var3) { }
- public static void fill(long[] var0, long var1) { }
- public static void fill(long[] var0, int var1, int var2, long var3) { }
- public static void fill(float[] var0, float var1) { }
- public static void fill(float[] var0, int var1, int var2, float var3) { }
- public static void fill(double[] var0, double var1) { }
- public static void fill(double[] var0, int var1, int var2, double var3) { }
- public static void fill(boolean[] var0, boolean var1) { }
- public static void fill(boolean[] var0, int var1, int var2, boolean var3) { }
- public static void fill(java.lang.Object[] var0, java.lang.Object var1) { }
- public static void fill(java.lang.Object[] var0, int var1, int var2, java.lang.Object var3) { }
- public static boolean equals(byte[] var0, byte[] var1) { return false; }
- public static boolean equals(short[] var0, short[] var1) { return false; }
- public static boolean equals(char[] var0, char[] var1) { return false; }
- public static boolean equals(int[] var0, int[] var1) { return false; }
- public static boolean equals(long[] var0, long[] var1) { return false; }
- public static boolean equals(float[] var0, float[] var1) { return false; }
- public static boolean equals(double[] var0, double[] var1) { return false; }
- public static boolean equals(boolean[] var0, boolean[] var1) { return false; }
- public static boolean equals(java.lang.Object[] var0, java.lang.Object[] var1) { return false; }
- public static void sort(byte[] var0) { }
- public static void sort(byte[] var0, int var1, int var2) { }
- public static void sort(char[] var0) { }
- public static void sort(char[] var0, int var1, int var2) { }
- public static void sort(double[] var0) { }
- public static void sort(double[] var0, int var1, int var2) { }
- public static void sort(float[] var0) { }
- public static void sort(float[] var0, int var1, int var2) { }
- public static void sort(int[] var0) { }
- public static void sort(int[] var0, int var1, int var2) { }
- public static void sort(long[] var0) { }
- public static void sort(long[] var0, int var1, int var2) { }
- public static void sort(java.lang.Object[] var0) { }
- public static void sort(java.lang.Object[] var0, int var1, int var2) { }
- public static void sort(java.lang.Object[] var0, int var1, int var2, java.util.Comparator var3) { }
- public static void sort(java.lang.Object[] var0, java.util.Comparator var1) { }
- public static void sort(short[] var0) { }
- public static void sort(short[] var0, int var1, int var2) { }
- private Arrays() { } /* generated constructor to prevent compiler adding default public constructor */
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/util/BitSet.java b/org.osgi.foundation/src/main/java/java/util/BitSet.java
deleted file mode 100644
index 44e4c67..0000000
--- a/org.osgi.foundation/src/main/java/java/util/BitSet.java
+++ /dev/null
@@ -1,38 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/util/BitSet.java,v 1.6 2006/03/14 01:20:25 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.util;
-public class BitSet implements java.io.Serializable, java.lang.Cloneable {
- public BitSet() { }
- public BitSet(int var0) { }
- public void and(java.util.BitSet var0) { }
- public void clear(int var0) { }
- public java.lang.Object clone() { return null; }
- public boolean equals(java.lang.Object var0) { return false; }
- public boolean get(int var0) { return false; }
- public int hashCode() { return 0; }
- public void or(java.util.BitSet var0) { }
- public void set(int var0) { }
- public int size() { return 0; }
- public java.lang.String toString() { return null; }
- public void xor(java.util.BitSet var0) { }
- public int length() { return 0; }
- public void andNot(java.util.BitSet var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/util/Calendar.java b/org.osgi.foundation/src/main/java/java/util/Calendar.java
deleted file mode 100644
index 9912b33..0000000
--- a/org.osgi.foundation/src/main/java/java/util/Calendar.java
+++ /dev/null
@@ -1,115 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/util/Calendar.java,v 1.6 2006/03/14 01:20:26 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.util;
-public abstract class Calendar implements java.io.Serializable, java.lang.Cloneable {
- protected Calendar() { }
- protected Calendar(java.util.TimeZone var0, java.util.Locale var1) { }
- public abstract void add(int var0, int var1);
- public boolean after(java.lang.Object var0) { return false; }
- public boolean before(java.lang.Object var0) { return false; }
- public final void clear() { }
- public final void clear(int var0) { }
- public java.lang.Object clone() { return null; }
- protected void complete() { }
- protected abstract void computeFields();
- protected abstract void computeTime();
- public boolean equals(java.lang.Object var0) { return false; }
- public final int get(int var0) { return 0; }
- public int getActualMaximum(int var0) { return 0; }
- public int getActualMinimum(int var0) { return 0; }
- public static java.util.Locale[] getAvailableLocales() { return null; }
- public int getFirstDayOfWeek() { return 0; }
- public abstract int getGreatestMinimum(int var0);
- public static java.util.Calendar getInstance() { return null; }
- public static java.util.Calendar getInstance(java.util.Locale var0) { return null; }
- public static java.util.Calendar getInstance(java.util.TimeZone var0) { return null; }
- public static java.util.Calendar getInstance(java.util.TimeZone var0, java.util.Locale var1) { return null; }
- public abstract int getLeastMaximum(int var0);
- public abstract int getMaximum(int var0);
- public int getMinimalDaysInFirstWeek() { return 0; }
- public abstract int getMinimum(int var0);
- public final java.util.Date getTime() { return null; }
- protected long getTimeInMillis() { return 0l; }
- public java.util.TimeZone getTimeZone() { return null; }
- public int hashCode() { return 0; }
- protected final int internalGet(int var0) { return 0; }
- public boolean isLenient() { return false; }
- public final boolean isSet(int var0) { return false; }
- public void roll(int var0, int var1) { }
- public abstract void roll(int var0, boolean var1);
- public final void set(int var0, int var1) { }
- public final void set(int var0, int var1, int var2) { }
- public final void set(int var0, int var1, int var2, int var3, int var4) { }
- public final void set(int var0, int var1, int var2, int var3, int var4, int var5) { }
- public void setFirstDayOfWeek(int var0) { }
- public void setLenient(boolean var0) { }
- public void setMinimalDaysInFirstWeek(int var0) { }
- public final void setTime(java.util.Date var0) { }
- protected void setTimeInMillis(long var0) { }
- public void setTimeZone(java.util.TimeZone var0) { }
- public java.lang.String toString() { return null; }
- protected boolean areFieldsSet;
- protected int[] fields;
- protected boolean[] isSet;
- protected boolean isTimeSet;
- protected long time;
- public final static int JANUARY = 0;
- public final static int FEBRUARY = 1;
- public final static int MARCH = 2;
- public final static int APRIL = 3;
- public final static int MAY = 4;
- public final static int JUNE = 5;
- public final static int JULY = 6;
- public final static int AUGUST = 7;
- public final static int SEPTEMBER = 8;
- public final static int OCTOBER = 9;
- public final static int NOVEMBER = 10;
- public final static int DECEMBER = 11;
- public final static int UNDECIMBER = 12;
- public final static int SUNDAY = 1;
- public final static int MONDAY = 2;
- public final static int TUESDAY = 3;
- public final static int WEDNESDAY = 4;
- public final static int THURSDAY = 5;
- public final static int FRIDAY = 6;
- public final static int SATURDAY = 7;
- public final static int ERA = 0;
- public final static int YEAR = 1;
- public final static int MONTH = 2;
- public final static int WEEK_OF_YEAR = 3;
- public final static int WEEK_OF_MONTH = 4;
- public final static int DATE = 5;
- public final static int DAY_OF_MONTH = 5;
- public final static int DAY_OF_YEAR = 6;
- public final static int DAY_OF_WEEK = 7;
- public final static int DAY_OF_WEEK_IN_MONTH = 8;
- public final static int AM_PM = 9;
- public final static int HOUR = 10;
- public final static int HOUR_OF_DAY = 11;
- public final static int MINUTE = 12;
- public final static int SECOND = 13;
- public final static int MILLISECOND = 14;
- public final static int ZONE_OFFSET = 15;
- public final static int DST_OFFSET = 16;
- public final static int FIELD_COUNT = 17;
- public final static int AM = 0;
- public final static int PM = 1;
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/util/Collection.java b/org.osgi.foundation/src/main/java/java/util/Collection.java
deleted file mode 100644
index 985e35e..0000000
--- a/org.osgi.foundation/src/main/java/java/util/Collection.java
+++ /dev/null
@@ -1,38 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/util/Collection.java,v 1.6 2006/03/14 01:20:26 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.util;
-public abstract interface Collection {
- public abstract boolean add(java.lang.Object var0);
- public abstract boolean addAll(java.util.Collection var0);
- public abstract void clear();
- public abstract boolean contains(java.lang.Object var0);
- public abstract boolean containsAll(java.util.Collection var0);
- public abstract boolean equals(java.lang.Object var0);
- public abstract int hashCode();
- public abstract boolean isEmpty();
- public abstract java.util.Iterator iterator();
- public abstract boolean remove(java.lang.Object var0);
- public abstract boolean removeAll(java.util.Collection var0);
- public abstract boolean retainAll(java.util.Collection var0);
- public abstract int size();
- public abstract java.lang.Object[] toArray();
- public abstract java.lang.Object[] toArray(java.lang.Object[] var0);
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/util/Collections.java b/org.osgi.foundation/src/main/java/java/util/Collections.java
deleted file mode 100644
index fa452c2..0000000
--- a/org.osgi.foundation/src/main/java/java/util/Collections.java
+++ /dev/null
@@ -1,58 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/util/Collections.java,v 1.6 2006/03/14 01:20:26 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.util;
-public class Collections {
- public static int binarySearch(java.util.List var0, java.lang.Object var1) { return 0; }
- public static int binarySearch(java.util.List var0, java.lang.Object var1, java.util.Comparator var2) { return 0; }
- public static void copy(java.util.List var0, java.util.List var1) { }
- public static java.util.Enumeration enumeration(java.util.Collection var0) { return null; }
- public static void fill(java.util.List var0, java.lang.Object var1) { }
- public static java.lang.Object max(java.util.Collection var0) { return null; }
- public static java.lang.Object max(java.util.Collection var0, java.util.Comparator var1) { return null; }
- public static java.lang.Object min(java.util.Collection var0) { return null; }
- public static java.lang.Object min(java.util.Collection var0, java.util.Comparator var1) { return null; }
- public static java.util.List nCopies(int var0, java.lang.Object var1) { return null; }
- public static void reverse(java.util.List var0) { }
- public static java.util.Comparator reverseOrder() { return null; }
- public static void shuffle(java.util.List var0) { }
- public static void shuffle(java.util.List var0, java.util.Random var1) { }
- public static java.util.Set singleton(java.lang.Object var0) { return null; }
- public static java.util.List singletonList(java.lang.Object var0) { return null; }
- public static java.util.Map singletonMap(java.lang.Object var0, java.lang.Object var1) { return null; }
- public static void sort(java.util.List var0) { }
- public static void sort(java.util.List var0, java.util.Comparator var1) { }
- public static java.util.Collection synchronizedCollection(java.util.Collection var0) { return null; }
- public static java.util.List synchronizedList(java.util.List var0) { return null; }
- public static java.util.Map synchronizedMap(java.util.Map var0) { return null; }
- public static java.util.Set synchronizedSet(java.util.Set var0) { return null; }
- public static java.util.SortedMap synchronizedSortedMap(java.util.SortedMap var0) { return null; }
- public static java.util.SortedSet synchronizedSortedSet(java.util.SortedSet var0) { return null; }
- public static java.util.Collection unmodifiableCollection(java.util.Collection var0) { return null; }
- public static java.util.List unmodifiableList(java.util.List var0) { return null; }
- public static java.util.Map unmodifiableMap(java.util.Map var0) { return null; }
- public static java.util.Set unmodifiableSet(java.util.Set var0) { return null; }
- public static java.util.SortedMap unmodifiableSortedMap(java.util.SortedMap var0) { return null; }
- public static java.util.SortedSet unmodifiableSortedSet(java.util.SortedSet var0) { return null; }
- public final static java.util.List EMPTY_LIST; static { EMPTY_LIST = null; }
- public final static java.util.Set EMPTY_SET; static { EMPTY_SET = null; }
- public final static java.util.Map EMPTY_MAP; static { EMPTY_MAP = null; }
- private Collections() { } /* generated constructor to prevent compiler adding default public constructor */
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/util/Comparator.java b/org.osgi.foundation/src/main/java/java/util/Comparator.java
deleted file mode 100644
index b977285..0000000
--- a/org.osgi.foundation/src/main/java/java/util/Comparator.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/util/Comparator.java,v 1.6 2006/03/14 01:20:26 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.util;
-public abstract interface Comparator {
- public abstract int compare(java.lang.Object var0, java.lang.Object var1);
- public abstract boolean equals(java.lang.Object var0);
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/util/ConcurrentModificationException.java b/org.osgi.foundation/src/main/java/java/util/ConcurrentModificationException.java
deleted file mode 100644
index 829e3ce..0000000
--- a/org.osgi.foundation/src/main/java/java/util/ConcurrentModificationException.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/util/ConcurrentModificationException.java,v 1.6 2006/03/14 01:20:25 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.util;
-public class ConcurrentModificationException extends java.lang.RuntimeException {
- public ConcurrentModificationException() { }
- public ConcurrentModificationException(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/util/Date.java b/org.osgi.foundation/src/main/java/java/util/Date.java
deleted file mode 100644
index 123388b..0000000
--- a/org.osgi.foundation/src/main/java/java/util/Date.java
+++ /dev/null
@@ -1,35 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/util/Date.java,v 1.6 2006/03/14 01:20:25 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.util;
-public class Date implements java.io.Serializable, java.lang.Cloneable, java.lang.Comparable {
- public Date() { }
- public Date(long var0) { }
- public boolean after(java.util.Date var0) { return false; }
- public boolean before(java.util.Date var0) { return false; }
- public java.lang.Object clone() { return null; }
- public int compareTo(java.lang.Object var0) { return 0; }
- public int compareTo(java.util.Date var0) { return 0; }
- public boolean equals(java.lang.Object var0) { return false; }
- public long getTime() { return 0l; }
- public int hashCode() { return 0; }
- public void setTime(long var0) { }
- public java.lang.String toString() { return null; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/util/Dictionary.java b/org.osgi.foundation/src/main/java/java/util/Dictionary.java
deleted file mode 100644
index 977afd9..0000000
--- a/org.osgi.foundation/src/main/java/java/util/Dictionary.java
+++ /dev/null
@@ -1,31 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/util/Dictionary.java,v 1.6 2006/03/14 01:20:25 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.util;
-public abstract class Dictionary {
- public Dictionary() { }
- public abstract java.util.Enumeration elements();
- public abstract java.lang.Object get(java.lang.Object var0);
- public abstract boolean isEmpty();
- public abstract java.util.Enumeration keys();
- public abstract java.lang.Object put(java.lang.Object var0, java.lang.Object var1);
- public abstract java.lang.Object remove(java.lang.Object var0);
- public abstract int size();
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/util/EmptyStackException.java b/org.osgi.foundation/src/main/java/java/util/EmptyStackException.java
deleted file mode 100644
index 9b3c57d..0000000
--- a/org.osgi.foundation/src/main/java/java/util/EmptyStackException.java
+++ /dev/null
@@ -1,24 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/util/EmptyStackException.java,v 1.6 2006/03/14 01:20:26 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.util;
-public class EmptyStackException extends java.lang.RuntimeException {
- public EmptyStackException() { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/util/Enumeration.java b/org.osgi.foundation/src/main/java/java/util/Enumeration.java
deleted file mode 100644
index eff5b3a..0000000
--- a/org.osgi.foundation/src/main/java/java/util/Enumeration.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/util/Enumeration.java,v 1.6 2006/03/14 01:20:25 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.util;
-public abstract interface Enumeration {
- public abstract boolean hasMoreElements();
- public abstract java.lang.Object nextElement();
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/util/EventListener.java b/org.osgi.foundation/src/main/java/java/util/EventListener.java
deleted file mode 100644
index 9bdb6ea..0000000
--- a/org.osgi.foundation/src/main/java/java/util/EventListener.java
+++ /dev/null
@@ -1,23 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/util/EventListener.java,v 1.6 2006/03/14 01:20:25 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.util;
-public abstract interface EventListener {
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/util/EventObject.java b/org.osgi.foundation/src/main/java/java/util/EventObject.java
deleted file mode 100644
index 9bef5e7..0000000
--- a/org.osgi.foundation/src/main/java/java/util/EventObject.java
+++ /dev/null
@@ -1,27 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/util/EventObject.java,v 1.6 2006/03/14 01:20:25 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.util;
-public class EventObject implements java.io.Serializable {
- public EventObject(java.lang.Object var0) { }
- public java.lang.Object getSource() { return null; }
- public java.lang.String toString() { return null; }
- protected java.lang.Object source;
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/util/GregorianCalendar.java b/org.osgi.foundation/src/main/java/java/util/GregorianCalendar.java
deleted file mode 100644
index 7cd7175..0000000
--- a/org.osgi.foundation/src/main/java/java/util/GregorianCalendar.java
+++ /dev/null
@@ -1,48 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/util/GregorianCalendar.java,v 1.6 2006/03/14 01:20:25 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.util;
-public class GregorianCalendar extends java.util.Calendar {
- public GregorianCalendar() { }
- public GregorianCalendar(int var0, int var1, int var2) { }
- public GregorianCalendar(int var0, int var1, int var2, int var3, int var4) { }
- public GregorianCalendar(int var0, int var1, int var2, int var3, int var4, int var5) { }
- public GregorianCalendar(java.util.Locale var0) { }
- public GregorianCalendar(java.util.TimeZone var0) { }
- public GregorianCalendar(java.util.TimeZone var0, java.util.Locale var1) { }
- public void add(int var0, int var1) { }
- protected void computeFields() { }
- protected void computeTime() { }
- public boolean equals(java.lang.Object var0) { return false; }
- public int getActualMaximum(int var0) { return 0; }
- public int getActualMinimum(int var0) { return 0; }
- public int getGreatestMinimum(int var0) { return 0; }
- public final java.util.Date getGregorianChange() { return null; }
- public int getLeastMaximum(int var0) { return 0; }
- public int getMaximum(int var0) { return 0; }
- public int getMinimum(int var0) { return 0; }
- public int hashCode() { return 0; }
- public boolean isLeapYear(int var0) { return false; }
- public void roll(int var0, int var1) { }
- public void roll(int var0, boolean var1) { }
- public void setGregorianChange(java.util.Date var0) { }
- public final static int BC = 0;
- public final static int AD = 1;
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/util/HashMap.java b/org.osgi.foundation/src/main/java/java/util/HashMap.java
deleted file mode 100644
index 506187e..0000000
--- a/org.osgi.foundation/src/main/java/java/util/HashMap.java
+++ /dev/null
@@ -1,40 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/util/HashMap.java,v 1.6 2006/03/14 01:20:26 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.util;
-public class HashMap extends java.util.AbstractMap implements java.util.Map, java.lang.Cloneable, java.io.Serializable {
- public HashMap() { }
- public HashMap(int var0) { }
- public HashMap(int var0, float var1) { }
- public HashMap(java.util.Map var0) { }
- public void clear() { }
- public java.lang.Object clone() { return null; }
- public boolean containsKey(java.lang.Object var0) { return false; }
- public boolean containsValue(java.lang.Object var0) { return false; }
- public java.util.Set entrySet() { return null; }
- public java.lang.Object get(java.lang.Object var0) { return null; }
- public boolean isEmpty() { return false; }
- public java.util.Set keySet() { return null; }
- public java.lang.Object put(java.lang.Object var0, java.lang.Object var1) { return null; }
- public void putAll(java.util.Map var0) { }
- public java.lang.Object remove(java.lang.Object var0) { return null; }
- public int size() { return 0; }
- public java.util.Collection values() { return null; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/util/HashSet.java b/org.osgi.foundation/src/main/java/java/util/HashSet.java
deleted file mode 100644
index 5d16a4d..0000000
--- a/org.osgi.foundation/src/main/java/java/util/HashSet.java
+++ /dev/null
@@ -1,35 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/util/HashSet.java,v 1.6 2006/03/14 01:20:25 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.util;
-public class HashSet extends java.util.AbstractSet implements java.util.Set, java.lang.Cloneable, java.io.Serializable {
- public HashSet() { }
- public HashSet(int var0) { }
- public HashSet(int var0, float var1) { }
- public HashSet(java.util.Collection var0) { }
- public boolean add(java.lang.Object var0) { return false; }
- public void clear() { }
- public java.lang.Object clone() { return null; }
- public boolean contains(java.lang.Object var0) { return false; }
- public boolean isEmpty() { return false; }
- public java.util.Iterator iterator() { return null; }
- public boolean remove(java.lang.Object var0) { return false; }
- public int size() { return 0; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/util/Hashtable.java b/org.osgi.foundation/src/main/java/java/util/Hashtable.java
deleted file mode 100644
index e77464a..0000000
--- a/org.osgi.foundation/src/main/java/java/util/Hashtable.java
+++ /dev/null
@@ -1,47 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/util/Hashtable.java,v 1.6 2006/03/14 01:20:26 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.util;
-public class Hashtable extends java.util.Dictionary implements java.util.Map, java.lang.Cloneable, java.io.Serializable {
- public Hashtable() { }
- public Hashtable(int var0) { }
- public Hashtable(int var0, float var1) { }
- public Hashtable(java.util.Map var0) { }
- public void clear() { }
- public java.lang.Object clone() { return null; }
- public boolean contains(java.lang.Object var0) { return false; }
- public boolean containsKey(java.lang.Object var0) { return false; }
- public boolean containsValue(java.lang.Object var0) { return false; }
- public java.util.Enumeration elements() { return null; }
- public java.util.Set entrySet() { return null; }
- public boolean equals(java.lang.Object var0) { return false; }
- public java.lang.Object get(java.lang.Object var0) { return null; }
- public int hashCode() { return 0; }
- public boolean isEmpty() { return false; }
- public java.util.Enumeration keys() { return null; }
- public java.util.Set keySet() { return null; }
- public java.lang.Object put(java.lang.Object var0, java.lang.Object var1) { return null; }
- public void putAll(java.util.Map var0) { }
- protected void rehash() { }
- public java.lang.Object remove(java.lang.Object var0) { return null; }
- public int size() { return 0; }
- public java.lang.String toString() { return null; }
- public java.util.Collection values() { return null; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/util/Iterator.java b/org.osgi.foundation/src/main/java/java/util/Iterator.java
deleted file mode 100644
index a715983..0000000
--- a/org.osgi.foundation/src/main/java/java/util/Iterator.java
+++ /dev/null
@@ -1,26 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/util/Iterator.java,v 1.6 2006/03/14 01:20:25 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.util;
-public abstract interface Iterator {
- public abstract boolean hasNext();
- public abstract java.lang.Object next();
- public abstract void remove();
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/util/LinkedList.java b/org.osgi.foundation/src/main/java/java/util/LinkedList.java
deleted file mode 100644
index 6c42f1a..0000000
--- a/org.osgi.foundation/src/main/java/java/util/LinkedList.java
+++ /dev/null
@@ -1,48 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/util/LinkedList.java,v 1.6 2006/03/14 01:20:25 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.util;
-public class LinkedList extends java.util.AbstractSequentialList implements java.util.List, java.lang.Cloneable, java.io.Serializable {
- public LinkedList() { }
- public LinkedList(java.util.Collection var0) { }
- public void add(int var0, java.lang.Object var1) { }
- public boolean add(java.lang.Object var0) { return false; }
- public boolean addAll(int var0, java.util.Collection var1) { return false; }
- public boolean addAll(java.util.Collection var0) { return false; }
- public void addFirst(java.lang.Object var0) { }
- public void addLast(java.lang.Object var0) { }
- public void clear() { }
- public java.lang.Object clone() { return null; }
- public boolean contains(java.lang.Object var0) { return false; }
- public java.lang.Object get(int var0) { return null; }
- public java.lang.Object getFirst() { return null; }
- public java.lang.Object getLast() { return null; }
- public int indexOf(java.lang.Object var0) { return 0; }
- public int lastIndexOf(java.lang.Object var0) { return 0; }
- public java.util.ListIterator listIterator(int var0) { return null; }
- public java.lang.Object remove(int var0) { return null; }
- public boolean remove(java.lang.Object var0) { return false; }
- public java.lang.Object removeFirst() { return null; }
- public java.lang.Object removeLast() { return null; }
- public java.lang.Object set(int var0, java.lang.Object var1) { return null; }
- public int size() { return 0; }
- public java.lang.Object[] toArray() { return null; }
- public java.lang.Object[] toArray(java.lang.Object[] var0) { return null; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/util/List.java b/org.osgi.foundation/src/main/java/java/util/List.java
deleted file mode 100644
index 57df7ea..0000000
--- a/org.osgi.foundation/src/main/java/java/util/List.java
+++ /dev/null
@@ -1,48 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/util/List.java,v 1.6 2006/03/14 01:20:25 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.util;
-public abstract interface List extends java.util.Collection {
- public abstract void add(int var0, java.lang.Object var1);
- public abstract boolean add(java.lang.Object var0);
- public abstract boolean addAll(int var0, java.util.Collection var1);
- public abstract boolean addAll(java.util.Collection var0);
- public abstract void clear();
- public abstract boolean contains(java.lang.Object var0);
- public abstract boolean containsAll(java.util.Collection var0);
- public abstract boolean equals(java.lang.Object var0);
- public abstract java.lang.Object get(int var0);
- public abstract int hashCode();
- public abstract int indexOf(java.lang.Object var0);
- public abstract boolean isEmpty();
- public abstract java.util.Iterator iterator();
- public abstract int lastIndexOf(java.lang.Object var0);
- public abstract java.util.ListIterator listIterator();
- public abstract java.util.ListIterator listIterator(int var0);
- public abstract java.lang.Object remove(int var0);
- public abstract boolean remove(java.lang.Object var0);
- public abstract boolean removeAll(java.util.Collection var0);
- public abstract boolean retainAll(java.util.Collection var0);
- public abstract java.lang.Object set(int var0, java.lang.Object var1);
- public abstract int size();
- public abstract java.util.List subList(int var0, int var1);
- public abstract java.lang.Object[] toArray();
- public abstract java.lang.Object[] toArray(java.lang.Object[] var0);
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/util/ListIterator.java b/org.osgi.foundation/src/main/java/java/util/ListIterator.java
deleted file mode 100644
index 0138312..0000000
--- a/org.osgi.foundation/src/main/java/java/util/ListIterator.java
+++ /dev/null
@@ -1,32 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/util/ListIterator.java,v 1.6 2006/03/14 01:20:25 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.util;
-public abstract interface ListIterator extends java.util.Iterator {
- public abstract void add(java.lang.Object var0);
- public abstract boolean hasNext();
- public abstract boolean hasPrevious();
- public abstract java.lang.Object next();
- public abstract int nextIndex();
- public abstract java.lang.Object previous();
- public abstract int previousIndex();
- public abstract void remove();
- public abstract void set(java.lang.Object var0);
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/util/ListResourceBundle.java b/org.osgi.foundation/src/main/java/java/util/ListResourceBundle.java
deleted file mode 100644
index cea95ff..0000000
--- a/org.osgi.foundation/src/main/java/java/util/ListResourceBundle.java
+++ /dev/null
@@ -1,27 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/util/ListResourceBundle.java,v 1.6 2006/03/14 01:20:26 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.util;
-public abstract class ListResourceBundle extends java.util.ResourceBundle {
- public ListResourceBundle() { }
- protected abstract java.lang.Object[][] getContents();
- public java.util.Enumeration getKeys() { return null; }
- public final java.lang.Object handleGetObject(java.lang.String var0) { return null; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/util/Locale.java b/org.osgi.foundation/src/main/java/java/util/Locale.java
deleted file mode 100644
index df28d97..0000000
--- a/org.osgi.foundation/src/main/java/java/util/Locale.java
+++ /dev/null
@@ -1,68 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/util/Locale.java,v 1.6 2006/03/14 01:20:26 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.util;
-public final class Locale implements java.lang.Cloneable, java.io.Serializable {
- public Locale(java.lang.String var0, java.lang.String var1) { }
- public Locale(java.lang.String var0, java.lang.String var1, java.lang.String var2) { }
- public java.lang.Object clone() { return null; }
- public boolean equals(java.lang.Object var0) { return false; }
- public static java.util.Locale[] getAvailableLocales() { return null; }
- public java.lang.String getCountry() { return null; }
- public static java.util.Locale getDefault() { return null; }
- public final java.lang.String getDisplayCountry() { return null; }
- public java.lang.String getDisplayCountry(java.util.Locale var0) { return null; }
- public final java.lang.String getDisplayLanguage() { return null; }
- public java.lang.String getDisplayLanguage(java.util.Locale var0) { return null; }
- public final java.lang.String getDisplayName() { return null; }
- public java.lang.String getDisplayName(java.util.Locale var0) { return null; }
- public final java.lang.String getDisplayVariant() { return null; }
- public java.lang.String getDisplayVariant(java.util.Locale var0) { return null; }
- public java.lang.String getISO3Country() throws java.util.MissingResourceException { return null; }
- public java.lang.String getISO3Language() throws java.util.MissingResourceException { return null; }
- public static java.lang.String[] getISOCountries() { return null; }
- public static java.lang.String[] getISOLanguages() { return null; }
- public java.lang.String getLanguage() { return null; }
- public java.lang.String getVariant() { return null; }
- public int hashCode() { return 0; }
- public static void setDefault(java.util.Locale var0) { }
- public final java.lang.String toString() { return null; }
- public final static java.util.Locale CANADA; static { CANADA = null; }
- public final static java.util.Locale CANADA_FRENCH; static { CANADA_FRENCH = null; }
- public final static java.util.Locale CHINA; static { CHINA = null; }
- public final static java.util.Locale CHINESE; static { CHINESE = null; }
- public final static java.util.Locale ENGLISH; static { ENGLISH = null; }
- public final static java.util.Locale FRANCE; static { FRANCE = null; }
- public final static java.util.Locale FRENCH; static { FRENCH = null; }
- public final static java.util.Locale GERMAN; static { GERMAN = null; }
- public final static java.util.Locale GERMANY; static { GERMANY = null; }
- public final static java.util.Locale ITALIAN; static { ITALIAN = null; }
- public final static java.util.Locale ITALY; static { ITALY = null; }
- public final static java.util.Locale JAPAN; static { JAPAN = null; }
- public final static java.util.Locale JAPANESE; static { JAPANESE = null; }
- public final static java.util.Locale KOREA; static { KOREA = null; }
- public final static java.util.Locale KOREAN; static { KOREAN = null; }
- public final static java.util.Locale PRC; static { PRC = null; }
- public final static java.util.Locale SIMPLIFIED_CHINESE; static { SIMPLIFIED_CHINESE = null; }
- public final static java.util.Locale TAIWAN; static { TAIWAN = null; }
- public final static java.util.Locale TRADITIONAL_CHINESE; static { TRADITIONAL_CHINESE = null; }
- public final static java.util.Locale UK; static { UK = null; }
- public final static java.util.Locale US; static { US = null; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/util/Map.java b/org.osgi.foundation/src/main/java/java/util/Map.java
deleted file mode 100644
index 5efe372..0000000
--- a/org.osgi.foundation/src/main/java/java/util/Map.java
+++ /dev/null
@@ -1,44 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/util/Map.java,v 1.6 2006/03/14 01:20:25 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.util;
-public abstract interface Map {
- public abstract void clear();
- public abstract boolean containsKey(java.lang.Object var0);
- public abstract boolean containsValue(java.lang.Object var0);
- public abstract java.util.Set entrySet();
- public abstract boolean equals(java.lang.Object var0);
- public abstract java.lang.Object get(java.lang.Object var0);
- public abstract int hashCode();
- public abstract boolean isEmpty();
- public abstract java.util.Set keySet();
- public abstract java.lang.Object put(java.lang.Object var0, java.lang.Object var1);
- public abstract void putAll(java.util.Map var0);
- public abstract java.lang.Object remove(java.lang.Object var0);
- public abstract int size();
- public abstract java.util.Collection values();
- public static abstract interface Entry {
- public abstract boolean equals(java.lang.Object var0);
- public abstract java.lang.Object getKey();
- public abstract java.lang.Object getValue();
- public abstract int hashCode();
- public abstract java.lang.Object setValue(java.lang.Object var0);
- }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/util/MissingResourceException.java b/org.osgi.foundation/src/main/java/java/util/MissingResourceException.java
deleted file mode 100644
index 5a16e21..0000000
--- a/org.osgi.foundation/src/main/java/java/util/MissingResourceException.java
+++ /dev/null
@@ -1,26 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/util/MissingResourceException.java,v 1.6 2006/03/14 01:20:26 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.util;
-public class MissingResourceException extends java.lang.RuntimeException {
- public MissingResourceException(java.lang.String var0, java.lang.String var1, java.lang.String var2) { }
- public java.lang.String getClassName() { return null; }
- public java.lang.String getKey() { return null; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/util/NoSuchElementException.java b/org.osgi.foundation/src/main/java/java/util/NoSuchElementException.java
deleted file mode 100644
index c1d6dc8..0000000
--- a/org.osgi.foundation/src/main/java/java/util/NoSuchElementException.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/util/NoSuchElementException.java,v 1.6 2006/03/14 01:20:25 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.util;
-public class NoSuchElementException extends java.lang.RuntimeException {
- public NoSuchElementException() { }
- public NoSuchElementException(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/util/Observable.java b/org.osgi.foundation/src/main/java/java/util/Observable.java
deleted file mode 100644
index e56f52c..0000000
--- a/org.osgi.foundation/src/main/java/java/util/Observable.java
+++ /dev/null
@@ -1,33 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/util/Observable.java,v 1.6 2006/03/14 01:20:25 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.util;
-public class Observable {
- public Observable() { }
- public void addObserver(java.util.Observer var0) { }
- protected void clearChanged() { }
- public int countObservers() { return 0; }
- public void deleteObserver(java.util.Observer var0) { }
- public void deleteObservers() { }
- public boolean hasChanged() { return false; }
- public void notifyObservers() { }
- public void notifyObservers(java.lang.Object var0) { }
- protected void setChanged() { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/util/Observer.java b/org.osgi.foundation/src/main/java/java/util/Observer.java
deleted file mode 100644
index f896e32..0000000
--- a/org.osgi.foundation/src/main/java/java/util/Observer.java
+++ /dev/null
@@ -1,24 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/util/Observer.java,v 1.6 2006/03/14 01:20:25 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.util;
-public abstract interface Observer {
- public abstract void update(java.util.Observable var0, java.lang.Object var1);
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/util/Properties.java b/org.osgi.foundation/src/main/java/java/util/Properties.java
deleted file mode 100644
index 7e8185c..0000000
--- a/org.osgi.foundation/src/main/java/java/util/Properties.java
+++ /dev/null
@@ -1,35 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/util/Properties.java,v 1.6 2006/03/14 01:20:25 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.util;
-public class Properties extends java.util.Hashtable {
- public Properties() { }
- public Properties(java.util.Properties var0) { }
- public java.lang.String getProperty(java.lang.String var0) { return null; }
- public java.lang.String getProperty(java.lang.String var0, java.lang.String var1) { return null; }
- public void list(java.io.PrintStream var0) { }
- public void list(java.io.PrintWriter var0) { }
- public void load(java.io.InputStream var0) throws java.io.IOException { }
- public java.util.Enumeration propertyNames() { return null; }
- public void save(java.io.OutputStream var0, java.lang.String var1) { }
- public java.lang.Object setProperty(java.lang.String var0, java.lang.String var1) { return null; }
- public void store(java.io.OutputStream var0, java.lang.String var1) throws java.io.IOException { }
- protected java.util.Properties defaults;
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/util/PropertyPermission.java b/org.osgi.foundation/src/main/java/java/util/PropertyPermission.java
deleted file mode 100644
index 8091f92..0000000
--- a/org.osgi.foundation/src/main/java/java/util/PropertyPermission.java
+++ /dev/null
@@ -1,29 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/util/PropertyPermission.java,v 1.6 2006/03/14 01:20:25 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.util;
-public final class PropertyPermission extends java.security.BasicPermission {
- public PropertyPermission(java.lang.String var0, java.lang.String var1) { super((java.lang.String) null, (java.lang.String) null); }
- public boolean equals(java.lang.Object var0) { return false; }
- public java.lang.String getActions() { return null; }
- public int hashCode() { return 0; }
- public boolean implies(java.security.Permission var0) { return false; }
- public java.security.PermissionCollection newPermissionCollection() { return null; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/util/PropertyResourceBundle.java b/org.osgi.foundation/src/main/java/java/util/PropertyResourceBundle.java
deleted file mode 100644
index 9310f41..0000000
--- a/org.osgi.foundation/src/main/java/java/util/PropertyResourceBundle.java
+++ /dev/null
@@ -1,26 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/util/PropertyResourceBundle.java,v 1.6 2006/03/14 01:20:26 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.util;
-public class PropertyResourceBundle extends java.util.ResourceBundle {
- public PropertyResourceBundle(java.io.InputStream var0) throws java.io.IOException { }
- public java.util.Enumeration getKeys() { return null; }
- public java.lang.Object handleGetObject(java.lang.String var0) { return null; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/util/Random.java b/org.osgi.foundation/src/main/java/java/util/Random.java
deleted file mode 100644
index 7ba2c58..0000000
--- a/org.osgi.foundation/src/main/java/java/util/Random.java
+++ /dev/null
@@ -1,35 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/util/Random.java,v 1.6 2006/03/14 01:20:25 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.util;
-public class Random implements java.io.Serializable {
- public Random() { }
- public Random(long var0) { }
- protected int next(int var0) { return 0; }
- public boolean nextBoolean() { return false; }
- public void nextBytes(byte[] var0) { }
- public double nextDouble() { return 0.0d; }
- public float nextFloat() { return 0.0f; }
- public double nextGaussian() { return 0.0d; }
- public int nextInt() { return 0; }
- public int nextInt(int var0) { return 0; }
- public long nextLong() { return 0l; }
- public void setSeed(long var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/util/ResourceBundle.java b/org.osgi.foundation/src/main/java/java/util/ResourceBundle.java
deleted file mode 100644
index 84767f8..0000000
--- a/org.osgi.foundation/src/main/java/java/util/ResourceBundle.java
+++ /dev/null
@@ -1,35 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/util/ResourceBundle.java,v 1.6 2006/03/14 01:20:26 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.util;
-public abstract class ResourceBundle {
- public ResourceBundle() { }
- public final static java.util.ResourceBundle getBundle(java.lang.String var0) throws java.util.MissingResourceException { return null; }
- public final static java.util.ResourceBundle getBundle(java.lang.String var0, java.util.Locale var1) { return null; }
- public static java.util.ResourceBundle getBundle(java.lang.String var0, java.util.Locale var1, java.lang.ClassLoader var2) throws java.util.MissingResourceException { return null; }
- public abstract java.util.Enumeration getKeys();
- public java.util.Locale getLocale() { return null; }
- public final java.lang.Object getObject(java.lang.String var0) throws java.util.MissingResourceException { return null; }
- public final java.lang.String getString(java.lang.String var0) throws java.util.MissingResourceException { return null; }
- public final java.lang.String[] getStringArray(java.lang.String var0) throws java.util.MissingResourceException { return null; }
- protected abstract java.lang.Object handleGetObject(java.lang.String var0) throws java.util.MissingResourceException;
- protected void setParent(java.util.ResourceBundle var0) { }
- protected java.util.ResourceBundle parent;
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/util/Set.java b/org.osgi.foundation/src/main/java/java/util/Set.java
deleted file mode 100644
index 69da8da..0000000
--- a/org.osgi.foundation/src/main/java/java/util/Set.java
+++ /dev/null
@@ -1,38 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/util/Set.java,v 1.6 2006/03/14 01:20:26 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.util;
-public abstract interface Set extends java.util.Collection {
- public abstract boolean add(java.lang.Object var0);
- public abstract boolean addAll(java.util.Collection var0);
- public abstract void clear();
- public abstract boolean contains(java.lang.Object var0);
- public abstract boolean containsAll(java.util.Collection var0);
- public abstract boolean equals(java.lang.Object var0);
- public abstract int hashCode();
- public abstract boolean isEmpty();
- public abstract java.util.Iterator iterator();
- public abstract boolean remove(java.lang.Object var0);
- public abstract boolean removeAll(java.util.Collection var0);
- public abstract boolean retainAll(java.util.Collection var0);
- public abstract int size();
- public abstract java.lang.Object[] toArray();
- public abstract java.lang.Object[] toArray(java.lang.Object[] var0);
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/util/SimpleTimeZone.java b/org.osgi.foundation/src/main/java/java/util/SimpleTimeZone.java
deleted file mode 100644
index 642d472..0000000
--- a/org.osgi.foundation/src/main/java/java/util/SimpleTimeZone.java
+++ /dev/null
@@ -1,45 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/util/SimpleTimeZone.java,v 1.6 2006/03/14 01:20:25 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.util;
-public class SimpleTimeZone extends java.util.TimeZone {
- public SimpleTimeZone(int var0, java.lang.String var1) { }
- public SimpleTimeZone(int var0, java.lang.String var1, int var2, int var3, int var4, int var5, int var6, int var7, int var8, int var9) { }
- public SimpleTimeZone(int var0, java.lang.String var1, int var2, int var3, int var4, int var5, int var6, int var7, int var8, int var9, int var10) { }
- public java.lang.Object clone() { return null; }
- public boolean equals(java.lang.Object var0) { return false; }
- public int getDSTSavings() { return 0; }
- public int getOffset(int var0, int var1, int var2, int var3, int var4, int var5) { return 0; }
- public int getRawOffset() { return 0; }
- public int hashCode() { return 0; }
- public boolean hasSameRules(java.util.TimeZone var0) { return false; }
- public boolean inDaylightTime(java.util.Date var0) { return false; }
- public void setDSTSavings(int var0) { }
- public void setEndRule(int var0, int var1, int var2) { }
- public void setEndRule(int var0, int var1, int var2, int var3) { }
- public void setEndRule(int var0, int var1, int var2, int var3, boolean var4) { }
- public void setRawOffset(int var0) { }
- public void setStartRule(int var0, int var1, int var2) { }
- public void setStartRule(int var0, int var1, int var2, int var3) { }
- public void setStartRule(int var0, int var1, int var2, int var3, boolean var4) { }
- public void setStartYear(int var0) { }
- public java.lang.String toString() { return null; }
- public boolean useDaylightTime() { return false; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/util/SortedMap.java b/org.osgi.foundation/src/main/java/java/util/SortedMap.java
deleted file mode 100644
index 794ff42..0000000
--- a/org.osgi.foundation/src/main/java/java/util/SortedMap.java
+++ /dev/null
@@ -1,29 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/util/SortedMap.java,v 1.6 2006/03/14 01:20:26 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.util;
-public abstract interface SortedMap extends java.util.Map {
- public abstract java.util.Comparator comparator();
- public abstract java.lang.Object firstKey();
- public abstract java.util.SortedMap headMap(java.lang.Object var0);
- public abstract java.lang.Object lastKey();
- public abstract java.util.SortedMap subMap(java.lang.Object var0, java.lang.Object var1);
- public abstract java.util.SortedMap tailMap(java.lang.Object var0);
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/util/SortedSet.java b/org.osgi.foundation/src/main/java/java/util/SortedSet.java
deleted file mode 100644
index 6aebef0..0000000
--- a/org.osgi.foundation/src/main/java/java/util/SortedSet.java
+++ /dev/null
@@ -1,29 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/util/SortedSet.java,v 1.6 2006/03/14 01:20:25 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.util;
-public abstract interface SortedSet extends java.util.Set {
- public abstract java.util.Comparator comparator();
- public abstract java.lang.Object first();
- public abstract java.util.SortedSet headSet(java.lang.Object var0);
- public abstract java.lang.Object last();
- public abstract java.util.SortedSet subSet(java.lang.Object var0, java.lang.Object var1);
- public abstract java.util.SortedSet tailSet(java.lang.Object var0);
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/util/Stack.java b/org.osgi.foundation/src/main/java/java/util/Stack.java
deleted file mode 100644
index 417a217..0000000
--- a/org.osgi.foundation/src/main/java/java/util/Stack.java
+++ /dev/null
@@ -1,29 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/util/Stack.java,v 1.6 2006/03/14 01:20:25 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.util;
-public class Stack extends java.util.Vector {
- public Stack() { }
- public boolean empty() { return false; }
- public java.lang.Object peek() { return null; }
- public java.lang.Object pop() { return null; }
- public java.lang.Object push(java.lang.Object var0) { return null; }
- public int search(java.lang.Object var0) { return 0; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/util/StringTokenizer.java b/org.osgi.foundation/src/main/java/java/util/StringTokenizer.java
deleted file mode 100644
index becbcac..0000000
--- a/org.osgi.foundation/src/main/java/java/util/StringTokenizer.java
+++ /dev/null
@@ -1,32 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/util/StringTokenizer.java,v 1.6 2006/03/14 01:20:25 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.util;
-public class StringTokenizer implements java.util.Enumeration {
- public StringTokenizer(java.lang.String var0) { }
- public StringTokenizer(java.lang.String var0, java.lang.String var1) { }
- public StringTokenizer(java.lang.String var0, java.lang.String var1, boolean var2) { }
- public int countTokens() { return 0; }
- public boolean hasMoreElements() { return false; }
- public boolean hasMoreTokens() { return false; }
- public java.lang.Object nextElement() { return null; }
- public java.lang.String nextToken() { return null; }
- public java.lang.String nextToken(java.lang.String var0) { return null; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/util/TimeZone.java b/org.osgi.foundation/src/main/java/java/util/TimeZone.java
deleted file mode 100644
index ba3be4a..0000000
--- a/org.osgi.foundation/src/main/java/java/util/TimeZone.java
+++ /dev/null
@@ -1,44 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/util/TimeZone.java,v 1.6 2006/03/14 01:20:26 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.util;
-public abstract class TimeZone implements java.io.Serializable, java.lang.Cloneable {
- public TimeZone() { }
- public java.lang.Object clone() { return null; }
- public static java.lang.String[] getAvailableIDs() { return null; }
- public static java.lang.String[] getAvailableIDs(int var0) { return null; }
- public static java.util.TimeZone getDefault() { return null; }
- public final java.lang.String getDisplayName() { return null; }
- public final java.lang.String getDisplayName(java.util.Locale var0) { return null; }
- public final java.lang.String getDisplayName(boolean var0, int var1) { return null; }
- public java.lang.String getDisplayName(boolean var0, int var1, java.util.Locale var2) { return null; }
- public java.lang.String getID() { return null; }
- public abstract int getOffset(int var0, int var1, int var2, int var3, int var4, int var5);
- public abstract int getRawOffset();
- public static java.util.TimeZone getTimeZone(java.lang.String var0) { return null; }
- public boolean hasSameRules(java.util.TimeZone var0) { return false; }
- public abstract boolean inDaylightTime(java.util.Date var0);
- public static void setDefault(java.util.TimeZone var0) { }
- public void setID(java.lang.String var0) { }
- public abstract void setRawOffset(int var0);
- public abstract boolean useDaylightTime();
- public final static int SHORT = 0;
- public final static int LONG = 1;
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/util/Timer.java b/org.osgi.foundation/src/main/java/java/util/Timer.java
deleted file mode 100644
index c261ec2..0000000
--- a/org.osgi.foundation/src/main/java/java/util/Timer.java
+++ /dev/null
@@ -1,32 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/util/Timer.java,v 1.6 2006/03/14 01:20:25 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.util;
-public class Timer {
- public Timer(boolean var0) { }
- public Timer() { }
- public void cancel() { }
- public void schedule(java.util.TimerTask var0, java.util.Date var1) { }
- public void schedule(java.util.TimerTask var0, long var1) { }
- public void schedule(java.util.TimerTask var0, long var1, long var2) { }
- public void schedule(java.util.TimerTask var0, java.util.Date var1, long var2) { }
- public void scheduleAtFixedRate(java.util.TimerTask var0, long var1, long var2) { }
- public void scheduleAtFixedRate(java.util.TimerTask var0, java.util.Date var1, long var2) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/util/TimerTask.java b/org.osgi.foundation/src/main/java/java/util/TimerTask.java
deleted file mode 100644
index bdfce97..0000000
--- a/org.osgi.foundation/src/main/java/java/util/TimerTask.java
+++ /dev/null
@@ -1,27 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/util/TimerTask.java,v 1.6 2006/03/14 01:20:25 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.util;
-public abstract class TimerTask implements java.lang.Runnable {
- protected TimerTask() { }
- public boolean cancel() { return false; }
- public long scheduledExecutionTime() { return 0l; }
- public abstract void run();
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/util/TooManyListenersException.java b/org.osgi.foundation/src/main/java/java/util/TooManyListenersException.java
deleted file mode 100644
index bd94738..0000000
--- a/org.osgi.foundation/src/main/java/java/util/TooManyListenersException.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/util/TooManyListenersException.java,v 1.6 2006/03/14 01:20:26 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.util;
-public class TooManyListenersException extends java.lang.Exception {
- public TooManyListenersException() { }
- public TooManyListenersException(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/util/TreeMap.java b/org.osgi.foundation/src/main/java/java/util/TreeMap.java
deleted file mode 100644
index 0eb4fba..0000000
--- a/org.osgi.foundation/src/main/java/java/util/TreeMap.java
+++ /dev/null
@@ -1,45 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/util/TreeMap.java,v 1.6 2006/03/14 01:20:25 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.util;
-public class TreeMap extends java.util.AbstractMap implements java.util.SortedMap, java.lang.Cloneable, java.io.Serializable {
- public TreeMap() { }
- public TreeMap(java.util.Comparator var0) { }
- public TreeMap(java.util.Map var0) { }
- public TreeMap(java.util.SortedMap var0) { }
- public void clear() { }
- public java.lang.Object clone() { return null; }
- public java.util.Comparator comparator() { return null; }
- public boolean containsKey(java.lang.Object var0) { return false; }
- public boolean containsValue(java.lang.Object var0) { return false; }
- public java.util.Set entrySet() { return null; }
- public java.lang.Object firstKey() { return null; }
- public java.lang.Object get(java.lang.Object var0) { return null; }
- public java.util.SortedMap headMap(java.lang.Object var0) { return null; }
- public java.util.Set keySet() { return null; }
- public java.lang.Object lastKey() { return null; }
- public java.lang.Object put(java.lang.Object var0, java.lang.Object var1) { return null; }
- public void putAll(java.util.Map var0) { }
- public java.lang.Object remove(java.lang.Object var0) { return null; }
- public int size() { return 0; }
- public java.util.SortedMap subMap(java.lang.Object var0, java.lang.Object var1) { return null; }
- public java.util.SortedMap tailMap(java.lang.Object var0) { return null; }
- public java.util.Collection values() { return null; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/util/TreeSet.java b/org.osgi.foundation/src/main/java/java/util/TreeSet.java
deleted file mode 100644
index e44c496..0000000
--- a/org.osgi.foundation/src/main/java/java/util/TreeSet.java
+++ /dev/null
@@ -1,42 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/util/TreeSet.java,v 1.6 2006/03/14 01:20:25 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.util;
-public class TreeSet extends java.util.AbstractSet implements java.util.SortedSet, java.lang.Cloneable, java.io.Serializable {
- public TreeSet() { }
- public TreeSet(java.util.Collection var0) { }
- public TreeSet(java.util.Comparator var0) { }
- public TreeSet(java.util.SortedSet var0) { }
- public boolean add(java.lang.Object var0) { return false; }
- public boolean addAll(java.util.Collection var0) { return false; }
- public void clear() { }
- public java.lang.Object clone() { return null; }
- public java.util.Comparator comparator() { return null; }
- public boolean contains(java.lang.Object var0) { return false; }
- public java.lang.Object first() { return null; }
- public java.util.SortedSet headSet(java.lang.Object var0) { return null; }
- public boolean isEmpty() { return false; }
- public java.util.Iterator iterator() { return null; }
- public java.lang.Object last() { return null; }
- public boolean remove(java.lang.Object var0) { return false; }
- public int size() { return 0; }
- public java.util.SortedSet subSet(java.lang.Object var0, java.lang.Object var1) { return null; }
- public java.util.SortedSet tailSet(java.lang.Object var0) { return null; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/util/Vector.java b/org.osgi.foundation/src/main/java/java/util/Vector.java
deleted file mode 100644
index a949d46..0000000
--- a/org.osgi.foundation/src/main/java/java/util/Vector.java
+++ /dev/null
@@ -1,72 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/util/Vector.java,v 1.6 2006/03/14 01:20:26 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.util;
-public class Vector extends java.util.AbstractList implements java.util.List, java.lang.Cloneable, java.io.Serializable {
- public Vector() { }
- public Vector(int var0) { }
- public Vector(int var0, int var1) { }
- public Vector(java.util.Collection var0) { }
- public void add(int var0, java.lang.Object var1) { }
- public boolean add(java.lang.Object var0) { return false; }
- public boolean addAll(int var0, java.util.Collection var1) { return false; }
- public boolean addAll(java.util.Collection var0) { return false; }
- public void addElement(java.lang.Object var0) { }
- public int capacity() { return 0; }
- public void clear() { }
- public java.lang.Object clone() { return null; }
- public boolean contains(java.lang.Object var0) { return false; }
- public boolean containsAll(java.util.Collection var0) { return false; }
- public void copyInto(java.lang.Object[] var0) { }
- public java.lang.Object elementAt(int var0) { return null; }
- public java.util.Enumeration elements() { return null; }
- public void ensureCapacity(int var0) { }
- public boolean equals(java.lang.Object var0) { return false; }
- public java.lang.Object firstElement() { return null; }
- public java.lang.Object get(int var0) { return null; }
- public int hashCode() { return 0; }
- public int indexOf(java.lang.Object var0) { return 0; }
- public int indexOf(java.lang.Object var0, int var1) { return 0; }
- public void insertElementAt(java.lang.Object var0, int var1) { }
- public boolean isEmpty() { return false; }
- public java.lang.Object lastElement() { return null; }
- public int lastIndexOf(java.lang.Object var0) { return 0; }
- public int lastIndexOf(java.lang.Object var0, int var1) { return 0; }
- public java.lang.Object remove(int var0) { return null; }
- public boolean remove(java.lang.Object var0) { return false; }
- public boolean removeAll(java.util.Collection var0) { return false; }
- public void removeAllElements() { }
- public boolean removeElement(java.lang.Object var0) { return false; }
- public void removeElementAt(int var0) { }
- protected void removeRange(int var0, int var1) { }
- public boolean retainAll(java.util.Collection var0) { return false; }
- public java.lang.Object set(int var0, java.lang.Object var1) { return null; }
- public void setElementAt(java.lang.Object var0, int var1) { }
- public void setSize(int var0) { }
- public int size() { return 0; }
- public java.util.List subList(int var0, int var1) { return null; }
- public java.lang.Object[] toArray() { return null; }
- public java.lang.Object[] toArray(java.lang.Object[] var0) { return null; }
- public java.lang.String toString() { return null; }
- public void trimToSize() { }
- protected int elementCount;
- protected java.lang.Object[] elementData;
- protected int capacityIncrement;
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/util/WeakHashMap.java b/org.osgi.foundation/src/main/java/java/util/WeakHashMap.java
deleted file mode 100644
index d806884..0000000
--- a/org.osgi.foundation/src/main/java/java/util/WeakHashMap.java
+++ /dev/null
@@ -1,35 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/util/WeakHashMap.java,v 1.6 2006/03/14 01:20:26 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.util;
-public class WeakHashMap extends java.util.AbstractMap implements java.util.Map {
- public WeakHashMap() { }
- public WeakHashMap(int var0) { }
- public WeakHashMap(int var0, float var1) { }
- public WeakHashMap(java.util.Map var0) { }
- public void clear() { }
- public boolean containsKey(java.lang.Object var0) { return false; }
- public java.util.Set entrySet() { return null; }
- public java.lang.Object get(java.lang.Object var0) { return null; }
- public boolean isEmpty() { return false; }
- public java.lang.Object put(java.lang.Object var0, java.lang.Object var1) { return null; }
- public java.lang.Object remove(java.lang.Object var0) { return null; }
- public int size() { return 0; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/util/jar/Attributes.java b/org.osgi.foundation/src/main/java/java/util/jar/Attributes.java
deleted file mode 100644
index 4968514..0000000
--- a/org.osgi.foundation/src/main/java/java/util/jar/Attributes.java
+++ /dev/null
@@ -1,68 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/util/jar/Attributes.java,v 1.6 2006/03/14 01:20:30 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.util.jar;
-public class Attributes implements java.lang.Cloneable, java.util.Map {
- public Attributes() { }
- public Attributes(java.util.jar.Attributes var0) { }
- public Attributes(int var0) { }
- public void clear() { }
- public boolean containsKey(java.lang.Object var0) { return false; }
- public boolean containsValue(java.lang.Object var0) { return false; }
- public java.util.Set entrySet() { return null; }
- public java.lang.Object get(java.lang.Object var0) { return null; }
- public boolean isEmpty() { return false; }
- public java.util.Set keySet() { return null; }
- public java.lang.Object put(java.lang.Object var0, java.lang.Object var1) { return null; }
- public void putAll(java.util.Map var0) { }
- public java.lang.Object remove(java.lang.Object var0) { return null; }
- public int size() { return 0; }
- public java.util.Collection values() { return null; }
- public java.lang.Object clone() { return null; }
- public int hashCode() { return 0; }
- public boolean equals(java.lang.Object var0) { return false; }
- public java.lang.String getValue(java.util.jar.Attributes.Name var0) { return null; }
- public java.lang.String getValue(java.lang.String var0) { return null; }
- public java.lang.String putValue(java.lang.String var0, java.lang.String var1) { return null; }
- protected java.util.Map map;
- public static class Name {
- public Name(java.lang.String var0) { }
- public java.lang.String toString() { return null; }
- public boolean equals(java.lang.Object var0) { return false; }
- public int hashCode() { return 0; }
- public final static java.util.jar.Attributes.Name CLASS_PATH; static { CLASS_PATH = null; }
- public final static java.util.jar.Attributes.Name MANIFEST_VERSION; static { MANIFEST_VERSION = null; }
- public final static java.util.jar.Attributes.Name MAIN_CLASS; static { MAIN_CLASS = null; }
- public final static java.util.jar.Attributes.Name SIGNATURE_VERSION; static { SIGNATURE_VERSION = null; }
- public final static java.util.jar.Attributes.Name CONTENT_TYPE; static { CONTENT_TYPE = null; }
- public final static java.util.jar.Attributes.Name SEALED; static { SEALED = null; }
- public final static java.util.jar.Attributes.Name IMPLEMENTATION_TITLE; static { IMPLEMENTATION_TITLE = null; }
- public final static java.util.jar.Attributes.Name IMPLEMENTATION_VERSION; static { IMPLEMENTATION_VERSION = null; }
- public final static java.util.jar.Attributes.Name IMPLEMENTATION_VENDOR; static { IMPLEMENTATION_VENDOR = null; }
- public final static java.util.jar.Attributes.Name SPECIFICATION_TITLE; static { SPECIFICATION_TITLE = null; }
- public final static java.util.jar.Attributes.Name SPECIFICATION_VERSION; static { SPECIFICATION_VERSION = null; }
- public final static java.util.jar.Attributes.Name SPECIFICATION_VENDOR; static { SPECIFICATION_VENDOR = null; }
- public final static java.util.jar.Attributes.Name EXTENSION_LIST; static { EXTENSION_LIST = null; }
- public final static java.util.jar.Attributes.Name EXTENSION_NAME; static { EXTENSION_NAME = null; }
- public final static java.util.jar.Attributes.Name EXTENSION_INSTALLATION; static { EXTENSION_INSTALLATION = null; }
- public final static java.util.jar.Attributes.Name IMPLEMENTATION_VENDOR_ID; static { IMPLEMENTATION_VENDOR_ID = null; }
- public final static java.util.jar.Attributes.Name IMPLEMENTATION_URL; static { IMPLEMENTATION_URL = null; }
- }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/util/jar/JarEntry.java b/org.osgi.foundation/src/main/java/java/util/jar/JarEntry.java
deleted file mode 100644
index 93e8213..0000000
--- a/org.osgi.foundation/src/main/java/java/util/jar/JarEntry.java
+++ /dev/null
@@ -1,28 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/util/jar/JarEntry.java,v 1.6 2006/03/14 01:20:30 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.util.jar;
-public class JarEntry extends java.util.zip.ZipEntry {
- public JarEntry(java.lang.String var0) { super((java.util.zip.ZipEntry) null); }
- public JarEntry(java.util.zip.ZipEntry var0) { super((java.util.zip.ZipEntry) null); }
- public java.util.jar.Attributes getAttributes() throws java.io.IOException { return null; }
- public java.security.cert.Certificate[] getCertificates() { return null; }
- public JarEntry(java.util.jar.JarEntry var0) { super((java.util.zip.ZipEntry) null); }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/util/jar/JarException.java b/org.osgi.foundation/src/main/java/java/util/jar/JarException.java
deleted file mode 100644
index d08ef6a..0000000
--- a/org.osgi.foundation/src/main/java/java/util/jar/JarException.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/util/jar/JarException.java,v 1.6 2006/03/14 01:20:30 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.util.jar;
-public class JarException extends java.util.zip.ZipException {
- public JarException() { }
- public JarException(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/util/jar/JarFile.java b/org.osgi.foundation/src/main/java/java/util/jar/JarFile.java
deleted file mode 100644
index 2b59a53..0000000
--- a/org.osgi.foundation/src/main/java/java/util/jar/JarFile.java
+++ /dev/null
@@ -1,34 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/util/jar/JarFile.java,v 1.6 2006/03/14 01:20:30 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.util.jar;
-public class JarFile extends java.util.zip.ZipFile {
- public JarFile(java.io.File var0) throws java.io.IOException { super((java.io.File) null); }
- public JarFile(java.io.File var0, boolean var1) throws java.io.IOException { super((java.io.File) null); }
- public JarFile(java.io.File var0, boolean var1, int var2) throws java.io.IOException { super((java.io.File) null); }
- public JarFile(java.lang.String var0) throws java.io.IOException { super((java.io.File) null); }
- public JarFile(java.lang.String var0, boolean var1) throws java.io.IOException { super((java.io.File) null); }
- public java.util.Enumeration entries() { return null; }
- public java.util.jar.JarEntry getJarEntry(java.lang.String var0) { return null; }
- public java.util.jar.Manifest getManifest() throws java.io.IOException { return null; }
- public java.io.InputStream getInputStream(java.util.zip.ZipEntry var0) throws java.io.IOException { return null; }
- public java.util.zip.ZipEntry getEntry(java.lang.String var0) { return null; }
- public final static java.lang.String MANIFEST_NAME = "META-INF/MANIFEST.MF";
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/util/jar/JarInputStream.java b/org.osgi.foundation/src/main/java/java/util/jar/JarInputStream.java
deleted file mode 100644
index 4f0a774..0000000
--- a/org.osgi.foundation/src/main/java/java/util/jar/JarInputStream.java
+++ /dev/null
@@ -1,30 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/util/jar/JarInputStream.java,v 1.6 2006/03/14 01:20:30 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.util.jar;
-public class JarInputStream extends java.util.zip.ZipInputStream {
- public JarInputStream(java.io.InputStream var0, boolean var1) throws java.io.IOException { super((java.io.InputStream) null); }
- public JarInputStream(java.io.InputStream var0) throws java.io.IOException { super((java.io.InputStream) null); }
- public java.util.jar.Manifest getManifest() { return null; }
- public java.util.jar.JarEntry getNextJarEntry() throws java.io.IOException { return null; }
- public int read(byte[] var0, int var1, int var2) throws java.io.IOException { return 0; }
- public java.util.zip.ZipEntry getNextEntry() throws java.io.IOException { return null; }
- protected java.util.zip.ZipEntry createZipEntry(java.lang.String var0) { return null; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/util/jar/JarOutputStream.java b/org.osgi.foundation/src/main/java/java/util/jar/JarOutputStream.java
deleted file mode 100644
index 7a1d92a..0000000
--- a/org.osgi.foundation/src/main/java/java/util/jar/JarOutputStream.java
+++ /dev/null
@@ -1,26 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/util/jar/JarOutputStream.java,v 1.6 2006/03/14 01:20:30 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.util.jar;
-public class JarOutputStream extends java.util.zip.ZipOutputStream {
- public JarOutputStream(java.io.OutputStream var0, java.util.jar.Manifest var1) throws java.io.IOException { super((java.io.OutputStream) null); }
- public JarOutputStream(java.io.OutputStream var0) throws java.io.IOException { super((java.io.OutputStream) null); }
- public void putNextEntry(java.util.zip.ZipEntry var0) throws java.io.IOException { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/util/jar/Manifest.java b/org.osgi.foundation/src/main/java/java/util/jar/Manifest.java
deleted file mode 100644
index 04de7b6..0000000
--- a/org.osgi.foundation/src/main/java/java/util/jar/Manifest.java
+++ /dev/null
@@ -1,35 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/util/jar/Manifest.java,v 1.6 2006/03/14 01:20:30 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.util.jar;
-public class Manifest implements java.lang.Cloneable {
- public Manifest() { }
- public Manifest(java.io.InputStream var0) throws java.io.IOException { }
- public void clear() { }
- public java.util.jar.Attributes getAttributes(java.lang.String var0) { return null; }
- public java.util.Map getEntries() { return null; }
- public java.util.jar.Attributes getMainAttributes() { return null; }
- public Manifest(java.util.jar.Manifest var0) { }
- public java.lang.Object clone() { return null; }
- public void write(java.io.OutputStream var0) throws java.io.IOException { }
- public void read(java.io.InputStream var0) throws java.io.IOException { }
- public int hashCode() { return 0; }
- public boolean equals(java.lang.Object var0) { return false; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/util/zip/Adler32.java b/org.osgi.foundation/src/main/java/java/util/zip/Adler32.java
deleted file mode 100644
index 5ccfb5e..0000000
--- a/org.osgi.foundation/src/main/java/java/util/zip/Adler32.java
+++ /dev/null
@@ -1,29 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/util/zip/Adler32.java,v 1.6 2006/03/14 01:20:30 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.util.zip;
-public class Adler32 implements java.util.zip.Checksum {
- public Adler32() { }
- public long getValue() { return 0l; }
- public void reset() { }
- public void update(int var0) { }
- public void update(byte[] var0) { }
- public void update(byte[] var0, int var1, int var2) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/util/zip/CRC32.java b/org.osgi.foundation/src/main/java/java/util/zip/CRC32.java
deleted file mode 100644
index 584fc1c..0000000
--- a/org.osgi.foundation/src/main/java/java/util/zip/CRC32.java
+++ /dev/null
@@ -1,29 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/util/zip/CRC32.java,v 1.6 2006/03/14 01:20:30 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.util.zip;
-public class CRC32 implements java.util.zip.Checksum {
- public CRC32() { }
- public long getValue() { return 0l; }
- public void reset() { }
- public void update(int var0) { }
- public void update(byte[] var0) { }
- public void update(byte[] var0, int var1, int var2) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/util/zip/CheckedInputStream.java b/org.osgi.foundation/src/main/java/java/util/zip/CheckedInputStream.java
deleted file mode 100644
index 4bb93f4..0000000
--- a/org.osgi.foundation/src/main/java/java/util/zip/CheckedInputStream.java
+++ /dev/null
@@ -1,28 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/util/zip/CheckedInputStream.java,v 1.6 2006/03/14 01:20:30 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.util.zip;
-public class CheckedInputStream extends java.io.FilterInputStream {
- public CheckedInputStream(java.io.InputStream var0, java.util.zip.Checksum var1) { super((java.io.InputStream) null); }
- public int read() throws java.io.IOException { return 0; }
- public int read(byte[] var0, int var1, int var2) throws java.io.IOException { return 0; }
- public java.util.zip.Checksum getChecksum() { return null; }
- public long skip(long var0) throws java.io.IOException { return 0l; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/util/zip/CheckedOutputStream.java b/org.osgi.foundation/src/main/java/java/util/zip/CheckedOutputStream.java
deleted file mode 100644
index d8a3916..0000000
--- a/org.osgi.foundation/src/main/java/java/util/zip/CheckedOutputStream.java
+++ /dev/null
@@ -1,27 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/util/zip/CheckedOutputStream.java,v 1.6 2006/03/14 01:20:30 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.util.zip;
-public class CheckedOutputStream extends java.io.FilterOutputStream {
- public CheckedOutputStream(java.io.OutputStream var0, java.util.zip.Checksum var1) { super((java.io.OutputStream) null); }
- public java.util.zip.Checksum getChecksum() { return null; }
- public void write(int var0) throws java.io.IOException { }
- public void write(byte[] var0, int var1, int var2) throws java.io.IOException { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/util/zip/Checksum.java b/org.osgi.foundation/src/main/java/java/util/zip/Checksum.java
deleted file mode 100644
index 821bc25..0000000
--- a/org.osgi.foundation/src/main/java/java/util/zip/Checksum.java
+++ /dev/null
@@ -1,27 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/util/zip/Checksum.java,v 1.6 2006/03/14 01:20:30 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.util.zip;
-public abstract interface Checksum {
- public abstract long getValue();
- public abstract void reset();
- public abstract void update(int var0);
- public abstract void update(byte[] var0, int var1, int var2);
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/util/zip/DataFormatException.java b/org.osgi.foundation/src/main/java/java/util/zip/DataFormatException.java
deleted file mode 100644
index 12672de..0000000
--- a/org.osgi.foundation/src/main/java/java/util/zip/DataFormatException.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/util/zip/DataFormatException.java,v 1.6 2006/03/14 01:20:30 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.util.zip;
-public class DataFormatException extends java.lang.Exception {
- public DataFormatException() { }
- public DataFormatException(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/util/zip/Deflater.java b/org.osgi.foundation/src/main/java/java/util/zip/Deflater.java
deleted file mode 100644
index 22787db..0000000
--- a/org.osgi.foundation/src/main/java/java/util/zip/Deflater.java
+++ /dev/null
@@ -1,51 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/util/zip/Deflater.java,v 1.6 2006/03/14 01:20:30 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.util.zip;
-public class Deflater {
- public int deflate(byte[] var0) { return 0; }
- public int deflate(byte[] var0, int var1, int var2) { return 0; }
- public void end() { }
- protected void finalize() { }
- public void finish() { }
- public boolean finished() { return false; }
- public int getAdler() { return 0; }
- public int getTotalIn() { return 0; }
- public int getTotalOut() { return 0; }
- public boolean needsInput() { return false; }
- public void reset() { }
- public void setDictionary(byte[] var0) { }
- public void setDictionary(byte[] var0, int var1, int var2) { }
- public void setInput(byte[] var0) { }
- public void setInput(byte[] var0, int var1, int var2) { }
- public void setLevel(int var0) { }
- public void setStrategy(int var0) { }
- public Deflater() { }
- public Deflater(int var0, boolean var1) { }
- public Deflater(int var0) { }
- public final static int BEST_COMPRESSION = 9;
- public final static int BEST_SPEED = 1;
- public final static int DEFAULT_COMPRESSION = -1;
- public final static int DEFAULT_STRATEGY = 0;
- public final static int DEFLATED = 8;
- public final static int FILTERED = 1;
- public final static int HUFFMAN_ONLY = 2;
- public final static int NO_COMPRESSION = 0;
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/util/zip/DeflaterOutputStream.java b/org.osgi.foundation/src/main/java/java/util/zip/DeflaterOutputStream.java
deleted file mode 100644
index 944df5c..0000000
--- a/org.osgi.foundation/src/main/java/java/util/zip/DeflaterOutputStream.java
+++ /dev/null
@@ -1,33 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/util/zip/DeflaterOutputStream.java,v 1.6 2006/03/14 01:20:30 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.util.zip;
-public class DeflaterOutputStream extends java.io.FilterOutputStream {
- public DeflaterOutputStream(java.io.OutputStream var0, java.util.zip.Deflater var1) { super((java.io.OutputStream) null); }
- public DeflaterOutputStream(java.io.OutputStream var0) { super((java.io.OutputStream) null); }
- public DeflaterOutputStream(java.io.OutputStream var0, java.util.zip.Deflater var1, int var2) { super((java.io.OutputStream) null); }
- protected void deflate() throws java.io.IOException { }
- public void close() throws java.io.IOException { }
- public void finish() throws java.io.IOException { }
- public void write(int var0) throws java.io.IOException { }
- public void write(byte[] var0, int var1, int var2) throws java.io.IOException { }
- protected byte[] buf;
- protected java.util.zip.Deflater def;
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/util/zip/GZIPInputStream.java b/org.osgi.foundation/src/main/java/java/util/zip/GZIPInputStream.java
deleted file mode 100644
index 4836689..0000000
--- a/org.osgi.foundation/src/main/java/java/util/zip/GZIPInputStream.java
+++ /dev/null
@@ -1,30 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/util/zip/GZIPInputStream.java,v 1.6 2006/03/14 01:20:30 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.util.zip;
-public class GZIPInputStream extends java.util.zip.InflaterInputStream {
- public GZIPInputStream(java.io.InputStream var0) throws java.io.IOException { super((java.io.InputStream) null, (java.util.zip.Inflater) null, 0); }
- public GZIPInputStream(java.io.InputStream var0, int var1) throws java.io.IOException { super((java.io.InputStream) null, (java.util.zip.Inflater) null, 0); }
- public int read(byte[] var0, int var1, int var2) throws java.io.IOException { return 0; }
- public void close() throws java.io.IOException { }
- protected java.util.zip.CRC32 crc;
- protected boolean eos;
- public final static int GZIP_MAGIC = 35615;
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/util/zip/GZIPOutputStream.java b/org.osgi.foundation/src/main/java/java/util/zip/GZIPOutputStream.java
deleted file mode 100644
index 6bb5393..0000000
--- a/org.osgi.foundation/src/main/java/java/util/zip/GZIPOutputStream.java
+++ /dev/null
@@ -1,29 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/util/zip/GZIPOutputStream.java,v 1.6 2006/03/14 01:20:30 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.util.zip;
-public class GZIPOutputStream extends java.util.zip.DeflaterOutputStream {
- public GZIPOutputStream(java.io.OutputStream var0) throws java.io.IOException { super((java.io.OutputStream) null, (java.util.zip.Deflater) null, 0); }
- public GZIPOutputStream(java.io.OutputStream var0, int var1) throws java.io.IOException { super((java.io.OutputStream) null, (java.util.zip.Deflater) null, 0); }
- public void finish() throws java.io.IOException { }
- public void close() throws java.io.IOException { }
- public void write(byte[] var0, int var1, int var2) throws java.io.IOException { }
- protected java.util.zip.CRC32 crc;
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/util/zip/Inflater.java b/org.osgi.foundation/src/main/java/java/util/zip/Inflater.java
deleted file mode 100644
index 5c66401..0000000
--- a/org.osgi.foundation/src/main/java/java/util/zip/Inflater.java
+++ /dev/null
@@ -1,41 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/util/zip/Inflater.java,v 1.6 2006/03/14 01:20:30 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.util.zip;
-public class Inflater {
- public void end() { }
- protected void finalize() { }
- public boolean finished() { return false; }
- public int getAdler() { return 0; }
- public int getRemaining() { return 0; }
- public int getTotalIn() { return 0; }
- public int getTotalOut() { return 0; }
- public int inflate(byte[] var0) throws java.util.zip.DataFormatException { return 0; }
- public int inflate(byte[] var0, int var1, int var2) throws java.util.zip.DataFormatException { return 0; }
- public Inflater() { }
- public Inflater(boolean var0) { }
- public boolean needsDictionary() { return false; }
- public boolean needsInput() { return false; }
- public void reset() { }
- public void setDictionary(byte[] var0) { }
- public void setDictionary(byte[] var0, int var1, int var2) { }
- public void setInput(byte[] var0) { }
- public void setInput(byte[] var0, int var1, int var2) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/util/zip/InflaterInputStream.java b/org.osgi.foundation/src/main/java/java/util/zip/InflaterInputStream.java
deleted file mode 100644
index 856b453..0000000
--- a/org.osgi.foundation/src/main/java/java/util/zip/InflaterInputStream.java
+++ /dev/null
@@ -1,35 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/util/zip/InflaterInputStream.java,v 1.6 2006/03/14 01:20:30 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.util.zip;
-public class InflaterInputStream extends java.io.FilterInputStream {
- public InflaterInputStream(java.io.InputStream var0) { super((java.io.InputStream) null); }
- public InflaterInputStream(java.io.InputStream var0, java.util.zip.Inflater var1) { super((java.io.InputStream) null); }
- public InflaterInputStream(java.io.InputStream var0, java.util.zip.Inflater var1, int var2) { super((java.io.InputStream) null); }
- public int read() throws java.io.IOException { return 0; }
- public int read(byte[] var0, int var1, int var2) throws java.io.IOException { return 0; }
- protected void fill() throws java.io.IOException { }
- public long skip(long var0) throws java.io.IOException { return 0l; }
- public int available() throws java.io.IOException { return 0; }
- public void close() throws java.io.IOException { }
- protected java.util.zip.Inflater inf;
- protected byte[] buf;
- protected int len;
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/util/zip/ZipConstants.java b/org.osgi.foundation/src/main/java/java/util/zip/ZipConstants.java
deleted file mode 100644
index 9133977..0000000
--- a/org.osgi.foundation/src/main/java/java/util/zip/ZipConstants.java
+++ /dev/null
@@ -1,63 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/util/zip/ZipConstants.java,v 1.6 2006/03/14 01:20:30 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.util.zip;
-abstract interface ZipConstants {
- public final static long LOCSIG = 67324752l;
- public final static long EXTSIG = 134695760l;
- public final static long CENSIG = 33639248l;
- public final static long ENDSIG = 101010256l;
- public final static int LOCHDR = 30;
- public final static int EXTHDR = 16;
- public final static int CENHDR = 46;
- public final static int ENDHDR = 22;
- public final static int LOCVER = 4;
- public final static int LOCFLG = 6;
- public final static int LOCHOW = 8;
- public final static int LOCTIM = 10;
- public final static int LOCCRC = 14;
- public final static int LOCSIZ = 18;
- public final static int LOCLEN = 22;
- public final static int LOCNAM = 26;
- public final static int LOCEXT = 28;
- public final static int EXTCRC = 4;
- public final static int EXTSIZ = 8;
- public final static int EXTLEN = 12;
- public final static int CENVEM = 4;
- public final static int CENVER = 6;
- public final static int CENFLG = 8;
- public final static int CENHOW = 10;
- public final static int CENTIM = 12;
- public final static int CENCRC = 16;
- public final static int CENSIZ = 20;
- public final static int CENLEN = 24;
- public final static int CENNAM = 28;
- public final static int CENEXT = 30;
- public final static int CENCOM = 32;
- public final static int CENDSK = 34;
- public final static int CENATT = 36;
- public final static int CENATX = 38;
- public final static int CENOFF = 42;
- public final static int ENDSUB = 8;
- public final static int ENDTOT = 10;
- public final static int ENDSIZ = 12;
- public final static int ENDOFF = 16;
- public final static int ENDCOM = 20;
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/util/zip/ZipEntry.java b/org.osgi.foundation/src/main/java/java/util/zip/ZipEntry.java
deleted file mode 100644
index 474e1bb..0000000
--- a/org.osgi.foundation/src/main/java/java/util/zip/ZipEntry.java
+++ /dev/null
@@ -1,46 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/util/zip/ZipEntry.java,v 1.6 2006/03/14 01:20:30 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.util.zip;
-public class ZipEntry implements java.util.zip.ZipConstants, java.lang.Cloneable {
- public ZipEntry(java.lang.String var0) { }
- public java.lang.String getComment() { return null; }
- public long getCompressedSize() { return 0l; }
- public long getCrc() { return 0l; }
- public byte[] getExtra() { return null; }
- public int getMethod() { return 0; }
- public java.lang.String getName() { return null; }
- public long getSize() { return 0l; }
- public long getTime() { return 0l; }
- public boolean isDirectory() { return false; }
- public void setComment(java.lang.String var0) { }
- public void setCompressedSize(long var0) { }
- public void setCrc(long var0) { }
- public void setExtra(byte[] var0) { }
- public void setMethod(int var0) { }
- public void setSize(long var0) { }
- public void setTime(long var0) { }
- public java.lang.String toString() { return null; }
- public ZipEntry(java.util.zip.ZipEntry var0) { }
- public java.lang.Object clone() { return null; }
- public int hashCode() { return 0; }
- public final static int DEFLATED = 8;
- public final static int STORED = 0;
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/util/zip/ZipException.java b/org.osgi.foundation/src/main/java/java/util/zip/ZipException.java
deleted file mode 100644
index 6943bdb..0000000
--- a/org.osgi.foundation/src/main/java/java/util/zip/ZipException.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/util/zip/ZipException.java,v 1.6 2006/03/14 01:20:30 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.util.zip;
-public class ZipException extends java.io.IOException {
- public ZipException() { }
- public ZipException(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/util/zip/ZipFile.java b/org.osgi.foundation/src/main/java/java/util/zip/ZipFile.java
deleted file mode 100644
index 043f5b1..0000000
--- a/org.osgi.foundation/src/main/java/java/util/zip/ZipFile.java
+++ /dev/null
@@ -1,35 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/util/zip/ZipFile.java,v 1.6 2006/03/14 01:20:30 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.util.zip;
-public class ZipFile implements java.util.zip.ZipConstants {
- public ZipFile(java.io.File var0) throws java.util.zip.ZipException, java.io.IOException { }
- public ZipFile(java.io.File var0, int var1) throws java.io.IOException { }
- public ZipFile(java.lang.String var0) throws java.io.IOException { }
- protected void finalize() throws java.io.IOException { }
- public void close() throws java.io.IOException { }
- public java.util.Enumeration entries() { return null; }
- public java.util.zip.ZipEntry getEntry(java.lang.String var0) { return null; }
- public java.io.InputStream getInputStream(java.util.zip.ZipEntry var0) throws java.io.IOException { return null; }
- public java.lang.String getName() { return null; }
- public int size() { return 0; }
- public final static int OPEN_READ = 1;
- public final static int OPEN_DELETE = 4;
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/util/zip/ZipInputStream.java b/org.osgi.foundation/src/main/java/java/util/zip/ZipInputStream.java
deleted file mode 100644
index 74abd52..0000000
--- a/org.osgi.foundation/src/main/java/java/util/zip/ZipInputStream.java
+++ /dev/null
@@ -1,31 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/util/zip/ZipInputStream.java,v 1.6 2006/03/14 01:20:30 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.util.zip;
-public class ZipInputStream extends java.util.zip.InflaterInputStream implements java.util.zip.ZipConstants {
- public ZipInputStream(java.io.InputStream var0) { super((java.io.InputStream) null, (java.util.zip.Inflater) null, 0); }
- public void close() throws java.io.IOException { }
- public void closeEntry() throws java.io.IOException { }
- public java.util.zip.ZipEntry getNextEntry() throws java.io.IOException { return null; }
- public int read(byte[] var0, int var1, int var2) throws java.io.IOException { return 0; }
- public long skip(long var0) throws java.io.IOException { return 0l; }
- public int available() throws java.io.IOException { return 0; }
- protected java.util.zip.ZipEntry createZipEntry(java.lang.String var0) { return null; }
-}
-
diff --git a/org.osgi.foundation/src/main/java/java/util/zip/ZipOutputStream.java b/org.osgi.foundation/src/main/java/java/util/zip/ZipOutputStream.java
deleted file mode 100644
index e01c07a..0000000
--- a/org.osgi.foundation/src/main/java/java/util/zip/ZipOutputStream.java
+++ /dev/null
@@ -1,34 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/java/util/zip/ZipOutputStream.java,v 1.6 2006/03/14 01:20:30 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package java.util.zip;
-public class ZipOutputStream extends java.util.zip.DeflaterOutputStream implements java.util.zip.ZipConstants {
- public ZipOutputStream(java.io.OutputStream var0) { super((java.io.OutputStream) null, (java.util.zip.Deflater) null, 0); }
- public void close() throws java.io.IOException { }
- public void closeEntry() throws java.io.IOException { }
- public void finish() throws java.io.IOException { }
- public void putNextEntry(java.util.zip.ZipEntry var0) throws java.io.IOException { }
- public void setComment(java.lang.String var0) { }
- public void setLevel(int var0) { }
- public void setMethod(int var0) { }
- public void write(byte[] var0, int var1, int var2) throws java.io.IOException { }
- public final static int DEFLATED = 8;
- public final static int STORED = 0;
-}
-
diff --git a/org.osgi.foundation/src/main/java/javax/microedition/io/Connection.java b/org.osgi.foundation/src/main/java/javax/microedition/io/Connection.java
deleted file mode 100644
index 742d358..0000000
--- a/org.osgi.foundation/src/main/java/javax/microedition/io/Connection.java
+++ /dev/null
@@ -1,24 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/javax/microedition/io/Connection.java,v 1.6 2006/03/14 01:20:29 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package javax.microedition.io;
-public abstract interface Connection {
- public abstract void close() throws java.io.IOException;
-}
-
diff --git a/org.osgi.foundation/src/main/java/javax/microedition/io/ConnectionNotFoundException.java b/org.osgi.foundation/src/main/java/javax/microedition/io/ConnectionNotFoundException.java
deleted file mode 100644
index 7a2be03..0000000
--- a/org.osgi.foundation/src/main/java/javax/microedition/io/ConnectionNotFoundException.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/javax/microedition/io/ConnectionNotFoundException.java,v 1.6 2006/03/14 01:20:29 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package javax.microedition.io;
-public class ConnectionNotFoundException extends java.io.IOException {
- public ConnectionNotFoundException() { }
- public ConnectionNotFoundException(java.lang.String var0) { }
-}
-
diff --git a/org.osgi.foundation/src/main/java/javax/microedition/io/Connector.java b/org.osgi.foundation/src/main/java/javax/microedition/io/Connector.java
deleted file mode 100644
index f2d284f..0000000
--- a/org.osgi.foundation/src/main/java/javax/microedition/io/Connector.java
+++ /dev/null
@@ -1,34 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/javax/microedition/io/Connector.java,v 1.6 2006/03/14 01:20:29 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package javax.microedition.io;
-public class Connector {
- public static javax.microedition.io.Connection open(java.lang.String var0) throws java.io.IOException { return null; }
- public static javax.microedition.io.Connection open(java.lang.String var0, int var1) throws java.io.IOException { return null; }
- public static javax.microedition.io.Connection open(java.lang.String var0, int var1, boolean var2) throws java.io.IOException { return null; }
- public static java.io.DataInputStream openDataInputStream(java.lang.String var0) throws java.io.IOException { return null; }
- public static java.io.DataOutputStream openDataOutputStream(java.lang.String var0) throws java.io.IOException { return null; }
- public static java.io.InputStream openInputStream(java.lang.String var0) throws java.io.IOException { return null; }
- public static java.io.OutputStream openOutputStream(java.lang.String var0) throws java.io.IOException { return null; }
- public final static int READ = 1;
- public final static int WRITE = 2;
- public final static int READ_WRITE = 3;
- private Connector() { } /* generated constructor to prevent compiler adding default public constructor */
-}
-
diff --git a/org.osgi.foundation/src/main/java/javax/microedition/io/ContentConnection.java b/org.osgi.foundation/src/main/java/javax/microedition/io/ContentConnection.java
deleted file mode 100644
index e523e26..0000000
--- a/org.osgi.foundation/src/main/java/javax/microedition/io/ContentConnection.java
+++ /dev/null
@@ -1,26 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/javax/microedition/io/ContentConnection.java,v 1.6 2006/03/14 01:20:29 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package javax.microedition.io;
-public abstract interface ContentConnection extends javax.microedition.io.StreamConnection {
- public abstract java.lang.String getEncoding();
- public abstract long getLength();
- public abstract java.lang.String getType();
-}
-
diff --git a/org.osgi.foundation/src/main/java/javax/microedition/io/Datagram.java b/org.osgi.foundation/src/main/java/javax/microedition/io/Datagram.java
deleted file mode 100644
index 0b90e0b..0000000
--- a/org.osgi.foundation/src/main/java/javax/microedition/io/Datagram.java
+++ /dev/null
@@ -1,32 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/javax/microedition/io/Datagram.java,v 1.6 2006/03/14 01:20:29 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package javax.microedition.io;
-public abstract interface Datagram extends java.io.DataInput, java.io.DataOutput {
- public abstract java.lang.String getAddress();
- public abstract byte[] getData();
- public abstract int getLength();
- public abstract int getOffset();
- public abstract void reset();
- public abstract void setAddress(javax.microedition.io.Datagram var0);
- public abstract void setAddress(java.lang.String var0) throws java.io.IOException;
- public abstract void setData(byte[] var0, int var1, int var2);
- public abstract void setLength(int var0);
-}
-
diff --git a/org.osgi.foundation/src/main/java/javax/microedition/io/DatagramConnection.java b/org.osgi.foundation/src/main/java/javax/microedition/io/DatagramConnection.java
deleted file mode 100644
index 05f9b6c..0000000
--- a/org.osgi.foundation/src/main/java/javax/microedition/io/DatagramConnection.java
+++ /dev/null
@@ -1,31 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/javax/microedition/io/DatagramConnection.java,v 1.6 2006/03/14 01:20:29 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package javax.microedition.io;
-public abstract interface DatagramConnection extends javax.microedition.io.Connection {
- public abstract int getMaximumLength() throws java.io.IOException;
- public abstract int getNominalLength() throws java.io.IOException;
- public abstract javax.microedition.io.Datagram newDatagram(byte[] var0, int var1) throws java.io.IOException;
- public abstract javax.microedition.io.Datagram newDatagram(byte[] var0, int var1, java.lang.String var2) throws java.io.IOException;
- public abstract javax.microedition.io.Datagram newDatagram(int var0) throws java.io.IOException;
- public abstract javax.microedition.io.Datagram newDatagram(int var0, java.lang.String var1) throws java.io.IOException;
- public abstract void receive(javax.microedition.io.Datagram var0) throws java.io.IOException;
- public abstract void send(javax.microedition.io.Datagram var0) throws java.io.IOException;
-}
-
diff --git a/org.osgi.foundation/src/main/java/javax/microedition/io/HttpConnection.java b/org.osgi.foundation/src/main/java/javax/microedition/io/HttpConnection.java
deleted file mode 100644
index 1a7b7fb..0000000
--- a/org.osgi.foundation/src/main/java/javax/microedition/io/HttpConnection.java
+++ /dev/null
@@ -1,85 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/javax/microedition/io/HttpConnection.java,v 1.6 2006/03/14 01:20:29 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package javax.microedition.io;
-public abstract interface HttpConnection extends javax.microedition.io.ContentConnection {
- public abstract long getDate() throws java.io.IOException;
- public abstract long getExpiration() throws java.io.IOException;
- public abstract java.lang.String getFile();
- public abstract java.lang.String getHeaderField(int var0) throws java.io.IOException;
- public abstract java.lang.String getHeaderField(java.lang.String var0) throws java.io.IOException;
- public abstract long getHeaderFieldDate(java.lang.String var0, long var1) throws java.io.IOException;
- public abstract int getHeaderFieldInt(java.lang.String var0, int var1) throws java.io.IOException;
- public abstract java.lang.String getHeaderFieldKey(int var0) throws java.io.IOException;
- public abstract java.lang.String getHost();
- public abstract long getLastModified() throws java.io.IOException;
- public abstract int getPort();
- public abstract java.lang.String getProtocol();
- public abstract java.lang.String getQuery();
- public abstract java.lang.String getRef();
- public abstract java.lang.String getRequestMethod();
- public abstract java.lang.String getRequestProperty(java.lang.String var0);
- public abstract int getResponseCode() throws java.io.IOException;
- public abstract java.lang.String getResponseMessage() throws java.io.IOException;
- public abstract java.lang.String getURL();
- public abstract void setRequestMethod(java.lang.String var0) throws java.io.IOException;
- public abstract void setRequestProperty(java.lang.String var0, java.lang.String var1) throws java.io.IOException;
- public final static java.lang.String GET = "GET";
- public final static java.lang.String HEAD = "HEAD";
- public final static java.lang.String POST = "POST";
- public final static int HTTP_ACCEPTED = 202;
- public final static int HTTP_BAD_GATEWAY = 502;
- public final static int HTTP_BAD_METHOD = 405;
- public final static int HTTP_BAD_REQUEST = 400;
- public final static int HTTP_CLIENT_TIMEOUT = 408;
- public final static int HTTP_CONFLICT = 409;
- public final static int HTTP_CREATED = 201;
- public final static int HTTP_ENTITY_TOO_LARGE = 413;
- public final static int HTTP_EXPECT_FAILED = 417;
- public final static int HTTP_FORBIDDEN = 403;
- public final static int HTTP_GATEWAY_TIMEOUT = 504;
- public final static int HTTP_GONE = 410;
- public final static int HTTP_INTERNAL_ERROR = 500;
- public final static int HTTP_LENGTH_REQUIRED = 411;
- public final static int HTTP_MOVED_PERM = 301;
- public final static int HTTP_MOVED_TEMP = 302;
- public final static int HTTP_MULT_CHOICE = 300;
- public final static int HTTP_NO_CONTENT = 204;
- public final static int HTTP_NOT_ACCEPTABLE = 406;
- public final static int HTTP_NOT_AUTHORITATIVE = 203;
- public final static int HTTP_NOT_FOUND = 404;
- public final static int HTTP_NOT_IMPLEMENTED = 501;
- public final static int HTTP_NOT_MODIFIED = 304;
- public final static int HTTP_OK = 200;
- public final static int HTTP_PARTIAL = 206;
- public final static int HTTP_PAYMENT_REQUIRED = 402;
- public final static int HTTP_PRECON_FAILED = 412;
- public final static int HTTP_PROXY_AUTH = 407;
- public final static int HTTP_REQ_TOO_LONG = 414;
- public final static int HTTP_RESET = 205;
- public final static int HTTP_SEE_OTHER = 303;
- public final static int HTTP_TEMP_REDIRECT = 307;
- public final static int HTTP_UNAUTHORIZED = 401;
- public final static int HTTP_UNAVAILABLE = 503;
- public final static int HTTP_UNSUPPORTED_RANGE = 416;
- public final static int HTTP_UNSUPPORTED_TYPE = 415;
- public final static int HTTP_USE_PROXY = 305;
- public final static int HTTP_VERSION = 505;
-}
-
diff --git a/org.osgi.foundation/src/main/java/javax/microedition/io/InputConnection.java b/org.osgi.foundation/src/main/java/javax/microedition/io/InputConnection.java
deleted file mode 100644
index 7099d4a..0000000
--- a/org.osgi.foundation/src/main/java/javax/microedition/io/InputConnection.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/javax/microedition/io/InputConnection.java,v 1.6 2006/03/14 01:20:29 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package javax.microedition.io;
-public abstract interface InputConnection extends javax.microedition.io.Connection {
- public abstract java.io.DataInputStream openDataInputStream() throws java.io.IOException;
- public abstract java.io.InputStream openInputStream() throws java.io.IOException;
-}
-
diff --git a/org.osgi.foundation/src/main/java/javax/microedition/io/OutputConnection.java b/org.osgi.foundation/src/main/java/javax/microedition/io/OutputConnection.java
deleted file mode 100644
index cb9508d..0000000
--- a/org.osgi.foundation/src/main/java/javax/microedition/io/OutputConnection.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/javax/microedition/io/OutputConnection.java,v 1.6 2006/03/14 01:20:29 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package javax.microedition.io;
-public abstract interface OutputConnection extends javax.microedition.io.Connection {
- public abstract java.io.DataOutputStream openDataOutputStream() throws java.io.IOException;
- public abstract java.io.OutputStream openOutputStream() throws java.io.IOException;
-}
-
diff --git a/org.osgi.foundation/src/main/java/javax/microedition/io/StreamConnection.java b/org.osgi.foundation/src/main/java/javax/microedition/io/StreamConnection.java
deleted file mode 100644
index cf6f524..0000000
--- a/org.osgi.foundation/src/main/java/javax/microedition/io/StreamConnection.java
+++ /dev/null
@@ -1,23 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/javax/microedition/io/StreamConnection.java,v 1.6 2006/03/14 01:20:29 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package javax.microedition.io;
-public abstract interface StreamConnection extends javax.microedition.io.InputConnection, javax.microedition.io.OutputConnection {
-}
-
diff --git a/org.osgi.foundation/src/main/java/javax/microedition/io/StreamConnectionNotifier.java b/org.osgi.foundation/src/main/java/javax/microedition/io/StreamConnectionNotifier.java
deleted file mode 100644
index 584c9ef..0000000
--- a/org.osgi.foundation/src/main/java/javax/microedition/io/StreamConnectionNotifier.java
+++ /dev/null
@@ -1,24 +0,0 @@
-/*
- * $Header: /cvshome/build/ee.foundation/src/javax/microedition/io/StreamConnectionNotifier.java,v 1.6 2006/03/14 01:20:29 hargrave Exp $
- *
- * (C) Copyright 2001 Sun Microsystems, Inc.
- * Copyright (c) OSGi Alliance (2001, 2005). All Rights Reserved.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package javax.microedition.io;
-public abstract interface StreamConnectionNotifier extends javax.microedition.io.Connection {
- public abstract javax.microedition.io.StreamConnection acceptAndOpen() throws java.io.IOException;
-}
-
diff --git a/pom.xml b/pom.xml
index d0eabac..afa0be8 100644
--- a/pom.xml
+++ b/pom.xml
@@ -94,10 +94,6 @@
</property>
</activation>
<modules>
- <module>org.osgi.foundation</module>
- <module>javax.servlet</module>
- <module>org.osgi.core</module>
- <module>org.osgi.compendium</module>
<module>resolver</module>
<module>framework</module>
<module>main</module>