public IModule getModule() { if (this.isAutoModule && this.module == null) { return this.module = IModule.createAutomatic(this.path, false, null/*no manifest*/); } return this.module; } }
@Override public IModule getModule() { if (this.isAutoModule && this.module == null) { return this.module = IModule.createAutomatic(this.path, false, null/*no manifest*/); } return this.module; } }
public static IModule getAutomaticModule(ClasspathLocation location) { if (location instanceof ClasspathJar) { ClasspathJar classpathJar = (ClasspathJar) location; return IModule.createAutomatic(classpathJar.zipFilename, true, classpathJar.getManifest()); } if (location instanceof ClasspathDirectory) { return IModule.createAutomatic(((ClasspathDirectory) location).binaryFolder.getName(), false, null); } return null; } private void initModule(ClasspathLocation location) {
public static IModule getAutomaticModule(ClasspathLocation location) { if (location instanceof ClasspathJar) { ClasspathJar classpathJar = (ClasspathJar) location; return IModule.createAutomatic(classpathJar.zipFilename, true, classpathJar.getManifest()); } if (location instanceof ClasspathDirectory) { return IModule.createAutomatic(((ClasspathDirectory) location).binaryFolder.getName(), false, null); } return null; } private void initModule(ClasspathLocation location) {
public static IModule createAutomatic(String fileName, boolean isFile, Manifest manifest) { return createAutomatic(AutomaticModuleNaming.determineAutomaticModuleName(fileName, isFile, manifest)); } }
public IModule getModule() { if (this.isAutoModule && this.module == null) { Manifest manifest = null; try { initialize(); ZipEntry entry = this.zipFile.getEntry(TypeConstants.META_INF_MANIFEST_MF); if (entry != null) manifest = new Manifest(this.zipFile.getInputStream(entry)); } catch (IOException e) { // no usable manifest } return this.module = IModule.createAutomatic(this.file.getName(), true, manifest); } return this.module; } }
@Override public IModule getModule() { if (this.isAutoModule && this.module == null) { Manifest manifest = null; try { initialize(); ZipEntry entry = this.zipFile.getEntry(TypeConstants.META_INF_MANIFEST_MF); if (entry != null) manifest = new Manifest(this.zipFile.getInputStream(entry)); } catch (IOException e) { // no usable manifest } return this.module = IModule.createAutomatic(this.file.getName(), true, manifest); } return this.module; } }
public static IModule createAutomatic(String fileName, boolean isFile, Manifest manifest) { boolean fromManifest = true; char[] inferredName = AutomaticModuleNaming.determineAutomaticModuleNameFromManifest(manifest); if (inferredName == null) { fromManifest = false; inferredName = AutomaticModuleNaming.determineAutomaticModuleNameFromFileName(fileName, true, isFile); } return createAutomatic(inferredName, fromManifest); } }
module = IModule.createAutomatic(getFileName(file), file.isFile(), getManifest(file));
module = IModule.createAutomatic(getFileName(file), file.isFile(), getManifest(file));
public static IModule getModuleDescriptionInfo(IModuleDescription moduleDesc) { if (moduleDesc != null) { try { if (moduleDesc instanceof AutoModule) { boolean nameFromManifest = ((AutoModule) moduleDesc).isAutoNameFromManifest(); return IModule.createAutomatic(moduleDesc.getElementName().toCharArray(), nameFromManifest); } else { return ((AbstractModule) moduleDesc).getModuleInfo(); } } catch (JavaModelException e) { if (!e.isDoesNotExist()) Util.log(e); } } return null; }
public static IModule getModuleDescriptionInfo(IModuleDescription moduleDesc) { if (moduleDesc != null) { try { if (moduleDesc instanceof BinaryModule) { return (ModuleDescriptionInfo)((BinaryModule) moduleDesc).getElementInfo(); } else if (moduleDesc instanceof SourceModule) { return (ModuleDescriptionInfo)((SourceModule) moduleDesc).getElementInfo(); } else { return IModule.createAutomatic(moduleDesc.getElementName().toCharArray()); } } catch (JavaModelException e) { // TODO Auto-generated catch block if (!e.isDoesNotExist()) e.printStackTrace(); } } return null; }
info = IModule.createAutomatic(prereqJavaProject.getElementName(), false, prereqJavaProject.getManifest()); ModulePathEntry projectEntry = new ModulePathEntry(prereqJavaProject.getPath(), info, projectLocations.toArray(new ClasspathLocation[projectLocations.size()]));
info = IModule.createAutomatic(prereqJavaProject.getElementName(), false, prereqJavaProject.getManifest()); ModulePathEntry projectEntry = new ModulePathEntry(prereqJavaProject.getPath(), info, projectLocations.toArray(new ClasspathLocation[projectLocations.size()]));