Click or drag to resize

WikiSite(IWikiClient, SiteOptions, String, String) Constructor

This is preliminary documentation and is subject to change.

Initializes a WikiSite instance with the specified settings and optional login before fetching for site information.

Namespace: WikiClientLibrary.Sites
Assembly: WikiClientLibrary (in WikiClientLibrary.dll) Version: 0.9.0-int.2+447d1d590e6726b7881f750a0a0e42908f3e417e
Syntax
public WikiSite(
	IWikiClient wikiClient,
	SiteOptions options,
	string? userName,
	string? password
)

Parameters

wikiClient  IWikiClient
WikiClient instance.
options  SiteOptions
Site options.
userName  String
The user name used to login before fetching for site information. Pass null to fetch site information without login first.
password  String
The password used to login before fetching for site information.
Exceptions
ExceptionCondition
ArgumentNullExceptionwikiClient or options is null. - OR - userName is not null, but password is null.
ArgumentExceptionOne or more settings in options is invalid.
Remarks

For the private wiki where anonymous users cannot access query API, you can use this overload to login to the site before any querying API invocations are issued.

See Also