-
Notifications
You must be signed in to change notification settings - Fork 6
/
tempscript.py
92 lines (81 loc) · 2.83 KB
/
tempscript.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
# -*- coding: utf-8 -*-
"""
__project_ = 'hjp-bilink'
__file_name__ = 'tempscript.py'
__author__ = '十五'
__email__ = '[email protected]'
__time__ = '2022/8/17 0:57'
本文件用于将 linkinfo.db中的全部对象修改其sync行为
"""
import json
from lib.common_tools import funcs, G
# from lib.common_tools.compatible_import import *
# from lib.common_tools.objs import LinkDataPair
# from lib.common_tools import G, baseClass,funcs
# from lib.common_tools.widgets import ConfigWidget
# from lib.bilink.dialogs.linkdata_grapher import GViewAdmin, Grapher, GViewData
# from PyQt5.QtCore import
import sys
import faulthandler
import sqlite3
import abc
# from lib.clipper3.httpserver import Resquest,HTTPServer
from PyQt5.QtWidgets import QApplication, QDialog, QLabel, QPushButton, QVBoxLayout, QTextEdit
if __name__ == "__main__":
# app = QApplication(sys.argv)
# print(funcs.组件定制.长文本获取())
#
# sys.exit(app.exec_())
def 设置结点属性(结点编号: str, 属性名: str, 值):
assert type(结点编号) == str and type(属性名) == str
设置结点属性(1,2,3)
#
# DB = funcs.G.DB
# if DB.go(DB.table_linkinfo).exists(DB.EQ(card_id="1592550168494")):
# data_str = DB.select(DB.EQ(card_id="1592550168494")).return_all().zip_up()[0]["data"]
# print(json.loads(data_str))
# def 漫游路径生成之深度优先遍历():
# 栈 = ["1"]
# 结点集 = set(["1","2","3","4","5","6"])
# 已访问 = []
# 边集 = ["1,2","2,3","2,4","4,5","5,6","6,2"]
# while 结点集:
# if not 栈:
# 栈.append(结点集.pop())
# while 栈:
# 结点 = 栈.pop()
# 已访问.append(结点)
# 结点为起点的边集 = [边 for 边 in 边集 if 边.startswith(结点)]
# for 边 in 结点为起点的边集:
# 终点 = 边.split(",")[1]
# if 终点 not in 已访问:
# 栈.append(终点)
# 结点集 -= set(已访问)
# print(已访问)
# class 值类型:
# 数值="number"
# 时间戳="timestamp"
# 布尔 = "bool"
# 枚举 = lambda 枚举表:"enum:"+枚举表.__str__()
#
# print(值类型.枚举(["1","2","3"]))
pass
# def 播报(内容):
# return lambda :print(内容)
# 播报 = lambda 内容:lambda:print(内容)
# # def 内置():
# # print(内容)
# #
# # return 内置
# c = ["1","2","3"]
# e=[]
# [e.append((lambda :lambda:print(i))()) for i in c]
# # [lambda :e.append(lambda k=i:print(i)) for s in ["1","2","3"]]
# # list(map( lambda i: e.append(lambda:print(i)) , ["1","2","3"]))
# [e[i]() for i in range(3)]
# sys.exit()
# class A:
# def B(self):
# print("I'm A")
# C = A()
# print()