title: Converting a character into keycode
body: <p>I have a character and I want to convert it into KeyEvent KeyCode constraints <a href="http://developer.android.com/reference/android/view/KeyEvent.html#KEYCODE_0">http://developer.android.com/reference/android/view/KeyEvent.html#KEYCODE_0</a></p>
  
  <p>Like if I have a character '0' I wan to convert into </p>
  
  <blockquote>
    <p>Key code constant: '0' key.</p>
    
    <p>Constant Value: <strong>7</strong> (0x00000007)</p>
  </blockquote>
  
  <p>as specified in the KeyEvent page. What can be a best method for doing this? Is there any predefined function to do it?</p>