@Override
public String parseFunction(List<String> list, IWikiModel model, char[] src, int beginIndex, int endIndex, boolean isSubst) {
if (list.size() > 1) {
String wikiTopicName = isSubst ? list.get(0) : parseTrim(list.get(0), model);
final INamespace namespace = model.getNamespace();
// note: appended "#section" does not count for the check whether a page
// exists or not!
// -> strip off
ParsedPageName parsedPagename = AbstractParser.parsePageName(model, wikiTopicName, namespace.getMain(), false, true);
String rawWikiContent = null;
// if parsing failed, e.g. double "::" at the page titles beginning, this
// is the same as if the page does not exist.
if (parsedPagename.valid) {
try {