Java 类com.intellij.util.xml.ExtendClass 实例源码

项目:consulo-java    文件:ExtendsClassChecker.java   
public List<DomElementProblemDescriptor> checkForProblems(@NotNull final ExtendClass extend, @NotNull final DomElement _element, @NotNull final DomElementAnnotationHolder holder,
                          @NotNull final DomHighlightingHelper helper) {
  if (!(_element instanceof GenericDomValue)) return Collections.emptyList();
  GenericDomValue element = (GenericDomValue)_element;

  if (!isPsiClassType(element)) return Collections.emptyList();

  final Object valueObject = element.getValue();
  PsiClass psiClass = null;

  if (valueObject instanceof PsiClass) {
    psiClass = (PsiClass)valueObject;
  } else if (valueObject instanceof PsiClassType) {
    psiClass = ((PsiClassType)valueObject).resolve();
  }

  if (psiClass != null) {
      return checkExtendClass(element, psiClass, extend.value(),
                              extend.instantiatable(), extend.canBeDecorator(), extend.allowInterface(),
                              extend.allowNonPublic(), extend.allowAbstract(), extend.allowEnum(), holder);
  }
  return Collections.emptyList();
}
项目:intellij-ce-playground    文件:MenuItem.java   
@Attribute("actionViewClass")
@Convert(PackageClassConverter.class)
@ExtendClass(value = "android.view.View",
             instantiatable = false,
             allowAbstract = false,
             allowInterface = false,
             allowEnum = false)
AndroidAttributeValue<PsiClass> getActionViewClass();
项目:intellij-ce-playground    文件:MenuItem.java   
@Attribute("actionProviderClass")
@Convert(PackageClassConverter.class)
@ExtendClass(value = "android.view.ActionProvider",
             instantiatable = false,
             allowAbstract = false,
             allowInterface = false,
             allowEnum = false)
AndroidAttributeValue<PsiClass> getActionProviderClass();
项目:intellij-ce-playground    文件:PluginPsiClassConverter.java   
@Override
protected JavaClassReferenceProvider createClassReferenceProvider(GenericDomValue<PsiClass> genericDomValue,
                                                                  ConvertContext context,
                                                                  ExtendClass extendClass) {
  final JavaClassReferenceProvider provider = super.createClassReferenceProvider(genericDomValue, context, extendClass);
  provider.setOption(JavaClassReferenceProvider.JVM_FORMAT, Boolean.TRUE);
  provider.setOption(JavaClassReferenceProvider.ALLOW_DOLLAR_NAMES, Boolean.TRUE);
  return provider;
}
项目:tools-idea    文件:PluginPsiClassConverter.java   
@Override
protected JavaClassReferenceProvider createClassReferenceProvider(GenericDomValue<PsiClass> genericDomValue,
                                                                  ConvertContext context,
                                                                  ExtendClass extendClass) {
  final JavaClassReferenceProvider provider = super.createClassReferenceProvider(genericDomValue, context, extendClass);
  provider.setOption(JavaClassReferenceProvider.JVM_FORMAT, Boolean.TRUE);
  provider.setOption(JavaClassReferenceProvider.ALLOW_DOLLAR_NAMES, Boolean.TRUE);
  return provider;
}
项目:intellij-ce-playground    文件:Instrumentation.java   
@Attribute("name")
@Required
@Convert(PackageClassConverter.class)
@CompleteNonModuleClass
@ExtendClass(AndroidUtils.INSTRUMENTATION_RUNNER_BASE_CLASS)
AndroidAttributeValue<PsiClass> getInstrumentationClass();
项目:intellij-ce-playground    文件:Application.java   
@Convert(PackageClassConverter.class)
@ExtendClass("android.app.Activity")
@Attribute("manageSpaceActivity")
AndroidAttributeValue<PsiClass> getManageSpaceActivity();
项目:intellij-ce-playground    文件:Application.java   
@Convert(PackageClassConverter.class)
@ExtendClass("android.app.backup.BackupAgent")
@Attribute("backupAgent")
AndroidAttributeValue<PsiClass> getBackupAgent();
项目:intellij-ce-playground    文件:Application.java   
@Convert(PackageClassConverter.class)
@ExtendClass("android.app.Application")
AndroidAttributeValue<PsiClass> getName();
项目:intellij-ce-playground    文件:Activity.java   
@Attribute("name")
@Required
@Convert(PackageClassConverter.class)
@ExtendClass("android.app.Activity")
AndroidAttributeValue<PsiClass> getActivityClass();
项目:intellij-ce-playground    文件:Activity.java   
@Attribute("parentActivityName")
@Convert(value = PackageClassConverter.class)
@ExtendClass("android.app.Activity")
AndroidAttributeValue<PsiClass> getParentActivityName();
项目:intellij-ce-playground    文件:ActivityAlias.java   
@Required
@Convert(value = PackageClassConverter.class)
@ExtendClass("android.app.Activity")
@Attribute("targetActivity")
AndroidAttributeValue<PsiClass> getTargetActivity();
项目:consulo-java    文件:ExtendsClassChecker.java   
@NotNull
public Class<ExtendClass> getAnnotationClass() {
  return ExtendClass.class;
}
项目:consulo-javaee    文件:Servlet.java   
/**
 * Returns the value of the servlet-class child.
 * <pre>
 * <h3>Element http://java.sun.com/xml/ns/javaee:servlet-class documentation</h3>
 * The servlet-class element contains the fully
 *        qualified class name of the servlet.
 * </pre>
 * <pre>
 * <h3>Type http://java.sun.com/xml/ns/javaee:fully-qualified-classType documentation</h3>
 * The elements that use this type designate the name of a
 *  Java class or interface.  The name is in the form of a
 *  "binary name", as defined in the JLS.  This is the form
 *  of name used in Class.forName().  Tools that need the
 *  canonical name (the name used in source code) will need
 *  to convert this binary name to the canonical name.
 * </pre>
 *
 * @return the value of the servlet-class child.
 */
@ExtendClass("javax.servlet.Servlet")
@ClassTemplate(J2EEFileTemplateNames.SERVLET_CLASS_TEMPLATE)
@MappingClass
@NotNull
@Stubbed
GenericDomValue<PsiClass> getServletClass();
项目:consulo-javaee    文件:ErrorPage.java   
/**
 * Returns the value of the exception-type child.
 * <pre>
 * <h3>Element http://java.sun.com/xml/ns/javaee:exception-type documentation</h3>
 * The exception-type contains a fully qualified class
 *        name of a Java exception type.
 * </pre>
 * <pre>
 * <h3>Type http://java.sun.com/xml/ns/javaee:fully-qualified-classType documentation</h3>
 * The elements that use this type designate the name of a
 *  Java class or interface.  The name is in the form of a
 *  "binary name", as defined in the JLS.  This is the form
 *  of name used in Class.forName().  Tools that need the
 *  canonical name (the name used in source code) will need
 *  to convert this binary name to the canonical name.
 * </pre>
 * @return the value of the exception-type child.
 */
@NotNull
       @ExtendClass(value = CommonClassNames.JAVA_LANG_EXCEPTION, instantiatable = false)
       GenericDomValue<PsiClass> getExceptionType();