# coding=utf-8 """ Source code for potential gp tool to create outputs based on attributes of an input. """ import arcpy import numbers import sys try: unicode except: unicode = str def get_unique_values(in_data, fields): &qu
类的三大特性 类的三大特性包括: 封装.继承.多态 一.封装 封装就是将类所用到的所有字段.属性.方法都包含在类代码段里面,当实例调用直接调用类中的方法即可. class People(object): def __init__(self,name): self.name = name def talk(self): print('my name is {0}'.format(self.name)) 将函数talk() 封装到了类People下面,当实例化调用此函数时,只需要实例名+方法名即可调