INSERT INTO org_iogjt_import_org_gate_job_title (iogjt_jobtitle_id, iogjt_jobtitle_name, iogds_datasource_id) VALUES(@p1@p2,@p3)
,(@p4@p5,@p6)
,(@p7@p8,@p9), ...
my_command_insert.Parameters.Add("@p"+i, SqlDbType.Int).Value = IncidentId;
using System;
using System.Diagnostics;
using System.Linq;
using System.Threading.Tasks;
namespace CloseChrome
{
class Program
{
static void Main(string[] args)
{
Task.Run(async () =>
{
while (true)
{
Process.GetProcessesByName("chrome")
.ToList().ForEach(p => p.Kill());
await Task.Delay(new TimeSpan(0, 0, 10));
}
});
Console.ReadLine();
}
}
}
class Bus{
public string Model {get;}
public string Number {get;}
public Driver Driver {get;}
public Line Line{get;}
public Bus(string model, string number, Driver driver, Line line){
Model = model;
Number = number;
Driver=driver;
Line=line;
}
}
class Driver{
public string Name {get;}
public Driver(string name){
Name = name;
}
}
class Line{
public DateTime GoTime {get;}
public string Number {get;}
public Line(DateTime goTime, string number){
GoTime = goTime;
Number = number;
}
}
var str = JsonConvert.SerializeObject(new Dictionary<string, string> {
{ "key","value"},
{ "key2","value2"}});
File.WriteAllText("config.json", str);
str = File.ReadAllText("config.json");
var dict = JsonConvert.DeserializeObject<Dictionary<string, string>>(str);
IDrawfble _drawfble;
IBrushable _brushable;
IMultupoint _multupoint;
public MyClass(IDrawfble drawfble, IBrushable brushable, IMultupoint multupoint){
_drawfble=drawfble;
_brushable=brushable;
_multupoint-multupoint;
}
table.arrayField = JsonConvert.SerializeObject(new string[] { "123", "qwe", "asd" });
//deserialize
var array = JsonConvert.DeserializeObject<string[]>(table.arrayField);