24#ifndef MYSQL_CSA_EVENT_SET_FETCHABLE_H
25#define MYSQL_CSA_EVENT_SET_FETCHABLE_H
35class Event_set_fetchable;
82 virtual void reset(
bool reset_events) = 0;
Represents metadata of a set of events, capable of being fetched from a storage.
Definition: event_set_fetchable.h:55
virtual std::optional< Managed_event > fetch_next()=0
Fetches the next event if possible.
virtual bool is_done() const =0
Checks if the event set has been fully fetched successfully.
virtual bool wait_next()=0
Waits until the next event can be fetched.
virtual ~Event_set_fetchable()=default
Sets the end of the stream if needed.
virtual bool is_trx() const =0
Checks if this event set represents a complete transaction.
std::shared_ptr< Log_event > Log_event_ptr
Definition: event_set_fetchable.h:59
virtual bool is_error() const =0
Checks if an error occurred during fetching.
virtual void reset(bool reset_events)=0
Resets the state to allow fetching the event set again, also clearing any error state.
virtual Fde_ptr get_fde()=0
Obtains non-owning pointer to current transaction FDE.
virtual void set_success()
Callback on success, default - do nothing.
Definition: event_set_fetchable.h:93
virtual const std::string & get_error_str() const =0
Retrieves the error message if an error occurred.
Definition: channel.cpp:28
std::unique_ptr< Event_set_fetchable > Event_set_fetchable_ptr
Unique pointer to a specific implementation of Event_set_fetchable (no need to share).
Definition: event_set_fetchable.h:39
std::list< Event_set_fetchable_ptr > Event_set_fetchable_list
List of Event_set_fetchable pointers, each able to fetch a whole transaction from the storage.
Definition: event_set_fetchable.h:43