Returns an empty array of child maps.
504542
@SuppressWarnings("unchecked") // Empty array is safe to cast.
  private static <K, V> HamtPMap<K, V>[] emptyChildren() {
    return (HamtPMap<K, V>[]) EMPTY_CHILDREN;
  }
113844
public String[] getChildNames() {
	if (children == null || children.size() == 0) return EMPTY_NAMES;
	String[] arr = new String[children.size()];
	for (int i = 0; i < arr.length; i++) {
	    arr[i] = ((RamResourceCore) children.get(i)).getName();
	}
	return arr;
    }
1281449
@SuppressWarnings("unchecked")
	protected Map<String, Object> getNestedMap(Map<String, Object> map, String key) {
		Object value = map.get(key);
		if (value == null) {
			return Collections.emptyMap();
		}
		return (Map<String, Object>) value;
	}
627243
public PackageInfoList getChildren() {
        if (children == null) {
            return PackageInfoList.EMPTY_LIST;
        }
        final PackageInfoList childrenSorted = new PackageInfoList(children);
        // Ensure children are sorted
        CollectionUtils.sortIfNotEmpty(childrenSorted, new Comparator<PackageInfo>() {
            @Override
            public int compare(final PackageInfo o1, final PackageInfo o2) {
                return o1.name.compareTo(o2.name);
            }
        });
        return childrenSorted;
    }
1304588
private Map<String,Namespace> buildByPrefixMap()
    {
        int len = mNamespaces.size();
        if (len == 0) {
            return Collections.emptyMap();
        }

        LinkedHashMap<String,Namespace> m = new LinkedHashMap<String,Namespace>(1 + len + (len>>1));
        for (int i = 0; i < len; ++i) {
            Namespace ns = mNamespaces.get(i);
            String prefix = ns.getPrefix();
            if (prefix == null) { // shouldn't happen but...
                prefix = "";
            }
            m.put(prefix, ns);
        }
        return m;
    }
148053
def get_children(self):
        """"""
        if hasattr(self, '_cached_children'):
            children = self._toplevel().objects.filter(
                pk__in=[n.pk for n in self._cached_children]
            )
            children._result_cache = self._cached_children
            return children
        else:
            return self.get_descendants(include_self=False, depth=1)
154138
def render_children options = {}
      return if children.empty?

      flattened_children.map{ |child| render_child(child, options) }.join
    end
546132
@SuppressWarnings("unused")
        public Map<A, B> toMap() {
            Map<A, B> m = new HashMap<A, B>();
            m.put(_1, _2);
            return m;
        }
1099600
def data_children(self) -> List["DataNode"]:
        """"""
        res = []
        for child in self.children:
            if isinstance(child, DataNode):
                res.append(child)
            elif not isinstance(child, SchemaTreeNode):
                res.extend(child.data_children())
        return res
573575
Map<Integer, Integer> initParentMap() {
        Map<Integer, Integer> parentMap = new LinkedHashMap<>(numWorkers);
        for(int r = 0; r < numWorkers; r++) {
            parentMap.put(r, ((r + 1) / 2 - 1) );
        }
        return parentMap;
    }
22422
Map<String, String> packageNameMap() {
        if (packageNames == null) {
            return emptyMap();
        }

        Map<String, String> names = new LinkedHashMap<String, String>();
        for (PackageName name : packageNames) {
            names.put(name.getUri(), name.getPackage());
        }
        return names;
    }
747964
public static <K, V> SortedMap<K, V> nullToEmpty(final SortedMap<K, V> map) {
        return map == null ? N.<K, V> emptySortedMap() : map;
    }
505929
public Map<?, ?> getByContainer() {

        if (m_byContainer == null) {
            m_byContainer = CmsCollectionsGenericWrapper.createLazyMap(new Transformer() {

                public Object transform(Object arg0) {

                    String key = (String)arg0;
                    CmsContainerBean container = m_page.getContainers().get(key);
                    if (container == null) {
                        return Collections.emptyList();
                    } else {
                        return container.getElements();
                    }
                }
            });
        }
        return m_byContainer;
    }
1154211
@SuppressWarnings("unchecked")
	public JSONNavi<T> array() {
		if (failure)
			return this;
		if (current == null && readonly)
			failure("Can not create Array child in readonly", null);
		if (current != null) {
			if (isArray())
				return this;
			if (isObject())
				failure("can not use Object feature on Array.", null);
			failure("Can not use current possition as Object", null);
		} else {
			current = mapper.createArray();
		}
		if (root == null)
			root = (T) current;
		else
			store();
		return this;
	}
1072631
private static List<WComponent> copyChildren(final List<WComponent> children) {
		ArrayList<WComponent> copy;

		if (children == null) {
			copy = new ArrayList<>(1);
		} else {
			copy = new ArrayList<>(children);
		}

		return copy;
	}
948778
public Map<K, V> getAll(Iterable<K> keys) {
    List<K> missingKeys = new ArrayList<>();
    Map<K, V> result = new HashMap<>();
    for (K key : keys) {
      V value = map.get(key);
      if (value == null && !map.containsKey(key)) {
        missingKeys.add(key);
      } else {
        result.put(key, value);
      }
    }
    if (!missingKeys.isEmpty()) {
      Map<K, V> missingValues = loader.loadAll(missingKeys);
      map.putAll(missingValues);
      result.putAll(missingValues);
      for (K missingKey : missingKeys) {
        if (!map.containsKey(missingKey)) {
          map.put(missingKey, null);
          result.put(missingKey, null);
        }
      }
    }
    return result;
  }
39354
public static <K, V> Map<K, V> emptyMapIfNull(final Map<K, V> map) {
		return map == null ? (Map<K, V>) Collections.EMPTY_MAP : map;
	}