def _configure_subclass_mapper(mapper, context, path, adapter):
 def configure_subclass_mapper(discriminator):
  try:
   sub_mapper = mapper.polymorphic_map[discriminator]
  except KeyError:
   raise AssertionError(('No such polymorphic_identity %r is defined' % discriminator))
  if (sub_mapper is mapper):
   return None
  return instance_processor(sub_mapper, context, path, adapter, polymorphic_from=mapper)
 return configure_subclass_mapper

def _configure_subclass_mapper ( mapper , context , path , adapter ) : def configure_subclass_mapper ( discriminator ) : try : sub_mapper = mapper . polymorphic_map [ discriminator ] except KeyError : raise AssertionError ( ( 'No such polymorphic_identity %r is defined' % discriminator ) ) if ( sub_mapper is mapper ) : return None return instance_processor ( sub_mapper , context , path , adapter , polymorphic_from = mapper ) return configure_subclass_mapper
produce a mapper level row processor callable factory for mappers inheriting this one .