java.util.ArrayList.containsAll()方法的使用及代码示例

x33g5p2x  于2022-01-15 转载在 其他  
字(4.6k)|赞(0)|评价(0)|浏览(217)

本文整理了Java中java.util.ArrayList.containsAll()方法的一些代码示例,展示了ArrayList.containsAll()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。ArrayList.containsAll()方法的具体详情如下:
包路径:java.util.ArrayList
类名称:ArrayList
方法名:containsAll

ArrayList.containsAll介绍

暂无

代码示例

代码示例来源:origin: ReactiveX/RxJava

@Override
public boolean containsAll(Collection<?> c) {
  return list.containsAll(c);
}

代码示例来源:origin: redisson/redisson

@Override
public boolean containsAll(Collection<?> c) {
  return list.containsAll(c);
}

代码示例来源:origin: commons-collections/commons-collections

/**
 * Return <code>true</code> if this list contains all of the elements
 * in the specified Collection.
 *
 * @param collection Collection whose elements are to be checked
 */
public boolean containsAll(Collection collection) {
  if (fast) {
    return (list.containsAll(collection));
  } else {
    synchronized (list) {
      return (list.containsAll(collection));
    }
  }
}

代码示例来源:origin: ltsopensource/light-task-scheduler

public boolean containsAll(Collection<?> c) {
  return list.containsAll(c);
}

代码示例来源:origin: ltsopensource/light-task-scheduler

public boolean containsAll(Collection<?> c) {
  return list.containsAll(c);
}

代码示例来源:origin: Sable/soot

/**
 * {@inheritDoc}
 */
public boolean containsAll(Collection c) {
 return worklist.containsAll(c);
}

代码示例来源:origin: wildfly/wildfly

/**
 * Return <code>true</code> if this list contains all of the elements
 * in the specified Collection.
 *
 * @param collection Collection whose elements are to be checked
 */
public boolean containsAll(Collection collection) {
  if (fast) {
    return (list.containsAll(collection));
  } else {
    synchronized (list) {
      return (list.containsAll(collection));
    }
  }
}

代码示例来源:origin: requery/requery

private ArrayList<Type<?>> sortTypes() {
  // sort the types in table creation order to avoid referencing not created table via a
  // reference (could also add constraints at the end but SQLite doesn't support that)
  ArrayDeque<Type<?>> queue = new ArrayDeque<>(model.getTypes());
  ArrayList<Type<?>> sorted = new ArrayList<>();
  while (!queue.isEmpty()) {
    Type<?> type = queue.poll();
    if (type.isView()) {
      continue;
    }
    Set<Type<?>> referencing = referencedTypesOf(type);
    for (Type<?> referenced : referencing) {
      Set<Type<?>> backReferences = referencedTypesOf(referenced);
      if (backReferences.contains(type)) {
        throw new CircularReferenceException("circular reference detected between "
          + type.getName() + " and " + referenced.getName());
      }
    }
    if (referencing.isEmpty() || sorted.containsAll(referencing)) {
      sorted.add(type);
      queue.remove(type);
    } else {
      queue.offer(type); // put back
    }
  }
  return sorted;
}

代码示例来源:origin: facebook/facebook-android-sdk

Set<String> permissions = request.getPermissions();
if ((currentPermissions != null) &&
    ((permissions == null) || currentPermissions.containsAll(permissions))) {

代码示例来源:origin: cloudfoundry/uaa

if (tokenScopes.isEmpty() || !tokenScopes.containsAll(requestedScopes)) {
  throw new InvalidScopeException(
      "Unable to narrow the scope of the client authentication to " + requestedScopes + ".",

代码示例来源:origin: jankotek/mapdb

if (rnd.nextBoolean()) assertIteratorExhausted(it);
assertTrue(copy.containsAll(iterated));
assertTrue(copy.containsAll(spliterated));

代码示例来源:origin: jankotek/mapdb

assertTrue(c.containsAll(rejects));
assertTrue(c.containsAll(survivors));
assertTrue(survivors.containsAll(rejects));
if (threwAt.get() == null) {
  assertEquals(n - accepts.size(), c.size());

代码示例来源:origin: jankotek/mapdb

while (it.hasNext())
  iterated.add(it.next());
assertTrue(copy.containsAll(iterated));
assertTrue(copy.containsAll(spliterated));
assertTrue(copy.containsAll(removed));
if (s.hasCharacteristics(Spliterator.CONCURRENT)) {
  ArrayList iteratedAndRemoved = new ArrayList(iterated);

代码示例来源:origin: apache/geode

ArrayList<String> resultList = (ArrayList) functionContext.getResult();
Set<String> nonAllowedKeys = functionParameter.getKeySet();
if (resultList.containsAll(nonAllowedKeys)) {
 return false;

代码示例来源:origin: voldemort/voldemort

if(!fetchedKeysForNode.containsAll(keysForNode))
  return false;
else

代码示例来源:origin: geotools/geotools

assertTrue(realValues.containsAll(Arrays.asList(values)));
assertTrue(realValues.containsAll(Arrays.asList(values)));

代码示例来源:origin: geotools/geotools

assertTrue(processedFeatureIds.containsAll(guToOccurrenceMap.keySet()));

代码示例来源:origin: geotools/geotools

assertTrue(nestedCpIds.containsAll(Arrays.asList(cpIds)));
assertTrue(nestedGuIds.containsAll(Arrays.asList(guIds)));

代码示例来源:origin: org.drools/drools-compiler

assertTrue( list.containsAll( asList( "A", "B" ) ) );
list.clear();
assertTrue( list.containsAll( asList( "B", "C" ) ) );
list.clear();

代码示例来源:origin: org.drools/drools-compiler

assertTrue( list.containsAll( asList( "A", "B" ) ) );
list.clear();

相关文章