def __init__(self, length, name, mappinginfo):
    self.length = length
    self.name = name
    cols = inspect(self.__class__).columns
    if (len(mappinginfo) != (len(cols) - 3)):
        raise TypeError
    for col in mappinginfo:
        setattr(self, str((u'sch_' + col['label']['name'])), int(col['col']))
def __init__(self, length, name, mappinginfo):
    self.length = length
    self.name = name
    cols = inspect(self.__class__).columns
    if (len(mappinginfo) != (len(cols) - 3)):
        raise TypeError
    for col in mappinginfo:
        setattr(self, str((u'sch_' + col['label']['name'])), int(col['col']))