public override ResolveResultWithInfo ResolveWithoutCache()
{
ISymbolTable table = this.GetReferenceSymbolTable(true);
IList<DeclaredElementInstance> elements = new List<DeclaredElementInstance>();
{
IList<ISymbolInfo> infos = table.GetSymbolInfos(this.GetName());
foreach (ISymbolInfo info in infos)
{
var element = new DeclaredElementInstance(info.GetDeclaredElement(), EmptySubstitution.INSTANCE);
elements.Add(element);
}
}
if (elements.Count == 0)
{
var ruleName = this.myOwner as Prefix;
// Unresolved namespaces creation
if (ruleName != null)
{
elements = new List<DeclaredElementInstance>
{
new DeclaredElementInstance(
new UnresolvedNamespacePrefixDeclaredElement(
ruleName.GetSourceFile(), this.GetName(), this.myOwner.GetPsiServices()))
};
}
}
return new ResolveResultWithInfo(ResolveResultFactory.CreateResolveResultFinaly(elements), ResolveErrorType.OK);
}