Class NoopBuffer

java.lang.Object
com.mewna.catnip.shard.buffer.AbstractBuffer
com.mewna.catnip.shard.buffer.NoopBuffer
All Implemented Interfaces:
EventBuffer

public class NoopBuffer extends AbstractBuffer
A no-op implementation of EventBuffer. The no-op buffer simply passes all incoming events to the event bus, without any processing or buffering (eg. for caching). This is mainly useful for the case of writing a "stateless" (ie. cacheless) bot.
Since:
9/9/18.
Author:
amy
  • Constructor Details

    • NoopBuffer

      public NoopBuffer()
  • Method Details

    • buffer

      public void buffer(com.grack.nanojson.JsonObject event)
      Description copied from interface: EventBuffer
      Buffers a single event.
      Parameters:
      event - The event to buffer.