[This is preliminary documentation and is subject to change.]

Gets value indicationg if given Type has default constructor

Namespace: Tools
Assembly: Tools (in Tools.dll) Version: 1.5.3.38916 (1.5.3.38916)

Syntax

C#
public static bool HasDefaultCTor(
	this Type Type,
	BindingFlags Attributes
)
Visual Basic
<ExtensionAttribute> _
Public Shared Function HasDefaultCTor ( _
	Type As Type, _
	Attributes As BindingFlags _
) As Boolean
Visual C++
[ExtensionAttribute]
public:
static bool HasDefaultCTor(
	Type^ Type, 
	BindingFlags Attributes
)
F#
static member HasDefaultCTor : 
        Type:Type * 
        Attributes:BindingFlags -> bool 
JScript
public static function HasDefaultCTor(
	Type : Type, 
	Attributes : BindingFlags
) : boolean

Parameters

Type
Type: System..::..Type
Type to check
Attributes
Type: System.Reflection..::..BindingFlags
Optionaly specifies aaccesibility attributes for default constructor. Default is Public.

Return Value

[Missing <returns> documentation for "M:Tools.TypeTools.HasDefaultCTor(System.Type,System.Reflection.BindingFlags)"]

Usage Note

In Visual Basic and C#, you can call this method as an instance method on any object of type Type. When you use instance method syntax to call this method, omit the first parameter. For more information, see or .

Remarks

True if type has default (parameterless) CTor, fale otherwise.

Exceptions

ExceptionCondition
System..::..ArgumentNullExceptionType is null

See Also