The follows is my code snippet, and I want to deliver the List parameter to my construct.
public class MyClass
{
public MyClass(List<string> parmList)
{
this.MyList=parmList;
}
public List<string> MyList
{
get;set;
}
}
The config:
<alias alias="List" type="System.Collections.Generic.List[[System.String,
mscorlib],mscorlib]"/>
<register>
<constructor>
<param name="paraList" type="List" />
</constructor>
</register>
But when I resolve request to the container it throw out the exception:
The type List`1 has multiple constructors of length 1. Unable to disambiguate.
Is there any configuration error?