public class TaskWrapper : ITaskWrapper
{
public TaskWrapper(Action action)
{
this.action = action;
}
}
public void Connect()
{
Program.Container.Resolve<TaskWrapper>(new NamedParameter("action", ToConnect)); // не работает!
Program.Container.Resolve<TaskWrapper>(new TypedParameter(typeof(Action), ToConnect)); // не работает!
}
private void ToConnect()
{
// some code...
}