public class CssResolverPipeline extends AbstractPipeline<ObjectContext<CSSResolver>>
open(WorkerContext, Tag, ProcessObject)| Modifier and Type | Field and Description |
|---|---|
static String |
CSS_RESOLVER |
| Constructor and Description |
|---|
CssResolverPipeline(CSSResolver cssResolver,
Pipeline<?> next) |
| Modifier and Type | Method and Description |
|---|---|
String |
getContextKey()
This allows the descendant classes to be fetched from the context.
|
Pipeline<?> |
init(WorkerContext context)
The init method allows implementation to initialize the pipeline.
|
Pipeline<?> |
open(WorkerContext context,
Tag t,
ProcessObject po)
Just calls getNext.
Override this to get notified on encountered opening tags. |
void |
setResolver(CSSResolver resolver)
Stores the cssResolver for the calling thread.
|
close, content, getLocalContext, getNext, setNextpublic static final String CSS_RESOLVER
public CssResolverPipeline(CSSResolver cssResolver, Pipeline<?> next)
next - the next pipeline.cssResolver - the CSSResolver to use in this Pipeline, it
will be stored in a ThreadLocal variable.public String getContextKey()
getContextKey in class AbstractPipeline<ObjectContext<CSSResolver>>getClass().getName() as name.public Pipeline<?> init(WorkerContext context) throws PipelineException
PipelineWorkerContext.put(String, CustomContext).init in interface Pipeline<ObjectContext<CSSResolver>>init in class AbstractPipeline<ObjectContext<CSSResolver>>context - the WorkerContextPipelineException - can be thrown to indicate that something went wrong.public Pipeline<?> open(WorkerContext context, Tag t, ProcessObject po) throws PipelineException
AbstractPipelineopen in interface Pipeline<ObjectContext<CSSResolver>>open in class AbstractPipeline<ObjectContext<CSSResolver>>context - the WorkerContextt - the Tagpo - a processObject to put Writables inPipelineException - can be thrown to indicate that something went wrong.public void setResolver(CSSResolver resolver)
resolver - the CSSResolver to use.Copyright © 2019. All rights reserved.