DLESE Tools
v1.6.0

org.dlese.dpc.schemedit.ndr.mets
Class DownLoadedFile

java.lang.Object
  extended by org.dlese.dpc.schemedit.ndr.mets.DownLoadedFile

public class DownLoadedFile
extends Object

Utility to download a URL and provide information about it, such as it's contentType, contentLength, binary content, etc

NOTE: getContent fetches binary content encoded to string for binary Files

Author:
Jonathan Ostwald

Constructor Summary
DownLoadedFile(URL url)
          Constructor for the DownLoadedFile object
 
Method Summary
 String getContent()
          Gets the content attribute of the DownLoadedFile object
 int getContentLength()
          Gets the contentLength attribute of the DownLoadedFile object
 String getContentType()
          Gets the contentType attribute of the DownLoadedFile object
 String getFileName()
          Gets the fileName attribute of the DownLoadedFile object
 boolean getIsBinary()
          Gets the isBinary attribute of the DownLoadedFile object
static void main(String[] args)
          NOT YET DOCUMENTED
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DownLoadedFile

public DownLoadedFile(URL url)
               throws Exception
Constructor for the DownLoadedFile object

Parameters:
url - url to be downloaded
Throws:
Exception - if url cannot be processed
Method Detail

getContent

public String getContent()
Gets the content attribute of the DownLoadedFile object

Returns:
The content value

getFileName

public String getFileName()
Gets the fileName attribute of the DownLoadedFile object

Returns:
The fileName value

getIsBinary

public boolean getIsBinary()
Gets the isBinary attribute of the DownLoadedFile object

Returns:
The isBinary value

getContentLength

public int getContentLength()
Gets the contentLength attribute of the DownLoadedFile object

Returns:
The contentLength value

getContentType

public String getContentType()
Gets the contentType attribute of the DownLoadedFile object

Returns:
The contentType value

main

public static void main(String[] args)
                 throws Exception
NOT YET DOCUMENTED

Parameters:
args - NOT YET DOCUMENTED
Throws:
Exception - NOT YET DOCUMENTED

DLESE Tools
v1.6.0