private void InitializeWriter()
{
_nodeType = JsonNodeType.None;
_dataType = JsonDataType.None;
_isWritingDataTypeAttribute = false;
_wroteServerTypeAttribute = false;
_isWritingServerTypeAttribute = false;
_serverTypeValue = null;
_attributeText = null;
if (_depth != 0)
{
_depth = 0;
}
if ((_scopes != null) && (_scopes.Length > JsonGlobals.maxScopeSize))
{
_scopes = null;
}
// Can't let writeState be at Closed if reinitializing.
_writeState = WriteState.Start;
_endElementBuffer = false;
_indentLevel = 0;
}