List of usage examples for com.google.common.collect Sets union
public static <E> SetView<E> union(final Set<? extends E> set1, final Set<? extends E> set2)
From source file:com.tesora.dve.groupmanager.SimpleMembershipView.java
@Override public Set<InetSocketAddress> allMembers() { return Sets.union(catalogRegistered, clusterReachable); }
From source file:io.mindmaps.graql.internal.query.ValuePredicateImpl.java
@Override public ValuePredicate or(ValuePredicate other) { P<Object> or = predicate.or(other.admin().getPredicate()); ImmutableSet<Object> innerUnion = ImmutableSet .copyOf(Sets.union(innerValues, other.admin().getInnerValues())); return new ValuePredicateImpl(or, "(" + repr + " or " + other.admin().toString() + ")", false, innerUnion); }
From source file:springfox.documentation.spring.web.plugins.CombinedRequestHandler.java
@Override public Set<RequestMethod> supportedMethods() { return Sets.union(first.supportedMethods(), second.supportedMethods()); }
From source file:org.eclipse.sirius.diagram.business.internal.metamodel.helper.ContainerMappingHelper.java
/** * Helper for {@link ContainerMapping#getAllNodeMappings()}. The result * should be wrapped in an appropriate EList by users. * /*from w ww . j a va 2 s . c o m*/ * @param self * the container mapping. * @return the node mappings. */ public static Collection<NodeMapping> getAllNodeMappings(ContainerMapping self) { return Sets.union(Sets.newLinkedHashSet(self.getSubNodeMappings()), Sets.newLinkedHashSet(self.getReusedNodeMappings())); }
From source file:org.jamocha.filter.PathNodeFilterSet.java
public static PathNodeFilterSet merge(final PathNodeFilterSet a, final PathNodeFilterSet b) { if (a.containsExistentials() || b.containsExistentials()) return newExistentialPathNodeFilterSet( Sets.union(a.getPositiveExistentialPaths(), b.getPositiveExistentialPaths()), Sets.union(a.getNegativeExistentialPaths(), b.getNegativeExistentialPaths()), Sets.union(a.getFilters(), b.getFilters())); return newRegularPathNodeFilterSet(Sets.union(a.getFilters(), b.getFilters())); }
From source file:org.asoem.greyfish.utils.math.ImmutableMarkovChain.java
@Override public Set<S> getStates() { return Sets.union(transitionTable.rowKeySet(), transitionTable.columnKeySet()); }
From source file:com.linecorp.armeria.common.logback.UnionMap.java
@Override public Set<Entry<K, V>> entrySet() { if (entrySet != null) { return entrySet; }// w ww. ja va 2 s . com return entrySet = Collections.unmodifiableSet(Sets.union(first.entrySet(), second.entrySet())); }
From source file:com.github.lukaszkusek.xml.comparator.comparators.children.XMLChildrenIgnoringOrderComparator.java
private Set<String> getChildrenKeysToIterate(Node node1, Node node2) { return Sets.union(node1.getChildrenXPaths(), node2.getChildrenXPaths()); }
From source file:org.sosy_lab.cpachecker.cfa.ast.c.FileLocationCollectingVisitor.java
@Override public Set<FileLocation> visit(CUnaryExpression pE) throws RuntimeException { return Sets.union(Collections.singleton(pE.getFileLocation()), pE.getOperand().accept(this)); }
From source file:org.dllearner.kb.sparql.ClassBasedSampleGenerator.java
/** * Computes a sample fragment of the knowledge base by using instances of the * given OWL class and also, if enabled, use some instances that do not belong to the class. * @param cls the OWL class//from w w w . j a v a 2 s . com * @return a sample fragment */ public OWLOntology getSample(OWLClass cls) { // get positive examples posExamples = computePosExamples(cls); // get negative examples if enabled negExamples = computeNegExamples(cls, posExamples); // compute sample based on positive (and negative) examples return getSample(Sets.union(posExamples, negExamples)); }