changed controls for psiClass properties
[fedora-idea.git] / openapi / src / com / intellij / util / xml / highlighting / DomElementsInspection.java
blobe7d23f53dcc9d8c9c26bba73ee061ff12b0d163c
1 /*
2 * Copyright 2000-2006 JetBrains s.r.o.
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
8 * http://www.apache.org/licenses/LICENSE-2.0
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
18 package com.intellij.util.xml.highlighting;
20 import com.intellij.codeInspection.*;
21 import com.intellij.psi.PsiElementVisitor;
22 import com.intellij.psi.PsiReferenceExpression;
23 import com.intellij.psi.PsiFile;
24 import com.intellij.psi.PsiElement;
25 import com.intellij.psi.xml.XmlFile;
26 import com.intellij.psi.xml.XmlTag;
27 import com.intellij.codeInsight.daemon.GroupNames;
28 import com.intellij.util.xml.DomElement;
29 import com.intellij.util.xml.GenericValue;
30 import com.intellij.lang.ASTNode;
31 import org.jetbrains.annotations.NonNls;
32 import org.jetbrains.annotations.Nullable;
34 /**
35 * User: Sergey.Vasiliev
37 abstract public class DomElementsInspection extends LocalInspectionTool {
40 @Nullable
41 public ProblemDescriptor[] checkFile(PsiFile file, InspectionManager manager, boolean isOnTheFly) {
42 if (isAcceptable(file)) {
43 return findProblems(file, manager, isOnTheFly);
46 return super.checkFile(file, manager, isOnTheFly);
49 @Nullable
50 public PsiElementVisitor buildVisitor(final ProblemsHolder holder, final boolean isOnTheFly) {
51 return null;
54 abstract protected boolean isAcceptable(final PsiFile file);
55 abstract protected ProblemDescriptor[] findProblems(final PsiFile file, InspectionManager manager, final boolean onTheFly);