Record Class GitFlowPlanner.Facts

java.lang.Object
java.lang.Record
io.github.jbastgen.stemma.gitflow.GitFlowPlanner.Facts
Record Components:
local - the local branches
remote - the branches of the remotes by remote name
hasCommits - whether there is a commit at all
current - the gitflow.* keys written now
Enclosing class:
GitFlowPlanner

public static record GitFlowPlanner.Facts(Set<String> local, Map<String,Set<String>> remote, boolean hasCommits, Map<String,String> current) extends Record
The facts of a repository the plan depends on.
  • Constructor Details

    • Facts

      public Facts(Set<String> local, Map<String,Set<String>> remote, boolean hasCommits, Map<String,String> current)
      Creates an instance of a Facts record class.
      Parameters:
      local - the value for the local record component
      remote - the value for the remote record component
      hasCommits - the value for the hasCommits record component
      current - the value for the current record component
  • Method Details

    • toString

      public final String 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.
      Specified by:
      toString in class Record
      Returns:
      a string representation of this object
    • hashCode

      public final int hashCode()
      Returns a hash code value for this object. The value is derived from the hash code of each of the record components.
      Specified by:
      hashCode in class Record
      Returns:
      a hash code value for this object
    • equals

      public final boolean equals(Object o)
      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. Reference components are compared with Objects::equals(Object,Object); primitive components are compared with '=='.
      Specified by:
      equals in class Record
      Parameters:
      o - the object with which to compare
      Returns:
      true if this object is the same as the o argument; false otherwise.
    • local

      public Set<String> local()
      Returns the value of the local record component.
      Returns:
      the value of the local record component
    • remote

      public Map<String,Set<String>> remote()
      Returns the value of the remote record component.
      Returns:
      the value of the remote record component
    • hasCommits

      public boolean hasCommits()
      Returns the value of the hasCommits record component.
      Returns:
      the value of the hasCommits record component
    • current

      public Map<String,String> current()
      Returns the value of the current record component.
      Returns:
      the value of the current record component