public interface

MarkupService

com.atlassian.stash.markup.MarkupService

Class Overview

Renders content to markup using a pipeline of handlers, such as updating mentions and linking to JIRA issues.

Summary

Public Methods
@Nonnull String render(String content, RenderContext renderContext)
Renders a given string into HTML.
void stream(Reader reader, Appendable writer, RenderContext renderContext)
Streams a given string into HTML, appending the results to a given writer.

Public Methods

@Nonnull public String render (String content, RenderContext renderContext)

Renders a given string into HTML.

Parameters
content that should be the standard markup type
renderContext which contains data for rendering in this context
Returns
  • an HTML string
Throws
RenderException when there an error rendering the markup

public void stream (Reader reader, Appendable writer, RenderContext renderContext)

Streams a given string into HTML, appending the results to a given writer.

Parameters
reader that should be the standard markup type
writer for streaming the results
renderContext which contains data for rendering in this context
Throws
RenderException when there an error streaming the markup