KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > eclipse > help > browser > IBrowser


1 /*******************************************************************************
2  * Copyright (c) 2000, 2006 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.help.browser;
12 /**
13  * Represents a web browser that can be used by clients to display documents for
14  * the given URLs.
15  *
16  * @since 2.1
17  */

18 public interface IBrowser {
19     /**
20      * Closes the browser.
21      */

22     public void close();
23     /**
24      * Queries the browser if close method is supported.
25      *
26      * @return true if the method is fully implemented
27      */

28     public boolean isCloseSupported();
29     /**
30      * Displays document with the given URL, and makes the browser visible. This
31      * method starts the browser if necessary.
32      *
33      * @param url
34      * the URL to display in the browser
35      */

36     public void displayURL(String JavaDoc url) throws Exception JavaDoc;
37     /**
38      * Queries the browser if setLocation method is supported.
39      *
40      * @return true if the method is fully implemented
41      */

42     public boolean isSetLocationSupported();
43     /**
44      * Queries the browser if setSize method is supported.
45      *
46      * @return true if the method is fully implemented
47      */

48     public boolean isSetSizeSupported();
49     /**
50      * Causes the browser to be moved to the specified location. If the actual
51      * browser is not visible, the next time it becomes visible, it will be
52      * shown at the give location
53      *
54      * @param x
55      * horizontal coordinates of the left-top external corner
56      * @param y
57      * vertical coordinates of the left-top external corner
58      */

59     public void setLocation(int x, int y);
60     /**
61      * Causes the browser to be resized to the specified size. If the actual
62      * browser is not visible, the next time it becomes visible, it will be
63      * shown with the give size.
64      *
65      * @param width
66      * width in pixels
67      * @param height
68      * height in pixels external corner
69      */

70     public void setSize(int width, int height);
71 }
72
73
Popular Tags