Expandable Node Params - GhostLabsAB/Examples GitHub Wiki
Expandable node params is a list of value pairs that the adapter will populate for every processed message.
This list will be passed with the message and can be used later on in other adapter configurations or in message routing.
Please note that the message content is not affected when adding these params.
Example:
[Export(typeof(INodeExpandableParametersBase))]
public class ExpandableNodeParams : NodeExpandableParametersBase<ExpandableNodeParams>
{
[DisplayName("Name"), Description("Gets the name of the file."), Category("Expandable")]
public string Name { get; set; }
[DisplayName("FileName")]
[Description("Gets the name of the file.")]
[Category("Expandable")]
public string FileName { get; set; }
}
There are also a number of built-in expandable-params that can be used while configuring an adapter.
Pattern Expands to
============================= ===============================
%guid% -> Guid.NewGuid()
%guid64% -> Guid64.NextId().ToString()
%NewLine% -> Environment.NewLine
%MachineName% -> Environment.MachineName
%DateTimeFormat:{format}% -> DateTime.Now.ToString({format})
%UtcDateTimeFormat:{format}% -> DateTime.UtcNow.ToString({format})
%datetime% -> DateTime.Now.ToString("yyyy-MM-dd HH.mm.ss.ffff")
%utc_datetime% -> DateTime.UtcNow.ToString("yyyy-MM-dd HH.mm.ss.ffff")
%time% -> DateTime.Now.ToString("HH.mm.ss.ffff")
%utc_time% -> DateTime.UtcNow.ToString("HH.mm.ss.ffff")
%date% -> DateTime.Now.ToString("yyyy-MM-dd")
%utc_date% -> DateTime.UtcNow.ToString("yyyy-MM-dd")
%completemessage% -> message.GetDataAsString()
%MessageLength% -> message.MessageLength
%MessageID% -> message.MessageID
%link% -> link.Name