Class GitHubTagDecisionContext
- java.lang.Object
-
- com.github.kostyasha.github.integration.generic.GitHubDecisionContext<GitHubTagEvent,GitHubTagCause>
-
- com.github.kostyasha.github.integration.generic.GitHubTagDecisionContext
-
public class GitHubTagDecisionContext extends GitHubDecisionContext<GitHubTagEvent,GitHubTagCause>
- Author:
- Kanstantsin Shautsou
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
GitHubTagDecisionContext.Builder
-
Constructor Summary
Constructors Constructor Description GitHubTagDecisionContext(org.kohsuke.github.GHTag remoteTag, GitHubTag localTag, GitHubTagRepository localRepo, GitHubTagHandler tagHandler, GitHubSCMSource scmSource, TaskListener listener)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description GitHubTagCause
checkEvent(GitHubTagEvent event)
GitHubTagHandler
getHandler()
GitHubTagRepository
getLocalRepo()
GitHubTag
getLocalTag()
org.kohsuke.github.GHTag
getRemoteTag()
GitHubTagCause
newCause(String reason, boolean skip)
static GitHubTagDecisionContext.Builder
newGitHubTagDecisionContext()
-
Methods inherited from class com.github.kostyasha.github.integration.generic.GitHubDecisionContext
getListener, getRemoteRepository, getScmSource, getTrigger
-
-
-
-
Constructor Detail
-
GitHubTagDecisionContext
public GitHubTagDecisionContext(org.kohsuke.github.GHTag remoteTag, GitHubTag localTag, @NonNull GitHubTagRepository localRepo, GitHubTagHandler tagHandler, GitHubSCMSource scmSource, TaskListener listener)
-
-
Method Detail
-
getRemoteTag
@CheckForNull public org.kohsuke.github.GHTag getRemoteTag()
- Returns:
- current tag state fetched from GH.
-
getLocalTag
@CheckForNull public GitHubTag getLocalTag()
- Returns:
- tag state from last run saved in jenkins. null when not exist before.
-
getLocalRepo
@NonNull public GitHubTagRepository getLocalRepo()
- Returns:
- local repository state. Useful to extract repo URLs for example.
-
getHandler
public GitHubTagHandler getHandler()
- Overrides:
getHandler
in classGitHubDecisionContext<GitHubTagEvent,GitHubTagCause>
-
checkEvent
public GitHubTagCause checkEvent(GitHubTagEvent event) throws IOException
- Specified by:
checkEvent
in classGitHubDecisionContext<GitHubTagEvent,GitHubTagCause>
- Throws:
IOException
-
newCause
public GitHubTagCause newCause(String reason, boolean skip)
- Specified by:
newCause
in classGitHubDecisionContext<GitHubTagEvent,GitHubTagCause>
-
newGitHubTagDecisionContext
@NonNull public static GitHubTagDecisionContext.Builder newGitHubTagDecisionContext()
-
-