C# Class SenseNet.Portal.UI.Controls.Captcha.CaptchaControl

Inheritance: FieldControl, INamingContainer, IValidator
Mostra file Open project: maxpavlov/FlexNet

Private Properties

Property Type Description
CssStyle string
GenerateNewCaptcha void
GetCachedCaptcha CaptchaImage
HtmlColor string
RemoveCachedCaptcha void

Public Methods

Method Description
GetData ( ) : object

Gets object data.

Exception handling and displayed is done at ContentView level; FormatExceptions and Exceptions are handled and displayed at this level. Should you need custom or localized error messages, throw a FieldControlDataException with your own error message.

SetData ( object data ) : void

Sets data within the FieldControl

System ( ) : void
ValidateCaptcha ( ) : void

Validate the user's text against the CAPTCHA text

Protected Methods

Method Description
CreateChildControls ( ) : void
GetSR ( string strResId ) : string
LoadControlState ( object state ) : void
OnInit ( System e ) : void
OnPreRender ( System e ) : void
OnUnload ( System e ) : void
SaveControlState ( ) : object

Retrieve the user's CAPTCHA input from the posted data

Private Methods

Method Description
CssStyle ( ) : string

returns css "style=" tag for this control based on standard control visual properties

GenerateNewCaptcha ( ) : void

generate a new captcha and store it in the ASP.NET Cache by unique GUID

GetCachedCaptcha ( string guid ) : CaptchaImage
HtmlColor ( System color ) : string

returns HTML-ized color strings

RemoveCachedCaptcha ( string guid ) : void

Method Details

CreateChildControls() protected method

protected CreateChildControls ( ) : void
return void

GetData() public method

Gets object data.
Exception handling and displayed is done at ContentView level; FormatExceptions and Exceptions are handled and displayed at this level. Should you need custom or localized error messages, throw a FieldControlDataException with your own error message.
public GetData ( ) : object
return object

GetSR() protected static method

protected static GetSR ( string strResId ) : string
strResId string
return string

LoadControlState() protected method

protected LoadControlState ( object state ) : void
state object
return void

OnInit() protected method

protected OnInit ( System e ) : void
e System
return void

OnPreRender() protected method

protected OnPreRender ( System e ) : void
e System
return void

OnUnload() protected method

protected OnUnload ( System e ) : void
e System
return void

SaveControlState() protected method

Retrieve the user's CAPTCHA input from the posted data
protected SaveControlState ( ) : object
return object

SetData() public method

Sets data within the FieldControl
public SetData ( object data ) : void
data object Data of the Field wrapped
return void

System() public method

public System ( ) : void
return void

ValidateCaptcha() public method

Validate the user's text against the CAPTCHA text
public ValidateCaptcha ( ) : void
return void