title: Equivalent java code to measure response time of server
body: <p>what are the equivalent java api s that I should be using for the following C# code please? What i need is to check the response time.</p>
  
  <pre><code>HttpWebRequest request = (HttpWebRequest)WebRequest.Create(address);
  System.Diagnostics.Stopwatch timer = new Stopwatch();
  timer.Start();
  HttpWebResponse response = (HttpWebResponse)request.GetResponse();
  timer.Stop();
  TimeSpan timeTaken = timer.Elapsed;
  </code></pre>
  
  <p>Thanks in advance. </p>