@UnstableApi public class DefaultMemcacheContent extends AbstractMemcacheObject implements MemcacheContent
MemcacheContent
implementation.Constructor and Description |
---|
DefaultMemcacheContent(ByteBuf content)
Creates a new instance with the specified content.
|
Modifier and Type | Method and Description |
---|---|
ByteBuf |
content()
Return the data which is held by this
ByteBufHolder . |
MemcacheContent |
copy()
Creates a deep copy of this
ByteBufHolder . |
protected void |
deallocate()
Called once
AbstractReferenceCounted.refCnt() is equals 0. |
MemcacheContent |
duplicate()
Duplicates this
ByteBufHolder . |
MemcacheContent |
replace(ByteBuf content)
Returns a new
ByteBufHolder which contains the specified content . |
MemcacheContent |
retain()
Increases the reference count by
1 . |
MemcacheContent |
retain(int increment)
Increases the reference count by the specified
increment . |
MemcacheContent |
retainedDuplicate()
Duplicates this
ByteBufHolder . |
String |
toString() |
MemcacheContent |
touch()
Records the current access location of this object for debugging purposes.
|
MemcacheContent |
touch(Object hint)
Records the current access location of this object with an additional arbitrary information for debugging
purposes.
|
decoderResult, setDecoderResult
refCnt, release, release, setRefCnt
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
decoderResult, setDecoderResult
refCnt, release, release
public DefaultMemcacheContent(ByteBuf content)
public ByteBuf content()
ByteBufHolder
ByteBufHolder
.content
in interface ByteBufHolder
public MemcacheContent copy()
ByteBufHolder
ByteBufHolder
.copy
in interface ByteBufHolder
copy
in interface MemcacheContent
public MemcacheContent duplicate()
ByteBufHolder
ByteBufHolder
. Be aware that this will not automatically call ByteBufHolder.retain()
.duplicate
in interface ByteBufHolder
duplicate
in interface MemcacheContent
public MemcacheContent retainedDuplicate()
ByteBufHolder
ByteBufHolder
. This method returns a retained duplicate unlike ByteBufHolder.duplicate()
.retainedDuplicate
in interface ByteBufHolder
retainedDuplicate
in interface MemcacheContent
ByteBuf.retainedDuplicate()
public MemcacheContent replace(ByteBuf content)
ByteBufHolder
ByteBufHolder
which contains the specified content
.replace
in interface ByteBufHolder
replace
in interface MemcacheContent
public MemcacheContent retain()
ReferenceCounted
1
.retain
in interface ByteBufHolder
retain
in interface MemcacheContent
retain
in interface ReferenceCounted
retain
in class AbstractReferenceCounted
public MemcacheContent retain(int increment)
ReferenceCounted
increment
.retain
in interface ByteBufHolder
retain
in interface MemcacheContent
retain
in interface ReferenceCounted
retain
in class AbstractReferenceCounted
public MemcacheContent touch()
ReferenceCounted
ResourceLeakDetector
. This method is a shortcut to touch(null)
.touch
in interface ByteBufHolder
touch
in interface MemcacheContent
touch
in interface ReferenceCounted
touch
in class AbstractReferenceCounted
public MemcacheContent touch(Object hint)
ReferenceCounted
ResourceLeakDetector
.touch
in interface ByteBufHolder
touch
in interface MemcacheContent
touch
in interface ReferenceCounted
protected void deallocate()
AbstractReferenceCounted
AbstractReferenceCounted.refCnt()
is equals 0.deallocate
in class AbstractReferenceCounted
Copyright © 2008–2017 The Netty Project. All rights reserved.