Package net.sf.basedb.util.uri
Class UriMetadata
java.lang.Object
net.sf.basedb.util.uri.UriMetadata
Holds metadata about the data referenced by given URI. All metadata
information is optional and clients should be prepared to handle
it.
- Since:
- 3.0
- Author:
- Nicklas
- Last modified
- $Date: 2011-03-15 13:55:59 +0100 (ti, 15 mar 2011) $
-
Field Summary
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionGet the character set used by the resource.Get the date and time the resource was last modified.Get the length in bytes of the resource.getMd5()
Get the MD5 checksum of the resource.Get the MIME type of the resource.void
setCharacterSet
(String charset) void
setLastModified
(Date lastModified) void
void
void
setMimeType
(String mimeType)
-
Field Details
-
uri
-
length
-
lastModified
-
mimeType
-
charset
-
md5
-
-
Constructor Details
-
UriMetadata
Create an empty metadata object for the given URI.- Parameters:
uri
- The URI that defines the referenced resource
-
-
Method Details
-
getLength
Get the length in bytes of the resource.- Returns:
- The size in bytes or null if not known
-
setLength
-
getLastModified
Get the date and time the resource was last modified.- Returns:
- A date or null if not known
-
setLastModified
-
getMimeType
Get the MIME type of the resource.- Returns:
- A string or null if not known
-
setMimeType
-
getCharacterSet
Get the character set used by the resource.- Returns:
- A string or null if not known
-
setCharacterSet
-
getMd5
Get the MD5 checksum of the resource.- Returns:
- A string or null if not known
-
setMd5
-