'Constructor
@param tablename: the table name'

def __init__(self, tablename):

    self.tablename = tablename
    table = self.define_table(tablename)
    if table:
        self.table = table
    else:
        raise AttributeError(('Undefined    dynamic    model:    %s' % tablename))
