Package org.sonar.go.coverage
Class GoPathContext
- java.lang.Object
-
- org.sonar.go.coverage.GoPathContext
-
public class GoPathContext extends java.lang.Object
-
-
Field Summary
Fields Modifier and Type Field Description static GoPathContextDEFAULT
-
Constructor Summary
Constructors Constructor Description GoPathContext(char fileSeparator, java.lang.String pathSeparator, java.lang.String goPath)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.Stringresolve(java.lang.String filePath)Try to resolve the absolute path of the given filePath.
-
-
-
Field Detail
-
DEFAULT
public static final GoPathContext DEFAULT
-
-
Method Detail
-
resolve
public java.lang.String resolve(java.lang.String filePath)
Try to resolve the absolute path of the given filePath. If filePath is absolute (start with _) return the absolute path without the '_'. If filePath is relative, try to append the first GOPATH entry where this file exists, otherwise return a non-existing absolute path using the first GOPATH entry (or just filePath itself if GOPATH is empty). SeeGoCoverSensor.findInputFile(String, FileSystem)
-
-