1 classCat(Animal): 2 def __init__(self): 3 importwarnings 4 warnings.warn("Cat类带删除线了", DeprecationWarning) 5 6 defrun(self): 7 importwarnings 8 warnings.warn("run方法带删除线了", DeprecationWarning)
python 对过时类或方法添加删除线的方法
免责声明:文章转载自《python 对过时类或方法添加删除线的方法》仅用于学习参考。如对内容有疑问,请及时联系本站处理。
宿迁高防,2C2G15M,22元/月;香港BGP,2C5G5M,25元/月 雨云优惠码:MjYwNzM=