def _get_out_class(tables):
 out_class = tables[0].__class__
 for t in tables[1:]:
  if issubclass(t.__class__, out_class):
   out_class = t.__class__
 return out_class

def _get_out_class ( tables ) : out_class = tables [ 0 ] . __class__ for t in tables [ 1 : ] : if issubclass ( t . __class__ , out_class ) : out_class = t . __class__ return out_class
from a list of table instances get the merged output table class .