public class WarcResource extends Resource
Modifier and Type | Field and Description |
---|---|
static String |
PROFILE_REVISIT_SERVER_NOT_MODIFIED |
Constructor and Description |
---|
WarcResource(org.archive.io.warc.WARCRecord rec,
org.archive.io.ArchiveReader reader) |
Modifier and Type | Method and Description |
---|---|
void |
close() |
Map<String,String> |
getHttpHeaders()
Assumes an HTTP response - return the HTTP headers, not including the
HTTP Message header
|
long |
getRecordLength() |
String |
getRefersToDate()
return
WARC-Refers-To-Date WARC record header value or
equivalent. |
String |
getRefersToTargetURI()
return
WARC-Refer-To-Target-URI WARC record header value or
equivalent. |
int |
getStatusCode()
Assumes an HTTP resource - return the HTTP response code
|
org.archive.io.ArchiveRecordHeader |
getWarcHeaders() |
boolean |
isRevisitNotModified()
whether this Resource is
server-not-modified revisit. |
void |
parseHeaders() |
available, getHeader, mark, markSupported, read, read, read, reset, setChunkedEncoding, setInputStream, skip
public static final String PROFILE_REVISIT_SERVER_NOT_MODIFIED
public WarcResource(org.archive.io.warc.WARCRecord rec, org.archive.io.ArchiveReader reader)
public void parseHeaders() throws IOException
parseHeaders
in class Resource
IOException
public Map<String,String> getHttpHeaders()
Resource
getHttpHeaders
in class Resource
public org.archive.io.ArchiveRecordHeader getWarcHeaders()
public long getRecordLength()
getRecordLength
in class Resource
public int getStatusCode()
Resource
getStatusCode
in class Resource
public void close() throws IOException
close
in interface Closeable
close
in interface AutoCloseable
close
in class Resource
IOException
public String getRefersToTargetURI()
Resource
WARC-Refer-To-Target-URI
WARC record header value or
equivalent.
Default implementation returns null
.getRefersToTargetURI
in class Resource
public String getRefersToDate()
Resource
WARC-Refers-To-Date
WARC record header value or
equivalent.
Default implementation returns null
getRefersToDate
in class Resource
yyyyMMddHHmmss
)public boolean isRevisitNotModified()
server-not-modified
revisit.
(this method used to be AccessPoint#isWarcRevisitNotModified(Resource)
.
Not made a part of Resource
interface because it was unused.)true
if it isCopyright © 2005–2015 IIPC. All rights reserved.