Unnamed: 0
int64 0
305k
| body
stringlengths 7
52.9k
| name
stringlengths 1
185
|
---|---|---|
1,500 | String (final DependencyContext context) { final StringBuilder buf = new StringBuilder(); buf.append("("); for (TypeRepr.AbstractType t : myArgumentTypes) { buf.append(t.getDescr(context)); } buf.append(")"); buf.append(myType.getDescr(context)); return buf.toString(); } | getDescr |
1,501 | void (final DependencyContext context, final PrintStream stream) { super.toStream(context, stream); stream.print(" Arguments : "); for (TypeRepr.AbstractType t : myArgumentTypes) { stream.print(t.getDescr(context)); stream.print("; "); } stream.println(); final TypeRepr.AbstractType[] es = myExceptions.toArray(TypeRepr.AbstractType.EMPTY_TYPE_ARRAY); Arrays.sort(es, Comparator.comparing(o -> o.getDescr(context))); stream.print(" Exceptions : "); for (final TypeRepr.AbstractType e : es) { stream.print(e.getDescr(context)); stream.print("; "); } stream.println(); } | toStream |
1,502 | Set<Recompile> ( DependencyContext context, MethodRepr method, Difference.Specifier<TypeRepr.ClassType, Difference> annotationsDiff, Difference.Specifier<ParamAnnotation, Difference> paramAnnotationsDiff ) { return RECOMPILE_NONE; } | methodAnnotationsChanged |
1,503 | Set<Recompile> ( NamingContext context, ProtoMethodEntity method, Difference.Specifier<TypeRepr.ClassType, Difference> annotationsDiff, Difference.Specifier<ParamAnnotation, Difference> paramAnnotationsDiff ) { if (method instanceof MethodRepr && context instanceof DependencyContext) { Set<Recompile> result = methodAnnotationsChanged((DependencyContext)context, (MethodRepr)method, annotationsDiff, paramAnnotationsDiff); if (!result.isEmpty()) { return result; } } return RECOMPILE_NONE; } | methodAnnotationsChanged |
1,504 | Set<Recompile> (NamingContext context, FieldRepr field, Difference.Specifier<TypeRepr.ClassType, Difference> annotationsDiff) { return RECOMPILE_NONE; } | fieldAnnotationsChanged |
1,505 | Set<Recompile> (NamingContext context, ProtoFieldEntity field, Difference.Specifier<TypeRepr.ClassType, Difference> annotationsDiff) { if (field instanceof FieldRepr) { Set<Recompile> result = fieldAnnotationsChanged(context, (FieldRepr)field, annotationsDiff); if (!result.isEmpty()) { return result; } } return RECOMPILE_NONE; } | fieldAnnotationsChanged |
1,506 | Set<Recompile> (NamingContext context, ClassRepr aClass, Difference.Specifier<TypeRepr.ClassType, Difference> annotationsDiff) { return RECOMPILE_NONE; } | classAnnotationsChanged |
1,507 | int () { return myDelegate.base(); } | base |
1,508 | boolean () { return myDelegate.no(); } | no |
1,509 | boolean () { return myDelegate.accessRestricted(); } | accessRestricted |
1,510 | boolean () { return myDelegate.accessExpanded(); } | accessExpanded |
1,511 | int () { return myDelegate.addedModifiers(); } | addedModifiers |
1,512 | int () { return myDelegate.removedModifiers(); } | removedModifiers |
1,513 | boolean () { return myDelegate.packageLocalOn(); } | packageLocalOn |
1,514 | boolean () { return myDelegate.hadValue(); } | hadValue |
1,515 | Set<Integer> () { return Collections.unmodifiableSet(myModuleNames); } | getModuleNames |
1,516 | boolean () { return !myModuleNames.isEmpty(); } | isQualified |
1,517 | void (DataOutput out) { super.save(out); RW.save(myModuleNames, INT_EXTERNALIZER, out); } | save |
1,518 | boolean (Object o) { if (this == o) { return true; } if (o == null || getClass() != o.getClass()) { return false; } return name == ((ModulePackageRepr)o).name; } | equals |
1,519 | int () { return 31 * name; } | hashCode |
1,520 | Diff (Proto past) { final Difference.Specifier<Integer, Difference> targetModulesDiff = Difference.make(((ModulePackageRepr)past).myModuleNames, myModuleNames); return new Diff(super.difference(past)) { @Override public Specifier<Integer, Difference> targetModules() { return targetModulesDiff; } @Override public boolean no() { return super.no() && targetModules().unchanged(); } }; } | difference |
1,521 | boolean () { return super.no() && targetModules().unchanged(); } | no |
1,522 | void (DependencyContext context, PrintStream stream) { final StringBuilder sb = new StringBuilder(); sb.append("Module package: ").append(context.getValue(name)); final Set<Integer> moduleNames = myModuleNames; if (!moduleNames.isEmpty()) { final List<String> names = new ArrayList<>(); for (Integer moduleName : moduleNames) { names.add(context.getValue(moduleName)); } names.sort(String::compareToIgnoreCase); sb.append(" to"); for (String s : names) { sb.append(" ").append(s); } } stream.println(sb); } | toStream |
1,523 | DataExternalizer<ModulePackageRepr> (final DependencyContext context) { return new DataExternalizer<ModulePackageRepr>() { @Override public void save(@NotNull DataOutput out, ModulePackageRepr value) { value.save(out); } @Override public ModulePackageRepr read(@NotNull DataInput in) { return new ModulePackageRepr(context, in); } }; } | externalizer |
1,524 | void (@NotNull DataOutput out, ModulePackageRepr value) { value.save(out); } | save |
1,525 | ModulePackageRepr (@NotNull DataInput in) { return new ModulePackageRepr(context, in); } | read |
1,526 | boolean (final int key) { try { return map.containsMapping(key); } catch (IOException e) { throw new BuildDataCorruptedException(e); } } | containsKey |
1,527 | IntSet (final int key) { final IntSet collection = cache.get(key); return collection == NULL_COLLECTION ? null : collection; } | get |
1,528 | void (int key, IntSet value) { try { cache.invalidate(key); if (value == null || value.isEmpty()) { map.remove(key); } else { map.put(key, value); } } catch (IOException e) { throw new BuildDataCorruptedException(e); } } | replace |
1,529 | void (final int key, final IntSet values) { try { if (!values.isEmpty()) { cache.invalidate(key); map.appendData(key, getAddAppender(values)); } } catch (IOException e) { throw new BuildDataCorruptedException(e); } } | put |
1,530 | void (final int key, final int value) { try { cache.invalidate(key); map.appendData(key, getAddAppender(value)); } catch (IOException e) { throw new BuildDataCorruptedException(e); } } | put |
1,531 | void (int key, IntSet values) { try { if (!values.isEmpty()) { cache.invalidate(key); map.appendData(key, getRemoveAppender(values)); } } catch (IOException e) { throw new BuildDataCorruptedException(e); } } | removeAll |
1,532 | void (final int key, final int value) { try { final IntSet collection = cache.get(key); if (collection != NULL_COLLECTION) { if (collection.remove(value)) { cache.invalidate(key); if (collection.isEmpty()) { map.remove(key); } else { map.appendData(key, getRemoveAppender(value)); } } } } catch (IOException e) { throw new BuildDataCorruptedException(e); } } | removeFrom |
1,533 | void (final int key) { try { cache.invalidate(key); map.remove(key); } catch (IOException e) { throw new BuildDataCorruptedException(e); } } | remove |
1,534 | void (IntIntMultiMaplet m) { m.forEachEntry((integers, value) -> put(value, integers)); } | putAll |
1,535 | void (IntIntMultiMaplet m) { m.forEachEntry((integers, value) -> replace(value, integers)); } | replaceAll |
1,536 | void () { try { cache.invalidateAll(); map.close(); } catch (IOException e) { throw new BuildDataCorruptedException(e); } } | close |
1,537 | void (boolean memoryCachesOnly) { if (memoryCachesOnly) { if (map.isDirty()) { map.dropMemoryCaches(); } } else { map.force(); } } | flush |
1,538 | boolean (final int key) { try { return map.containsMapping(key); } catch (IOException e) { throw new BuildDataCorruptedException(e); } } | containsKey |
1,539 | IntSet (final int key) { final IntSet collection = cache.get(key); return collection == NULL_COLLECTION ? null : collection; } | get |
1,540 | void (int key, IntSet value) { try { cache.invalidate(key); if (value == null || value.isEmpty()) { map.remove(key); } else { map.put(key, value); } } catch (IOException e) { throw new BuildDataCorruptedException(e); } } | replace |
1,541 | void (final int key, final IntSet value) { try { cache.invalidate(key); map.appendData(key, new AppendablePersistentMap.ValueDataAppender() { @Override public void append(final @NotNull DataOutput out) throws IOException { IntIterator iterator = value.iterator(); while (iterator.hasNext()) { int value1 = iterator.nextInt(); DataInputOutputUtil.writeINT(out, value1); } } }); } catch (IOException e) { throw new BuildDataCorruptedException(e); } } | put |
1,542 | void (final int key, final int value) { try { cache.invalidate(key); map.appendData(key, new AppendablePersistentMap.ValueDataAppender() { @Override public void append(final @NotNull DataOutput out) throws IOException { DataInputOutputUtil.writeINT(out, value); } }); } catch (IOException e) { throw new BuildDataCorruptedException(e); } } | put |
1,543 | void (int key, IntSet values) { try { IntSet collection = cache.get(key); if (collection != NULL_COLLECTION) { if (collection.removeAll(values)) { cache.invalidate(key); if (collection.isEmpty()) { map.remove(key); } else { map.put(key, collection); } } } } catch (IOException e) { throw new BuildDataCorruptedException(e); } } | removeAll |
1,544 | void (final int key, final int value) { try { final IntSet collection = cache.get(key); if (collection != NULL_COLLECTION) { if (collection.remove(value)) { cache.invalidate(key); if (collection.isEmpty()) { map.remove(key); } else { map.put(key, collection); } } } } catch (IOException e) { throw new BuildDataCorruptedException(e); } } | removeFrom |
1,545 | void (final int key) { try { cache.invalidate(key); map.remove(key); } catch (IOException e) { throw new BuildDataCorruptedException(e); } } | remove |
1,546 | void (IntIntMultiMaplet m) { m.forEachEntry((integers, value) -> put(value, integers)); } | putAll |
1,547 | void (IntIntMultiMaplet m) { m.forEachEntry((integers, value) -> replace(value, integers)); } | replaceAll |
1,548 | void () { try { cache.invalidateAll(); map.close(); } catch (IOException e) { throw new BuildDataCorruptedException(e); } } | close |
1,549 | void (boolean memoryCachesOnly) { if (memoryCachesOnly) { if (map.isDirty()) { map.dropMemoryCaches(); } } else { map.force(); } } | flush |
1,550 | void (ObjIntConsumer<? super IntSet> procedure) { try { map.processKeysWithExistingMapping(key -> { try { procedure.accept(map.get(key), key); } catch (IOException e) { throw new BuildDataCorruptedException(e); } return true; }); } catch (IOException e) { throw new BuildDataCorruptedException(e); } } | forEachEntry |
1,551 | int () { return myFileName; } | getFileName |
1,552 | boolean (final UsageRepr.Usage usage) { return myUsages.add(usage); } | addUsage |
1,553 | void (DependencyContext context, PrintStream stream) { super.toStream(context, stream); stream.print(" Filename : "); stream.println(context.getValue(myFileName)); } | toStream |
1,554 | void (final DataOutput out) { try { super.save(out); DataInputOutputUtil.writeINT(out, myFileName); RW.save(myUsages, UsageRepr.externalizer(myContext), out); } catch (IOException e) { throw new BuildDataCorruptedException(e); } } | save |
1,555 | int () { return 31 * myFileName + name; } | hashCode |
1,556 | boolean (Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; ClassFileRepr classRepr = (ClassFileRepr)o; if (myFileName != classRepr.myFileName) return false; if (name != classRepr.name) return false; return true; } | equals |
1,557 | InternedString (final DependencyContext context, final String val) { return new InternedString() { @Override public DependencyContext getContext() { return context; } @Override public int asInt() { return context.get(val); } @Override public String asString() { return val; } }; } | create |
1,558 | DependencyContext () { return context; } | getContext |
1,559 | int () { return context.get(val); } | asInt |
1,560 | String () { return val; } | asString |
1,561 | InternedString (final DependencyContext context, final int val) { return new InternedString() { @Override public @NotNull DependencyContext getContext() { return context; } @Override public int asInt() { return val; } @Override public String asString() { return getContext().getValue(val); } }; } | create |
1,562 | DependencyContext () { return context; } | getContext |
1,563 | int () { return val; } | asInt |
1,564 | String () { return getContext().getValue(val); } | asString |
1,565 | int (final Entry o) { return o.myString.compareTo(myString); } | compareTo |
1,566 | void (final DependencyContext context, final PrintStream stream) { final OrderProvider op = new OrderProvider(context); forEachEntry((integers, value) -> op.register(value)); final int[] keys = op.get(); for (final int a : keys) { final IntSet b = get(a); if (b == null) { continue; } stream.print(" Key: "); stream.println(context.getValue(a)); stream.println(" Values:"); final List<String> list = new LinkedList<>(); b.forEach(value -> { list.add(context.getValue(value)); }); Collections.sort(list); for (final String l : list) { stream.print(" "); stream.println(l); } stream.println(" End Of Values"); } } | toStream |
1,567 | ArtifactOutputToSourceMapping (File targetDataDir) { throw new UnsupportedOperationException("Unsupported creation type of ArtifactOutputToSourceMapping"); } | createStorage |
1,568 | List<BuildTargetChunk> (@NotNull CompileContext context) { initializeChunks(context); return myTargetChunks; } | getSortedTargetChunks |
1,569 | boolean (@NotNull BuildTarget<?> target) { return target.getTargetType().isFileBased() && myBuildRootIndex.getTargetRoots(target, null).isEmpty(); } | isDummy |
1,570 | void (BuildTarget<?> target, LinkedHashSet<? super BuildTarget<?>> result, CompileContext context) { if (result.add(target)) { for (BuildTarget<?> dep : getDependencies(target,context)) { collectDependenciesRecursively(dep, result, context); } } } | collectDependenciesRecursively |
1,571 | String () { return myTargets.toString(); } | toString |
1,572 | String () { final String name = myTargets.iterator().next().getPresentableName(); final int size = myTargets.size(); return size > 1 ? name + " and " + (size - 1) + " more" : name; } | getPresentableName |
1,573 | BuildTargetChunk (@NotNull BuildTarget<?> target) { return new BuildTargetChunk(Collections.singleton(target)); } | forSingleTarget |
1,574 | BuildTargetChunk (@NotNull ModuleChunk chunk) { return new BuildTargetChunk(chunk.getTargets()); } | forModulesChunk |
1,575 | File () { return myDataStorageRoot; } | getDataStorageRoot |
1,576 | File () { return new File(myDataStorageRoot, "targets"); } | getTargetsDataRoot |
1,577 | File (@NotNull BuildTargetType<?> targetType) { return new File(getTargetsDataRoot(), targetType.getTypeId()); } | getTargetTypeDataRoot |
1,578 | File (@NotNull BuildTarget<?> target) { BuildTargetType<?> targetType = target.getTargetType(); final String targetId = target.getId(); return getTargetDataRoot(targetType, targetId); } | getTargetDataRoot |
1,579 | File (@NotNull BuildTargetType<?> targetType, @NotNull String targetId) { // targetId may diff from another targetId only in case // when used as a file name in case-insensitive file systems, both paths for different targets will point to the same dir return new File(getTargetTypeDataRoot(targetType), PathUtilRt.suggestFileName(targetId + "_" + Integer.toHexString(targetId.hashCode()), true, false)); } | getTargetDataRoot |
1,580 | void (File output, String outputRootPath, String relativePath) { File[] children = output.listFiles(); if (children == null) { myFileGeneratedEvent.add(outputRootPath, relativePath); } else { String prefix = relativePath.isEmpty() || relativePath.equals(".") ? "" : relativePath + "/"; for (File child : children) { addEventsRecursively(child, outputRootPath, prefix + child.getName()); } } } | addEventsRecursively |
1,581 | int () { return myRegisteredSources.size(); } | getNumberOfProcessedSources |
1,582 | void () { if (!myFileGeneratedEvent.getPaths().isEmpty()) { myContext.processMessage(myFileGeneratedEvent); } } | fireFileGeneratedEvent |
1,583 | void (BuildRootDescriptor descriptor) { List<BuildRootDescriptor> list = myRootToDescriptors.get(descriptor.getRootFile()); if (list == null) { list = new SmartList<>(); myRootToDescriptors.put(descriptor.getRootFile(), list); } list.add(descriptor); } | registerDescriptor |
1,584 | boolean (File file, int parentsToCheck, BuildRootDescriptor descriptor) { File current = file; while (parentsToCheck-- > 0) { current = FileUtil.getParentFile(current); if (!isDirectoryAccepted(current, descriptor)) { return false; } } return true; } | isParentDirectoriesAccepted |
1,585 | FileFilter (@NotNull BuildRootDescriptor descriptor) { FileFilter filter = myFileFilters.get(descriptor); if (filter == null) { filter = descriptor.createFileFilter(); myFileFilters.put(descriptor, filter); } return filter; } | getRootFilter |
1,586 | boolean (@NotNull File file, @NotNull BuildRootDescriptor descriptor) { return !myIgnoredFileIndex.isIgnored(file.getName()) && getRootFilter(descriptor).accept(file); } | isFileAccepted |
1,587 | boolean (@NotNull File dir, @NotNull BuildRootDescriptor descriptor) { return !myIgnoredFileIndex.isIgnored(dir.getName()) && !descriptor.getExcludedRoots().contains(dir); } | isDirectoryAccepted |
1,588 | boolean (@NotNull T target, @NotNull File file, @NotNull R root) { hasDirtyFiles.set(true); return false; } | apply |
1,589 | boolean () { Map<BuildTarget<?>, Collection<String>> map = Utils.REMOVED_SOURCES_KEY.get(myContext); return map != null && !map.isEmpty(); } | hasRemovedFiles |
1,590 | Collection<String> (@NotNull T target) { Map<BuildTarget<?>, Collection<String>> map = Utils.REMOVED_SOURCES_KEY.get(myContext); if (map != null) { Collection<String> paths = map.get(target); if (paths != null) { return paths; } } return Collections.emptyList(); } | getRemovedFiles |
1,591 | String () { return FileUtilRt.toSystemIndependentName(myRoot.getAbsolutePath()); } | getRootId |
1,592 | File () { return myRoot; } | getRootFile |
1,593 | boolean () { return myCanUseFileCache; } | canUseFileCache |
1,594 | Iterable<StorageOwner> () { return () -> myStorages.values().iterator(); } | getChildStorages |
1,595 | String () { return JavaCompilers.ECLIPSE_ID; } | getId |
1,596 | String () { return JavaCompilers.ECLIPSE_EMBEDDED_ID; } | getAlternativeId |
1,597 | String () { String version = myVersion; if (version == null) { version = ""; JavaCompiler compiler = findCompiler(); Path file = compiler == null ? null : PathManager.getJarForClass(compiler.getClass()); if (file != null) { String name = file.getFileName().toString(); if (name.startsWith(JAR_FILE_NAME_PREFIX) && name.endsWith(JAR_FILE_NAME_SUFFIX)) { version = " " + name.substring(JAR_FILE_NAME_PREFIX.length(), name.length() - JAR_FILE_NAME_SUFFIX.length()); } } myVersion = version; } return "Eclipse compiler" + version; } | getDescription |
1,598 | List<File> () { File element = findEcjJarFile(); return ContainerUtil.createMaybeSingletonList(element); } | getAdditionalClasspath |
1,599 | List<String> () { return Collections.singletonList("-noExit"); } | getDefaultCompilerOptions |