本文整理匯總了Java中com.intellij.xml.index.XsdNamespaceBuilder類的典型用法代碼示例。如果您正苦於以下問題:Java XsdNamespaceBuilder類的具體用法?Java XsdNamespaceBuilder怎麽用?Java XsdNamespaceBuilder使用的例子?那麽, 這裏精選的類代碼示例或許可以為您提供幫助。
XsdNamespaceBuilder類屬於com.intellij.xml.index包,在下文中一共展示了XsdNamespaceBuilder類的3個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。
示例1: findNSFilesByURI
import com.intellij.xml.index.XsdNamespaceBuilder; //導入依賴的package包/類
public static Collection<XmlFile> findNSFilesByURI(String namespace, final Project project, Module module) {
final List<IndexedRelevantResource<String, XsdNamespaceBuilder>>
resources = XmlNamespaceIndex.getResourcesByNamespace(namespace, project, module);
final PsiManager psiManager = PsiManager.getInstance(project);
return ContainerUtil.mapNotNull(resources, new NullableFunction<IndexedRelevantResource<String, XsdNamespaceBuilder>, XmlFile>() {
@Override
public XmlFile fun(IndexedRelevantResource<String, XsdNamespaceBuilder> resource) {
PsiFile file = psiManager.findFile(resource.getFile());
return file instanceof XmlFile ? (XmlFile)file : null;
}
});
}
示例2: findNSFilesByURI
import com.intellij.xml.index.XsdNamespaceBuilder; //導入依賴的package包/類
public static Collection<XmlFile> findNSFilesByURI(String namespace, final Project project, Module module) {
final List<IndexedRelevantResource<String, XsdNamespaceBuilder>>
resources = XmlNamespaceIndex.getResourcesByNamespace(namespace, project, module);
final PsiManager psiManager = PsiManager.getInstance(project);
return ContainerUtil.mapNotNull(resources, new NullableFunction<IndexedRelevantResource<String, XsdNamespaceBuilder>, XmlFile>() {
public XmlFile fun(IndexedRelevantResource<String, XsdNamespaceBuilder> resource) {
PsiFile file = psiManager.findFile(resource.getFile());
return file instanceof XmlFile ? (XmlFile)file : null;
}
});
}
示例3: findNSFilesByURI
import com.intellij.xml.index.XsdNamespaceBuilder; //導入依賴的package包/類
public static Collection<XmlFile> findNSFilesByURI(String namespace, final Project project, Module module)
{
final List<IndexedRelevantResource<String, XsdNamespaceBuilder>> resources = XmlNamespaceIndex.getResourcesByNamespace(namespace, project, module);
final PsiManager psiManager = PsiManager.getInstance(project);
return ContainerUtil.mapNotNull(resources, (NullableFunction<IndexedRelevantResource<String, XsdNamespaceBuilder>, XmlFile>) resource ->
{
PsiFile file = psiManager.findFile(resource.getFile());
return file instanceof XmlFile ? (XmlFile) file : null;
});
}