KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > eclipse > ui > browser > BrowserFactory


1 /*******************************************************************************
2  * Copyright (c) 2005 IBM Corporation and others.
3  * All rights reserved. This program and the accompanying materials
4  * are made available under the terms of the Eclipse Public License v1.0
5  * which accompanies this distribution, and is available at
6  * http://www.eclipse.org/legal/epl-v10.html
7  *
8  * Contributors:
9  * IBM Corporation - initial API and implementation
10  *******************************************************************************/

11 package org.eclipse.ui.browser;
12
13 import org.eclipse.ui.browser.IWebBrowser;
14 /**
15  * Implementators of <code>org.eclipse.ui.browser.browsers</code> extension
16  * points must provide an implementation of this abstract class.
17  *
18  * @since 3.1
19  */

20 public abstract class BrowserFactory {
21     /**
22      * Checks whether the factory can work on the user system.
23      *
24      * @return <code>false</code> if the factory can work on this system; for
25      * example the required native browser required by browser adapters that
26      * it creates is not installed, or <code>true</code> otherwise
27      */

28     public boolean isAvailable() {
29         return true;
30     }
31
32     /**
33      * Obtains a new instance of a web browser.
34      *
35      * @param id the browser id
36      * @param location the browser location
37      * @param parameters the browser parameters
38      * @return an instance of IWebBrowser
39      */

40     public abstract IWebBrowser createBrowser(String JavaDoc id, String JavaDoc location, String JavaDoc parameters);
41 }
Popular Tags