Jive Forums API (5.5.20.2-oracle) Developer Javadocs

com.jivesoftware.forum.renderer
Class RenderStrategy

java.lang.Object
  extended by com.jivesoftware.forum.renderer.RenderStrategy

public class RenderStrategy
extends java.lang.Object

A RenderStrategy allows for the coarse grained ability to determine what will be rendered by a particular render call irregardless of what filters are included. Filters and macros are required to respect the RenderStrategy and only transform text into html (or html into text) allowed by the strategy.

A RenderStrategy consists of both a RenderTarget and a set of flags to determine what is to be rendered and what isn't. Filters and macros should determine how the are to render/unrender content as appropriate to the given target and flags. For example, given a target of RenderTarget.TARGET_WYSIWYG_EDITOR and the RENDER_ALL flag macro's should only render html output if they are able to also unrender that html back into wiki markup. Otherwise, the macro should just output it's wiki markup.


Field Summary
static RenderStrategy NO_MARKUP_STRATEGY
          A render stragegy used to render text without any markup
static long RENDER_ALL
          Use this render flag to enable the rendering of all links, tables, images, lists, macros and text decorations.
static long RENDER_IMAGES
          Use this render flag to render images.
static long RENDER_LINKS
          Use this render flag to render links.
static long RENDER_LISTS
          Use this render flag to render lists.
static long RENDER_MACROS
          Use this render flag to render macros.
static long RENDER_TABLES
          Use this render flag to render tables.
static long RENDER_TEXT_DECORATION
          Use this render flag to render text decorations.
 
Constructor Summary
RenderStrategy()
           
RenderStrategy(RenderTarget target, long flags)
           
 
Method Summary
 void exclude(long flags)
           
 RenderTarget getTarget()
           
 void include(long flags)
           
 boolean renderImages()
           
 boolean renderLinks()
           
 boolean renderLists()
           
 boolean renderMacros()
           
 boolean renderTables()
           
 boolean renderTextDecoration()
           
 void setTarget(RenderTarget target)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

RENDER_ALL

public static final long RENDER_ALL
Use this render flag to enable the rendering of all links, tables, images, lists, macros and text decorations.

See Also:
Constant Field Values

RENDER_LINKS

public static final long RENDER_LINKS
Use this render flag to render links.

See Also:
Constant Field Values

RENDER_TABLES

public static final long RENDER_TABLES
Use this render flag to render tables.

See Also:
Constant Field Values

RENDER_IMAGES

public static final long RENDER_IMAGES
Use this render flag to render images.

See Also:
Constant Field Values

RENDER_LISTS

public static final long RENDER_LISTS
Use this render flag to render lists.

See Also:
Constant Field Values

RENDER_MACROS

public static final long RENDER_MACROS
Use this render flag to render macros.

See Also:
Constant Field Values

RENDER_TEXT_DECORATION

public static final long RENDER_TEXT_DECORATION
Use this render flag to render text decorations.

See Also:
Constant Field Values

NO_MARKUP_STRATEGY

public static final RenderStrategy NO_MARKUP_STRATEGY
A render stragegy used to render text without any markup

Constructor Detail

RenderStrategy

public RenderStrategy()

RenderStrategy

public RenderStrategy(RenderTarget target,
                      long flags)
Method Detail

getTarget

public RenderTarget getTarget()

setTarget

public void setTarget(RenderTarget target)

renderLinks

public boolean renderLinks()

renderTables

public boolean renderTables()

renderImages

public boolean renderImages()

renderLists

public boolean renderLists()

renderMacros

public boolean renderMacros()

renderTextDecoration

public boolean renderTextDecoration()

include

public void include(long flags)

exclude

public void exclude(long flags)

Jive Forums Project Page

Copyright © 1999-2006 Jive Software.