net.sf.jasperreports.jsf.resource.providers
Class ClasspathResource

java.lang.Object
  extended by net.sf.jasperreports.jsf.resource.AbstractResource
      extended by net.sf.jasperreports.jsf.resource.providers.ClasspathResource
All Implemented Interfaces:
Resource

public final class ClasspathResource
extends AbstractResource
implements Resource


Constructor Summary
protected ClasspathResource(String name, ClassLoader classLoader)
           
 
Method Summary
 InputStream getInputStream()
          Obtains an InputStream which can be used to read the resource data.
 URL getLocation()
          Obtains the URL location of this resource
 String getPath()
          The path part of the resource
 
Methods inherited from class net.sf.jasperreports.jsf.resource.AbstractResource
getName
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface net.sf.jasperreports.jsf.resource.Resource
getName
 

Constructor Detail

ClasspathResource

protected ClasspathResource(String name,
                            ClassLoader classLoader)
Method Detail

getInputStream

public InputStream getInputStream()
                           throws IOException
Description copied from interface: Resource
Obtains an InputStream which can be used to read the resource data.

Users of this stream are responsible of closing it

Specified by:
getInputStream in interface Resource
Returns:
An InputStream to read the resource data
Throws:
IOException

getLocation

public URL getLocation()
                throws IOException
Description copied from interface: Resource
Obtains the URL location of this resource

Specified by:
getLocation in interface Resource
Returns:
The location of the resource
Throws:
IOException

getPath

public String getPath()
Description copied from interface: Resource
The path part of the resource

Specified by:
getPath in interface Resource
Returns:


Copyright © 2009 SourceForge.net. All Rights Reserved.