Search in sources :

Example 1 with RString

use of water.util.RString in project h2o-2 by h2oai.

the class SummaryPage2 method link.

public static String link(Key k, String content) {
    RString rs = new RString("<a href='SummaryPage2.query?source=%$key'>" + content + "</a>");
    rs.replace("key", k.toString());
    return rs.toString();
}
Also used : RString(water.util.RString)

Example 2 with RString

use of water.util.RString in project h2o-2 by h2oai.

the class Parse2 method link.

public static String link(String k, String content) {
    RString rs = new RString("<a href='Parse2.query?source_key=%key'>%content</a>");
    rs.replace("key", k.toString());
    rs.replace("content", content);
    return rs.toString();
}
Also used : RString(water.util.RString)

Example 3 with RString

use of water.util.RString in project h2o-2 by h2oai.

the class Predict method link.

public static String link(Key k, String content) {
    RString rs = new RString("<a href='Predict.query?model=%$key'>%content</a>");
    rs.replace("key", k.toString());
    rs.replace("content", content);
    return rs.toString();
}
Also used : RString(water.util.RString)

Example 4 with RString

use of water.util.RString in project h2o-2 by h2oai.

the class QuantilesPage method link.

public static String link(Key k, String content) {
    RString rs = new RString("<a href='QuantilesPage.query?source=%$key'>" + content + "</a>");
    rs.replace("key", k.toString());
    return rs.toString();
}
Also used : RString(water.util.RString)

Example 5 with RString

use of water.util.RString in project h2o-2 by h2oai.

the class RequestBuilders method buildJSONResponseBox.

protected String buildJSONResponseBox(Response response) {
    switch(response._status) {
        case done:
            RString result = new RString(_jsonResponseBox);
            result.replace("JSON_RESPONSE_BOX", response._response == null ? new String(response._req.writeJSON(new AutoBuffer()).buf()) : GSON_BUILDER.toJson(response.toJson()));
            return result.toString();
        case error:
        case redirect:
        case poll:
        default:
            return "";
    }
}
Also used : AutoBuffer(water.AutoBuffer) RString(water.util.RString) RString(water.util.RString)

Aggregations

RString (water.util.RString)30 Frame (water.fvec.Frame)3 Test (org.junit.Test)2 AutoBuffer (water.AutoBuffer)1 PrettyPrint (water.PrettyPrint)1