public class COMPRESS extends Protocol
| Modifier and Type | Class | Description |
|---|---|---|
static class |
COMPRESS.CompressHeader |
| Constructor | Description |
|---|---|
COMPRESS() |
| Modifier and Type | Method | Description |
|---|---|---|
void |
destroy() |
This method is called on a
Channel.close(). |
java.lang.Object |
down(Event evt) |
We compress the payload if it is larger than
min_size. |
java.lang.String |
getName() |
|
void |
init() |
Called after instance has been created (null constructor) and before protocol is started.
|
boolean |
setProperties(java.util.Properties props) |
Configures the protocol initially.
|
java.lang.Object |
up(Event evt) |
If there is no header, we pass the message up.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitdownThreadEnabled, dumpStats, enableStats, getDownProtocol, getProperties, getProtocolStack, getThreadFactory, getTransport, getUpProtocol, printStats, providedDownServices, providedUpServices, requiredDownServices, requiredUpServices, resetStats, setDownProtocol, setPropertiesInternal, setProtocolStack, setUpProtocol, start, statsEnabled, stop, upThreadEnabledpublic void init()
throws java.lang.Exception
Protocolpublic void destroy()
ProtocolChannel.close().
Does some cleanup; after the call the VM will terminatepublic boolean setProperties(java.util.Properties props)
Protocol"loopback=false;unicast_inport=4444"
setProperties in class Protocolpublic java.lang.Object down(Event evt)
min_size. In this case we add a header containing
the original size before compression. Otherwise we add no header.Copyright ? 1998-2008 Bela Ban. All Rights Reserved.