C# Class Microsoft.HockeyApp.AsyncSynchronizationContext

Wrapper around a standard synchronization context, that catches any unhandled exceptions. Acts as a facade passing calls to the original SynchronizationContext
Inheritance: System.Threading.SynchronizationContext
Afficher le fichier Open project: bitstadium/HockeySDK-Windows Class Usage Examples

Méthodes publiques

Méthode Description
AsyncSynchronizationContext ( SynchronizationContext syncContext ) : System

Initializes a new instance of the AsyncSynchronizationContext class.

CreateCopy ( ) : SynchronizationContext

When overridden in a derived class, creates a copy of the synchronization context.

OperationCompleted ( ) : void

When overridden in a derived class, responds to the notification that an operation has completed.

OperationStarted ( ) : void

When overridden in a derived class, responds to the notification that an operation has started.

Post ( SendOrPostCallback d, object state ) : void

When overridden in a derived class, dispatches an asynchronous message to a synchronization context.

Register ( ) : AsyncSynchronizationContext

Registration method. Call this from OnLaunched and OnActivated inside the App.xaml.cs

RegisterForFrame ( System.Windows.Controls.Frame rootFrame, CrashHandler handler ) : AsyncSynchronizationContext

Links the synchronization context to the specified frame and ensures that it is still in use after each navigation event

Send ( SendOrPostCallback d, object state ) : void

When overridden in a derived class, dispatches a synchronous message to a synchronization context.

Private Methods

Méthode Description
EnsureContext ( SynchronizationContext context ) : void
WrapCallback ( SendOrPostCallback sendOrPostCallback ) : SendOrPostCallback

Method Details

AsyncSynchronizationContext() public méthode

Initializes a new instance of the AsyncSynchronizationContext class.
public AsyncSynchronizationContext ( SynchronizationContext syncContext ) : System
syncContext System.Threading.SynchronizationContext The synchronize context.
Résultat System

CreateCopy() public méthode

When overridden in a derived class, creates a copy of the synchronization context.
public CreateCopy ( ) : SynchronizationContext
Résultat System.Threading.SynchronizationContext

OperationCompleted() public méthode

When overridden in a derived class, responds to the notification that an operation has completed.
public OperationCompleted ( ) : void
Résultat void

OperationStarted() public méthode

When overridden in a derived class, responds to the notification that an operation has started.
public OperationStarted ( ) : void
Résultat void

Post() public méthode

When overridden in a derived class, dispatches an asynchronous message to a synchronization context.
public Post ( SendOrPostCallback d, object state ) : void
d SendOrPostCallback The delegate to call.
state object The object passed to the delegate.
Résultat void

Register() public static méthode

Registration method. Call this from OnLaunched and OnActivated inside the App.xaml.cs
public static Register ( ) : AsyncSynchronizationContext
Résultat AsyncSynchronizationContext

RegisterForFrame() public static méthode

Links the synchronization context to the specified frame and ensures that it is still in use after each navigation event
rootFrame
public static RegisterForFrame ( System.Windows.Controls.Frame rootFrame, CrashHandler handler ) : AsyncSynchronizationContext
rootFrame System.Windows.Controls.Frame The root frame.
handler CrashHandler The handler.
Résultat AsyncSynchronizationContext

Send() public méthode

When overridden in a derived class, dispatches a synchronous message to a synchronization context.
public Send ( SendOrPostCallback d, object state ) : void
d SendOrPostCallback The delegate to call.
state object The object passed to the delegate.
Résultat void