title: Getting hours,minutes, and seconds from Date?
body: <p>I want to get the current hour,minute, and second from the <code>Date</code> object.</p>
  
  <p>This is my code:</p>
  
  <pre><code>Date date = new Date();
  int hour = date.getHours();
  </code></pre>
  
  <p>But I get a kind of error, the <code>getHours()</code> part doesnt work. I get a "The method getHours() from the type Data is deprecated". What does that mean, and how do I get the hour,minutes, and seconds?</p>