Example #1
0
  @Override
  protected Widget createContentWidget(
      final HttpServletRequest request,
      final HttpServletResponse response,
      final HttpContext context)
      throws IOException {
    final ListWidget widgets = new ListWidget();
    widgets.add(new H1Widget(getTitle()));

    final UlWidget ul = new UlWidget();
    ul.add(cronGuiLinkFactory.history(request));
    ul.add(cronGuiLinkFactory.manage(request));
    ul.add(cronGuiLinkFactory.list(request));

    widgets.add(ul);

    return widgets;
  }
  @Override
  protected Widget createWidget(
      final HttpServletRequest request,
      final HttpServletResponse response,
      final HttpContext context)
      throws Exception {
    final ListWidget widgets = new ListWidget();

    widgets.add("completed: " + seleniumExecutionProtocol.isCompleted());
    widgets.add(new BrWidget());
    widgets.add("hasErrors: " + seleniumExecutionProtocol.hasErrors());
    widgets.add(new BrWidget());
    {
      widgets.add(new H2Widget("Messages"));
      final UlWidget ul = new UlWidget();
      for (final String message : seleniumExecutionProtocol.getMessages()) {
        ul.add(message);
      }
      widgets.add(ul);
    }
    return widgets;
  }