Package io.debezium.connector.mysql
Interface GtidSet
- All Known Implementing Classes:
MariaDbGtidSet
,MySqlGtidSet
public interface GtidSet
Represents a common contract for GTID behavior for MySQL and MariaDB.
- Author:
- Randall Hauch, Chris Cranford
-
Method Summary
Modifier and TypeMethodDescriptionboolean
Return whether the specified GTID is present in this set.Returns a copy of this with all intervals set to the beginning.boolean
isContainedWithin
(GtidSet other) Determine whether the GTIDs represented by this object are contained completely within the supplied set.boolean
isEmpty()
Returns whether thisGtidSet
is empty.Obtain a copy of thisGtidSet
except with only the GTID ranges match the specified predicate.Subtracts the two GTID sets.
-
Method Details
-
isEmpty
boolean isEmpty()Returns whether thisGtidSet
is empty. -
retainAll
Obtain a copy of thisGtidSet
except with only the GTID ranges match the specified predicate.- Parameters:
sourceFilter
- the predicate that returns whether a server identifier is to be included- Returns:
- the new GtidSet, or this object if
sourceFilter
is null; never null
-
isContainedWithin
Determine whether the GTIDs represented by this object are contained completely within the supplied set.- Parameters:
other
- the other set of GTIDs; may be null- Returns:
true
if all GTIDs are present in the provided set,false
otherwise
-
with
-
getGtidSetBeginning
GtidSet getGtidSetBeginning()Returns a copy of this with all intervals set to the beginning. -
contains
Return whether the specified GTID is present in this set.- Parameters:
gtid
- the gtid to check; may not be null- Returns:
true
if contained by this set,false
otherwise
-
subtract
Subtracts the two GTID sets.- Parameters:
other
- ther other set; may be null- Returns:
- a new
GtidSet
that contains the difference in GTIDs
-