Class HookRegistrationTrait
java.lang.Object
hudson.model.AbstractDescribableImpl<T>
jenkins.scm.api.trait.SCMTrait<jenkins.scm.api.trait.SCMSourceTrait>
jenkins.scm.api.trait.SCMSourceTrait
io.jenkins.plugins.gitlabbranchsource.HookRegistrationTrait
- All Implemented Interfaces:
ExtensionPoint,Describable<jenkins.scm.api.trait.SCMSourceTrait>
public class HookRegistrationTrait
extends jenkins.scm.api.trait.SCMSourceTrait
A
SCMSourceTrait for GitLabSCMSource that overrides the GitLabServers
settings for web hook and system hook registration.-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic classOur constructor.Nested classes/interfaces inherited from interface hudson.ExtensionPoint
ExtensionPoint.LegacyInstancesAreScopedToHudson -
Constructor Summary
ConstructorsConstructorDescriptionHookRegistrationTrait(GitLabHookRegistration webHookMode, GitLabHookRegistration systemHookMode) Constructor.HookRegistrationTrait(String webHookMode, String systemHookMode) Constructor. -
Method Summary
Modifier and TypeMethodDescriptionprotected voiddecorateContext(jenkins.scm.api.trait.SCMSourceContext<?, ?> context) final GitLabHookRegistrationGets the system hook mode of registration to apply.final GitLabHookRegistrationGets the web hook mode of registration to apply.Methods inherited from class jenkins.scm.api.trait.SCMSourceTrait
_for, _for, all, applyToBuilder, applyToContext, applyToObserver, decorateBuilder, decorateObserver, getDescriptor, includeCategory, isCategoryEnabledMethods inherited from class jenkins.scm.api.trait.SCMTrait
asSetList, asSetList, find
-
Constructor Details
-
HookRegistrationTrait
@DataBoundConstructor public HookRegistrationTrait(@NonNull String webHookMode, @NonNull String systemHookMode) Constructor.- Parameters:
webHookMode- the web hook mode of registration to apply.systemHookMode- the system hook mode of registration to apply.
-
HookRegistrationTrait
public HookRegistrationTrait(@NonNull GitLabHookRegistration webHookMode, @NonNull GitLabHookRegistration systemHookMode) Constructor.- Parameters:
webHookMode- the web hook mode of registration to apply.systemHookMode- the system hook mode of registration to apply.
-
-
Method Details
-
getWebHookMode
Gets the web hook mode of registration to apply.- Returns:
- the web hook mode of registration to apply.
-
getSystemHookMode
Gets the system hook mode of registration to apply.- Returns:
- the system hook mode of registration to apply.
-
decorateContext
protected void decorateContext(jenkins.scm.api.trait.SCMSourceContext<?, ?> context) - Overrides:
decorateContextin classjenkins.scm.api.trait.SCMSourceTrait
-