public class FetchOutput extends Object
The output produced by the HtmlElement.fetchResources(com.univocity.api.io.FileProvider, com.univocity.api.entity.html.FetchOptions) methods.
| Constructor and Description |
|---|
FetchOutput(HtmlElement treeRoot,
File treeHtmlFile,
Map<File,URL> resourceMap)
Creates a new
FetchOutput with the results obtained from a call to HtmlElement.fetchResources(com.univocity.api.io.FileProvider, com.univocity.api.entity.html.FetchOptions) |
| Modifier and Type | Method and Description |
|---|---|
Map<File,URL> |
getResourceMap()
Returns the mapping of each local
File that has been downloaded to its original remote URL |
File |
getTreeHtmlFile()
Returns
File pointing to where the new HTML has been saved. |
HtmlElement |
getTreeRoot()
Returns the root
HtmlElement of the new HTML structure. |
public FetchOutput(HtmlElement treeRoot, File treeHtmlFile, Map<File,URL> resourceMap)
Creates a new FetchOutput with the results obtained from a call to HtmlElement.fetchResources(com.univocity.api.io.FileProvider, com.univocity.api.entity.html.FetchOptions)
treeRoot - the root of the HTML structure that had its resources fetchedtreeHtmlFile - a File with the saved HTML content, with all resources pointing to local files.resourceMap - the mapping of each local File that has been downloaded to its original remote URLpublic HtmlElement getTreeRoot()
Returns the root HtmlElement of the new HTML structure.
For each remote resource downloaded the remote url has been replaced with the relative local file location.
public File getTreeHtmlFile()
Returns File pointing to where the new HTML has been saved.
Copyright © 2018 uniVocity Software Pty Ltd. All rights reserved.