Click here to Skip to main content
15,892,480 members
Articles / Programming Languages / C#

WS-Enumeration for WCF/WF

Rate me:
Please Sign up or sign in to vote.
4.86/5 (5 votes)
4 Feb 2011CPOL5 min read 25.8K   220   10  
In this article, I describe the design and implementation of a WS-Enumeration for WCF.
using System;
using System.ComponentModel;
using System.ComponentModel.Design;
using System.Collections;
using System.Drawing;
using System.Reflection;
using System.Workflow.ComponentModel.Compiler;
using System.Workflow.ComponentModel.Serialization;
using System.Workflow.ComponentModel;
using System.Workflow.ComponentModel.Design;
using System.Workflow.Runtime;
using System.Workflow.Activities;
using System.Workflow.Activities.Rules;

namespace WSEnumerationWorkflow.FileSystem
{
    partial class WorkflowRenew
    {
        #region Designer generated code

        /// <summary> 
        /// Required method for Designer support - do not modify 
        /// the contents of this method with the code editor.
        /// </summary>
        [System.Diagnostics.DebuggerNonUserCode]
        private void InitializeComponent()
        {
            this.CanModifyActivities = true;
            System.Workflow.ComponentModel.ActivityBind activitybind1 = new System.Workflow.ComponentModel.ActivityBind();
            System.Workflow.ComponentModel.WorkflowParameterBinding workflowparameterbinding1 = new System.Workflow.ComponentModel.WorkflowParameterBinding();
            System.Workflow.ComponentModel.ActivityBind activitybind2 = new System.Workflow.ComponentModel.ActivityBind();
            System.Workflow.ComponentModel.WorkflowParameterBinding workflowparameterbinding2 = new System.Workflow.ComponentModel.WorkflowParameterBinding();
            System.Workflow.ComponentModel.ActivityBind activitybind3 = new System.Workflow.ComponentModel.ActivityBind();
            System.Workflow.ComponentModel.WorkflowParameterBinding workflowparameterbinding3 = new System.Workflow.ComponentModel.WorkflowParameterBinding();
            this.WSEnumerationRenewResponse = new System.Workflow.Activities.CallExternalMethodActivity();
            this.RenewExecutor = new System.Workflow.Activities.CodeActivity();
            this.WSEnumerationRenewRequest = new System.Workflow.Activities.HandleExternalEventActivity();
            // 
            // WSEnumerationRenewResponse
            // 
            this.WSEnumerationRenewResponse.InterfaceType = typeof(WSEnumeration.Adapters.IWSEnumerationLocalServiceOut);
            this.WSEnumerationRenewResponse.MethodName = "RaiseResponseEvent";
            this.WSEnumerationRenewResponse.Name = "WSEnumerationRenewResponse";
            activitybind1.Name = "WorkflowRenew";
            activitybind1.Path = "EnumerationDescriptor";
            workflowparameterbinding1.ParameterName = "ed";
            workflowparameterbinding1.SetBinding(System.Workflow.ComponentModel.WorkflowParameterBinding.ValueProperty, ((System.Workflow.ComponentModel.ActivityBind)(activitybind1)));
            activitybind2.Name = "WorkflowRenew";
            activitybind2.Path = "WorkflowInstanceID";
            workflowparameterbinding2.ParameterName = "workflowInstanceId";
            workflowparameterbinding2.SetBinding(System.Workflow.ComponentModel.WorkflowParameterBinding.ValueProperty, ((System.Workflow.ComponentModel.ActivityBind)(activitybind2)));
            this.WSEnumerationRenewResponse.ParameterBindings.Add(workflowparameterbinding1);
            this.WSEnumerationRenewResponse.ParameterBindings.Add(workflowparameterbinding2);
            this.WSEnumerationRenewResponse.MethodInvoking += new System.EventHandler(this.WSEnumerationRenewResponse_Invoking);
            // 
            // RenewExecutor
            // 
            this.RenewExecutor.Name = "RenewExecutor";
            this.RenewExecutor.ExecuteCode += new System.EventHandler(this.ProcessRenew_ExecuteCode);
            // 
            // WSEnumerationRenewRequest
            // 
            this.WSEnumerationRenewRequest.EventName = "Request";
            this.WSEnumerationRenewRequest.InterfaceType = typeof(WSEnumeration.Adapters.IWSEnumerationLocalServiceIn);
            this.WSEnumerationRenewRequest.Name = "WSEnumerationRenewRequest";
            activitybind3.Name = "WorkflowRenew";
            activitybind3.Path = "RequestEvent";
            workflowparameterbinding3.ParameterName = "e";
            workflowparameterbinding3.SetBinding(System.Workflow.ComponentModel.WorkflowParameterBinding.ValueProperty, ((System.Workflow.ComponentModel.ActivityBind)(activitybind3)));
            this.WSEnumerationRenewRequest.ParameterBindings.Add(workflowparameterbinding3);
            this.WSEnumerationRenewRequest.Invoked += new System.EventHandler<System.Workflow.Activities.ExternalDataEventArgs>(this.WSEnumerationRenewRequest_Invoked);
            // 
            // WorkflowRenew
            // 
            this.Activities.Add(this.WSEnumerationRenewRequest);
            this.Activities.Add(this.RenewExecutor);
            this.Activities.Add(this.WSEnumerationRenewResponse);
            this.Name = "WorkflowRenew";
            this.CanModifyActivities = false;

        }

        #endregion

        private CallExternalMethodActivity WSEnumerationRenewResponse;
        private CodeActivity RenewExecutor;
        private HandleExternalEventActivity WSEnumerationRenewRequest;











    }
}

By viewing downloads associated with this article you agree to the Terms of Service and the article's licence.

If a file you wish to view isn't highlighted, and is a text file (not binary), please let us know and we'll add colourisation support for it.

License

This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)


Written By
Software Developer
Russian Federation Russian Federation
I have Master degree in Particle Physics. During my last several years I work as software developer.

Primary Interests
- c#, c++, php, java.
- scientific programming

Comments and Discussions