1 PowerDesigner中在生成的数据库脚本中用name列替换comment列作为字段描述的方法如下, 依次打开Tools -- Execute Commands -- Run Script,运行以下脚本: Option Explicit ValidationMode = True InteractiveMode = im_Batch Dim mdl 'the current model 'get the current active model Set mdl = ActiveModel
#!/usr/local/bin/python # -*- coding: UTF-8 -*- #coding:gbk import re import os w_str="" x="assets2.res.json" fopen=open(x,'r') number=1 for line in fopen: list1=re.findall(r"\"name\"\:\"(.+?)\"",line) lis
类的是劣化过程解剖 类的语法 class Dog(object): print("hello,I am a dog!") d = Dog() #实例化这个类 #此时的d就是类Dog的实例化对象 #实例化,其实就是以Dog类为模版,在内存里开辟一块空间,存上数据,赋值成一个变量名 注:上面的代码其实有问题,想给狗起名字传不进去 传如名字,类的局部函数内的转换过程 class Dog(object): def __init__(self,name): #构造函数,构造方法==初始化方法 s
import os, time import sys import re def read_old_part(filename, start, end): content = [] recording = False with open(filename) as f: for line in f: line = line.strip() if line == end: break if recording: content.append(line) if line == start: recor