Package io.netty.util.internal
Class PendingWrite
java.lang.Object
io.netty.util.internal.PendingWrite
Some pending write which should be picked up later.
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final ObjectPool.Handle
<PendingWrite> private Object
private static final ObjectPool
<PendingWrite> -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionboolean
failAndRecycle
(Throwable cause) Fails the underlyingPromise
with the given cause and recycle this instance.msg()
static PendingWrite
newInstance
(Object msg, Promise<Void> promise) Create a new emptyRecyclableArrayList
instancepromise()
boolean
recycle()
Clear and recycle this instance.Recycle this instance and return thePromise
.boolean
Mark the underlyingPromise
successfully and recycle this instance.
-
Field Details
-
RECYCLER
-
handle
-
msg
-
promise
-
-
Constructor Details
-
PendingWrite
-
-
Method Details
-
newInstance
Create a new emptyRecyclableArrayList
instance -
recycle
public boolean recycle()Clear and recycle this instance. -
failAndRecycle
Fails the underlyingPromise
with the given cause and recycle this instance. -
successAndRecycle
public boolean successAndRecycle()Mark the underlyingPromise
successfully and recycle this instance. -
msg
-
promise
-
recycleAndGet
Recycle this instance and return thePromise
.
-