问题描述
我有一个复杂的对象file_path = "a.js"
with open(file_path,"r") as f:
data = f.readlines()
with open(file_path,"w") as f:
removing = False
for line in data :
if '}' in line and removing:
removing = False
continue
if 'if (aaaaa == b) {' in line:
removing = True
if not removing: f.write(line)
,我不直接控制它,并且想从代表该对象的xml字符串中创建该对象的实例。
我试图做:
x=(w-tw)/2:y=h/6-th/2
但是我得到了著名的错误:
MyClass
有没有一种方法可以通过xml字符串创建我的对象,而无需添加相关对象的任何注释?
谢谢
解决方法
暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!
如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。
小编邮箱:dio#foxmail.com (将#修改为@)