public static <E> LinkedHashSet<E> asSet(final Collection<E> elements) {
        return new LinkedHashSet<>(elements);
    }
Converts {@code Collection} to a {@code Set}.
gremlin-core/src/main/java/org/apache/tinkerpop/gremlin/util/CollectionUtil.java