Examples of markdownToHtml()


Examples of org.pegdown.PegDownProcessor.markdownToHtml()

        JsonNode body = request().body().asJson();
        String subjet = body.get("subject").asText();
        String mailMarkdown = body.get("mail").asText();

        PegDownProcessor pegDownProcessor = new PegDownProcessor();
        String mailHtml = pegDownProcessor.markdownToHtml(mailMarkdown);

        Set<String> mailsOfSpeakers = new HashSet<String>();

        for (Proposal proposal : Proposal.findByStatus(status,getEvent())) {
            if (proposal.getSpeaker() != null && proposal.getSpeaker().email != null) {
View Full Code Here

Examples of org.pegdown.PegDownProcessor.markdownToHtml()

    // New processor each time due to pegdown not being thread-safe internally
    PegDownProcessor processor = new PegDownProcessor();

    // Return the rendered HTML
    return processor.markdownToHtml(markdown);

  }


}
View Full Code Here

Examples of org.pegdown.PegDownProcessor.markdownToHtml()

        }
       
        long maxParsingTime = context.getConfig().getLong("markdown.maxParsingTimeInMillis", PegDownProcessor.DEFAULT_MAX_PARSING_TIME);
       
        PegDownProcessor pegdownProcessor = new PegDownProcessor(extensions, maxParsingTime);
        context.setBody(pegdownProcessor.markdownToHtml(context.getBody()));
    }
}
View Full Code Here

Examples of org.pegdown.PegDownProcessor.markdownToHtml()

            Item item = new Item();

            String statusText = tempContent.getContent();

            PegDownProcessor processor = new PegDownProcessor();
            String htmlText = processor.markdownToHtml(statusText);
            log.debug("feed html content {}", htmlText);
            // url handling  for mention & tags
            htmlText = convertLinks(htmlText);

            Content content = new Content();
View Full Code Here

Examples of org.pegdown.PegDownProcessor.markdownToHtml()

   * @return html version of markdown text
   * @throws java.text.ParseException
   */
  public static String transformMarkdown(String markdown, LinkRenderer linkRenderer) {
    PegDownProcessor pd = new PegDownProcessor(ALL & ~SMARTYPANTS);
    String html = pd.markdownToHtml(markdown, linkRenderer == null ? new LinkRenderer() : linkRenderer);
    return html;
  }
}
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.