Class RefLeaseSpec

java.lang.Object
org.eclipse.jgit.transport.RefLeaseSpec
All Implemented Interfaces:
Serializable

public class RefLeaseSpec extends Object implements Serializable
Describes the expected value for a ref being pushed.
Since:
4.7
See Also:
  • Field Details

    • serialVersionUID

      private static final long serialVersionUID
      See Also:
    • ref

      private final String ref
      Name of the ref whose value we want to check.
    • expected

      private final String expected
      Local commitish to get expected value from.
  • Constructor Details

    • RefLeaseSpec

      public RefLeaseSpec(String ref, String expected)

      Constructor for RefLeaseSpec.

      Parameters:
      ref - ref being pushed
      expected - the expected value of the ref
  • Method Details

    • getRef

      public String getRef()
      Get the ref to protect.
      Returns:
      name of ref to check.
    • getExpected

      public String getExpected()
      Get the expected value of the ref, in the form of a local committish
      Returns:
      expected ref value.
    • toString

      public String toString()
      Overrides:
      toString in class Object