Compartilhar via


WorkflowPersistenceService Construtor

Definição

Quando implementado em uma classe derivada, inicializa uma nova instância da classe WorkflowPersistenceService.

protected:
 WorkflowPersistenceService();
protected WorkflowPersistenceService ();
Protected Sub New ()

Exemplos

O exemplo a seguir demonstra a criação de uma instância da SqlWorkflowPersistenceService classe (derivada de WorkflowPersistenceService). Este exemplo é do exemplo de SDK de Manipuladores de Exceção Aninhados, da classe Program.cs. Para obter mais informações, consulte o exemplo de manipuladores de exceção aninhados.

// A workflow is always run asychronously; the main thread waits on this event so the program
// doesn't exit before the workflow completes
workflowRuntime.AddService(new SqlWorkflowPersistenceService("Initial Catalog=SqlPersistenceService;Data Source=localhost;Integrated Security=SSPI;"));
' A workflow is always run asychronously the main thread waits on Me event so the program
' doesn't exit before the workflow completes
WorkflowRuntime.AddService(New SqlWorkflowPersistenceService("Initial Catalog=SqlPersistenceServiceData Source=localhostIntegrated Security=SSPI"))

Aplica-se a