@ScannerSide public class FileMetadata extends Object
Modifier and Type | Class and Description |
---|---|
static class |
FileMetadata.CharHandler |
static interface |
FileMetadata.LineHashConsumer |
Constructor and Description |
---|
FileMetadata() |
Modifier and Type | Method and Description |
---|---|
static void |
computeLineHashesForIssueTracking(InputFile f,
FileMetadata.LineHashConsumer consumer)
Compute a MD5 hash of each line of the file after removing of all blank chars
|
static void |
readFile(InputStream stream,
Charset encoding,
String filePath,
FileMetadata.CharHandler[] handlers) |
Metadata |
readMetadata(InputStream stream,
Charset encoding,
String filePath) |
Metadata |
readMetadata(InputStream stream,
Charset encoding,
String filePath,
FileMetadata.CharHandler otherHandler)
Compute hash of a file ignoring line ends differences.
|
Metadata |
readMetadata(Reader reader)
For testing purpose
|
public FileMetadata()
public Metadata readMetadata(InputStream stream, Charset encoding, String filePath, @Nullable FileMetadata.CharHandler otherHandler)
public Metadata readMetadata(InputStream stream, Charset encoding, String filePath)
public Metadata readMetadata(Reader reader)
public static void readFile(InputStream stream, Charset encoding, String filePath, FileMetadata.CharHandler[] handlers)
public static void computeLineHashesForIssueTracking(InputFile f, FileMetadata.LineHashConsumer consumer)
Copyright © 2009–2017 SonarSource. All rights reserved.