private static ITypeElement GetClassForMethodSearch(IType invokedObjectType, [NotNull] IParametersOwner originalMethod, [NotNull] IPsiModule psiModule) { var containingType = originalMethod.GetContainingType(); if (containingType == null) { return(null); } if (!invokedObjectType.IsGenericIQueryable() || !IsEnumerable(containingType)) { return(containingType); } var queryableName = new ClrTypeName("System.Data.Entity.QueryableExtensions"); var queryableType = TypeFactory.CreateTypeByCLRName(queryableName, psiModule); var queryableTypeElement = queryableType.GetTypeElement(); return(queryableTypeElement); }
public ITypeElement GetClassForSearch(IParametersOwner originalMethod, IType invokedType) { var containingType = originalMethod.GetContainingType(); if (containingType == null) { return(null); } if (!invokedType.IsGenericIQueryable() || !containingType.IsEnumerableClass()) { return(null); } var queryableName = new ClrTypeName("System.Data.Entity.QueryableExtensions"); var queryableType = TypeFactory.CreateTypeByCLRName(queryableName, NullableAnnotation.Unknown, invokedType.Module); var queryableTypeElement = queryableType.GetTypeElement(); return(queryableTypeElement); }
public ITypeElement GetContainingType() => Owner.GetContainingType();
public ITypeElement GetClassForSearch(IParametersOwner originalMethod, IType invokedType) { return(originalMethod.GetContainingType()); }
public ITypeElement GetContainingType() => myParametersOwner.GetContainingType();