// Class constructor. The reference to the PSWorkflowConfigurationProvider must be available to the class to access configuration properties.
        // The workflow instance reference provides access to the instance ID and properties during load and save operations.
        public SampleSqlInstanceStore(PSWorkflowConfigurationProvider configuration, PSWorkflowInstance instance, string connectionString)
            : base(instance)
        {
            _configuration         = configuration;
            this._connectionString = connectionString;

            this._psWorkflowStore = new SqlOperations(connectionString);
        }
Esempio n. 2
0
 // Override this method so that the runtime uses this instance store rather than the default store.
 public override PSWorkflowInstanceStore CreatePSWorkflowInstanceStore(PSWorkflowInstance workflowInstance)
 {
     return(new SampleSqlInstanceStore(this, workflowInstance, _connectionString));
 }