CSLA.NET 5.4.2
CSLA .NET is a software development framework that helps you build a reusable, maintainable object-oriented business layer for your app.
Csla.Core.ApplicationContextManager Class Reference

Default context manager for the user property and local/client/global context dictionaries. More...

Inheritance diagram for Csla.Core.ApplicationContextManager:
Csla.Core.IContextManager Csla.Windows.ApplicationContextManager Csla.Xaml.ApplicationContextManager

Public Member Functions

virtual IPrincipal GetUser ()
 Gets the current user principal. More...
 
virtual void SetUser (IPrincipal principal)
 Sets the current user principal. More...
 
ContextDictionary GetLocalContext ()
 Gets the local context dictionary. More...
 
void SetLocalContext (ContextDictionary localContext)
 Sets the local context dictionary. More...
 
ContextDictionary GetClientContext ()
 Gets the client context dictionary. More...
 
void SetClientContext (ContextDictionary clientContext)
 Sets the client context dictionary. More...
 
ContextDictionary GetGlobalContext ()
 Gets the global context dictionary. More...
 
void SetGlobalContext (ContextDictionary globalContext)
 Sets the global context dictionary. More...
 
IServiceProvider GetDefaultServiceProvider ()
 Gets the default IServiceProvider More...
 
void SetDefaultServiceProvider (IServiceProvider serviceProvider)
 Sets the default IServiceProvider More...
 
IServiceProvider GetServiceProvider ()
 Gets the service provider for current scope More...
 
void SetServiceProvider (IServiceProvider scope)
 Sets the service provider for current scope More...
 

Properties

bool IsValid [get]
 Returns a value indicating whether the context is valid. More...
 
- Properties inherited from Csla.Core.IContextManager
bool IsValid [get]
 Gets a value indicating whether this context manager is valid for use in the current environment. More...
 

Detailed Description

Default context manager for the user property and local/client/global context dictionaries.

Definition at line 20 of file Csla/Core/ApplicationContextManager.cs.

Member Function Documentation

◆ GetClientContext()

ContextDictionary Csla.Core.ApplicationContextManager.GetClientContext ( )

Gets the client context dictionary.

Implements Csla.Core.IContextManager.

Definition at line 78 of file Csla/Core/ApplicationContextManager.cs.

◆ GetDefaultServiceProvider()

IServiceProvider Csla.Core.ApplicationContextManager.GetDefaultServiceProvider ( )

Gets the default IServiceProvider

Implements Csla.Core.IContextManager.

Definition at line 116 of file Csla/Core/ApplicationContextManager.cs.

◆ GetGlobalContext()

ContextDictionary Csla.Core.ApplicationContextManager.GetGlobalContext ( )

Gets the global context dictionary.

Implements Csla.Core.IContextManager.

Definition at line 95 of file Csla/Core/ApplicationContextManager.cs.

◆ GetLocalContext()

ContextDictionary Csla.Core.ApplicationContextManager.GetLocalContext ( )

Gets the local context dictionary.

Implements Csla.Core.IContextManager.

Definition at line 61 of file Csla/Core/ApplicationContextManager.cs.

◆ GetServiceProvider()

IServiceProvider Csla.Core.ApplicationContextManager.GetServiceProvider ( )

Gets the service provider for current scope

Returns

Implements Csla.Core.IContextManager.

Definition at line 135 of file Csla/Core/ApplicationContextManager.cs.

◆ GetUser()

virtual IPrincipal Csla.Core.ApplicationContextManager.GetUser ( )
virtual

Gets the current user principal.

Returns
The current user principal

Implements Csla.Core.IContextManager.

Reimplemented in Csla.Windows.ApplicationContextManager, and Csla.Xaml.ApplicationContextManager.

Definition at line 38 of file Csla/Core/ApplicationContextManager.cs.

◆ SetClientContext()

void Csla.Core.ApplicationContextManager.SetClientContext ( ContextDictionary  clientContext)

Sets the client context dictionary.

Parameters
clientContextContext dictionary

Implements Csla.Core.IContextManager.

Definition at line 87 of file Csla/Core/ApplicationContextManager.cs.

◆ SetDefaultServiceProvider()

void Csla.Core.ApplicationContextManager.SetDefaultServiceProvider ( IServiceProvider  serviceProvider)

Sets the default IServiceProvider

Parameters
serviceProviderIServiceProvider instance

Implements Csla.Core.IContextManager.

Definition at line 125 of file Csla/Core/ApplicationContextManager.cs.

◆ SetGlobalContext()

void Csla.Core.ApplicationContextManager.SetGlobalContext ( ContextDictionary  globalContext)

Sets the global context dictionary.

Parameters
globalContextContext dictionary

Implements Csla.Core.IContextManager.

Definition at line 105 of file Csla/Core/ApplicationContextManager.cs.

◆ SetLocalContext()

void Csla.Core.ApplicationContextManager.SetLocalContext ( ContextDictionary  localContext)

Sets the local context dictionary.

Parameters
localContextContext dictionary

Implements Csla.Core.IContextManager.

Definition at line 70 of file Csla/Core/ApplicationContextManager.cs.

◆ SetServiceProvider()

void Csla.Core.ApplicationContextManager.SetServiceProvider ( IServiceProvider  scope)

Sets the service provider for current scope

Parameters
scopeIServiceProvider instance

Implements Csla.Core.IContextManager.

Definition at line 146 of file Csla/Core/ApplicationContextManager.cs.

◆ SetUser()

virtual void Csla.Core.ApplicationContextManager.SetUser ( IPrincipal  principal)
virtual

Sets the current user principal.

Parameters
principalUser principal value

Implements Csla.Core.IContextManager.

Reimplemented in Csla.Windows.ApplicationContextManager, and Csla.Xaml.ApplicationContextManager.

Definition at line 53 of file Csla/Core/ApplicationContextManager.cs.

Property Documentation

◆ IsValid

bool Csla.Core.ApplicationContextManager.IsValid
get

Returns a value indicating whether the context is valid.

Definition at line 29 of file Csla/Core/ApplicationContextManager.cs.