Class FileChanges
java.lang.Object
io.jenkins.plugins.forensics.delta.FileChanges
- All Implemented Interfaces:
Serializable
Wraps all changes made to one specific file.
- Author:
- Florian Orendi
- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionFileChanges
(String fileName, String oldFileName, String fileContent, FileEditType fileEditType, Map<ChangeEditType, Set<Change>> changes) Constructor for an instance which wraps all changes made to a specific file. -
Method Summary
Modifier and TypeMethodDescriptionvoid
Adds information about a change and stores it according to the type of edit.boolean
getChangesByType
(ChangeEditType changeEditType) Returns information about changes of a specified type.Returns all modified lines in this changed file.int
hashCode()
-
Constructor Details
-
FileChanges
public FileChanges(String fileName, String oldFileName, String fileContent, FileEditType fileEditType, Map<ChangeEditType, Set<Change>> changes) Constructor for an instance which wraps all changes made to a specific file.- Parameters:
fileName
- The name of the fileoldFileName
- The old file name before the editfileContent
- The content of the filefileEditType
- The change type how the file has been affectedchanges
- The changes made to the file
-
-
Method Details
-
getFileName
-
getOldFileName
-
getFileContent
-
getFileEditType
-
getChanges
-
getChangesByType
Returns information about changes of a specified type.- Parameters:
changeEditType
- The edit type- Returns:
- the information about changes of the specified type
-
addChange
Adds information about a change and stores it according to the type of edit.- Parameters:
change
- The change to be stored
-
getModifiedLines
Returns all modified lines in this changed file.- Returns:
- the modified line
-
equals
-
hashCode
public int hashCode()
-