21 lines
542 B
C#
Executable File
21 lines
542 B
C#
Executable File
using System;
|
|
using Objection;
|
|
using ThoughtWorks.CruiseControl.WebDashboard.MVC.Cruise;
|
|
|
|
namespace ThoughtWorks.CruiseControl.WebDashboard.Dashboard
|
|
{
|
|
public class ActionInstantiatorWithObjectSource : IActionInstantiator
|
|
{
|
|
private readonly ObjectSource objectSource;
|
|
|
|
public ActionInstantiatorWithObjectSource(ObjectSource objectSource)
|
|
{
|
|
this.objectSource = objectSource;
|
|
}
|
|
|
|
public ICruiseAction InstantiateAction(Type actionType)
|
|
{
|
|
return (ICruiseAction) objectSource.GetByType(actionType);
|
|
}
|
|
}
|
|
} |