Package org.jacoco.maven
Class ReportSupport.SourceFileCollection
- java.lang.Object
-
- org.jacoco.maven.ReportSupport.SourceFileCollection
-
- All Implemented Interfaces:
ISourceFileLocator
- Enclosing class:
- ReportSupport
private class ReportSupport.SourceFileCollection extends java.lang.Object implements ISourceFileLocator
-
-
Field Summary
Fields Modifier and Type Field Description private java.lang.String
encoding
private java.util.List<java.io.File>
sourceRoots
-
Constructor Summary
Constructors Constructor Description SourceFileCollection(org.apache.maven.project.MavenProject project, java.lang.String encoding)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.io.Reader
getSourceFile(java.lang.String packageName, java.lang.String fileName)
Tries to locate the given source file and opens a reader with the appropriate encoding.int
getTabWidth()
Returns number of blank characters that represent a tab in source code.
-
-
-
Method Detail
-
getSourceFile
public java.io.Reader getSourceFile(java.lang.String packageName, java.lang.String fileName) throws java.io.IOException
Description copied from interface:ISourceFileLocator
Tries to locate the given source file and opens a reader with the appropriate encoding.- Specified by:
getSourceFile
in interfaceISourceFileLocator
- Parameters:
packageName
- VM name of the packagefileName
- name of the source file- Returns:
- reader if the file could be located,
null
otherwise - Throws:
java.io.IOException
- in case of problems while opening the file
-
getTabWidth
public int getTabWidth()
Description copied from interface:ISourceFileLocator
Returns number of blank characters that represent a tab in source code.- Specified by:
getTabWidth
in interfaceISourceFileLocator
- Returns:
- tab width as number of blanks
-
-