PacketConsumer
@ExperimentalApi
public interface PacketConsumer<T extends Object>
PacketProcessor |
A |
RecordingPacketConsumer |
A |
RenderingPacketConsumer |
A |
DefaultHardwareBufferEffectsPipeline |
A |
RecordingHardwareBufferEffectsPipeline |
Wraps a |
A consumer that accepts Packets.
This interface is experimental and will be renamed or removed in a future release.
| Parameters | |
|---|---|
<T extends Object> |
The type of Packet.payload being consumed. |
Summary
Nested types |
|---|
public fun interface PacketConsumer.Factory<T extends Object>A factory for |
public sealed interface PacketConsumer.Packet<T extends Object>Represents a packet. |
public static class PacketConsumer.Packet.EndOfStream implements PacketConsumer.PacketA |
public final class PacketConsumer.Packet.Payload<T extends Object> implements PacketConsumer.Packet |
Public methods |
|
|---|---|
abstract void |
queuePacket(@NonNull PacketConsumer.Packet<@NonNull T> packet)Queues a |
abstract void |
release()Releases all resources. |
Public methods
queuePacket
abstract void queuePacket(@NonNull PacketConsumer.Packet<@NonNull T> packet)
Queues a Packet for processing, suspending the caller if the consumer is at capacity.
Once this method returns, the ownership of the packet is transferred to this PacketConsumer, and the caller should not modify the packet.
| Parameters | |
|---|---|
@NonNull PacketConsumer.Packet<@NonNull T> packet |
The |