2014-05-21 21:02:31 +00:00
|
|
|
|
using System;
|
|
|
|
|
|
|
|
|
|
namespace Mustache
|
|
|
|
|
{
|
|
|
|
|
public class PlaceholderArgument : IArgument
|
|
|
|
|
{
|
|
|
|
|
private readonly string name;
|
|
|
|
|
|
|
|
|
|
public PlaceholderArgument(string name)
|
|
|
|
|
{
|
|
|
|
|
this.name = name;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
public string GetKey()
|
|
|
|
|
{
|
|
|
|
|
return name;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
public object GetValue(Scope keyScope, Scope contextScope)
|
|
|
|
|
{
|
2016-03-21 17:41:46 +00:00
|
|
|
|
return keyScope.Find(name, false);
|
2014-05-21 21:02:31 +00:00
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|