Copy of {@link io.grpc.internal.ServiceConfigUtil#checkObjectList}.
511541
@SuppressWarnings("unchecked")
  private static List<Map<String, ?>> checkObjectList(List<?> rawList) {
    for (int i = 0; i < rawList.size(); i++) {
      if (!(rawList.get(i) instanceof Map)) {
        throw new ClassCastException(
            String.format("value %s for idx %d in %s is not object", rawList.get(i), i, rawList));
      }
    }
    return (List<Map<String, ?>>) rawList;
  }
129368
public String serializeFilterList(List<Filter> list) {
        ObjectMapper om = getObjectMapper();
        try {
            return om.writeValueAsString(new ListWrappers.FilterList(list));
        } catch (Exception e) {
            throw new RuntimeException(e);
        }
    }
1009748
public boolean checkService(String serviceName, String methodName) {
        Invoker invoker = invokerMap.get(serviceName);
        return invoker instanceof ProviderProxyInvoker && getMethod(serviceName, methodName) != null;
    }
113310
@Nullable
    private boolean[] getCheckedItems() {
        if (listView != null && adapter != null) {
            boolean[] result = new boolean[adapter.getItemCount()];

            for (int i = 0; i < result.length; i++) {
                result[i] = adapter.isItemChecked(i);
            }

            return result;
        } else {
            return checkedItems;
        }
    }
849226
public static <T /*>>> extends @NonNull Object*/> void checkListElementNotNull(
      List<T> list, @javax.annotation.Nullable Object errorMessage) {
    for (T element : list) {
      if (element == null) {
        throw new NullPointerException(String.valueOf(errorMessage));
      }
    }
  }
880248
private void checkSuccess(Message response) throws JdbcServerException {
        OperationResult operationResult = null;
        if (response instanceof JdbcMessage || response.getPayload() instanceof OperationResult) {
            operationResult = response.getPayload(OperationResult.class);
        } else if (response.getPayload() != null && StringUtils.hasText(response.getPayload(String.class))) {
            operationResult = (OperationResult) endpointConfiguration.getMarshaller().unmarshal(new StringSource(response.getPayload(String.class)));
        }

        if (!success(response, operationResult)) {
            throw new JdbcServerException(getExceptionMessage(response, operationResult));
        }
    }
705637
public String serializeConditionList(List<Condition> list) {
        ObjectMapper om = getObjectMapper();
        try {
            return om.writeValueAsString(new ListWrappers.ConditionList(list));
        } catch (Exception e) {
            throw new RuntimeException(e);
        }
    }
392537
@SuppressWarnings("unchecked")
    private <E extends R> List<E> getReadyObjectList(final UniqueKey<E> uniqueKey) {

        List<E> readyObjectList = null;
        synchronized (this.componentMap) {
            // retrieve the component from the singleton map
            // It the component is already registered, get it to return it
            if (exists(uniqueKey)) {

                readyObjectList = new ArrayList<>((Set<E>) this.componentMap.get(uniqueKey));

                // // Check that the reference is not null
                // if (weakHashSet != null) {
                // // If no key is provided retrieve from the singleton map
                // // Extract the value from the weak reference
                // readyObject = (E) weakHashSet.get();
                // }
            }
        }
        return readyObjectList;
    }
610277
@Override
    public List<String> getManagedObjects() {
        ArrayList<String> managedObjects = new ArrayList<String>();
        if (this.application != null) {
            managedObjects.addAll(application.getManagedObjects());
        }
        if (this.factory != null) {
            managedObjects.addAll(factory.getManagedObjects());
        }
        if (this.lifecycle != null) {
            managedObjects.addAll(lifecycle.getManagedObjects());
        }
        return managedObjects;
    }
524478
public String serializeDataActionList(List<DataAction> list) {
        ObjectMapper om = getObjectMapper();
        try {
            return om.writeValueAsString(new ListWrappers.DataActionList(list));
        } catch (Exception e) {
            throw new RuntimeException(e);
        }
    }
32171
private void gc() {
    if ((services != null && services.isConnected()) && debugger != null) {
      debugger.releaseObjects();
    }
    objectIds.clear();
  }
1109891
@Override
    public Rankable copy() {
        List<Object> shallowCopyOfFields = ImmutableList.copyOf(getFields());
        return new RankableObjectWithFields(getObject(), getCount(), shallowCopyOfFields);
    }
786119
@Override
  public Collection<Monitor<?>> getRegisteredMonitors() {
    if (updatePending.getAndSet(false)) {
      monitorList.set(UnmodifiableList.copyOf(monitors.values()));
    }
    return monitorList.get();
  }
689111
public List<Object> match() {
        final IntMatchResults result = new IntMatchResults();
        if (matches(result)) {
            return result.getIntResultList();
        } else {
            return null;
        }
    }
1141038
static boolean equalsImpl(List<?> list, @Nullable Object object) {
    if (object == checkNotNull(list)) {
      return true;
    }
    if (!(object instanceof List)) {
      return false;
    }

    List<?> o = (List<?>) object;

    return list.size() == o.size()
        && Iterators.elementsEqual(list.iterator(), o.iterator());
  }
654243
private static <T> boolean containsIdentity(List<T> list, T object) {
		for (T item : list) {
			if (item == object) {
				return true;
			}
		}
		return false;
	}
397969
public static <OriginObject, TargetObject> List<TargetObject> copyList(List<OriginObject> originObjects, Class<TargetObject> targetClass) {

        if (originObjects == null) {
            return null;
        }

        //参数不合法异常
        if (targetClass == null) {
            throw new IllegalArgumentException("targetClass can't be null");
        }
        List<TargetObject> targetObjects = new ArrayList<TargetObject>();
        for (OriginObject originObject : originObjects) {
            targetObjects.add(copy(originObject, targetClass));
        }
        return targetObjects;
    }