Newtonsoft.Json.JsonTextWriter.JsonTextWriter C# (CSharp) Method

JsonTextWriter() public method

Initializes a new instance of the JsonTextWriter class using the specified TextWriter.
public JsonTextWriter ( TextWriter textWriter ) : System
textWriter System.IO.TextWriter The to write to.
return System
        public JsonTextWriter(TextWriter textWriter)
        {
            if (textWriter == null)
            {
                throw new ArgumentNullException(nameof(textWriter));
            }

            _writer = textWriter;
            _quoteChar = '"';
            _quoteName = true;
            _indentChar = ' ';
            _indentation = 2;

            UpdateCharEscapeFlags();
        }