List of usage examples for com.intellij.openapi.util MixinExtension getInstance
@Nullable public static <T> T getInstance(ExtensionPointName<MixinEP<T>> name, Object key)
From source file:com.intellij.codeInsight.hint.DeclarationRangeUtil.java
License:Apache License
public static @Nullable TextRange getPossibleDeclarationAtRange(final PsiElement container) { DeclarationRangeHandler handler = MixinExtension.getInstance(DeclarationRangeHandler.EP_NAME, container); if (handler != null) { return handler.getDeclarationRange(container); } else {/*from w w w. ja v a2 s .c o m*/ for (Class clazz : ourDeclarationRangeRegistry.keySet()) { if (clazz.isInstance(container)) { final DeclarationRangeHandler handler2 = ourDeclarationRangeRegistry.get(clazz); if (handler2 != null) return handler2.getDeclarationRange(container); } } return null; } }