System.CodeDom.CodeObjectCreateExpression Class

Assembly: System.dll
Namespace: System.CodeDom
Summary
Represents an expression that creates a new instance of an object.
C# Syntax:
[Serializable]
public class CodeObjectCreateExpression : CodeExpression
Remarks
CodeObjectCreateExpression can be used to represent an expression that creates an instance of an object.
See also:
System.CodeDom Namespace

System.CodeDom.CodeObjectCreateExpression Member List:

Public Constructors
ctor #1 Overloaded:
.ctor()

Default constructor. This constructor is called by derived class constructors to initialize state in this type.
Initializes a new instance of the CodeObjectCreateExpression class.
ctor #2 Overloaded:
.ctor(CodeTypeReference createType, params CodeExpression[] parameters)

Initializes a new instance of the CodeObjectCreateExpression class using the specified type and parameters.
ctor #3 Overloaded:
.ctor(string createType, params CodeExpression[] parameters)

Initializes a new instance of the CodeObjectCreateExpression class using the specified type and parameters.
ctor #4 Overloaded:
.ctor(Type createType, params CodeExpression[] parameters)

Initializes a new instance of the CodeObjectCreateExpression class using the specified type and parameters.
Public Properties
CreateType Read-write

Gets or sets the data type of the object to create.
Parameters Read-only

Gets or sets the parameters to use in creating the object.
UserData
(inherited from System.CodeDom.CodeObject)
Read-only

See base class member description: System.CodeDom.CodeObject.UserData


Gets or sets the user-definable data for the current object.
Public Methods
Equals
(inherited from System.Object)
See base class member description: System.Object.Equals

Derived from System.Object, the primary base class for all objects.
GetHashCode
(inherited from System.Object)
See base class member description: System.Object.GetHashCode

Derived from System.Object, the primary base class for all objects.
GetType
(inherited from System.Object)
See base class member description: System.Object.GetType

Derived from System.Object, the primary base class for all objects.
ToString
(inherited from System.Object)
See base class member description: System.Object.ToString

Derived from System.Object, the primary base class for all objects.
Protected Methods
Finalize
(inherited from System.Object)
See base class member description: System.Object.Finalize

Derived from System.Object, the primary base class for all objects.
MemberwiseClone
(inherited from System.Object)
See base class member description: System.Object.MemberwiseClone

Derived from System.Object, the primary base class for all objects.

Hierarchy:


System.CodeDom.CodeObjectCreateExpression Member Details

Overloaded ctor #1
Summary
Initializes a new instance of the CodeObjectCreateExpression class.

Default constructor. This constructor is called by derived class constructors to initialize state in this type.
C# Syntax:
public CodeObjectCreateExpression();

Return to top


Overloaded ctor #2
Summary
Initializes a new instance of the CodeObjectCreateExpression class using the specified type and parameters.
C# Syntax:
public CodeObjectCreateExpression(
   CodeTypeReference createType,
   params CodeExpression[] parameters
);
Parameters:

createType

A CodeTypeReference that indicates the data type of the object to create.

parameters

An array of CodeExpression objects that indicates the parameters to use to create the object.

See also:
CodeExpression

Return to top


Overloaded ctor #3
Summary
Initializes a new instance of the CodeObjectCreateExpression class using the specified type and parameters.
C# Syntax:
public CodeObjectCreateExpression(
   string createType,
   params CodeExpression[] parameters
);
Parameters:

createType

The name of the data type of object to create.

parameters

An array of CodeExpression objects that indicates the parameters to use to create the object.

Return to top


Overloaded ctor #4
Summary
Initializes a new instance of the CodeObjectCreateExpression class using the specified type and parameters.
C# Syntax:
public CodeObjectCreateExpression(
   Type createType,
   params CodeExpression[] parameters
);
Parameters:

createType

The data type of the object to create.

parameters

An array of CodeExpression objects that indicates the parameters to use to create the object.

Return to top


Property: CreateType (read-write)
Summary
Gets or sets the data type of the object to create.
C# Syntax:
public CodeTypeReference CreateType {get; set;}

Return to top


Property: Parameters (read-only)
Summary
Gets or sets the parameters to use in creating the object.
C# Syntax:
public CodeExpressionCollection Parameters {get;}
See also:
CodeExpressionCollection

Return to top


Property: UserData (read-only)
Inherited
See base class member description: System.CodeDom.CodeObject.UserData

Summary
Gets or sets the user-definable data for the current object.
C# Syntax:
public IDictionary UserData {get;}
Remarks


Notes to inheritors: An inheritor can design the way this user data is stored, retrieved, and used.

Return to top


Method: Equals(
   object obj
)
Inherited
See base class member description: System.Object.Equals
C# Syntax:
public virtual bool Equals(
   object obj
);

For more information on members inherited from System.Object click on the link above.

Return to top


Method: Finalize()
Inherited
See base class member description: System.Object.Finalize
C# Syntax:
~CodeObjectCreateExpression();

For more information on members inherited from System.Object click on the link above.

Return to top


Method: GetHashCode()
Inherited
See base class member description: System.Object.GetHashCode
C# Syntax:
public virtual int GetHashCode();

For more information on members inherited from System.Object click on the link above.

Return to top


Method: GetType()
Inherited
See base class member description: System.Object.GetType
C# Syntax:
public Type GetType();

For more information on members inherited from System.Object click on the link above.

Return to top


Method: MemberwiseClone()
Inherited
See base class member description: System.Object.MemberwiseClone
C# Syntax:
protected object MemberwiseClone();

For more information on members inherited from System.Object click on the link above.

Return to top


Method: ToString()
Inherited
See base class member description: System.Object.ToString
C# Syntax:
public virtual string ToString();

For more information on members inherited from System.Object click on the link above.

Return to top


Top of page

Copyright (c) 2002 Microsoft Corporation. All rights reserved.