java.lang.Object
com.google.googlejavaformat.java.Replacement

public final class Replacement extends Object
Represents a range in the original source and replacement text for that range.

google-java-format doesn't depend on AutoValue, to allow AutoValue to depend on google-java-format.

  • Method Details

    • create

      public static Replacement create(int startPosition, int endPosition, String replaceWith)
    • getReplaceRange

      public Range<Integer> getReplaceRange()
      The range of characters in the original source to replace.
    • getReplacementString

      public String getReplacementString()
      The string to replace the range of characters with.
    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object