Class ModestConstructorQuery
Selects public constructors ordered by the most modest constructor first.
Inheritance
System.Object
ModestConstructorQuery
Implements
Inherited Members
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.ToString()
Namespace: AutoFixture.Kernel
Assembly: AutoFixture.dll
Syntax
public class ModestConstructorQuery : IMethodQuery
Methods
| Improve this Doc View SourceSelectMethods(Type)
Selects the constructors for the supplied type.
Declaration
public IEnumerable<IMethod> SelectMethods(Type type)
Parameters
Type | Name | Description |
---|---|---|
System.Type | type | The type. |
Returns
Type | Description |
---|---|
System.Collections.Generic.IEnumerable<IMethod> | All public constructors for |
Remarks
The ordering of the returned constructors is based on the number of parameters of the constructor. Constructors with fewer parameters are returned before constructors with more parameters. This means that if a default constructor exists, it will be the first one returned.
In case of two constructors with an equal number of parameters, the ordering is unspecified.