How to transform String[] into collection? : <p>I am trying to get a String Collection in my Java code, so i'm trying something like this:</p>

<pre><code>Collection c = new String[]{};
</code></pre>

<p>But i get this error: <code>incompatible types: String[] cannot be converted to Collection</code>.<br>
Is there a way to convert <strong>String[]</strong> into <strong>Collection</strong> without doing something like this:</p>

<pre><code>var array = new String[]{"Apple", "Banana"};
var arrayList = new ArrayList&lt;String&gt;();
for (String fruit : array) {
    arrayList.add(fruit);
}
Collection c = arrayList;
</code></pre>
