C# Class ImageGlass.Services.InstanceManagement.SingleInstance

Enforces single instance for an application.
Inheritance: IDisposable
Afficher le fichier Open project: d2phap/ImageGlass Class Usage Examples

Méthodes publiques

Méthode Description
Dispose ( ) : void
ListenForArgumentsFromSuccessiveInstances ( ) : void

Listens for arguments being passed from successive instances of the applicaiton.

PassArgumentsToFirstInstance ( String arguments ) : System.Boolean

Passes the given arguments to the first running instance of the application.

SingleInstance ( System.Guid identifier ) : System

Enforces single instance for an application.

Méthodes protégées

Méthode Description
Dispose ( bool disposing ) : void

Private Methods

Méthode Description
CallOnArgumentsReceived ( Object state ) : void

Calls the OnArgumentsReceived method casting the state Object to String[].

ListenForArguments ( Object state ) : void

Listens for arguments on a named pipe.

OnArgumentsReceived ( String arguments ) : void

Fires the ArgumentsReceived event.

Method Details

Dispose() public méthode

public Dispose ( ) : void
Résultat void

Dispose() protected méthode

protected Dispose ( bool disposing ) : void
disposing bool
Résultat void

ListenForArgumentsFromSuccessiveInstances() public méthode

Listens for arguments being passed from successive instances of the applicaiton.
public ListenForArgumentsFromSuccessiveInstances ( ) : void
Résultat void

PassArgumentsToFirstInstance() public méthode

Passes the given arguments to the first running instance of the application.
public PassArgumentsToFirstInstance ( String arguments ) : System.Boolean
arguments String The arguments to pass.
Résultat System.Boolean

SingleInstance() public méthode

Enforces single instance for an application.
public SingleInstance ( System.Guid identifier ) : System
identifier System.Guid An identifier unique to this application.
Résultat System