本文整理汇总了Java中com.intellij.navigation.GotoClassContributor类的典型用法代码示例。如果您正苦于以下问题:Java GotoClassContributor类的具体用法?Java GotoClassContributor怎么用?Java GotoClassContributor使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
GotoClassContributor类属于com.intellij.navigation包,在下文中一共展示了GotoClassContributor类的7个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的Java代码示例。
示例1: getFullName
import com.intellij.navigation.GotoClassContributor; //导入依赖的package包/类
@Override
public String getFullName(final Object element) {
for(ChooseByNameContributor c: getContributors()) {
if (c instanceof GotoClassContributor) {
String result = ((GotoClassContributor) c).getQualifiedName((NavigationItem) element);
if (result != null) {
return result;
}
}
}
String elementName = getElementName(element);
if (elementName == null) return null;
if (element instanceof PsiElement) {
return SymbolPresentationUtil.getSymbolContainerText((PsiElement)element) + "." + elementName;
}
return elementName;
}
开发者ID:jskierbi,项目名称:intellij-ce-playground,代码行数:21,代码来源:GotoSymbolModel2.java
示例2: getFullName
import com.intellij.navigation.GotoClassContributor; //导入依赖的package包/类
@Override
public String getFullName(final Object element) {
for(ChooseByNameContributor c: getContributors()) {
if (c instanceof GotoClassContributor) {
String result = ((GotoClassContributor) c).getQualifiedName((NavigationItem) element);
if (result != null) return result;
}
}
if (element instanceof PsiElement) {
final PsiElement psiElement = (PsiElement)element;
final String containerText = SymbolPresentationUtil.getSymbolContainerText(psiElement);
return containerText + "." + getElementName(element);
}
return getElementName(element);
}
开发者ID:lshain-android-source,项目名称:tools-idea,代码行数:19,代码来源:GotoSymbolModel2.java
示例3: getFullName
import com.intellij.navigation.GotoClassContributor; //导入依赖的package包/类
@Override
public String getFullName(final Object element) {
if (element instanceof PsiElement && !((PsiElement)element).isValid()) {
return null;
}
for (ChooseByNameContributor c : getContributors()) {
if (c instanceof GotoClassContributor) {
String result = ((GotoClassContributor)c).getQualifiedName((NavigationItem)element);
if (result != null) return result;
}
}
return getElementName(element);
}
开发者ID:jskierbi,项目名称:intellij-ce-playground,代码行数:16,代码来源:GotoClassModel2.java
示例4: getSeparatorsFromContributors
import com.intellij.navigation.GotoClassContributor; //导入依赖的package包/类
public static String[] getSeparatorsFromContributors(ChooseByNameContributor[] contributors) {
final Set<String> separators = new HashSet<String>();
separators.add(".");
for(ChooseByNameContributor c: contributors) {
if (c instanceof GotoClassContributor) {
ContainerUtil.addIfNotNull(separators, ((GotoClassContributor)c).getQualifiedNameSeparator());
}
}
return ArrayUtil.toStringArray(separators);
}
开发者ID:jskierbi,项目名称:intellij-ce-playground,代码行数:11,代码来源:GotoClassModel2.java
示例5: getFullName
import com.intellij.navigation.GotoClassContributor; //导入依赖的package包/类
@Override
public String getFullName(final Object element) {
for(ChooseByNameContributor c: getContributors()) {
if (c instanceof GotoClassContributor) {
String result = ((GotoClassContributor) c).getQualifiedName((NavigationItem) element);
if (result != null) return result;
}
}
return getElementName(element);
}
开发者ID:lshain-android-source,项目名称:tools-idea,代码行数:12,代码来源:GotoClassModel2.java
示例6: getSeparatorsFromContributors
import com.intellij.navigation.GotoClassContributor; //导入依赖的package包/类
public static String[] getSeparatorsFromContributors(ChooseByNameContributor[] contributors) {
final Set<String> separators = new HashSet<String>();
separators.add(".");
for(ChooseByNameContributor c: contributors) {
if (c instanceof GotoClassContributor) {
separators.add(((GotoClassContributor)c).getQualifiedNameSeparator());
}
}
return separators.toArray(new String[separators.size()]);
}
开发者ID:lshain-android-source,项目名称:tools-idea,代码行数:11,代码来源:GotoClassModel2.java
示例7: getSeparatorsFromContributors
import com.intellij.navigation.GotoClassContributor; //导入依赖的package包/类
public static String[] getSeparatorsFromContributors(ChooseByNameContributor[] contributors) {
final Set<String> separators = new HashSet<>();
separators.add(".");
for(ChooseByNameContributor c: contributors) {
if (c instanceof GotoClassContributor) {
ContainerUtil.addIfNotNull(separators, ((GotoClassContributor)c).getQualifiedNameSeparator());
}
}
return separators.toArray(new String[separators.size()]);
}
开发者ID:consulo,项目名称:consulo,代码行数:11,代码来源:GotoClassModel2.java
注:本文中的com.intellij.navigation.GotoClassContributor类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论