System.CodeDom.CodeTypeConstructor Class

Represents a static constructor for a class.

See Also: CodeTypeConstructor Members


public class CodeTypeConstructor : CodeMemberMethod


System.CodeDom.CodeTypeConstructor can be used to represent the static constructor for a class. A static constructor is called once when the type is loaded.


Not all languages support static constructors. Support for static constructors can be checked by calling System.CodeDom.Compiler.ICodeGenerator.Supports(System.CodeDom.Compiler.GeneratorSupport) with the System.CodeDom.Compiler.GeneratorSupport.StaticConstructors flag to determine if static constructors are supported by the code generator for a particular language.


Namespace: System.CodeDom
Assembly: System (in System.dll)
Assembly Versions: 1.0.3300.0, 1.0.5000.0,,