Package com.coravy.hudson.plugins.github
Class GithubProjectProperty
- java.lang.Object
-
- hudson.model.JobProperty<Job<?,?>>
-
- com.coravy.hudson.plugins.github.GithubProjectProperty
-
- All Implemented Interfaces:
ExtensionPoint
,Describable<JobProperty<?>>
,ReconfigurableDescribable<JobProperty<?>>
,BuildStep
public final class GithubProjectProperty extends JobProperty<Job<?,?>>
Stores the github related project properties.- URL to the GitHub project - Build status context name
- Author:
- Stefan Saasen
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
GithubProjectProperty.DescriptorImpl
-
Nested classes/interfaces inherited from interface hudson.tasks.BuildStep
BuildStep.PublisherList
-
Nested classes/interfaces inherited from interface hudson.ExtensionPoint
ExtensionPoint.LegacyInstancesAreScopedToHudson
-
-
Field Summary
-
Fields inherited from class hudson.model.JobProperty
owner
-
Fields inherited from interface hudson.tasks.BuildStep
BUILDERS, PUBLISHERS
-
-
Constructor Summary
Constructors Constructor Description GithubProjectProperty(String projectUrlStr)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static String
displayNameFor(Job<?,?> job)
Extracts value of display name from given job, or just returns full name if field or prop is not definedString
getDisplayName()
GithubUrl
getProjectUrl()
String
getProjectUrlStr()
Same asgetProjectUrl()
, but with a property name and type which match those used in theGithubProjectProperty(java.lang.String)
constructor.void
setDisplayName(String displayName)
-
Methods inherited from class hudson.model.JobProperty
getDescriptor, getJobAction, getJobActions, getJobOverrides, getProjectAction, getProjectActions, getRequiredMonitorService, getSubTasks, perform, prebuild, reconfigure, setOwner
-
-
-
-
Constructor Detail
-
GithubProjectProperty
@DataBoundConstructor public GithubProjectProperty(String projectUrlStr)
-
-
Method Detail
-
getProjectUrlStr
public String getProjectUrlStr()
Same asgetProjectUrl()
, but with a property name and type which match those used in theGithubProjectProperty(java.lang.String)
constructor. Should have been calledgetProjectUrl
and that method called something else (such asgetNormalizedProjectUrl
), but that cannot be done compatibly now.
-
getProjectUrl
public GithubUrl getProjectUrl()
- Returns:
- the projectUrl
-
getDisplayName
@CheckForNull public String getDisplayName()
- Since:
- 1.14.1
- See Also:
displayName
-
setDisplayName
@DataBoundSetter public void setDisplayName(String displayName)
- Since:
- 1.14.1
-
displayNameFor
public static String displayNameFor(@NonNull Job<?,?> job)
Extracts value of display name from given job, or just returns full name if field or prop is not defined- Parameters:
job
- project which wants to get current context name to use in GH status API- Returns:
- display name or full job name if field is not defined
- Since:
- 1.14.1
-
-