コード例 #1
0
ファイル: MapReader.cs プロジェクト: Violet-Liu/Learn
        /// <summary>
        /// 转为JSONstr
        /// </summary>
        /// <returns></returns>
        public string ToJsonStringByFastJson()
        {
            Dictionary <int, Node> ele = this.elements;

            JsonNode[] jn = new JsonNode[ele.Count];
            int        i  = 0;

            foreach (Node n in ele.Values)
            {
                jn[i] = JsonNode.Create(n);
                i++;
            }
            //fastJSON.JSON.ClearReflectionCache();
            return(jn.ToJson_Fast());
        }