title: Get an array from a map and convert the keys
body: <p>I have a <code>map&lt;String, Object&gt;</code> and an array of <code>int[]</code> which is supposed to contain the map keys.
  Is there a nice and short way to convert the keys to int, without using a loop?</p>
  
  <pre><code>myArray = myMap.keySet().toArray(new int[5]);
  </code></pre>
  
  <p>I use<code>Java 8</code>.
  Thanks!</p>