KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > edu > umd > cs > findbugs > classfile > IClassPathBuilder


1 /*
2  * FindBugs - Find Bugs in Java programs
3  * Copyright (C) 2006, University of Maryland
4  *
5  * This library is free software; you can redistribute it and/or
6  * modify it under the terms of the GNU Lesser General Public
7  * License as published by the Free Software Foundation; either
8  * version 2.1 of the License, or (at your option) any later version.
9  *
10  * This library is distributed in the hope that it will be useful,
11  * but WITHOUT ANY WARRANTY; without even the implied warranty of
12  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13  * Lesser General Public License for more details.
14  *
15  * You should have received a copy of the GNU Lesser General Public
16  * License along with this library; if not, write to the Free Software
17  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
18  */

19
20 package edu.umd.cs.findbugs.classfile;
21
22 import java.io.IOException JavaDoc;
23 import java.util.List JavaDoc;
24 import java.util.Set JavaDoc;
25
26 /**
27  * Build a classpath.
28  * Takes a list of project codebases and
29  * <ul>
30  * <li>Scans them for nested and referenced codebases</li>
31  * <li>Builds a list of application class descriptors</li>
32  * <li>Adds system codebases</li>
33  * </ul>
34  *
35  * @author David Hovemeyer
36  */

37 public interface IClassPathBuilder {
38     /**
39      * Add a project codebase.
40      *
41      * @param locator locator for project codebase
42      * @param isApplication true if the codebase is an application codebase, false otherwise
43      */

44     public void addCodeBase(ICodeBaseLocator locator, boolean isApplication);
45
46     /**
47      * Set whether or not nested archives should be scanned.
48      * This should be called before the build() method is called.
49      *
50      * @param scanNestedArchives true if nested archives should be scanned,
51      * false otherwise
52      */

53     public void scanNestedArchives(boolean scanNestedArchives);
54
55     /**
56      * Build the classpath.
57      *
58      * @param classPath IClassPath object to build
59      * @param progress IClassPathBuilderProgress callback
60      * @throws ResourceNotFoundException
61      * @throws IOException
62      * @throws InterruptedException
63      */

64     public void build(IClassPath classPath, IClassPathBuilderProgress progress) throws CheckedAnalysisException, IOException JavaDoc, InterruptedException JavaDoc;
65     
66     /**
67      * Get the list of application classes discovered while scanning the classpath.
68      *
69      * @return list of application classes
70      */

71     public List JavaDoc<ClassDescriptor> getAppClassList();
72 }
73
Popular Tags