Bundle.java

00001 /*
00002  * $Header: /cvshome/build/org.osgi.framework/src/org/osgi/framework/Bundle.java,v 1.36 2006/06/16 16:31:18 hargrave Exp $
00003  * 
00004  * Copyright (c) OSGi Alliance (2000, 2006). All Rights Reserved.
00005  * 
00006  * Licensed under the Apache License, Version 2.0 (the "License");
00007  * you may not use this file except in compliance with the License.
00008  * You may obtain a copy of the License at
00009  *
00010  *      http://www.apache.org/licenses/LICENSE-2.0
00011  *
00012  * Unless required by applicable law or agreed to in writing, software
00013  * distributed under the License is distributed on an "AS IS" BASIS,
00014  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
00015  * See the License for the specific language governing permissions and
00016  * limitations under the License.
00017  */
00018 
00019 package org.osgi.framework;
00020 
00021 import java.io.IOException;
00022 import java.io.InputStream;
00023 import java.net.URL;
00024 import java.util.Dictionary;
00025 import java.util.Enumeration;
00026 
00069 public interface Bundle {
00081         public static final int UNINSTALLED     = 0x00000001;
00082 
00097         public static final int INSTALLED       = 0x00000002;
00098 
00124         public static final int RESOLVED        = 0x00000004;
00125 
00138         public static final int STARTING        = 0x00000008;
00139 
00151         public static final int STOPPING        = 0x00000010;
00152 
00162         public static final int ACTIVE          = 0x00000020;
00163 
00174         public int getState();
00175 
00260         public void start() throws BundleException;
00261 
00332         public void stop() throws BundleException;
00333 
00419         public void update() throws BundleException;
00420 
00444         public void update(InputStream in) throws BundleException;
00445 
00506         public void uninstall() throws BundleException;
00507 
00547         public Dictionary getHeaders();
00548 
00570         public long getBundleId();
00571 
00590         public String getLocation();
00591 
00616         public ServiceReference[] getRegisteredServices();
00617 
00642         public ServiceReference[] getServicesInUse();
00643 
00673         public boolean hasPermission(Object permission);
00674 
00699         public URL getResource(String name);
00700 
00757         public Dictionary getHeaders(String locale);
00758 
00773         public String getSymbolicName();
00774 
00808         public Class loadClass(String name) throws ClassNotFoundException;
00809 
00835         public Enumeration getResources(String name) throws IOException;
00836 
00858         public Enumeration getEntryPaths(String path);
00859 
00878         public URL getEntry(String name);
00879 
00891         public long getLastModified();
00892 
00952         public Enumeration findEntries(String path, String filePattern,
00953                         boolean recurse);
00954 }

Generated on Mon Jan 11 21:19:13 2010 for OpenMobileIS by  doxygen 1.5.4