#NEWLINE# def class_and_features_of_client_call( a_project ) : #NEWLINE# #INDENT# '\n        Retreive the name of the class under the current cursor context and\n        the list or features of this class. The cursor context must be a\n        client call.\n    ' #NEWLINE# l_features = a_project . feature_list ( get_class_from_buffer ( a_project ) ) #NEWLINE# l_features . extend ( get_local_variable ( a_project ) ) #NEWLINE# l_features . extend ( get_result_and_arguments ( a_project ) ) #NEWLINE# l_stack = create_row_object_stack ( ) #NEWLINE# l_old_class = None #NEWLINE# l_class = None #NEWLINE# l_generics = None #NEWLINE# l_index = ( - 1 ) #NEWLINE# i = ( len ( l_stack ) - 1 ) #NEWLINE# l_abort = False #NEWLINE# while ( ( i >= 0 ) and ( not l_abort ) ) : #NEWLINE# #INDENT# l_index = index_of_key_in_pair ( l_stack [ i ] , l_features ) #NEWLINE# if ( l_index >= 0 ) : #NEWLINE# #INDENT# l_old_class = l_class #NEWLINE# l_class = l_features [ l_index ] [ 1 ] #NEWLINE# l_old_generics = l_generics #NEWLINE# l_generics = l_features [ l_index ] [ 2 ] #NEWLINE# if l_class : #NEWLINE# #INDENT# l_features = a_project . exported_feature_list ( l_class ) #NEWLINE# if ( ( not l_features ) and l_old_class and l_old_generics ) : #NEWLINE# #INDENT# l_class_generics = a_project . class_generic ( l_old_class ) #NEWLINE# if l_generics : #NEWLINE# #INDENT# l_new_class = translate_generics_to_class ( l_class_generics , l_old_generics , l_class ) #NEWLINE# if l_new_class : #NEWLINE# #INDENT# l_class = l_new_class #NEWLINE# l_features = a_project . exported_feature_list ( l_class ) #NEWLINE# #UNINDENT# #UNINDENT# #UNINDENT# #UNINDENT# else : #NEWLINE# #INDENT# l_features = [ ] #NEWLINE# l_abort = True #NEWLINE# #UNINDENT# #UNINDENT# else : #NEWLINE# #INDENT# l_features = [ ] #NEWLINE# l_abort = True #NEWLINE# #UNINDENT# i = ( i - 1 ) #NEWLINE# #UNINDENT# return ( l_class , l_features )