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



sourceManager
The EntityManager whose credentials will be used
Set authentication credentials on this EntityManager.

Syntax

Visual Basic (Declaration) 
<ObsoleteAttribute("Will be removed after 9/1/2012.")>
Public Sub LinkForAuthentication( _
   ByVal sourceManager As EntityManager _
) 
Visual Basic (Usage)Copy Code
Dim instance As EntityManager
Dim sourceManager As EntityManager
 
instance.LinkForAuthentication(sourceManager)
C# 
[ObsoleteAttribute("Will be removed after 9/1/2012.")]
public void LinkForAuthentication( 
   EntityManager sourceManager
)
C++/CLI 
[ObsoleteAttribute("Will be removed after 9/1/2012.")]
public:
void LinkForAuthentication( 
   EntityManager^ sourceManager
) 

Parameters

sourceManager
The EntityManager whose credentials will be used

Exceptions

ExceptionDescription
System.InvalidOperationExceptionThrown if linkage cannot occur becaue the source EntityManager is not logged in.
System.ArgumentNullExceptionThrown if the source EntityManager parameter is null

Remarks

LinkForAuthentication will set the AuthenticationContext of this EntityManager to that of the source EntityManager. When using this method a Login(ILoginCredential) call is not required. Using LinkForAuthentication performs the same authentication function as the EntityManager copy constructors, without also copying other settings.

Note that your IEntityLoginManager.Login method may still be called when you link EntityManagers. This will occur if different EntityServers are used by these EntityManagers.

The "link" causes the EntityManagers to share an AuthenticationContext. When that context is logged out, from any EntityManager using it via a Logout call, or from the IdeaBlade.EntityModel.Security.Authenticator.Logout method, all EntityManagers using the context will be logged out. You can link any number of EntityManagers in your application.

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.