当前位置: 首页>>代码示例>>Java>>正文


Java ModuleExtensionWithSdk类代码示例

本文整理汇总了Java中consulo.module.extension.ModuleExtensionWithSdk的典型用法代码示例。如果您正苦于以下问题:Java ModuleExtensionWithSdk类的具体用法?Java ModuleExtensionWithSdk怎么用?Java ModuleExtensionWithSdk使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。


ModuleExtensionWithSdk类属于consulo.module.extension包,在下文中一共展示了ModuleExtensionWithSdk类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: put0

import consulo.module.extension.ModuleExtensionWithSdk; //导入依赖的package包/类
private static void put0(Class<?> clazz, int index) {
  Class temp = clazz;

  do {
    if (temp == ModuleExtensionWithSdkImpl.class ||
        temp == ModuleExtensionImpl.class ||
        temp == ModuleExtension.class ||
        temp == ModuleExtensionWithSdk.class) {
      break;
    }

    putImpl(temp, index);

    Class[] interfaces = temp.getInterfaces();
    for (Class intef : interfaces) {
      put0(intef, index);
    }
  }
  while ((temp = temp.getSuperclass()) != null);
}
 
开发者ID:consulo,项目名称:consulo,代码行数:21,代码来源:ModuleExtensionIndexCache.java

示例2: putImpl

import consulo.module.extension.ModuleExtensionWithSdk; //导入依赖的package包/类
private static void putImpl(Class<?> temp, int index) {
  if (temp == ModuleExtensionWithSdkImpl.class ||
      temp == ModuleExtensionImpl.class ||
      temp == ModuleExtension.class ||
      temp == ModuleExtensionWithSdk.class) {
    return;
  }

  int[] ints = ourClassCache.get(temp);
  if (ints == null) {
    ourClassCache.put(temp, new int[]{index});
  }
  else {
    ourClassCache.put(temp, ArrayUtil.append(ints, index));
  }
}
 
开发者ID:consulo,项目名称:consulo,代码行数:17,代码来源:ModuleExtensionIndexCache.java

示例3: getPresentableName

import consulo.module.extension.ModuleExtensionWithSdk; //导入依赖的package包/类
@Override
@Nonnull
public String getPresentableName() {
  StringBuilder builder = new StringBuilder();

  ModuleExtensionWithSdk<?> moduleExtension = getModuleExtension();
  if (moduleExtension != null) {
    final Sdk sdk = moduleExtension.getSdk();
    if (sdk == null) {
      builder.append(moduleExtension.getSdkName());
    }
    else {
      builder.append(sdk.getName());
    }
  }
  else {
    builder.append(myModuleExtensionId);
  }

  return builder.toString();
}
 
开发者ID:consulo,项目名称:consulo,代码行数:22,代码来源:ModuleExtensionWithSdkOrderEntryImpl.java

示例4: isIKVMLibrary

import consulo.module.extension.ModuleExtensionWithSdk; //导入依赖的package包/类
@RequiredReadAction
private static boolean isIKVMLibrary(@NotNull DotNetTypeDeclaration typeDeclaration)
{
	VirtualFile virtualFile = PsiUtilCore.getVirtualFile(typeDeclaration);
	if(virtualFile == null)
	{
		return false;
	}
	VirtualFile virtualFileForArchive = ArchiveVfsUtil.getVirtualFileForArchive(virtualFile);
	if(virtualFileForArchive == null)
	{
		return false;
	}

	List<OrderEntry> orderEntriesForFile = ProjectFileIndex.SERVICE.getInstance(typeDeclaration.getProject()).getOrderEntriesForFile
			(virtualFile);
	if(orderEntriesForFile.isEmpty())
	{
		return false;
	}
	for(OrderEntry orderEntry : orderEntriesForFile)
	{
		if(orderEntry instanceof ModuleExtensionWithSdkOrderEntry)
		{
			ModuleExtensionWithSdk<?> moduleExtension = ((ModuleExtensionWithSdkOrderEntry) orderEntry).getModuleExtension();
			if(moduleExtension instanceof IkvmModuleExtension)
			{
				return true;
			}
		}
	}
	return false;
}
 
开发者ID:consulo,项目名称:consulo-ikvm,代码行数:34,代码来源:StubBuilder.java

示例5: getItemNameFromModule

import consulo.module.extension.ModuleExtensionWithSdk; //导入依赖的package包/类
@Override
public String getItemNameFromModule(@Nonnull Module module) {
  final ModuleExtensionWithSdk<?> extension = (ModuleExtensionWithSdk) ModuleUtilCore.getExtension(module, myExtensionId);
  if (extension != null) {
    return extension.getInheritableSdk().getName();
  }
  return null;
}
 
开发者ID:consulo,项目名称:consulo,代码行数:9,代码来源:SdkModuleInheritableNamedPointerImpl.java

示例6: getItemFromModule

import consulo.module.extension.ModuleExtensionWithSdk; //导入依赖的package包/类
@Override
public Sdk getItemFromModule(@Nonnull Module module) {
  final ModuleExtensionWithSdk<?> extension = (ModuleExtensionWithSdk)  ModuleUtilCore.getExtension(module, myExtensionId);
  if (extension != null) {
    return extension.getInheritableSdk().get();
  }
  return null;
}
 
开发者ID:consulo,项目名称:consulo,代码行数:9,代码来源:SdkModuleInheritableNamedPointerImpl.java

示例7: getSdk

