Export (0) Print
Expand All

WorkflowCompilerParameters Class

Note: This API is now obsolete.

Represents parameters passed to WorkflowCompiler during the compilation process.


Namespace:  System.Workflow.ComponentModel.Compiler
Assembly:  System.Workflow.ComponentModel (in System.Workflow.ComponentModel.dll)

[ObsoleteAttribute("The System.Workflow.* types are deprecated.  Instead, please use the new types from System.Activities.*")]
public sealed class WorkflowCompilerParameters : CompilerParameters

The WorkflowCompilerParameters type exposes the following members.

Public methodWorkflowCompilerParameters()Initializes a new instance of the WorkflowCompilerParameters class.
Public methodWorkflowCompilerParameters(String[])Initializes a new instance of the WorkflowCompilerParameters class, with the names of the assemblies used in compilation.
Public methodWorkflowCompilerParameters(WorkflowCompilerParameters)Initializes a new instance of the WorkflowCompilerParameters class from an existing instance.
Public methodWorkflowCompilerParameters(String[], String)Initializes a new instance of the WorkflowCompilerParameters class, with the names of the assemblies used in compilation, and the name to apply to the output file.
Public methodWorkflowCompilerParameters(String[], String, Boolean)Initializes a new instance of the WorkflowCompilerParameters class, with the names of the assemblies used in compilation, and the name to apply to the output file, and the designator for inclusion of debug information.

Public propertyCompilerOptionsGets or sets a string that contains command-line options for this compilation.
Public propertyCoreAssemblyFileNameGets or sets the name of the core or standard assembly that contains basic types such as Object, String, or Int32. (Inherited from CompilerParameters.)
Public propertyEmbeddedResourcesGets the .NET Framework resource files to include when compiling the assembly output. (Inherited from CompilerParameters.)
Public propertyEvidence Obsolete. Specifies an evidence object that represents the security policy permissions to grant the compiled assembly. (Inherited from CompilerParameters.)
Public propertyGenerateCodeCompileUnitOnlyGets or sets a value which indicates whether to generate only a CodeCompileUnit, or to call the C# or Visual Basic compiler to generate the executable or DLL.
Public propertyGenerateExecutableGets or sets a value indicating whether to generate an executable. (Inherited from CompilerParameters.)
Public propertyGenerateInMemoryGets or sets a value indicating whether to generate the output in memory. (Inherited from CompilerParameters.)
Public propertyIncludeDebugInformationGets or sets a value indicating whether to include debug information in the compiled executable. (Inherited from CompilerParameters.)
Public propertyLanguageToUseGets or sets a string which contains the language to use in compilation of the CodeCompileUnit.
Public propertyLibraryPathsGets the property that represents a collection of directory names under which compiler looks for referenced assemblies.
Public propertyLinkedResourcesGets the .NET Framework resource files that are referenced in the current source. (Inherited from CompilerParameters.)
Public propertyMainClassGets or sets the name of the main class. (Inherited from CompilerParameters.)
Public propertyOutputAssemblyGets or sets the name of the output assembly. (Inherited from CompilerParameters.)
Public propertyReferencedAssembliesGets the assemblies referenced by the current project. (Inherited from CompilerParameters.)
Public propertyTempFilesGets or sets the collection that contains the temporary files. (Inherited from CompilerParameters.)
Public propertyTreatWarningsAsErrorsGets or sets a value indicating whether to treat warnings as errors. (Inherited from CompilerParameters.)
Public propertyUserCodeCompileUnitsGets or sets the collection of code compile units which will be used in this invocation of the workflow compiler.
Public propertyUserTokenGets or sets the user token to use when creating the compiler process. (Inherited from CompilerParameters.)
Public propertyWarningLevelGets or sets the warning level at which the compiler aborts compilation. (Inherited from CompilerParameters.)
Public propertyWin32ResourceGets or sets the file name of a Win32 resource file to link into the compiled assembly. (Inherited from CompilerParameters.)

Public methodEquals(Object)Determines whether the specified object is equal to the current object. (Inherited from Object.)
Public methodGetHashCodeServes as the default hash function. (Inherited from Object.)
Public methodGetTypeGets the Type of the current instance. (Inherited from Object.)
Public methodToStringReturns a string that represents the current object. (Inherited from Object.)


This material discusses types and namespaces that are obsolete. For more information, see Deprecated Types in Windows Workflow Foundation 4.5.

The following code example demonstrates how to create a new instance of the WorkflowCompilerParameters class, add LibraryPaths and set the value for the CompilerParameters.OutputAssembly property. The code also creates a new instance of the WorkflowCompiler class and runs the WorkflowCompiler.Compile method. This code assumes that results is of type WorkflowCompilerResults. This code example is part of the Outlook Workflow Wizard SDK Sample from the WizardForm.cs file. For more information, see Outlook Workflow Wizard.

// Compile the workflow
String[] assemblyNames = { "ReadEmailActivity.dll" };
WorkflowCompiler compiler = new WorkflowCompiler();
WorkflowCompilerParameters parameters = new WorkflowCompilerParameters(assemblyNames);
parameters.OutputAssembly = "CustomOutlookWorkflow" + Guid.NewGuid().ToString() + ".dll";
results = compiler.Compile(parameters, this.xamlFile);

.NET Framework

Supported in: 4, 3.5, 3.0
Obsolete (compiler warning) in 4.5.2
Obsolete (compiler warning) in 4.5.1
Obsolete (compiler warning) in 4.5

Windows 8.1, Windows Server 2012 R2, Windows 8, Windows Server 2012, Windows 7, Windows Vista SP2, Windows Server 2008 (Server Core Role not supported), Windows Server 2008 R2 (Server Core Role supported with SP1 or later; Itanium not supported)

The .NET Framework does not support all versions of every platform. For a list of the supported versions, see .NET Framework System Requirements.

Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.
© 2014 Microsoft