public class HelpContentReader extends WikiReader
Constructor and Description |
---|
HelpContentReader(String baseUrl)
Constructs a new
HelpContentReader . |
Modifier and Type | Method and Description |
---|---|
String |
fetchHelpTopicContent(String helpTopicUrl,
boolean dotest)
Fetches the content of a help topic from the JOSM wiki.
|
protected String |
prepareHelpContent(BufferedReader in,
boolean dotest,
URL url)
Reads help content from the input stream and prepares it to be rendered later
in the internal help browser.
|
getBaseUrlWiki, read, readFromTrac, readLang
public HelpContentReader(String baseUrl)
HelpContentReader
.baseUrl
- the base url of the JOSM help wiki, i.e. https://josm.openstreetmap.orgpublic String fetchHelpTopicContent(String helpTopicUrl, boolean dotest) throws HelpContentReaderException
helpTopicUrl
- the absolute help topic URLdotest
- if true
, checks if help content is emptyHelpContentReaderException
- if problem occursMissingHelpContentException
- if this helpTopicUrl doesn't point to an existing Wiki help pageprotected String prepareHelpContent(BufferedReader in, boolean dotest, URL url) throws HelpContentReaderException
MissingHelpContentException
if the content read from the stream
most likely represents a stub help page.in
- the input streamdotest
- if true
, checks if help content is emptyurl
- help topic URLHelpContentReaderException
- if an exception occursMissingHelpContentException
- if the content read isn't a help page