1
0
mirror of synced 2024-11-15 01:33:51 +00:00
PettingZoo/PettingZoo.Core/Macros/DateTimePayloadMacro.cs

19 lines
412 B
C#

using System;
namespace PettingZoo.Core.Macros
{
public class JsonDateTimePayloadMacro : BasePayloadMacro
{
public JsonDateTimePayloadMacro()
: base("JsonUtcNow", "Current date/time (yyyy-mm-ddThh:mm:ss.mmmZ)")
{
}
public override string GetValue()
{
return DateTime.UtcNow.ToString("yyyy-MM-dd'T'HH:mm:ss.fff'Z'");
}
}
}