|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.milyn.delivery.Filter
public abstract class Filter
Content filter.
| Nested Class Summary | |
|---|---|
static class |
Filter.StreamFilterType
Filter type enumeration. |
| Field Summary | |
|---|---|
static String |
CLOSE_RESULT
|
static String |
CLOSE_SOURCE
|
static String |
DEFAULT_SERIALIZATION_ON
|
static String |
REVERSE_VISIT_ORDER_ON_VISIT_AFTER
|
static String |
STREAM_FILTER_TYPE
Stream filter type config parameter. |
static String |
TERMINATE_ON_VISITOR_EXCEPTION
|
| Constructor Summary | |
|---|---|
Filter()
|
|
| Method Summary | |
|---|---|
abstract void |
cleanup()
Cleanup the Filter. |
protected void |
close(Result result)
|
protected void |
close(Source source)
|
abstract void |
doFilter(Source source,
Result result)
Filter the content in the supplied Source instance, outputing the result
to the supplied Result instance. |
static ExecutionContext |
getCurrentExecutionContext()
Get the ExecutionContext instance bound to the current thread. |
static Filter |
getFilter()
Get the Filter instance for the current thread. |
protected Reader |
getReader(Source source,
ExecutionContext executionContext)
|
protected Writer |
getWriter(Result result,
ExecutionContext executionContext)
|
static void |
removeCurrentExecutionContext()
Remove the ExecutionContext bound to the current thread. |
static void |
removeCurrentFilter()
Remove the Filter bound to the current thread. |
static void |
setCurrentExecutionContext(ExecutionContext executionContext)
Set the ExecutionContext instance for the current thread. |
static void |
setFilter(Filter filter)
Set the Filter instance for the current thread. |
static void |
setFilterType(Smooks smooks,
Filter.StreamFilterType filterType)
Set the default stream filter type on the supplied Smooks instance. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final String STREAM_FILTER_TYPE
public static final String CLOSE_SOURCE
public static final String CLOSE_RESULT
public static final String DEFAULT_SERIALIZATION_ON
public static final String REVERSE_VISIT_ORDER_ON_VISIT_AFTER
public static final String TERMINATE_ON_VISITOR_EXCEPTION
| Constructor Detail |
|---|
public Filter()
| Method Detail |
|---|
public abstract void doFilter(Source source,
Result result)
throws SmooksException
Source instance, outputing the result
to the supplied Result instance.
source - The content Source.result - The content Result. To serialize the result, supply a StreamResult.
To have the result returned as a DOM, supply a DOMResult.
SmooksException - Failed to filter.public abstract void cleanup()
public static void setFilterType(Smooks smooks,
Filter.StreamFilterType filterType)
smooks - The Smooks instance.filterType - The filter type.public static Filter getFilter()
Filter instance for the current thread.
Filter instance.public static void setFilter(Filter filter)
Filter instance for the current thread.
filter - The thread-bound Filter instance.public static void removeCurrentFilter()
Filter bound to the current thread.
public static ExecutionContext getCurrentExecutionContext()
ExecutionContext instance bound to the current thread.
ExecutionContext instance.public static void setCurrentExecutionContext(ExecutionContext executionContext)
ExecutionContext instance for the current thread.
executionContext - The thread-bound ExecutionContext instance.public static void removeCurrentExecutionContext()
ExecutionContext bound to the current thread.
protected Reader getReader(Source source,
ExecutionContext executionContext)
protected Writer getWriter(Result result,
ExecutionContext executionContext)
protected void close(Source source)
protected void close(Result result)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||