public static void jsonTrace(String id) { if (id == null || !id.matches("[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}")) notFound("trace with id '" + id + "'"); String trace = TraceService.loadSavedTrace(id); response.contentType = "text/json"; renderTemplate("Traces/jsonTrace.json", trace); }
public static void show(String id) { if (id == null || !id.matches("[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}")) notFound("trace with id '" + id + "'"); String trace = TraceService.loadSavedTrace(id); render(id, trace); }
public static void list() { Collection<String> list = TraceService.list(); render(list); }