@Override protected Object createCollection(Class type) { return new AxisList(); } }
/** * Gets the {@link Label}s where the builds will be run. * @return never null */ public @Nonnull Set<Label> getLabels() { final Jenkins jenkins = Jenkins.getInstance(); if (jenkins == null) { return Collections.emptySet(); } Set<Label> r = new HashSet<Label>(); for (Combination c : axes.subList(LabelAxis.class).list()) r.add(jenkins.getLabel(Util.join(c.values(),"&&"))); return r; }
/** * Gets the {@link JDK}s where the builds will be run. * @return never null but can be empty */ public @Nonnull Set<JDK> getJDKs() { final Jenkins jenkins = Jenkins.getInstance(); if (jenkins == null) { return Collections.emptySet(); } Axis a = axes.find("jdk"); if(a==null) return Collections.emptySet(); Set<JDK> r = new HashSet<JDK>(); for (String j : a) { JDK jdk = jenkins.getJDK(j); if(jdk!=null) r.add(jdk); } return r; }
AxisList axes = getAxes(); if (!CollectionUtils.isEmpty(axes)) { for (Combination c : axes.list()) { String combinationFilter = getCombinationFilter(); if (c.evalGroovyExpression(axes, combinationFilter)) {
@Override public Object decode(Class targetClass, Object fromDBObject, MappedField optionalExtraInfo) { if (fromDBObject == null) return null; BasicDBList rawList = (BasicDBList) fromDBObject; AxisList axisList = new AxisList(); for (Object obj : rawList) { DBObject dbObj = (DBObject) obj; axisList.add((Axis) getMapper().fromDBObject(optionalExtraInfo.getSubClass(), dbObj, getMapper().createEntityCache())); } return axisList; }
@Override public Label getAssignedLabel() { // combine all the label axes by &&. String expr = Util.join(combination.values(getParent().getAxes().subList(LabelAxis.class)), "&&"); return Hudson.getInstance().getLabel(Util.fixEmpty(expr)); }
/** * Gets the {@link JDK}s where the builds will be run. * @return never null but can be empty */ public Set<JDK> getJDKs() { Axis a = getAxes().find("jdk"); if(a==null) return Collections.emptySet(); Set<JDK> r = new HashSet<JDK>(); for (String j : a) { JDK jdk = Hudson.getInstance().getJDK(j); if(jdk!=null) r.add(jdk); } return r; }
AxisList axes = getAxes(); if (!CollectionUtils.isEmpty(axes)) { for (Combination c : axes.list()) { String combinationFilter = getCombinationFilter(); if (c.evalScriptExpression(axes, combinationFilter)) {
@Override public Label getAssignedLabel() { // combine all the label axes by &&. String expr = Util.join(combination.values(getParent().getAxes().subList(LabelAxis.class)), "&&"); return Hudson.getInstance().getLabel(Util.fixEmpty(expr)); }
public DynamicBuildLayouter(AxisList axisList, DynamicBuild dynamicBuild) { super(axisList == null ? new AxisList() : axisList); this.axisList = axisList; this.dynamicBuild = dynamicBuild; }
/** * Gets the {@link Label}s where the builds will be run. * * @return never null */ public Set<Label> getLabels() { Set<Label> r = new HashSet<Label>(); for (Combination c : getAxes().subList(LabelAxis.class).list()) { r.add(Hudson.getInstance().getLabel(Util.join(c.values(), "&&"))); } return r; }
/** * Gets the {@link JDK}s where the builds will be run. * @return never null but can be empty */ public Set<JDK> getJDKs() { Axis a = getAxes().find("jdk"); if(a==null) return Collections.emptySet(); Set<JDK> r = new HashSet<JDK>(); for (String j : a) { JDK jdk = Hudson.getInstance().getJDK(j); if(jdk!=null) r.add(jdk); } return r; }
AxisList axes = getAxes(); if (!CollectionUtils.isEmpty(axes)) { for (Combination c : axes.list()) { String combinationFilter = getCombinationFilter(); if (c.evalScriptExpression(axes, combinationFilter)) {
@Override public Label getAssignedLabel() { // combine all the label axes by &&. String expr = Util.join(combination.values(getParent().getAxes().subList(LabelAxis.class)), "&&"); return Hudson.getInstance().getLabel(Util.fixEmpty(expr)); }
@Override public AxisList getDefaultValue() { return new AxisList(); } }