Package io.netty.channel
Interface AddressedEnvelope<M,A extends java.net.SocketAddress>
-
- Type Parameters:
M
- the type of the wrapped messageA
- the type of the address
- All Superinterfaces:
ReferenceCounted
- All Known Implementing Classes:
DatagramDnsQuery
,DatagramDnsResponse
,DatagramPacket
,DefaultAddressedEnvelope
,DomainDatagramPacket
,SegmentedDatagramPacket
,SegmentedDatagramPacket
public interface AddressedEnvelope<M,A extends java.net.SocketAddress> extends ReferenceCounted
A message that wraps another message with a sender address and a recipient address.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description M
content()
Returns the message wrapped by this envelope message.A
recipient()
Returns the address of the recipient of this message.AddressedEnvelope<M,A>
retain()
Increases the reference count by1
.AddressedEnvelope<M,A>
retain(int increment)
Increases the reference count by the specifiedincrement
.A
sender()
Returns the address of the sender of this message.AddressedEnvelope<M,A>
touch()
Records the current access location of this object for debugging purposes.AddressedEnvelope<M,A>
touch(java.lang.Object hint)
Records the current access location of this object with an additional arbitrary information for debugging purposes.-
Methods inherited from interface io.netty.util.ReferenceCounted
refCnt, release, release
-
-
-
-
Method Detail
-
content
M content()
Returns the message wrapped by this envelope message.
-
sender
A sender()
Returns the address of the sender of this message.
-
recipient
A recipient()
Returns the address of the recipient of this message.
-
retain
AddressedEnvelope<M,A> retain()
Description copied from interface:ReferenceCounted
Increases the reference count by1
.- Specified by:
retain
in interfaceReferenceCounted
-
retain
AddressedEnvelope<M,A> retain(int increment)
Description copied from interface:ReferenceCounted
Increases the reference count by the specifiedincrement
.- Specified by:
retain
in interfaceReferenceCounted
-
touch
AddressedEnvelope<M,A> touch()
Description copied from interface:ReferenceCounted
Records the current access location of this object for debugging purposes. If this object is determined to be leaked, the information recorded by this operation will be provided to you viaResourceLeakDetector
. This method is a shortcut totouch(null)
.- Specified by:
touch
in interfaceReferenceCounted
-
touch
AddressedEnvelope<M,A> touch(java.lang.Object hint)
Description copied from interface:ReferenceCounted
Records the current access location of this object with an additional arbitrary information for debugging purposes. If this object is determined to be leaked, the information recorded by this operation will be provided to you viaResourceLeakDetector
.- Specified by:
touch
in interfaceReferenceCounted
-
-