Package jenkins.scm.impl
Class NullSCMSource
java.lang.Object
hudson.model.AbstractDescribableImpl<SCMSource>
jenkins.scm.api.SCMSource
jenkins.scm.impl.NullSCMSource
- All Implemented Interfaces:
 ExtensionPoint,Describable<SCMSource>
- 
Nested Class Summary
Nested classes/interfaces inherited from class jenkins.scm.api.SCMSource
SCMSource.SourceByItemNested classes/interfaces inherited from interface hudson.ExtensionPoint
ExtensionPoint.LegacyInstancesAreScopedToHudson - 
Field Summary
Fields - 
Constructor Summary
Constructors - 
Method Summary
Modifier and TypeMethodDescriptionbuild(SCMHead head, SCMRevision revision) Builds aSCMinstance for the specified head and revision, no validation of the head is performed, a revision for a different head or source will be treated as equivalent to anullrevision.protected voidretrieve(SCMSourceCriteria criteria, SCMHeadObserver observer, SCMHeadEvent<?> event, TaskListener listener) SPI: Fetches the latest heads and corresponding revisions that are originating from the supplied event.Methods inherited from class jenkins.scm.api.SCMSource
afterSave, build, canProbe, checkInterrupt, createProbe, defaultListener, equals, fetch, fetch, fetch, fetch, fetch, fetch, fetch, fetch, fetchActions, fetchActions, fetchActions, fetchRevisions, fetchRevisions, fromSCMFileSystem, getCategories, getCriteria, getDescriptor, getId, getOwner, getPronoun, getTraits, getTrustedRevision, hashCode, hasId, isCategoryEnabled, newProbe, parentHeads, parentRevisions, retrieve, retrieve, retrieve, retrieve, retrieve, retrieve, retrieve, retrieveActions, retrieveActions, retrieveActions, retrieveRevisions, retrieveRevisions, setId, setOwner, setTraits, toString, withId 
- 
Field Details
- 
ID
The "magic" id of theNullSCMSource. 
 - 
 - 
Constructor Details
- 
NullSCMSource
public NullSCMSource()Constructor. 
 - 
 - 
Method Details
- 
retrieve
protected void retrieve(@CheckForNull SCMSourceCriteria criteria, @NonNull SCMHeadObserver observer, @CheckForNull SCMHeadEvent<?> event, @NonNull TaskListener listener) throws IOException, InterruptedException SPI: Fetches the latest heads and corresponding revisions that are originating from the supplied event. If the supplied event is one that the implementer trusts, then the implementer may be able to optimize retrieval to minimize round trips. Implementers are free to cache intermediary results but the call must always check the validity of any intermediary caches.It is vitally important that implementations must periodically call
SCMSource.checkInterrupt()otherwise it will be impossible for users to interrupt the operation.The default implementation wraps the
SCMHeadObserverusingSCMHeadEvent.filter(SCMSource, SCMHeadObserver)and delegates toSCMSource.retrieve(SCMSourceCriteria, SCMHeadObserver, TaskListener)- Specified by:
 retrievein classSCMSource- Parameters:
 criteria- the criteria to use, if non-nullthem implementations mustfilter allSCMHeadinstances against theSCMSourceCriteria.isHead(SCMSourceCriteria.Probe, TaskListener)before passing through to theSCMHeadObserver.observer- an observer of interim results, if the event is non-nullthen the observer will already have been filtered withSCMHeadEvent.filter(SCMSource, SCMHeadObserver).event- the (optional) event from which the operation should be scoped.listener- the task listener.- Throws:
 IOException- if an error occurs while performing the operation.InterruptedException- if any thread has interrupted the current thread.
 - 
build
Builds aSCMinstance for the specified head and revision, no validation of the head is performed, a revision for a different head or source will be treated as equivalent to anullrevision. 
 -