@SafeVarargs
    public static <E> List<E> asList(E... elements) {
        if (elements == null || elements.length == 0) {
            return Collections.emptyList();
        }

        // Integer overflow does not occur when a large array is passed in because the list array already exists
        return Arrays.asList(elements);
    }
Returns {@code true} if the specified {@code PrincipalCollection} is {@code null} or
{@link PrincipalCollection#isEmpty empty}, {@code false} otherwise.

@param principals the principals to check.
@return {@code true} if the specified {@code PrincipalCollection} is {@code null} or
{@link PrincipalCollection#isEmpty empty}, {@code false} otherwise.
@since 1.0
@deprecated Use PrincipalCollection.isEmpty() directly.
core/src/main/java/org/apache/shiro/util/CollectionUtils.java