title: How to convert a datetime from sqlserver to java.util.Date
body: <p>I am getting a row from a table with sql server database (with Asp net core as web api) using retrofit library in android and as far as I understood I must consider an string equivalent to datetime and then convert it to java.util.Date. An example of retrieved date time is <code>2018-10-29T19:56:59</code>. Is there anyway to convert datetime to java.util.Date directly?
  the code is shown below.</p>
  
  <pre><code>public class Food {
      @SerializedName("Id")
      private long Id;
  
      @SerializedName("Name")
      private String Name;
  
      @SerializedName("Content")
      private String Content;
  
      @SerializedName("IsActive")
      private boolean IsActive;
  
      @SerializedName("DoesExist")
      private boolean DoesExist;
  
      @SerializedName("Cost")
      private int Cost;
  
      @SerializedName("OffPercentage")
      private int OffPercentage;
  
      @SerializedName("OffTimeout")
      private Date OffTimeout;
  ...
  }
  </code></pre>