Convert a {@link List} of {@link Link}s into a list of {@link UberData}.

@param links
@return
421586
private static List<UberData> extractLinks(Links links) {

		return urlRelMap(links).entrySet().stream() //
				.map(entry -> new UberData() //
						.withUrl(entry.getKey()) //
						.withRel(entry.getValue().getRels())) //
				.collect(Collectors.toList());
	}
557138
@Nonnull
    public final LinkedList<A> toLinkedList() {
        LinkedList<A> list = new LinkedList<>();
        ImmutableList<A> l = this;
        for (int i = 0; i < length; i++) {
            list.add(((NonEmptyImmutableList<A>) l).head);
            l = ((NonEmptyImmutableList<A>) l).tail;
        }
        return list;
    }
708534
@SuppressWarnings("unchecked")
	public T add(Link... links) {

		Assert.notNull(links, "Given links must not be null!");

		add(Arrays.asList(links));

		return (T) this;
	}
582989
private Map<String, SiteLink> copySiteLinks(Map<String, SiteLink> siteLinks) {
		if (filter.excludeAllSiteLinks()) {
			return Collections.emptyMap();
		}

		Map<String, SiteLink> result = new HashMap<>(siteLinks.size());
		for (Entry<String, SiteLink> entry : siteLinks.entrySet()) {
			if (filter.includeSiteLink(entry.getKey())) {
				result.put(entry.getKey(), copy(entry.getValue()));
			}
		}
		return result;
	}
1215029
public static <T> List<T> arrayToList(T[] array) {
        List<T> list = null;
        if (array != null) {
            list = new ArrayList<>();
            for (T e : array) {
                list.add(e);
            }
        }
        return list;
    }
622058
public static <T> LinkedList<T> newLinkedList(Iterable<? extends T> elements) {
		return Lists.newLinkedList(elements);
	}
1060833
@JsonIgnore
	public List<Link> getLinks() {

		String url = this.url;

		if (url == null) {
			return Links.NONE.toList();
		}

		return Optional.ofNullable(this.rel) //
				.map(rels -> rels.stream() //
						.map(rel -> new Link(url, rel)) //
						.collect(Collectors.toList())) //
				.orElse(Collections.emptyList());
	}
991487
public static <T> List<T> toList( T... objects )
    {
        List<T> list = new ArrayList<T>( objects.length );
        for (T t : objects)
        {
            list.add( t );
        }
        return list;
    }
93650
public static DefaultListOperation<ContentKeyInfo> list(
            LinkInfo<ContentKeyInfo> link) {
        return new DefaultListOperation<ContentKeyInfo>(link.getHref(),
                new GenericType<ListResult<ContentKeyInfo>>() {
                });
    }
716703
private static List<UberData> doExtractLinksAndContent(Object item) {

		if (item instanceof EntityModel) {
			return extractLinksAndContent((EntityModel<?>) item);
		}

		if (item instanceof RepresentationModel) {
			return extractLinksAndContent((RepresentationModel<?>) item);
		}

		return extractLinksAndContent(new EntityModel<>(item));
	}
764200
public boolean contains(Iterable<Link> links) {
		return this.links.containsAll(Links.of(links).toList());
	}
897218
public static String[] arrayFromStringList(List<String> strings) {

        String[] result = new String[strings.size()];
        for (int i = 0; i < strings.size(); i++) {
            result[i] = strings.get(i);
        }
        return result;
    }
492768
public static <T> List<T> asArrayList(T[] values) {
    ArrayList<T> result = new ArrayList<T>();
    Collections.addAll(result, values);

    return result;
  }
451558
public static List<Date> toDateList(final List<Calendar> dates) {
        return dates.stream().map(Calendar::getTime).collect(Collectors.toList());
    }
274038
private static List<UberData> extractLinks(RepresentationModel<?> resource) {

		List<UberData> data = new ArrayList<>();

		List<UberData> links = extractLinks(resource.getLinks());
		List<UberData> affordanceBasedLinks = extractAffordances(resource.getLinks());

		if (affordanceBasedLinks.isEmpty()) {
			data.addAll(links);
		} else {
			data.addAll(mergeDeclaredLinksIntoAffordanceLinks(affordanceBasedLinks, links));
		}

		return data;
	}
1202228
@SafeVarargs
    public static <T> LinkedList<T> getLinkedList(T... values) {
        return new LinkedList<T>() {{addAll(Arrays.asList(values));}};
    }
574428
private static List<Integer> convertList(List<String> list) {
        if (list == null) {
            return null;
        }
        List<Integer> ret = new ArrayList<Integer>(list.size());
        for (String v : list) {
            ret.add(StringUtils.toInt(v));
        }

        return ret;
    }