@Immutable public final class GtidSet extends Object
GtidSet that is immutable,
and more properly supports comparisons.| Modifier and Type | Class and Description |
|---|---|
static class |
GtidSet.Interval |
static class |
GtidSet.UUIDSet
A range of GTIDs for a single server with a specific Uuid.
|
| Modifier and Type | Field and Description |
|---|---|
private Map<String,GtidSet.UUIDSet> |
uuidSetsByServerId |
| Modifier | Constructor and Description |
|---|---|
protected |
GtidSet(Map<String,GtidSet.UUIDSet> uuidSetsByServerId) |
|
GtidSet(String gtids) |
| Modifier and Type | Method and Description |
|---|---|
boolean |
equals(Object obj) |
GtidSet.UUIDSet |
forServerWithId(String uuid)
Find the
GtidSet.UUIDSet for the server with the specified Uuid. |
GtidSet |
getGtidSetBeginning()
Returns a copy with all intervals set to beginning
|
Collection<GtidSet.UUIDSet> |
getUUIDSets()
Get an immutable collection of the
range of GTIDs for a single server. |
int |
hashCode() |
boolean |
isContainedWithin(GtidSet other)
Determine if the GTIDs represented by this object are contained completely within the supplied set of GTIDs.
|
GtidSet |
retainAll(Predicate<String> sourceFilter)
Obtain a copy of this
GtidSet except with only the GTID ranges that have server UUIDs that match the given
predicate. |
String |
toString() |
GtidSet |
with(GtidSet other)
|
private final Map<String,GtidSet.UUIDSet> uuidSetsByServerId
protected GtidSet(Map<String,GtidSet.UUIDSet> uuidSetsByServerId)
public GtidSet(String gtids)
gtids - the string representation of the GTIDs.public GtidSet retainAll(Predicate<String> sourceFilter)
GtidSet except with only the GTID ranges that have server UUIDs that match the given
predicate.sourceFilter - the predicate that returns whether a server UUID is to be includedsourceFilter is null; never nullpublic Collection<GtidSet.UUIDSet> getUUIDSets()
range of GTIDs for a single server.GTID ranges for each server; never nullpublic GtidSet.UUIDSet forServerWithId(String uuid)
GtidSet.UUIDSet for the server with the specified Uuid.uuid - the Uuid of the serverGtidSet.UUIDSet for the identified server, or null if there are no GTIDs from that server.public boolean isContainedWithin(GtidSet other)
other - the other set of GTIDs; may be nulltrue if all of the GTIDs in this set are completely contained within the supplied set of GTIDs, or
false otherwisepublic GtidSet with(GtidSet other)
GtidSet except overwritten with all of the GTID ranges in the supplied GtidSet.other - the other GtidSet with ranges to add/overwrite on top of those in this set;other is null or empty; never nullpublic GtidSet getGtidSetBeginning()
Copyright © 2020 JBoss by Red Hat. All rights reserved.