DBlog保存
This commit is contained in:
commit
a5d4bc6241
1 file changed
+2
-3
+2
-3
@@ -34,7 +34,6 @@ namespace DyeingComputer.UserClass
|
|||||||
}
|
}
|
||||||
// 创建一个字符串类型的队列
|
// 创建一个字符串类型的队列
|
||||||
public static Queue<QueueString> DBQueue = new Queue<QueueString>();
|
public static Queue<QueueString> DBQueue = new Queue<QueueString>();
|
||||||
|
|
||||||
public static void DBlog(string Name, string ID, string Api, string MESSAGE)
|
public static void DBlog(string Name, string ID, string Api, string MESSAGE)
|
||||||
{
|
{
|
||||||
Dictionary<string, object> API_LOG = new Dictionary<string, object>();//缓存函数
|
Dictionary<string, object> API_LOG = new Dictionary<string, object>();//缓存函数
|
||||||
@@ -72,7 +71,7 @@ namespace DyeingComputer.UserClass
|
|||||||
API_LOG.Clear();
|
API_LOG.Clear();
|
||||||
}
|
}
|
||||||
|
|
||||||
public static void LOGDB(string NAME, Dictionary<string, object> dat)
|
public static void LOGDB(string NAME, Dictionary<string, object> dat)//添加信息到队列
|
||||||
{
|
{
|
||||||
DBQueue.Enqueue(new QueueString
|
DBQueue.Enqueue(new QueueString
|
||||||
{
|
{
|
||||||
@@ -88,7 +87,7 @@ namespace DyeingComputer.UserClass
|
|||||||
if(DBQueue.Count==0) QueueT=false;
|
if(DBQueue.Count==0) QueueT=false;
|
||||||
}
|
}
|
||||||
|
|
||||||
public static void LOGDB()
|
public static void LOGDB()//从队列写入数据库
|
||||||
{
|
{
|
||||||
SQLiteHelpers = new SQLiteHelper(LOGAddress); //数据库连接路径
|
SQLiteHelpers = new SQLiteHelper(LOGAddress); //数据库连接路径
|
||||||
SQLiteHelpers.Open(); //打开数据库
|
SQLiteHelpers.Open(); //打开数据库
|
||||||
|
|||||||
Reference in new issue
Block a user