28 lines
662 B
C#
28 lines
662 B
C#
using Newtonsoft.Json;
|
|
using System;
|
|
using System.Collections.Generic;
|
|
using System.Linq;
|
|
using System.Security.AccessControl;
|
|
using System.Text;
|
|
using System.Threading.Tasks;
|
|
using System.Xml;
|
|
|
|
namespace New_Spider
|
|
{
|
|
public class ITextGen
|
|
{
|
|
|
|
/// <summary>
|
|
/// 生成json文件
|
|
/// </summary>
|
|
/// <param name="jsons"></param>
|
|
public void GenJson(string jsons, string Ids)
|
|
{
|
|
string jsonString = JsonConvert.SerializeObject(jsons, Newtonsoft.Json.Formatting.Indented);
|
|
File.WriteAllText(string.Format(@"D:\\jsondoc\\2023-09-14\\{0}.json",Ids), jsonString);
|
|
}
|
|
}
|
|
|
|
|
|
|
|
} |