I have a string-array in a resource file with a few items in the array. I know how to call the array by name. What I want is to be able to call the array item by a name. The resource file allows me to give the item a name 'item 1. How can I call this item by the given name something like this in my Java class

```
String[]array = getResources().getStringArray(R.array.myarray);
String item1 = array["item1"];
String item2 = array["item2"];
String item3 = array["item3"];

```

and in the resources the array looking like

```
<string-array name="myarray">
    <item name="item1">item 1</item>
    <item name="item2">item 2</item>
    <item name="item3">item </item>
 </string-array>

```