public class ChainingHtmlParser<T extends ChainingHtmlParser<?>> extends Object
Ezvcard.parseHtml(InputStream)
,
Ezvcard.parseHtml(Path)
,
Ezvcard.parseHtml(Reader)
Constructor and Description |
---|
ChainingHtmlParser(InputStream in) |
ChainingHtmlParser(Path file) |
ChainingHtmlParser(Reader reader) |
ChainingHtmlParser(String string) |
ChainingHtmlParser(URL url) |
Modifier and Type | Method and Description |
---|---|
List<VCard> |
all()
Reads all vCards from the stream.
|
VCard |
first()
Reads the first vCard from the stream.
|
T |
pageUrl(String pageUrl)
Sets the original URL of the webpage.
|
T |
register(VCardPropertyScribe<? extends VCardProperty> scribe)
Registers a property scribe.
|
T |
warnings(List<List<ParseWarning>> warnings)
Provides a list object that any parser warnings will be put into.
|
public ChainingHtmlParser(String string)
public ChainingHtmlParser(InputStream in)
public ChainingHtmlParser(Reader reader)
public ChainingHtmlParser(Path file)
public ChainingHtmlParser(URL url)
public T pageUrl(String pageUrl)
URL
.pageUrl
- the webpage URLpublic T register(VCardPropertyScribe<? extends VCardProperty> scribe)
scribe
- the scribepublic T warnings(List<List<ParseWarning>> warnings)
warnings
- the list object that will be populated with the warnings
of each parsed vCard. Each element in the list is a list of warnings for
one parsed vCard. Therefore, the size of this list will be equal to the
number of parsed vCards. If a vCard does not have any warnings, then its
warning list will be empty.public VCard first() throws IOException
IOException
- if there's an I/O problempublic List<VCard> all() throws IOException
IOException
- if there's an I/O problemCopyright © 2012–2023 Michael Angstadt. All rights reserved.