public interface InputFile extends Serializable
File
adds information for code analyzers.Modifier and Type | Interface and Description |
---|---|
static class |
InputFile.Status
Status regarding previous analysis
|
static class |
InputFile.Type |
Modifier and Type | Method and Description |
---|---|
String |
absolutePath()
Normalized absolute path.
|
File |
file()
The underlying absolute
File |
String |
language()
Language, for example "java" or "php".
|
int |
lines()
Number of physical lines.
|
String |
relativePath()
Path relative to module base directory.
|
InputFile.Status |
status()
Status regarding previous analysis
|
InputFile.Type |
type()
Does it contain main or test code ?
|
String relativePath()
FileSystem
. File separator is the forward
slash ('/'), even on Microsoft Windows.
Returns src/main/java/com/Foo.java
if module base dir is
/path/to/module
and if file is
/path/to/module/src/main/java/com/Foo.java
.
Relative path is not null and is normalized ('foo/../foo' is replaced by 'foo').String absolutePath()
file().getCanonicalPath()
to resolve symbolic link.String language()
InputFile.Type type()
InputFile.Status status()
int lines()
Copyright © 2009-2014 SonarSource. All Rights Reserved.