MustacheSharp/mustache-sharp/PlaceholderArgument.cs

25 lines
444 B
C#

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)
{
return keyScope.Find(name);
}
}
}