Record Class HunkLocation
java.lang.Object
java.lang.Record
org.variantsync.studies.evolution.simulation.diff.components.HunkLocation
- Record Components:
startLineSource
- The line number of the hunk's start in the source filestartLineTarget
- The line number of the hunk's start in the target file
The location of a hunk which is the combination of its location in the source and target file of UNIX diff.
-
Constructor Summary
ConstructorsConstructorDescriptionHunkLocation
(int startLineSource, int startLineTarget) Creates an instance of aHunkLocation
record class. -
Method Summary
Modifier and TypeMethodDescriptionboolean
Indicates whether some other object is "equal to" this one.int
hashCode()
Returns a hash code value for this object.int
Returns the value of thestartLineSource
record component.int
Returns the value of thestartLineTarget
record component.final String
toString()
Returns a string representation of this record class.
-
Constructor Details
-
HunkLocation
public HunkLocation(int startLineSource, int startLineTarget) Creates an instance of aHunkLocation
record class.- Parameters:
startLineSource
- the value for thestartLineSource
record componentstartLineTarget
- the value for thestartLineTarget
record component
-
-
Method Details
-
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared with '=='. -
hashCode
public int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
toString
Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components. -
startLineSource
public int startLineSource()Returns the value of thestartLineSource
record component.- Returns:
- the value of the
startLineSource
record component
-
startLineTarget
public int startLineTarget()Returns the value of thestartLineTarget
record component.- Returns:
- the value of the
startLineTarget
record component
-