/** * @deprecated * Use {@link #getNodes()}. Since 1.252. */ @Deprecated public List<Slave> getSlaves() { return (List)getNodes(); }
/** * @deprecated * Use {@link #getNodes()}. Since 1.252. */ @Deprecated public List<Slave> getSlaves() { return (List)getNodes(); }
/** * Gets the slave node of the give name, hooked under this Hudson. */ public Node getNode(String name) { for (Node s : getNodes()) { if (s.getNodeName().equals(name)) { return s; } } return null; }
/** * Gets the slave node of the give name, hooked under this Hudson. */ public Node getNode(String name) { for (Node s : getNodes()) { if (s.getNodeName().equals(name)) { return s; } } return null; }
/** * Gets the slave node of the give name, hooked under this Hudson. */ public Node getNode(String name) { for (Node s : getNodes()) { if (s.getNodeName().equals(name)) { return s; } } return null; }
/** * Gets the slave node of the give name, hooked under this Hudson. */ public Node getNode(String name) { for (Node s : getNodes()) { if (s.getNodeName().equals(name)) { return s; } } return null; }
/** * Gets all the slave names. */ public List<String> get_slaveNames() { return new AbstractList<String>() { final List<Node> nodes = Hudson.getInstance().getNodes(); public String get(int index) { return nodes.get(index).getNodeName(); } public int size() { return nodes.size(); } }; }
/** * Gets all the slave names. */ public List<String> get_slaveNames() { return new AbstractList<String>() { final List<Node> nodes = Hudson.getInstance().getNodes(); public String get(int index) { return nodes.get(index).getNodeName(); } public int size() { return nodes.size(); } }; }
public List<Node> getNodes() { List<Node> nodesToCheck = getHudson().getNodes(); List<Node> nodesToReturn = new ArrayList<Node>(nodesToCheck.size()); for (hudson.model.Node node : nodesToCheck) { if (this.security.hasPermission(node, Permission.READ)) { nodesToReturn.add(node); } } return nodesToReturn; }
public List<Node> getNodes() { List<Node> nodesToCheck = getHudson().getNodes(); List<Node> nodesToReturn = new ArrayList<Node>(nodesToCheck.size()); for (hudson.model.Node node : nodesToCheck) { if (this.security.hasPermission(node, Permission.READ)) { nodesToReturn.add(node); } } return nodesToReturn; }
/** * If there's no distributed build set up, it's pointless to provide this axis. */ @Override public boolean isInstantiable() { Hudson h = Hudson.getInstance(); return !h.getNodes().isEmpty() || !h.clouds.isEmpty(); } }
/** * If there's no distributed build set up, it's pointless to provide * this axis. */ @Override public boolean isInstantiable() { Hudson h = Hudson.getInstance(); return !h.getNodes().isEmpty() || !h.clouds.isEmpty(); } }
/** * If there's no distributed build set up, it's pointless to provide this axis. */ @Override public boolean isInstantiable() { Hudson h = Hudson.getInstance(); return !h.getNodes().isEmpty() || !h.clouds.isEmpty(); } }
/** * If there's no distributed build set up, it's pointless to provide this axis. */ @Override public boolean isInstantiable() { Hudson h = Hudson.getInstance(); return !h.getNodes().isEmpty() || !h.clouds.isEmpty(); } }
public PretendSlave createPretendSlave(FakeLauncher faker) throws Exception { synchronized (hudson) { int sz = hudson.getNodes().size(); PretendSlave slave = new PretendSlave("slave" + sz, createTmpDir().getPath(), "", createComputerLauncher(null), faker); hudson.addNode(slave); return slave; } }
public PretendSlave createPretendSlave(FakeLauncher faker) throws Exception { synchronized (hudson) { int sz = hudson.getNodes().size(); PretendSlave slave = new PretendSlave("slave" + sz, createTmpDir().getPath(), "", createComputerLauncher(null), faker); hudson.addNode(slave); return slave; } }
public PretendSlave createPretendSlave(FakeLauncher faker) throws Exception { synchronized (hudson) { int sz = hudson.getNodes().size(); PretendSlave slave = new PretendSlave("slave" + sz, createTmpDir().getPath(), "", createComputerLauncher(null), faker); hudson.addNode(slave); return slave; } }
/** * Creates a slave with certain additional environment variables */ public DumbSlave createSlave(String labels, EnvVars env) throws Exception { synchronized (hudson) { // this synchronization block is so that we don't end up adding the same slave name more than once. int sz = hudson.getNodes().size(); DumbSlave slave = new DumbSlave("slave" + sz, "dummy", createTmpDir().getPath(), "1", Mode.NORMAL, labels == null ? "" : labels, createComputerLauncher(env), RetentionStrategy.NOOP, Collections.EMPTY_LIST); hudson.addNode(slave); return slave; } }
/** * Creates a slave with certain additional environment variables */ public DumbSlave createSlave(String labels, EnvVars env) throws Exception { synchronized (hudson) { // this synchronization block is so that we don't end up adding the same slave name more than once. int sz = hudson.getNodes().size(); DumbSlave slave = new DumbSlave("slave" + sz, "dummy", createTmpDir().getPath(), "1", Mode.NORMAL, labels==null?"":labels, createComputerLauncher(env), RetentionStrategy.NOOP, Collections.EMPTY_LIST); hudson.addNode(slave); return slave; } }
/** * Creates a slave with certain additional environment variables */ public DumbSlave createSlave(String labels, EnvVars env) throws Exception { synchronized (hudson) { // this synchronization block is so that we don't end up adding the same slave name more than once. int sz = hudson.getNodes().size(); DumbSlave slave = new DumbSlave("slave" + sz, "dummy", createTmpDir().getPath(), "1", Mode.NORMAL, labels==null?"":labels, createComputerLauncher(env), RetentionStrategy.NOOP, Collections.EMPTY_LIST); hudson.addNode(slave); return slave; } }