<commit_before>package hudson.model;

import hudson.model.Descriptor.FormException;
import hudson.node_monitors.NodeMonitor;
import org.kohsuke.stapler.StaplerRequest;
import org.kohsuke.stapler.StaplerResponse;

import java.util.ArrayList;
import java.util.Collections;
import java.util.List;
import java.io.IOException;

/**
 * Serves as the top of {@link Computer}s in the URL hierarchy.
 * <p>
 * Getter methods are prefixed with '_' to avoid collision with computer names.
 * 
 * @author <NAME>
 */
public final class ComputerSet implements ModelObject {
    private static volatile List<NodeMonitor> monitors = Collections.emptyList();

    public ComputerSet() {
        if(monitors.isEmpty()) {
            // create all instances when requested for the first time.
            ArrayList<NodeMonitor> r = new ArrayList<NodeMonitor>();
            for (Descriptor<NodeMonitor> d : NodeMonitor.LIST)
                try {
                    r.add(d.newInstance(null,null));
                } catch (FormException e) {
                    // so far impossible. TODO: report
                }
            monitors = r;
        }
    }

    public String getDisplayName() {
        return "nodes";
    }

    public List<NodeMonitor> get_monitors() {
        return monitors;
    }

    public Computer[] get_all() {
        return Hudson.getInstance().getComputers();
    }

    public Computer getDynamic(String token, StaplerRequest req, StaplerResponse rsp) {
        return Hudson.getInstance().getComputer(token);
    }

    public void do_launchAll(StaplerRequest req, StaplerResponse rsp) throws IOException {
        for(Computer c : get_all()) {
            if(c.isJnlpAgent())
                continue;
            c.launch();
        }
        rsp.sendRedirect(".");
    }
}<commit_msg>this can be static<commit_after>package hudson.model;

import hudson.model.Descriptor.FormException;
import hudson.node_monitors.NodeMonitor;
import org.kohsuke.stapler.StaplerRequest;
import org.kohsuke.stapler.StaplerResponse;

import java.util.ArrayList;
import java.util.Collections;
import java.util.List;
import java.io.IOException;

/**
 * Serves as the top of {@link Computer}s in the URL hierarchy.
 * <p>
 * Getter methods are prefixed with '_' to avoid collision with computer names.
 * 
 * @author <NAME>
 */
public final class ComputerSet implements ModelObject {
    private static volatile List<NodeMonitor> monitors = Collections.emptyList();

    public ComputerSet() {
        if(monitors.isEmpty()) {
            // create all instances when requested for the first time.
            ArrayList<NodeMonitor> r = new ArrayList<NodeMonitor>();
            for (Descriptor<NodeMonitor> d : NodeMonitor.LIST)
                try {
                    r.add(d.newInstance(null,null));
                } catch (FormException e) {
                    // so far impossible. TODO: report
                }
            monitors = r;
        }
    }

    public String getDisplayName() {
        return "nodes";
    }

    public static List<NodeMonitor> get_monitors() {
        return monitors;
    }

    public Computer[] get_all() {
        return Hudson.getInstance().getComputers();
    }

    public Computer getDynamic(String token, StaplerRequest req, StaplerResponse rsp) {
        return Hudson.getInstance().getComputer(token);
    }

    public void do_launchAll(StaplerRequest req, StaplerResponse rsp) throws IOException {
        for(Computer c : get_all()) {
            if(c.isJnlpAgent())
                continue;
            c.launch();
        }
        rsp.sendRedirect(".");
    }
}
{'fraction_non_alphanumeric': 0.09955752212389381, 'fraction_numerical': 0.0, 'mean_word_length': 2.448045757864633, 'pattern_counts': {'":': 0, '<': 17, '<?xml version=': 0, '>': 17, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '7313352', 'n_tokens_mistral': 1021, 'n_tokens_neox': 959, 'n_words': 258}