com.xmlmind.fo.converter
Interface UriResolver

All Known Implementing Classes:
Converter

public interface UriResolver

A URI resolver.

This interface provides a means of handling property values specified as a URI, such as the value of the src property of external-graphic objects. An application may supply a custom URI resolver by implementing this interface and calling the setUriResolver method. By default URI specifications that do not denote an absolute location are considered relative to the input source URI, unless the baseURL option is set.


Method Summary
 URL resolve(String spec, URL context)
          Resolve a URI.
 

Method Detail

resolve

URL resolve(String spec,
            URL context)
            throws Exception
Resolve a URI.

The conversion driver will call this method to resolve any URI in property values. This method will be called whether the URI is absolute or relative.

Parameters:
spec - the URI specification
context - the input source URI, or null if unknown
Returns:
the resolved URI, or null if undefined
Throws:
Exception - if an error occurs