#NEWLINE# def _find_entity_basestring( self , query , token , raiseerr ) : #NEWLINE# #INDENT# if token . endswith ( ( ':' + _WILDCARD_TOKEN ) ) : #NEWLINE# #INDENT# if ( len ( list ( query . _mapper_entities ) ) != 1 ) : #NEWLINE# #INDENT# if self : #NEWLINE# #INDENT# raise sa_exc . ArgumentError ( 'Wildcard loader can only be used with exactly one entity.  Use Load(ent) to specify specific entities.' ) #NEWLINE# #UNINDENT# #UNINDENT# #UNINDENT# else : #NEWLINE# #INDENT# if token . endswith ( _DEFAULT_TOKEN ) : #NEWLINE# #INDENT# raiseerr = False #NEWLINE# #UNINDENT# #UNINDENT# for ent in query . _mapper_entities : #NEWLINE# #INDENT# return ent #NEWLINE# #UNINDENT# else : #NEWLINE# #INDENT# if raiseerr : #NEWLINE# #INDENT# raise sa_exc . ArgumentError ( ( "Query has only expression-based entities - can't find property named '%s'." % ( token , ) ) ) #NEWLINE# #UNINDENT# else : #NEWLINE# #INDENT# return None