public abstract class AbstractCompressorEngine extends NodeEngine implements Pipe.Transformer<ConvertibleNut>
This engine defines the base treatments to execute when
compressing a set of files. It could be extended by different sub-classes
which provide compression support.
The compression is never performed if the doCompression flag is set to true.
| Constructor and Description |
|---|
AbstractCompressorEngine(Boolean compress,
String rnp)
Builds a new instance.
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
canAggregateTransformedStream()
Indicates if the content generated when
Pipe.Transformer.transform(InputStream, OutputStream, Object) is called can
be aggregated to an other one. |
List<ConvertibleNut> |
internalParse(EngineRequest request)
Internal method that parses eventually called by
NodeEngine.parse(EngineRequest) method during its invocation. |
Boolean |
works()
Returns a flag indicating if the engine is configured to do something or not.
|
callNextEngine, chain, getNext, getNutTypes, getPrevious, parse, setNextcompareTo, getEngineTypeclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waittransformpublic List<ConvertibleNut> internalParse(EngineRequest request) throws WuicException
Internal method that parses eventually called by NodeEngine.parse(EngineRequest) method during its invocation.
internalParse in class Enginerequest - the request with files to parseWuicException - if any kind of error occurspublic boolean canAggregateTransformedStream()
Indicates if the content generated when Pipe.Transformer.transform(InputStream, OutputStream, Object) is called can
be aggregated to an other one. This is usually the case but won't be possible for instance when a magic
number should appears only at the beginning of the composite stream and not in each stream of the aggregation.
canAggregateTransformedStream in interface Pipe.Transformer<ConvertibleNut>true if aggregation is possible, false otherwiseCopyright © 2012-2015. All Rights Reserved.