import consulo.module.extension.ModuleExtensionWithSdk; //导入依赖的package包/类
@Override
@Nullable
public Sdk getSdk() {
  final ModuleExtensionWithSdk<?> moduleExtension = getModuleExtension();
  if (moduleExtension == null) {
    return null;
  }
  return myModuleRootLayer.getRootModel().getConfigurationAccessor().getSdk(moduleExtension.getSdk(),
                                                                            moduleExtension.getSdkName());
}
 
开发者ID:consulo,项目名称:consulo,代码行数:11,代码来源:ModuleExtensionWithSdkOrderEntryImpl.java

示例8: getSdkName

import consulo.module.extension.ModuleExtensionWithSdk; //导入依赖的package包/类
@Override
@Nullable
public String getSdkName() {
  final ModuleExtensionWithSdk<?> moduleExtension = getModuleExtension();
  if (moduleExtension == null) {
    return null;
  }
  return moduleExtension.getSdkName();
}
 
开发者ID:consulo,项目名称:consulo,代码行数:10,代码来源:ModuleExtensionWithSdkOrderEntryImpl.java

示例9: getModuleExtension

import consulo.module.extension.ModuleExtensionWithSdk; //导入依赖的package包/类
@Nullable
@Override
public ModuleExtensionWithSdk<?> getModuleExtension() {
  ModuleExtension<?> extensionWithoutCheck = myModuleRootLayer.getExtensionWithoutCheck(myModuleExtensionId);
  if (!(extensionWithoutCheck instanceof ModuleExtensionWithSdk)) {
    return null;
  }
  return (ModuleExtensionWithSdk) extensionWithoutCheck;
}
 
开发者ID:consulo,项目名称:consulo,代码行数:10,代码来源:ModuleExtensionWithSdkOrderEntryImpl.java

示例10: getSdk

import consulo.module.extension.ModuleExtensionWithSdk; //导入依赖的package包/类
@Nullable
public static Sdk getSdk(@Nonnull Module module, @Nonnull Class<? extends ModuleExtensionWithSdk> extensionClass) {
  ModuleRootManager moduleRootManager = ModuleRootManager.getInstance(module);

  final ModuleExtensionWithSdk<?> extension = moduleRootManager.getExtension(extensionClass);
  if (extension == null) {
    return null;
  }
  else {
    return extension.getSdk();
  }
}
 
开发者ID:consulo,项目名称:consulo,代码行数:13,代码来源:ModuleUtilCore.java

示例11: getEffectiveJDK

import consulo.module.extension.ModuleExtensionWithSdk; //导入依赖的package包/类
@Nullable
public Sdk getEffectiveJDK()
{
	if(!XsltRunSettingsEditor.ALLOW_CHOOSING_SDK)
	{
		return getDefaultSdk();
	}
	if(myJdkChoice == JdkChoice.JDK)
	{
		return myJdk != null ? SdkTable.getInstance().findSdk(myJdk) : null;
	}
	Sdk jdk = null;
	final Module module = getEffectiveModule();
	if(module != null)
	{
		ModuleRootManager moduleRootManager = ModuleRootManager.getInstance(module);
		ModuleExtension maybeJavaExtension = moduleRootManager.getExtension("java");
		if(maybeJavaExtension instanceof ModuleExtensionWithSdk)
		{
			jdk = ((ModuleExtensionWithSdk) maybeJavaExtension).getSdk();
		}
	}

	// EA-33419
	if(jdk == null || !(jdk.getSdkType() instanceof JavaSdkType))
	{
		return getDefaultSdk();
	}
	return jdk;
}
 
开发者ID:consulo,项目名称:consulo-xslt,代码行数:31,代码来源:XsltRunConfiguration.java

示例12: LazyValueBySdk

import consulo.module.extension.ModuleExtensionWithSdk; //导入依赖的package包/类
public LazyValueBySdk(@NotNull ModuleExtensionWithSdk<?> extension, @NotNull T defaultValue, @NotNull NotNullFunction<Sdk, T> func)
{
	myExtension = extension;
	myFunc = func;
	myDefaultValue = defaultValue;
	myValue = defaultValue;
}
 
开发者ID:consulo,项目名称:consulo-java,代码行数:8,代码来源:LazyValueBySdk.java

示例13: isModifiedImpl

import consulo.module.extension.ModuleExtensionWithSdk; //导入依赖的package包/类
public boolean isModifiedImpl(ModuleExtensionWithSdk<T> originExtension) {
  if (myIsEnabled != originExtension.isEnabled()) {
    return true;
  }
  return !mySdkPointer.equals(originExtension.getInheritableSdk());
}
 
开发者ID:consulo,项目名称:consulo,代码行数:7,代码来源:ModuleExtensionWithSdkImpl.java

示例14: addModuleExtensionSdkEntry

import consulo.module.extension.ModuleExtensionWithSdk; //导入依赖的package包/类
@Nonnull
@Override
public ModuleExtensionWithSdkOrderEntry addModuleExtensionSdkEntry(@Nonnull ModuleExtensionWithSdk<?> moduleExtension) {
  assertWritable();
  return getCurrentLayer().addModuleExtensionSdkEntry(moduleExtension);
}
 
开发者ID:consulo,项目名称:consulo,代码行数:7,代码来源:RootModelImpl.java

示例15: addModuleExtensionSdkEntry

import consulo.module.extension.ModuleExtensionWithSdk; //导入依赖的package包/类
@Nonnull
ModuleExtensionWithSdkOrderEntry addModuleExtensionSdkEntry(@Nonnull ModuleExtensionWithSdk<?> moduleExtension);
 
开发者ID:consulo,项目名称:consulo,代码行数:3,代码来源:ModifiableModuleRootLayer.java


注:本文中的consulo.module.extension.ModuleExtensionWithSdk类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。