Package aQute.bnd.osgi.eclipse
Class EclipseClasspath
- java.lang.Object
-
- aQute.bnd.osgi.eclipse.EclipseClasspath
-
public class EclipseClasspath extends java.lang.ObjectParse the Eclipse project information for the classpath. Unfortunately, it is impossible to read the variables. They are ignored but that can cause problems. @version $Revision: 1.2 $
-
-
Field Summary
Fields Modifier and Type Field Description (package private) java.util.Set<java.io.File>allSources(package private) java.util.Set<java.io.File>bootclasspath(package private) java.util.Set<java.io.File>classpath(package private) java.util.List<java.io.File>dependentsstatic intDO_VARIABLES(package private) static javax.xml.parsers.DocumentBuilderFactorydocumentBuilderFactory(package private) java.util.Set<java.io.File>exports(package private) intoptions(package private) java.io.Fileoutputprivate static java.util.regex.PatternPATH(package private) java.io.Fileproject(package private) java.util.Map<java.lang.String,java.lang.String>properties(package private) booleanrecurse(package private) Reporterreporter(package private) java.util.Set<java.io.File>sources(package private) java.io.Fileworkspace
-
Constructor Summary
Constructors Constructor Description EclipseClasspath(Reporter reporter, java.io.File workspace, java.io.File project)EclipseClasspath(Reporter reporter, java.io.File workspace, java.io.File project, int options)Parse an Eclipse project structure to discover the classpath.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description private java.lang.Stringget(org.w3c.dom.NamedNodeMap map, java.lang.String name)java.util.Set<java.io.File>getAllSources()java.util.Set<java.io.File>getBootclasspath()java.util.Set<java.io.File>getClasspath()java.util.List<java.io.File>getDependents()java.util.Set<java.io.File>getExports()private java.io.FilegetFile(java.io.File abs, java.io.File relative, java.lang.String opath)java.io.FilegetOutput()java.util.Set<java.io.File>getSourcepath()(package private) voidparse(java.io.File project, boolean top)Recursive routine to parse the files.private java.io.FilereplaceVar(java.lang.String path)voidsetProperties(java.util.Map<java.lang.String,java.lang.String> map)voidsetRecurse(boolean recurse)
-
-
-
Field Detail
-
documentBuilderFactory
static final javax.xml.parsers.DocumentBuilderFactory documentBuilderFactory
-
project
java.io.File project
-
workspace
java.io.File workspace
-
sources
java.util.Set<java.io.File> sources
-
allSources
java.util.Set<java.io.File> allSources
-
classpath
java.util.Set<java.io.File> classpath
-
dependents
java.util.List<java.io.File> dependents
-
output
java.io.File output
-
recurse
boolean recurse
-
exports
java.util.Set<java.io.File> exports
-
properties
java.util.Map<java.lang.String,java.lang.String> properties
-
reporter
Reporter reporter
-
options
int options
-
bootclasspath
java.util.Set<java.io.File> bootclasspath
-
DO_VARIABLES
public static final int DO_VARIABLES
- See Also:
- Constant Field Values
-
PATH
private static final java.util.regex.Pattern PATH
-
-
Constructor Detail
-
EclipseClasspath
public EclipseClasspath(Reporter reporter, java.io.File workspace, java.io.File project, int options) throws java.lang.Exception
Parse an Eclipse project structure to discover the classpath.- Parameters:
workspace- Points to workspaceproject- Points to project- Throws:
javax.xml.parsers.ParserConfigurationExceptionorg.xml.sax.SAXExceptionjava.io.IOExceptionjava.lang.Exception
-
EclipseClasspath
public EclipseClasspath(Reporter reporter, java.io.File workspace, java.io.File project) throws java.lang.Exception
- Throws:
java.lang.Exception
-
-
Method Detail
-
parse
void parse(java.io.File project, boolean top) throws javax.xml.parsers.ParserConfigurationException, org.xml.sax.SAXException, java.io.IOExceptionRecursive routine to parse the files. If a sub project is detected, it is parsed before the parsing continues. This should give the right order.- Parameters:
project- Project directorytop- If this is the top project- Throws:
javax.xml.parsers.ParserConfigurationExceptionorg.xml.sax.SAXExceptionjava.io.IOException
-
getFile
private java.io.File getFile(java.io.File abs, java.io.File relative, java.lang.String opath)
-
replaceVar
private java.io.File replaceVar(java.lang.String path)
-
get
private java.lang.String get(org.w3c.dom.NamedNodeMap map, java.lang.String name)
-
getClasspath
public java.util.Set<java.io.File> getClasspath()
-
getSourcepath
public java.util.Set<java.io.File> getSourcepath()
-
getOutput
public java.io.File getOutput()
-
getDependents
public java.util.List<java.io.File> getDependents()
-
setRecurse
public void setRecurse(boolean recurse)
-
getExports
public java.util.Set<java.io.File> getExports()
-
setProperties
public void setProperties(java.util.Map<java.lang.String,java.lang.String> map)
-
getBootclasspath
public java.util.Set<java.io.File> getBootclasspath()
-
getAllSources
public java.util.Set<java.io.File> getAllSources()
-
-