Class CommitDataBean

  • All Implemented Interfaces:
    CommitData, CommitInfo

    public class CommitDataBean
    extends BaseCommitData
    implements CommitInfo
    This class is expected to be created from plugin code, provides implementation for CommitData
    Since:
    8.1
    Author:
    Eugene Petrenko (eugene.petrenko@jetbrains.com)
    • Constructor Detail

      • CommitDataBean

        public CommitDataBean​(@NotNull
                              String version,
                              @NotNull
                              String displayVersion,
                              @NotNull
                              Date vcsDate)
    • Method Detail

      • setCommitAuthor

        public void setCommitAuthor​(@NotNull
                                    String commitAuthor)
      • setCommitMessage

        public void setCommitMessage​(@NotNull
                                     String commitMessage)
      • addTag

        public void addTag​(@NotNull
                           String tag)
        Adds tag for this commit
        Parameters:
        tag - parent revision
        Since:
        8.1
      • setTags

        public void setTags​(@NotNull
                            Collection<String> tags)
        Replaces tags list for this commit
        Parameters:
        tags - parent revisions
        Since:
        8.1
      • addBranch

        public void addBranch​(@NotNull
                              String branch)
        Adds branch for this commit
        Parameters:
        branch - parent revision
        Since:
        8.1
      • setBranches

        public void setBranches​(@NotNull
                                Collection<String> branches)
        Replaces branches list for this commit
        Parameters:
        branches - parent revisions
        Since:
        8.1
      • getBranches

        @NotNull
        public List<String> getBranches()
        Specified by:
        getBranches in interface CommitInfo
        Returns:
        branches to which commit belongs or empty list if nothing is known
      • addHead

        public void addHead​(@NotNull
                            String head)
        adds one more head
        Since:
        8.1
      • setHeads

        public void setHeads​(@NotNull
                             Collection<String> heads)
        Replaces current heads with given
        Since:
        8.1
      • getHeadNames

        @NotNull
        public List<String> getHeadNames()
        Description copied from interface: CommitInfo
        Repository's current state contains a number of named commits. We name those commits 'heads' This method returns association of a commit with heads that are on the commit
        Specified by:
        getHeadNames in interface CommitInfo
        Returns:
        all head names that are on this commit
      • isIncludedByCheckoutRules

        public boolean isIncludedByCheckoutRules()
        Specified by:
        isIncludedByCheckoutRules in interface CommitInfo
        Returns:
        true if commit is not filtered by checkout rules
      • setIncludedByCheckoutRules

        public void setIncludedByCheckoutRules​(boolean isIncludedByCheckoutRules)
        Sets if this commit is included by checkout rules
        Parameters:
        isIncludedByCheckoutRules - set to true to include the commit by checkout rules
        Since:
        8.1