Package com.sun.ts.lib.util.sec.misc
Class Resource
java.lang.Object
com.sun.ts.lib.util.sec.misc.Resource
This class is used to represent a Resource that has been loaded from the class path.
- Since:
- 1.2
- Author:
- David Connelly
- 
Constructor SummaryConstructors
- 
Method SummaryModifier and TypeMethodDescriptionReturns the Resource data as a ByteBuffer, but only if the input stream was implemented on top of a ByteBuffer.byte[]getBytes()Returns the Resource data as an array of bytes.Returns theCertificates for the Resource, or null if none.Returns the code signers for the Resource, or null if none.abstract URLReturns the CodeSource URL for the Resource.abstract intReturns the length of the Resource data, or -1 if unknown.abstract InputStreamReturns an InputStream for reading the Resource data.Returns the Manifest for the Resource, or null if none.abstract StringgetName()Returns the name of the Resource.abstract URLgetURL()Returns the URL of the Resource.
- 
Constructor Details- 
Resourcepublic Resource()
 
- 
- 
Method Details- 
getNameReturns the name of the Resource.
- 
getURLReturns the URL of the Resource.
- 
getCodeSourceURLReturns the CodeSource URL for the Resource.
- 
getInputStreamReturns an InputStream for reading the Resource data.- Throws:
- IOException
 
- 
getContentLengthReturns the length of the Resource data, or -1 if unknown.- Throws:
- IOException
 
- 
getBytesReturns the Resource data as an array of bytes.- Throws:
- IOException
 
- 
getByteBufferReturns the Resource data as a ByteBuffer, but only if the input stream was implemented on top of a ByteBuffer. Returnnullotherwise.- Throws:
- IOException
 
- 
getManifestReturns the Manifest for the Resource, or null if none.- Throws:
- IOException
 
- 
getCertificatesReturns theCertificates for the Resource, or null if none.
- 
getCodeSignersReturns the code signers for the Resource, or null if none.
 
-