Package org.xhtmlrenderer.pdf
Class ITextUserAgent
- java.lang.Object
-
- org.xhtmlrenderer.swing.NaiveUserAgent
-
- org.xhtmlrenderer.pdf.ITextUserAgent
-
- All Implemented Interfaces:
DocumentListener
,UserAgentCallback
public class ITextUserAgent extends NaiveUserAgent
-
-
Constructor Summary
Constructors Constructor Description ITextUserAgent(ITextOutputDevice outputDevice)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description ImageResource
getImageResource(java.lang.String uri)
Retrieves the image located at the given URI.SharedContext
getSharedContext()
void
setSharedContext(SharedContext sharedContext)
-
Methods inherited from class org.xhtmlrenderer.swing.NaiveUserAgent
clearImageCache, documentLoaded, documentStarted, getBaseURL, getBinaryResource, getCSSResource, getXMLResource, isVisited, onLayoutException, onRenderException, resolveURI, setBaseURL, shrinkImageCache
-
-
-
-
Constructor Detail
-
ITextUserAgent
public ITextUserAgent(ITextOutputDevice outputDevice)
-
-
Method Detail
-
getImageResource
public ImageResource getImageResource(java.lang.String uri)
Description copied from class:NaiveUserAgent
Retrieves the image located at the given URI. It's assumed the URI does point to an image--the URI will be accessed (using java.io or java.net), opened, read and then passed into the JDK image-parsing routines. The result is packed up into an ImageResource for later consumption.- Specified by:
getImageResource
in interfaceUserAgentCallback
- Overrides:
getImageResource
in classNaiveUserAgent
- Parameters:
uri
- Location of the image source.- Returns:
- An ImageResource containing the image.
-
getSharedContext
public SharedContext getSharedContext()
-
setSharedContext
public void setSharedContext(SharedContext sharedContext)
-
-