本文整理匯總了C#中WikiFunctions.API.ApiEdit類的典型用法代碼示例。如果您正苦於以下問題:C# ApiEdit類的具體用法?C# ApiEdit怎麽用?C# ApiEdit使用的例子?那麽, 這裏精選的類代碼示例或許可以為您提供幫助。
ApiEdit類屬於WikiFunctions.API命名空間,在下文中一共展示了ApiEdit類的15個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的C#代碼示例。
示例1: Clone
/// <summary>
/// Creates a new instance of the ApiEdit class by cloning the current instance
/// ATTENTION: the clones will share the same cookie container, so logging off or logging under another username
/// with one instance will automatically make another one do the same
/// </summary>
public ApiEdit Clone()
{
ApiEdit clone = new ApiEdit();
clone.m_URL = m_URL;
clone.m_Maxlag = m_Maxlag;
clone.m_Cookies = m_Cookies;
clone.ProxySettings = ProxySettings;
return clone;
}
示例2: btnLogin_Click
private void btnLogin_Click(object sender, EventArgs e)
{
groupBox2.Enabled = false;
try
{
Editor = new ApiEdit(txtURL.Text);
Editor.Login(txtUsername.Text, txtPassword.Text);
groupBox2.Enabled = true;
txtEdit.Text = "";
btnSave.Enabled = false;
}
catch (Exception ex)
{
MessageBox.Show(ex.Message, ex.GetType().Name);
}
}
示例3: ApiErrorException
public ApiErrorException(ApiEdit editor, string errorCode, string errorMessage)
: base(editor, "API returned the following error: '" + errorMessage + "'")
{
ErrorCode = errorCode;
ApiErrorMessage = errorMessage;
}
示例4: SpamlistException
public SpamlistException(ApiEdit editor, string url)
: base(editor, "The link '" + url + "' is blocked by spam blacklist")
{
URL = url;
}
示例5: RedirectToSpecialPageException
public RedirectToSpecialPageException(ApiEdit editor)
: base(editor, "Redirect target is special page")
{
}
示例6: NewMessagesException
public NewMessagesException(ApiEdit editor)
: base(editor, "You have new messages")
{
}
示例7: MediaWikiSaysNoException
public MediaWikiSaysNoException(ApiEdit editor, string message)
: base(editor, message)
{
}
示例8: MaxlagException
public MaxlagException(ApiEdit editor, int maxlag, int retryAfter)
: base(editor, "maxlag", "Maxlag exceeded by " + maxlag + " seconds, retry in " + retryAfter + " seconds")
{
Maxlag = maxlag;
RetryAfter = retryAfter;
}
示例9: BrokenXmlException
public BrokenXmlException(ApiEdit editor, string message)
: base(editor, message)
{
}
示例10: AssertionFailedException
public AssertionFailedException(ApiEdit editor, string assertion)
: base(editor, "Assertion '" + assertion + "' failed")
{
}
示例11: ApiXmlException
public ApiXmlException(ApiEdit editor, XmlException innerException, string get, string post, string content)
: base(editor, "XmlException in ApiEdit.CheckForErrors", innerException)
{
GetUrl = get;
PostQuery = post;
Content = content;
}
示例12: ApiException
public ApiException(ApiEdit editor, string message, Exception innerException)
: base(message, innerException)
{
Editor = editor;
ThrowingThread = Thread.CurrentThread;
}
示例13: ApiOperationFailedException
public ApiOperationFailedException(ApiEdit editor, string action, string result)
: base(editor, "Operation '" + action + "' ended with result '" + result + "'.")
{
Action = action;
Result = result;
}
示例14: ApiException
public ApiException(ApiEdit editor, string message, Exception innerException)
: base(message, innerException)
{
Editor = editor;
}
示例15: LoggedOffException
public LoggedOffException(ApiEdit editor)
: base(editor, "User is logged off")
{
}