blob: 98bc27edd6185f6fbcd566c7e957b04044b0a991 [file] [log] [blame]
Richard S. Hall930fecc2005-08-16 18:33:34 +00001/*
2 * Copyright 2005 The Apache Software Foundation
3 *
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
7 *
8 * http://www.apache.org/licenses/LICENSE-2.0
9 *
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
15 *
16 */
17package org.ungoverned.osgi.service.shell;
18
19/**
20 * This interface defines the <tt>cd</tt> command service interface for the
Richard S. Hall5a031592005-08-19 19:53:58 +000021 * Felix impl service. The <tt>cd</tt> command does not really change the
22 * directory of the impl, rather it maintains a base URL for
Richard S. Hall930fecc2005-08-16 18:33:34 +000023 * simplifying URL entry.
24 * <p>
25 * For example, if the base URL is <tt>http://www.foo.com/<tt> and you
26 * try to install a bundle <tt>foo.jar</tt>, the actual URL will be
27 * expanded to <tt>http://www.foo.com/foo.jar</tt>. Any bundles wishing
Richard S. Hall5a031592005-08-19 19:53:58 +000028 * to retrieve or set the current directory of the impl can use this
Richard S. Hall930fecc2005-08-16 18:33:34 +000029 * service interface.
30**/
31public interface CdCommand extends Command
32{
33 /**
34 * Property used to configure the base URL.
35 **/
Richard S. Hall5a031592005-08-19 19:53:58 +000036 public static final String BASE_URL_PROPERTY = "felix.impl.baseurl";
Richard S. Hall930fecc2005-08-16 18:33:34 +000037
38 /**
Richard S. Hall5a031592005-08-19 19:53:58 +000039 * Returns the current <i>directory</i> of the impl service.
40 * @return the current impl directory.
Richard S. Hall930fecc2005-08-16 18:33:34 +000041 **/
42 public String getBaseURL();
43
44 /**
Richard S. Hall5a031592005-08-19 19:53:58 +000045 * Sets the current <i>directory</i> of the impl service.
Richard S. Hall930fecc2005-08-16 18:33:34 +000046 * @param s the new value for the base URL.
47 **/
48 public void setBaseURL(String s);
49}