NLog.Layouts.SimpleLayout.ToString C# (CSharp) Method

ToString() public method

Returns a that represents the current object.
public ToString ( ) : string
return string
        public override string ToString()
        {
            return "'" + this.Text + "'";
        }

Usage Example

Exemplo n.º 1
0
        public void SimpleLayoutToStringTest()
        {
            var l = new SimpleLayout("xx${level}yy");
            Assert.Equal("'xx${level}yy'", l.ToString());

            var l2 = new SimpleLayout(new LayoutRenderer[0], "someFakeText", ConfigurationItemFactory.Default);
            Assert.Equal("'someFakeText'", l2.ToString());
        }
All Usage Examples Of NLog.Layouts.SimpleLayout::ToString