Class PrioritySorterRestriction

  • All Implemented Interfaces:
    ExtensionPoint, Describable<com.synopsys.arc.jenkinsci.plugins.jobrestrictions.restrictions.JobRestriction>, Serializable

    public class PrioritySorterRestriction
    extends com.synopsys.arc.jenkinsci.plugins.jobrestrictions.restrictions.JobRestriction
    Extends the JobRestriction from Job Restrictions Plugin making it possible to restrict Node usage based on priority.
    Since:
    3.3
    Author:
    Magnus Sandberg
    See Also:
    Serialized Form
    • Constructor Detail

      • PrioritySorterRestriction

        @DataBoundConstructor
        public PrioritySorterRestriction​(int fromPriority,
                                         int toPriority)
    • Method Detail

      • getFromPriority

        public int getFromPriority()
      • getToPriority

        public int getToPriority()
      • canTake

        public boolean canTake​(Queue.BuildableItem buildableItem)
        Specified by:
        canTake in class com.synopsys.arc.jenkinsci.plugins.jobrestrictions.restrictions.JobRestriction
      • canTake

        public boolean canTake​(Run run)
        Specified by:
        canTake in class com.synopsys.arc.jenkinsci.plugins.jobrestrictions.restrictions.JobRestriction