public final class InstancesDiff.InstanceCollection
extends java.lang.Object
InstanceCollection
collection allows to filter the instances using a set of custom filter
either implementing InstanceFilter
or pre-defined ones.Filters conditions are joined combined together using the logical operator "AND".
Modifier and Type | Method and Description |
---|---|
InstancesDiff.InstanceCollection |
filterWith(InstanceFilter filter)
Filter the instances with a custom
InstanceFilter filter. |
java.util.Collection<InstanceDescription> |
get()
Return the collection of
InstanceDescription instances that have not been filtered out. |
InstancesDiff.InstanceCollection |
isInClusterView(ClusterView clusterView)
Keep only the instances that are contained in the same
ClusterView cluster view
as the one provided. |
InstancesDiff.InstanceCollection |
isLeader()
Keep only the leader instances (see
InstanceDescription.isLeader() . |
InstancesDiff.InstanceCollection |
isLocal()
Keep only the local instance (see
InstanceDescription.isLocal() . |
InstancesDiff.InstanceCollection |
isNotInClusterView(ClusterView clusterView)
Filter out the instances that are contained in the same
ClusterView cluster view
as the one provided. |
InstancesDiff.InstanceCollection |
isNotLeader()
Filter out the leader instances (see
InstanceDescription.isLeader() . |
InstancesDiff.InstanceCollection |
isNotLocal()
Filter out the local instances (see
InstanceDescription.isLocal() . |
public InstancesDiff.InstanceCollection filterWith(InstanceFilter filter)
InstanceFilter
filter.filter
- the filter to be applied on the instancesthis
public InstancesDiff.InstanceCollection isLocal()
InstanceDescription.isLocal()
.this
public InstancesDiff.InstanceCollection isNotLocal()
InstanceDescription.isLocal()
.this
public InstancesDiff.InstanceCollection isLeader()
InstanceDescription.isLeader()
.this
public InstancesDiff.InstanceCollection isNotLeader()
InstanceDescription.isLeader()
.this
public InstancesDiff.InstanceCollection isInClusterView(ClusterView clusterView)
ClusterView
cluster view
as the one provided.The comparison between cluster views is done on the basis of the cluster view identifier. Two cluster views with the same identifier are considered equal.
clusterView
- the cluster view used to filter the instancesthis
public InstancesDiff.InstanceCollection isNotInClusterView(ClusterView clusterView)
ClusterView
cluster view
as the one provided.The comparison between cluster views is done on the basis of the cluster view identifier. Two cluster views with the same identifier are considered equal.
clusterView
- the cluster view used to filter the instancesthis
public java.util.Collection<InstanceDescription> get()
InstanceDescription
instances that have not been filtered out."Copyright © 2010 - 2020 Adobe Systems Incorporated. All Rights Reserved"