Source code: netscape/jsdebug/SourceTextProvider.java
1 /* -*- Mode: C; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*-
2 *
3 * The contents of this file are subject to the Netscape Public
4 * License Version 1.1 (the "License"); you may not use this file
5 * except in compliance with the License. You may obtain a copy of
6 * the License at http://www.mozilla.org/NPL/
7 *
8 * Software distributed under the License is distributed on an "AS
9 * IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
10 * implied. See the License for the specific language governing
11 * rights and limitations under the License.
12 *
13 * The Original Code is mozilla.org code.
14 *
15 * The Initial Developer of the Original Code is Netscape
16 * Communications Corporation. Portions created by Netscape are
17 * Copyright (C) 1998 Netscape Communications Corporation. All
18 * Rights Reserved.
19 *
20 * Contributor(s):
21 */
22
23 package netscape.jsdebug;
24
25 import netscape.util.Vector;
26 import netscape.security.ForbiddenTargetException;
27
28 /**
29 * Abstract class to represent entity capable of providing access to source text
30 *
31 * @author John Bandhauer
32 * @version 1.0
33 * @since 1.0
34 */
35 public abstract class SourceTextProvider
36 {
37 public static SourceTextProvider getSourceTextProvider() throws Exception
38 {
39 return null;
40 }
41 /**
42 * Return the vector of SourceTextItems.
43 * <p>
44 * This is not liekly to be a copy. nor is it necessarily current
45 */
46 public abstract Vector getSourceTextVector() throws ForbiddenTargetException;
47 /**
48 * Refresh the vector by whatever means to reflect any changes made in the
49 * underlying native system
50 */
51 public abstract void refreshSourceTextVector();
52 /**
53 * Get the SourceText item for the given URL
54 */
55 public abstract SourceTextItem findSourceTextItem( String url ) throws ForbiddenTargetException;
56 /**
57 * Load the SourceText item for the given URL
58 * <p>
59 * <B>This is not guaranteed to be implemented</B>
60 */
61 public abstract SourceTextItem loadSourceTextItem( String url ) throws ForbiddenTargetException;
62 }