Examples of processDeclarations()


Examples of com.intellij.psi.PsiElement.processDeclarations()

  public static boolean treeWalkUp(PsiElement place, PsiScopeProcessor processor) {
    PsiElement lastParent = null;
    PsiElement run = place;
    while (run != null) {
      if (!run.processDeclarations(processor, ResolveState.initial(), lastParent, place)) return false;
      lastParent = run;
      run = run.getContext(); //same as getParent
    }

    return true;
View Full Code Here

Examples of com.intellij.psi.PsiElement.processDeclarations()

  public static boolean processChildren(PsiElement element, PsiScopeProcessor processor,
                                        ResolveState substitutor, PsiElement lastParent, PsiElement place) {
    PsiElement run = lastParent == null ? element.getLastChild() : lastParent.getPrevSibling();
    while (run != null) {
      if (PsiTreeUtil.findCommonParent(place, run) != run && !run.processDeclarations(processor, substitutor, null, place))
        return false;
      run = run.getPrevSibling();
    }

    return true;
View Full Code Here

Examples of org.jetbrains.plugins.clojure.psi.impl.ns.ClSyntheticNamespace.processDeclarations()

                                          PsiElement first, ResolveState state, PsiElement lastParent) {
    if ((USE.equals(parentHead) || ClojureKeywords.USE.equals(parentHead)) &&
        first instanceof ClSymbol) {
      final ClSymbol symbol = (ClSymbol) first;
      final ClSyntheticNamespace namespace = NamespaceUtil.getNamespace(symbol.getNameString(), place.getProject());
      return namespace == null? true : namespace.processDeclarations(processor, state, lastParent, place);
    }
    return true;
  }

  private static boolean processDeclareDeclaration(PsiScopeProcessor processor, ClList list, PsiElement place, PsiElement lastParent) {
View Full Code Here

Examples of ro.redeul.google.go.lang.psi.GoPackage.processDeclarations()

        if ( ResolveStates.get(state, ResolveStates.Key.IsOriginalFile)) {
            GoPackages packages = GoPackages.getInstance(getProject());

            GoPackage myPackage = packages.getPackage(getPackageImportPath());
            if (myPackage != null &&
                    !myPackage.processDeclarations(processor, ResolveStates.currentPackage(), this.getOriginalFile(), place))
                return false;

            GoPackage builtinPackage = packages.getBuiltinPackage();
            if ( builtinPackage != null )
                return builtinPackage.processDeclarations(processor, ResolveStates.builtins(), lastParent, place);
View Full Code Here

Examples of ro.redeul.google.go.lang.psi.GoPackage.processDeclarations()

                    !myPackage.processDeclarations(processor, ResolveStates.currentPackage(), this.getOriginalFile(), place))
                return false;

            GoPackage builtinPackage = packages.getBuiltinPackage();
            if ( builtinPackage != null )
                return builtinPackage.processDeclarations(processor, ResolveStates.builtins(), lastParent, place);
        }

        return true;
    }
View Full Code Here

Examples of ro.redeul.google.go.lang.psi.GoPackage.processDeclarations()

        // import . "asdfaf" -> exports in the target package should act as declaration in the current one (but only if this is the initial state)
        if ( packageReference != null && packageReference.isLocal() && lastParent != null ) {
            GoPackage goPackage = getPackage();
            if ( goPackage != null )
                return goPackage.processDeclarations(processor, ResolveStates.packageExports(), null,  place);
        }

        return processor.execute(this, state);
    }
View Full Code Here

Examples of ro.redeul.google.go.lang.psi.statements.GoBlockStatement.processDeclarations()

        GoShortVarDeclaration varDeclaration = getAs(GoShortVarDeclaration.class, getElement().getParent());

        GoBlockStatement blockStatement = getAs(GoBlockStatement.class, varDeclaration.getParent());

        if ( blockStatement != null)
            blockStatement.processDeclarations(solver, ResolveStates.initial(), varDeclaration, this.getElement());
    }
}
View Full Code Here

Examples of ro.redeul.google.go.lang.psi.statements.GoSimpleStatement.processDeclarations()

        if (lastParent == null)
            return true;

        GoSimpleStatement statement = getSimpleStatement();
        if (statement != null && lastParent != statement) {
            if (!statement.processDeclarations(processor, state, null, place))
                return false;
        }

        return true;
    }
View Full Code Here

Examples of ro.redeul.google.go.lang.psi.statements.GoSimpleStatement.processDeclarations()

    public boolean processDeclarations(@NotNull PsiScopeProcessor processor,
                                       @NotNull ResolveState state,
                                       PsiElement lastParent,
                                       @NotNull PsiElement place) {
        GoSimpleStatement initStatement = getSimpleStatement();
        return lastParent == null || initStatement == null || lastParent == initStatement || initStatement.processDeclarations(processor, state, null, place);

    }
    public void accept(GoElementVisitor visitor) {
        visitor.visitSwitchExpressionStatement(this);
    }
View Full Code Here

Examples of ro.redeul.google.go.lang.psi.statements.GoSimpleStatement.processDeclarations()

            if (!typeGuard.processDeclarations(processor, state, null, place))
                return false;
        }

        GoSimpleStatement initStatement = getSimpleStatement();
        return !(initStatement != null && lastParent != initStatement) || initStatement.processDeclarations(processor, state, null, place);

    }

    public void accept(GoElementVisitor visitor) { visitor.visitSwitchTypeStatement(this);}
}
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.