Java URL Read getLastModified(HttpURLConnection conn)

Here you can find the source of getLastModified(HttpURLConnection conn)

Description

get Last Modified

License

Open Source License

Declaration

static public long getLastModified(HttpURLConnection conn) 

Method Source Code


//package com.java2s;
// are made available under the terms of the Eclipse Public License v1.0

import java.net.HttpURLConnection;

public class Main {
    static public long getLastModified(HttpURLConnection conn) {
        long result = conn.getHeaderFieldDate("Last-Modified", 0L);
        return result;
    }/*from ww w .j  a v  a2 s . c o  m*/
}

Related

  1. getHTML(String urlToRead)
  2. getHTML(String urlToRead)
  3. getHttpResponse(HttpURLConnection conn, int expectedReturnCode)
  4. getHTTPResponse(String url)
  5. getHttpResponse(String urlStr)
  6. getLastModified(HttpURLConnection connection)
  7. getRemoteFileLength(String url)
  8. getRemoteFileSize(URL url)
  9. getStreamByConnection(final HttpURLConnection con)