Class GitHubSCMSource
- java.lang.Object
-
- hudson.model.AbstractDescribableImpl<jenkins.scm.api.SCMSource>
-
- jenkins.scm.api.SCMSource
-
- com.github.kostyasha.github.integration.multibranch.GitHubSCMSource
-
- All Implemented Interfaces:
ExtensionPoint
,Describable<jenkins.scm.api.SCMSource>
public class GitHubSCMSource extends jenkins.scm.api.SCMSource
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
GitHubSCMSource.DescriptorImpl
-
Nested classes/interfaces inherited from class jenkins.scm.api.SCMSource
jenkins.scm.api.SCMSource.SourceByItem
-
Nested classes/interfaces inherited from interface hudson.ExtensionPoint
ExtensionPoint.LegacyInstancesAreScopedToHudson
-
-
Constructor Summary
Constructors Constructor Description GitHubSCMSource()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
afterSave()
SCM
build(jenkins.scm.api.SCMHead scmHead, jenkins.scm.api.SCMRevision scmRevision)
boolean
canProbe()
protected jenkins.scm.api.SCMProbe
createProbe(jenkins.scm.api.SCMHead head, jenkins.scm.api.SCMRevision revision)
List<GitHubHandler>
getHandlers()
GitHubRepo
getLocalRepo()
protected GitHubSCMSourcesLocalStorage
getLocalStorage()
String
getProjectUrlStr()
org.kohsuke.github.GHRepository
getRemoteRepo()
com.cloudbees.jenkins.GitHubRepositoryName
getRepoFullName()
GitHubRepoProvider2
getRepoProvider()
GitHubSCMFactory
getScmFactory()
jenkins.scm.api.SCMRevision
getTrustedRevision(jenkins.scm.api.SCMRevision revision, TaskListener listener)
protected boolean
isCategoryEnabled(jenkins.scm.api.SCMHeadCategory category)
Map<jenkins.scm.api.SCMHead,jenkins.scm.api.SCMRevision>
parentHeads(jenkins.scm.api.SCMHead head, TaskListener listener)
Set<jenkins.scm.api.SCMRevision>
parentRevisions(jenkins.scm.api.SCMHead head, jenkins.scm.api.SCMRevision revision, TaskListener listener)
protected Set<jenkins.scm.api.SCMHead>
retrieve(TaskListener listener)
protected jenkins.scm.api.SCMRevision
retrieve(String thingName, TaskListener listener)
protected jenkins.scm.api.SCMRevision
retrieve(jenkins.scm.api.SCMHead head, TaskListener listener)
protected Set<jenkins.scm.api.SCMHead>
retrieve(jenkins.scm.api.SCMSourceCriteria criteria, TaskListener listener)
protected void
retrieve(jenkins.scm.api.SCMSourceCriteria scmSourceCriteria, jenkins.scm.api.SCMHeadObserver scmHeadObserver, jenkins.scm.api.SCMHeadEvent<?> scmHeadEvent, TaskListener taskListener)
protected List<Action>
retrieveActions(jenkins.scm.api.SCMHead head, jenkins.scm.api.SCMHeadEvent event, TaskListener listener)
protected List<Action>
retrieveActions(jenkins.scm.api.SCMRevision revision, jenkins.scm.api.SCMHeadEvent event, TaskListener listener)
protected List<Action>
retrieveActions(jenkins.scm.api.SCMSourceEvent event, TaskListener listener)
protected Set<String>
retrieveRevisions(TaskListener listener)
GitHubSCMSource
setHandlers(List<GitHubHandler> handlers)
void
setProjectUrlStr(String projectUrlStr)
GitHubSCMSource
setRepoProvider(GitHubRepoProvider2 repoProvider)
GitHubSCMSource
setScmFactory(GitHubSCMFactory scmFactory)
-
Methods inherited from class jenkins.scm.api.SCMSource
build, checkInterrupt, defaultListener, equals, fetch, fetch, fetch, fetch, fetch, fetch, fetch, fetch, fetchActions, fetchActions, fetchActions, fetchRevisions, fetchRevisions, fromSCMFileSystem, getCategories, getCriteria, getDescriptor, getId, getOwner, getPronoun, getTraits, hashCode, hasId, newProbe, retrieve, retrieve, retrieve, retrieveRevisions, setId, setOwner, setTraits, toString, withId
-
-
-
-
Method Detail
-
getRepoFullName
public com.cloudbees.jenkins.GitHubRepositoryName getRepoFullName()
-
setProjectUrlStr
@DataBoundSetter public void setProjectUrlStr(String projectUrlStr)
-
getProjectUrlStr
public String getProjectUrlStr()
-
getRepoProvider
@CheckForNull public GitHubRepoProvider2 getRepoProvider()
-
setRepoProvider
@DataBoundSetter public GitHubSCMSource setRepoProvider(GitHubRepoProvider2 repoProvider)
-
getHandlers
public List<GitHubHandler> getHandlers()
-
setHandlers
@DataBoundSetter public GitHubSCMSource setHandlers(List<GitHubHandler> handlers)
-
getScmFactory
public GitHubSCMFactory getScmFactory()
-
setScmFactory
@DataBoundSetter public GitHubSCMSource setScmFactory(GitHubSCMFactory scmFactory)
-
getLocalRepo
public GitHubRepo getLocalRepo()
-
getLocalStorage
protected GitHubSCMSourcesLocalStorage getLocalStorage()
-
retrieve
protected void retrieve(jenkins.scm.api.SCMSourceCriteria scmSourceCriteria, @NonNull jenkins.scm.api.SCMHeadObserver scmHeadObserver, jenkins.scm.api.SCMHeadEvent<?> scmHeadEvent, @NonNull TaskListener taskListener) throws IOException, InterruptedException
- Specified by:
retrieve
in classjenkins.scm.api.SCMSource
- Throws:
IOException
InterruptedException
-
afterSave
public void afterSave()
- Overrides:
afterSave
in classjenkins.scm.api.SCMSource
-
getRemoteRepo
@NonNull public org.kohsuke.github.GHRepository getRemoteRepo() throws IOException
- Throws:
IOException
-
build
@NonNull public SCM build(@NonNull jenkins.scm.api.SCMHead scmHead, jenkins.scm.api.SCMRevision scmRevision)
- Specified by:
build
in classjenkins.scm.api.SCMSource
-
parentRevisions
@NonNull public Set<jenkins.scm.api.SCMRevision> parentRevisions(@NonNull jenkins.scm.api.SCMHead head, @NonNull jenkins.scm.api.SCMRevision revision, @CheckForNull TaskListener listener) throws IOException, InterruptedException
- Overrides:
parentRevisions
in classjenkins.scm.api.SCMSource
- Throws:
IOException
InterruptedException
-
parentHeads
@NonNull public Map<jenkins.scm.api.SCMHead,jenkins.scm.api.SCMRevision> parentHeads(@NonNull jenkins.scm.api.SCMHead head, @CheckForNull TaskListener listener) throws IOException, InterruptedException
- Overrides:
parentHeads
in classjenkins.scm.api.SCMSource
- Throws:
IOException
InterruptedException
-
retrieve
@NonNull protected Set<jenkins.scm.api.SCMHead> retrieve(@NonNull TaskListener listener) throws IOException, InterruptedException
- Overrides:
retrieve
in classjenkins.scm.api.SCMSource
- Throws:
IOException
InterruptedException
-
retrieve
@NonNull protected Set<jenkins.scm.api.SCMHead> retrieve(@CheckForNull jenkins.scm.api.SCMSourceCriteria criteria, @NonNull TaskListener listener) throws IOException, InterruptedException
- Overrides:
retrieve
in classjenkins.scm.api.SCMSource
- Throws:
IOException
InterruptedException
-
retrieve
protected jenkins.scm.api.SCMRevision retrieve(@NonNull jenkins.scm.api.SCMHead head, @NonNull TaskListener listener) throws IOException, InterruptedException
- Overrides:
retrieve
in classjenkins.scm.api.SCMSource
- Throws:
IOException
InterruptedException
-
retrieve
protected jenkins.scm.api.SCMRevision retrieve(@NonNull String thingName, @NonNull TaskListener listener) throws IOException, InterruptedException
- Overrides:
retrieve
in classjenkins.scm.api.SCMSource
- Throws:
IOException
InterruptedException
-
retrieveRevisions
@NonNull protected Set<String> retrieveRevisions(@NonNull TaskListener listener) throws IOException, InterruptedException
- Overrides:
retrieveRevisions
in classjenkins.scm.api.SCMSource
- Throws:
IOException
InterruptedException
-
retrieveActions
@NonNull protected List<Action> retrieveActions(@NonNull jenkins.scm.api.SCMRevision revision, @CheckForNull jenkins.scm.api.SCMHeadEvent event, @NonNull TaskListener listener) throws IOException, InterruptedException
- Overrides:
retrieveActions
in classjenkins.scm.api.SCMSource
- Throws:
IOException
InterruptedException
-
retrieveActions
@NonNull protected List<Action> retrieveActions(@NonNull jenkins.scm.api.SCMHead head, @CheckForNull jenkins.scm.api.SCMHeadEvent event, @NonNull TaskListener listener) throws IOException, InterruptedException
- Overrides:
retrieveActions
in classjenkins.scm.api.SCMSource
- Throws:
IOException
InterruptedException
-
retrieveActions
@NonNull protected List<Action> retrieveActions(@CheckForNull jenkins.scm.api.SCMSourceEvent event, @NonNull TaskListener listener) throws IOException, InterruptedException
- Overrides:
retrieveActions
in classjenkins.scm.api.SCMSource
- Throws:
IOException
InterruptedException
-
getTrustedRevision
@NonNull public jenkins.scm.api.SCMRevision getTrustedRevision(@NonNull jenkins.scm.api.SCMRevision revision, @NonNull TaskListener listener) throws IOException, InterruptedException
- Overrides:
getTrustedRevision
in classjenkins.scm.api.SCMSource
- Throws:
IOException
InterruptedException
-
canProbe
public boolean canProbe()
- Overrides:
canProbe
in classjenkins.scm.api.SCMSource
-
createProbe
@NonNull protected jenkins.scm.api.SCMProbe createProbe(@NonNull jenkins.scm.api.SCMHead head, @CheckForNull jenkins.scm.api.SCMRevision revision) throws IOException
- Overrides:
createProbe
in classjenkins.scm.api.SCMSource
- Throws:
IOException
-
isCategoryEnabled
protected boolean isCategoryEnabled(@NonNull jenkins.scm.api.SCMHeadCategory category)
- Overrides:
isCategoryEnabled
in classjenkins.scm.api.SCMSource
-
-