| Modifier and Type | Field and Description |
|---|---|
Object |
magicWord
If the pagename was a magic word it will be this, otherwise null.
|
String |
magicWordParameter
Parameters of the magic word (null if not supplied).
|
INamespace.INamespaceValue |
namespace
The namespace the page is in.
|
String |
pagename
The name of the page (without the namespace).
|
boolean |
valid
Whether this pagename was successfully parsed or not.
|
| Constructor and Description |
|---|
ParsedPageName(INamespace.INamespaceValue namespace,
String pagename,
boolean valid)
Creates a new parsed page name object (no magic word).
|
ParsedPageName(INamespace.INamespaceValue namespace,
String pagename,
Object magicWord,
String magicWordParameter,
boolean valid)
Creates a new parsed page name object.
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
equals(Object o) |
String |
fullPagename() |
int |
hashCode() |
static ParsedPageName |
parsePageName(IWikiModel wikiModel,
String pagename,
INamespace.INamespaceValue namespace,
boolean magicWordAllowed,
boolean stripOffSection)
Parses a given page name into its components, e.g.
|
String |
toString() |
public final INamespace.INamespaceValue namespace
public final String pagename
public final boolean valid
public final Object magicWord
MagicWord implementation used by the
IWikiModel, e.g.
MagicWord.MagicWordE in case
MagicWord is used.public final String magicWordParameter
public ParsedPageName(INamespace.INamespaceValue namespace, String pagename, boolean valid)
namespace - the namespace the page is inpagename - the name of the page (without the namespace)valid - whether this pagename was successfully parsed or notpublic ParsedPageName(INamespace.INamespaceValue namespace, String pagename, Object magicWord, String magicWordParameter, boolean valid)
namespace - the namespace the page is inpagename - the name of the page (without the namespace)magicWord - the magic word object if the pagename was a magic word,
otherwise nullmagicWordParameter - parameters of the magic word (null if not supplied)valid - whether this pagename was successfully parsed or not@Nonnull public static ParsedPageName parsePageName(@Nonnull IWikiModel wikiModel, @Nonnull String pagename, INamespace.INamespaceValue namespace, boolean magicWordAllowed, boolean stripOffSection)
wikiModel - the wiki model to usepagename - the name in wiki textnamespace - the default namespace to use if there is no namespace in the
pagenamemagicWordAllowed - whether the pagename may be a magic word or not (if it is
a magic word and this is set to false, it will be parsed
as if it is a page name)public String fullPagename()
Copyright © 2017 Java Wikipedia API (Bliki engine). All rights reserved.