public static String getCallSimpleName ( XAbstractFeatureCall featureCall , ILogicalContainerProvider logicalContainerProvider , IdentifiableSimpleNameProvider featureNameProvider , Function0 < ? extends String > nullKeyword , Function0 < ? extends String > thisKeyword , Function0 < ? extends String > superKeyword , Function1 < ? super JvmIdentifiableElement , ? extends String > referenceNameLambda ) { String name = null ; final JvmIdentifiableElement calledFeature = featureCall . getFeature ( ) ; if ( calledFeature instanceof JvmConstructor ) { final JvmDeclaredType constructorContainer = ( ( JvmConstructor ) calledFeature ) . getDeclaringType ( ) ; final JvmIdentifiableElement logicalContainer = logicalContainerProvider . getNearestLogicalContainer ( featureCall ) ; final JvmDeclaredType contextType = ( ( JvmMember ) logicalContainer ) . getDeclaringType ( ) ; if ( contextType == constructorContainer ) { name = thisKeyword . apply ( ) ; } else { name = superKeyword . apply ( ) ; } } else if ( calledFeature != null ) { final String referenceName = referenceNameLambda . apply ( calledFeature ) ; if ( referenceName != null ) { name = referenceName ; } else if ( calledFeature instanceof JvmOperation ) { name = featureNameProvider . getSimpleName ( calledFeature ) ; } else { name = featureCall . getConcreteSyntaxFeatureName ( ) ; } } if ( name == null ) { return nullKeyword . apply ( ) ; } return name ; }
Compute the simple name for the called feature .