Package fitnesse.html.template

Examples of fitnesse.html.template.HtmlPage.html()


    SimpleResponse response = new SimpleResponse();
    HtmlPage html = context.pageFactory.newPage();
    html.setMainTemplate("render.vm");
    html.put("content", new SlimRenderer());
    response.setContent(html.html());
    return response;
  }

  protected void loadPage(String pageName, FitNesseContext context) {
    WikiPagePath path = PathParser.parse(pageName);
View Full Code Here


    HtmlPage page = context.pageFactory.newPage();
    page.addTitles("Stopping tests");
    page.put("testId", testId);
    page.put("runningTestingTracker", SuiteResponder.runningTestingTracker);
    page.setMainTemplate("stopTestPage.vm");
    return page.html();
  }

  public SecureOperation getSecureOperation() {
    return new SecureTestOperation();
  }
View Full Code Here

  private String getContentAfterSpecialImportHandling() {
    HtmlPage html = new PageFactory(FitNesseUtil.makeTestContext()).newPage();
    WikiImportingResponder.handleImportProperties(html, page);
    html.setNavTemplate("wikiNav.vm");
    html.put("actions", new WikiPageActions(page));
    return html.html();
  }

}
View Full Code Here

    html.setPageTitle(new PageTitle("New Page", PathParser.parse(request.getResource())));
    html.setMainTemplate("editPage");
    makeEditForm(html, context, request);

    return html.html();
  }

  private void makeEditForm(HtmlPage html, FitNesseContext context, Request request) {
    html.put("resource", request.getResource());
View Full Code Here

    page.put("editTime", SaveRecorder.timeStamp());
    page.put("ticketId", SaveRecorder.newTicket());
    page.put("oldContent", HtmlUtil.escapeHTML(existingContent));
    page.put("newContent", newContent);
    addHiddenAttributes(page);
    return page.html();
  }


  private void addHiddenAttributes(HtmlPage page) {
    if (request.hasInput(PageData.PAGE_TYPE_ATTRIBUTE)) {
View Full Code Here

  private String getActionsHtml(String pageName) {
    WikiPageUtil.addPage(root, PathParser.parse(pageName), "");
    HtmlPage htmlPage = context.pageFactory.newPage();
    htmlPage.setNavTemplate("wikiNav.vm");
    htmlPage.put("actions", new WikiPageActions(root.getChildPage(pageName)));
    return htmlPage.html();
  }

  private void verifyDefaultLinks(String html, String pageName) {
    assertSubString("<a href=\"" + pageName + "?edit\" accesskey=\"e\">Edit</a>", html);
    assertSubString("<a href=\"" + pageName + "?versions\" accesskey=\"v\">Versions</a>", html);
View Full Code Here

    page.put("refactoredRootPage", resource);
    page.put("request", request);
    page.put("type", request.getInput("type"));
    page.put("viewLocation", request.getResource());
    SimpleResponse response = new SimpleResponse();
    response.setContent(page.html());
    return response;
  }

  public SecureOperation getSecureOperation() {
    return new AlwaysSecureOperation();
View Full Code Here

    String fullPathName = PathParser.render(page.getPageCrawler().getFullPath());
    HtmlPage html = makeHtml(fullPathName, page, context, request);

    SimpleResponse response = new SimpleResponse();
    response.setContent(html.html());

    return response;
  }

  private HtmlPage makeHtml(String name, WikiPage page, FitNesseContext context, Request request) {
View Full Code Here

    if (!testing) {
      page.put("differences", comparer.getDifferences());
      page.setMainTemplate("compareVersions");
    }
    SimpleResponse response = new SimpleResponse();
    response.setContent(page.html());
    return response;
  }
 
  private PageTitle makePageTitle(String resource) {
View Full Code Here

    html.setTitle("Delete Confirmation");
    html.setPageTitle(new PageTitle("Confirm Deletion", PathParser.parse(qualifiedPageName), tags));

    makeMainContent(html, root, qualifiedPageName);
    html.setMainTemplate("deletePage");
    return html.html();
  }

  private void makeMainContent(final HtmlPage html, final WikiPage root, final String qualifiedPageName) {
    WikiPagePath path = PathParser.parse(qualifiedPageName);
    WikiPage pageToDelete = root.getPageCrawler().getPage(path);
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.