IdeaBlade DevForce 2010 Help Reference
LoginAsync Method
See Also  Send Feedback
IdeaBlade.EntityModel Assembly > IdeaBlade.EntityModel Namespace > EntityManager Class : LoginAsync Method



credential
Login credentials
userCallback
Callback invoked when asynchronous operation completes
userState
Token identifying the asynchronous operation
Perform an asynchronous login operation to validate the user's credentials.

Syntax

Visual Basic (Declaration) 
<ObsoleteAttribute("Will be removed after 9/1/2012.  Use Authenticator.Instance.LoginAsync instead.")>
Public Function LoginAsync( _
   Optional ByVal credential As ILoginCredential, _
   Optional ByVal userCallback As Action(Of LoginOperation), _
   Optional ByVal userState As Object _
) As LoginOperation
Visual Basic (Usage)Copy Code
Dim instance As EntityManager
Dim credential As ILoginCredential
Dim userCallback As Action(Of LoginOperation)
Dim userState As Object
Dim value As LoginOperation
 
value = instance.LoginAsync(credential, userCallback, userState)
C# 
[ObsoleteAttribute("Will be removed after 9/1/2012.  Use Authenticator.Instance.LoginAsync instead.")]
public LoginOperation LoginAsync( 
   ILoginCredential credential,
   Action<LoginOperation> userCallback,
   object userState
)
C++/CLI 
[ObsoleteAttribute("Will be removed after 9/1/2012.  Use Authenticator.Instance.LoginAsync instead.")]
public:
LoginOperation^ LoginAsync( 
   ILoginCredential^ credential,
   Action<LoginOperation^>^ userCallback,
   Object^ userState
) 

Parameters

credential
Login credentials
userCallback
Callback invoked when asynchronous operation completes
userState
Token identifying the asynchronous operation

Exceptions

ExceptionDescription
System.InvalidOperationExceptionCall Connect before doing a Login.

Remarks

Provide a userCallback if you want to be notified when the operation completes. Use the userState to uniquely identify this call.

Login may be used to validate a user's credentials and provide more secure communications between client and server tiers. In a Silverlight application, you can integrate with ASP.NET authentication features when the UseAspNetSecurityServices option is enabled.

If EntityManagerOptions.UseDefaultAuthenticationContext is true, the LoginAsync call will set the IdeaBlade.EntityModel.Security.Authenticator.DefaultAuthenticationContext, otherwise the AuthenticationContext is set.

Credentials are passed in clear text. Use a secure channel (such as SSL) or provide your own encryption if secure communications are necessary.

Requirements

Target Platforms: Windows 98, Windows NT 4.0, Windows Millennium Edition, Windows 2000, Windows XP Home Edition, Windows XP Professional, Windows Server 2003 family, Windows Vista, Windows Server 2008 family

See Also

© 2013 All Rights Reserved.