Unnamed: 0
int64
0
305k
body
stringlengths
7
52.9k
name
stringlengths
1
185
263,700
String (@NotNull String name) { if (!PRINTABLE_ASCII_PATTERN.matcher(name).matches()) return name; return StringUtil.toLowerCase(name); }
nameToLowerCase
263,701
String (@NotNull String name) { if (name.isEmpty()) return name; if (!PRINTABLE_ASCII_PATTERN.matcher(name).matches()) return name; return StringUtil.toUpperCase(name.substring(0, 1)) + name.substring(1); }
capitalizeName
263,702
String (@NotNull String email) { return StringUtil.toLowerCase(email); }
emailToLowerCase
263,703
int (@Nullable VcsUser user) { return user != null ? getNameInStandardForm(getName(user)).hashCode() : 0; }
hashCode
263,704
boolean (@Nullable VcsUser user1, @Nullable VcsUser user2) { if (user1 == user2) return true; if (user1 == null || user2 == null) return false; return isSamePerson(user1, user2); }
equals
263,705
StopWatch (@NonNls @NotNull String operation) { return new StopWatch(operation); }
start
263,706
void (@NotNull VirtualFile root) { long totalDuration = System.currentTimeMillis() - myStartTime; long duration = totalDuration - sum(myDurationPerRoot.values()); myDurationPerRoot.put(root, duration); }
rootCompleted
263,707
long (@NotNull Collection<Long> durations) { long sum = 0; for (Long duration : durations) { sum += duration; } return sum; }
sum
263,708
void () { report(LOG); }
report
263,709
void (@NotNull Logger logger) { mySpan.end(); String message = myOperation + " took " + formatTime(System.currentTimeMillis() - myStartTime); if (myDurationPerRoot.size() > 1) { message += "\n" + StringUtil.join(myDurationPerRoot.entrySet(), entry -> " " + entry.getKey().getName() + ": " + formatTime(entry.getValue()),...
report
263,710
String (long time) { if (time < 1000 * UNITS[0]) { return time + "ms"; } String result = ""; long remainder = time / 1000; long msec = time % 1000; for (int i = UNITS.length - 1; i >= 0; i--) { if (remainder < UNITS[i]) continue; long quotient = remainder / UNITS[i]; remainder = remainder % UNITS[i]; if (i == 0) { resu...
formatTime
263,711
String () { return myName; }
getName
263,712
String () { return myEmail; }
getEmail
263,713
boolean (Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; VcsUserImpl user = (VcsUserImpl)o; if (!myName.equals(user.myName)) return false; if (!myEmail.equals(user.myEmail)) return false; return true; }
equals
263,714
int () { return Objects.hash(myName, myEmail); }
hashCode
263,715
String () { return VcsUserUtil.toExactString(this); }
toString
263,716
ChangeListsScopesProvider (Project project) { return CUSTOM_SCOPES_PROVIDER.findExtension(ChangeListsScopesProvider.class, project); }
getInstance
263,717
List<NamedScope> () { if (myProject.isDefault() || !ProjectLevelVcsManager.getInstance(myProject).hasActiveVcss()) { return Collections.emptyList(); } ChangeListManager changeListManager = ChangeListManager.getInstance(myProject); List<NamedScope> result = new ArrayList<>(); result.add(new ChangeListScope(changeListMan...
getCustomScopes
263,718
NamedScope (@NotNull String name) { if (myProject.isDefault()) return null; final ChangeListManager changeListManager = ChangeListManager.getInstance(myProject); if (ChangeListScope.ALL_CHANGED_FILES_SCOPE_NAME.equals(name)) { return new ChangeListScope(changeListManager); } if (ChangesUtil.hasMeaningfulChangelists(myP...
getCustomScope
263,719
boolean (NamedScope scope, ScopePlace place) { if (place == ScopePlace.SETTING) { if (myProject.isDefault()) return false; final ChangeListManager changeListManager = ChangeListManager.getInstance(myProject); return changeListManager.findChangeList(scope.getScopeId()) != null; } return false; }
isVetoed
263,720
int () { return getScopeId().hashCode(); }
hashCode
263,721
boolean (Object object) { if (object == this) return true; if (object instanceof ChangeListScope scope) { return scope.getIcon() == getIcon() && scope.getScopeId().equals(getScopeId()); } return false; }
equals
263,722
String () { String string = super.toString(); if (AllIcons.Scope.ChangedFilesAll == getIcon()) string += "; ALL"; // NON-NLS return string; }
toString
263,723
int () { return AllIcons.Scope.ChangedFilesAll == getIcon() ? 0 : 1; }
getWeight
263,724
Block (@NotNull String prevContent) { return createPreviousBlock(tokenize(prevContent)); }
createPreviousBlock
263,725
Block (String @NotNull [] prevContent) { try { FairDiffIterable iterable = ByLine.compare(Arrays.asList(prevContent), Arrays.asList(mySource), ComparisonPolicy.IGNORE_WHITESPACES, DumbProgressIndicator.INSTANCE); // empty range should not be transferred to the non-empty range boolean greedy = myStart != myEnd; int star...
createPreviousBlock
263,726
String () { return StringUtil.join(getLines(), "\n"); }
getBlockContent
263,727
List<String> () { return Arrays.asList(mySource).subList(myStart, myEnd); }
getLines
263,728
int () { return Arrays.hashCode(mySource) ^ myStart ^ myEnd; }
hashCode
263,729
boolean (Object object) { if (!(object instanceof Block other)) return false; return myStart == other.myStart && myEnd == other.myEnd && Arrays.equals(mySource, other.mySource); }
equals
263,730
int () { return myStart; }
getStart
263,731
int () { return myEnd; }
getEnd
263,732
String () { StringBuilder result = new StringBuilder(); appendLines(result, 0, myStart); result.append("<-----------------------------\n"); appendLines(result, myStart, myEnd); result.append("----------------------------->\n"); appendLines(result, myEnd, mySource.length); return result.toString(); }
toString
263,733
void (@NotNull StringBuilder result, int from, int to) { for (int i = from; i < to; i++) { result.append(mySource[i]); result.append("\n"); } }
appendLines
263,734
boolean () { return !myConversionNeeded; }
conversionNotNeeded
263,735
boolean () { return myConversionCanceled || myErrorOccurred; }
openingIsCanceled
263,736
void (@NotNull Project project) { Application app = ApplicationManager.getApplication(); if (app.isHeadlessEnvironment() || app.isUnitTestMode()) { return; } List<VirtualFile> changedFiles = findVirtualFiles(myChangedFiles); if (!changedFiles.isEmpty()) { EditAction.editFilesAndShowErrors(project, changedFiles); } List...
postStartupActivity
263,737
boolean (@NotNull List<? extends VirtualFile> files, Project project) { if (files.isEmpty()) { return false; } ProjectLevelVcsManager projectLevelVcsManager = ProjectLevelVcsManager.getInstance(project); for (VirtualFile file : files) { if (projectLevelVcsManager.getVcsFor(file) != null) { return true; } } return false...
containsFilesUnderVcs
263,738
List<VirtualFile> (@NotNull Collection<? extends Path> files) { List<VirtualFile> result = new ArrayList<>(files.size()); for (Path file : files) { VirtualFile element = LocalFileSystem.getInstance().refreshAndFindFileByNioFile(file); if (element != null) { result.add(element); } } return result; }
findVirtualFiles
263,739
ASTNode (IElementType t, PsiBuilder b) { parseLight(t, b); return b.getTreeBuilt(); }
parse
263,740
void (IElementType t, PsiBuilder b) { boolean r; b = adapt_builder_(t, b, this, EXTENDS_SETS_); Marker m = enter_section_(b, 0, _COLLAPSE_, null); r = parse_root_(t, b); exit_section_(b, 0, m, t, r, true, TRUE_CONDITION); }
parseLight
263,741
boolean (IElementType t, PsiBuilder b) { return parse_root_(t, b, 0); }
parse_root_
263,742
boolean (IElementType t, PsiBuilder b, int l) { return ignoreFile(b, l + 1); }
parse_root_
263,743
boolean (PsiBuilder b, int l) { if (!recursion_guard_(b, l, "ENTRY")) return false; boolean r; Marker m = enter_section_(b, l, _NONE_, ENTRY, "<entry>"); r = ENTRY_0(b, l + 1); r = r && ENTRY_1(b, l + 1); r = r && list_macro(b, l + 1, value__parser_); exit_section_(b, l, m, r, false, null); return r; }
ENTRY
263,744
boolean (PsiBuilder b, int l) { if (!recursion_guard_(b, l, "ENTRY_0")) return false; NEGATION(b, l + 1); return true; }
ENTRY_0
263,745
boolean (PsiBuilder b, int l) { if (!recursion_guard_(b, l, "ENTRY_1")) return false; consumeToken(b, SLASH); return true; }
ENTRY_1
263,746
boolean (PsiBuilder b, int l) { if (!recursion_guard_(b, l, "ENTRY_DIRECTORY")) return false; boolean r; Marker m = enter_section_(b, l, _NONE_, ENTRY_DIRECTORY, "<entry>"); r = ENTRY_DIRECTORY_0(b, l + 1); r = r && ENTRY_DIRECTORY_1(b, l + 1); r = r && list_macro(b, l + 1, value__parser_); r = r && consumeToken(b, SLA...
ENTRY_DIRECTORY
263,747
boolean (PsiBuilder b, int l) { if (!recursion_guard_(b, l, "ENTRY_DIRECTORY_0")) return false; NEGATION(b, l + 1); return true; }
ENTRY_DIRECTORY_0
263,748
boolean (PsiBuilder b, int l) { if (!recursion_guard_(b, l, "ENTRY_DIRECTORY_1")) return false; consumeToken(b, SLASH); return true; }
ENTRY_DIRECTORY_1
263,749
boolean (PsiBuilder b, int l) { if (!recursion_guard_(b, l, "ENTRY_FILE")) return false; boolean r; Marker m = enter_section_(b, l, _NONE_, ENTRY_FILE, "<entry>"); r = ENTRY_FILE_0(b, l + 1); r = r && ENTRY_FILE_1(b, l + 1); r = r && list_macro(b, l + 1, value__parser_); exit_section_(b, l, m, r, false, null); return r...
ENTRY_FILE
263,750
boolean (PsiBuilder b, int l) { if (!recursion_guard_(b, l, "ENTRY_FILE_0")) return false; NEGATION(b, l + 1); return true; }
ENTRY_FILE_0
263,751
boolean (PsiBuilder b, int l) { if (!recursion_guard_(b, l, "ENTRY_FILE_1")) return false; consumeToken(b, SLASH); return true; }
ENTRY_FILE_1
263,752
boolean (PsiBuilder b, int l) { if (!recursion_guard_(b, l, "NEGATION")) return false; boolean r; Marker m = enter_section_(b, l, _NONE_, NEGATION, "<negation>"); r = consumeToken(b, "!"); exit_section_(b, l, m, r, false, null); return r; }
NEGATION
263,753
boolean (PsiBuilder b, int l) { if (!recursion_guard_(b, l, "SYNTAX")) return false; if (!nextTokenIs(b, SYNTAX_KEY)) return false; boolean r; Marker m = enter_section_(b); r = consumeToken(b, SYNTAX_KEY); r = r && SYNTAX_1(b, l + 1); r = r && consumeToken(b, VALUE); exit_section_(b, m, SYNTAX, r); return r; }
SYNTAX
263,754
boolean (PsiBuilder b, int l) { if (!recursion_guard_(b, l, "SYNTAX_1")) return false; while (true) { int c = current_position_(b); if (!consumeToken(b, CRLF)) break; if (!empty_element_parsed_guard_(b, "SYNTAX_1", c)) break; } return true; }
SYNTAX_1
263,755
boolean (PsiBuilder b, int l) { if (!recursion_guard_(b, l, "bvalue_")) return false; if (!nextTokenIs(b, BRACKET_LEFT)) return false; boolean r, p; Marker m = enter_section_(b, l, _NONE_); r = consumeToken(b, BRACKET_LEFT); p = r; // pin = BRACKET_LEFT r = r && report_error_(b, bvalue__1(b, l + 1)); r = p && consumeTo...
bvalue_
263,756
boolean (PsiBuilder b, int l) { if (!recursion_guard_(b, l, "bvalue__1")) return false; boolean r; Marker m = enter_section_(b); r = bvalue__1_0(b, l + 1); while (r) { int c = current_position_(b); if (!bvalue__1_0(b, l + 1)) break; if (!empty_element_parsed_guard_(b, "bvalue__1", c)) break; } exit_section_(b, m, null,...
bvalue__1
263,757
boolean (PsiBuilder b, int l) { if (!recursion_guard_(b, l, "bvalue__1_0")) return false; boolean r; Marker m = enter_section_(b); r = consumeToken(b, VALUE); r = r && bvalue__1_0_1(b, l + 1); exit_section_(b, m, null, r); return r; }
bvalue__1_0
263,758
boolean (PsiBuilder b, int l) { if (!recursion_guard_(b, l, "bvalue__1_0_1")) return false; consumeToken(b, SLASH); return true; }
bvalue__1_0_1
263,759
boolean (PsiBuilder b, int l) { if (!recursion_guard_(b, l, "ignoreFile")) return false; while (true) { int c = current_position_(b); if (!item_(b, l + 1)) break; if (!empty_element_parsed_guard_(b, "ignoreFile", c)) break; } return true; }
ignoreFile
263,760
boolean (PsiBuilder b, int l) { if (!recursion_guard_(b, l, "item_")) return false; boolean r; r = consumeToken(b, HEADER); if (!r) r = consumeToken(b, SECTION); if (!r) r = consumeToken(b, COMMENT); if (!r) r = SYNTAX(b, l + 1); if (!r) r = ENTRY_DIRECTORY(b, l + 1); if (!r) r = ENTRY_FILE(b, l + 1); if (!r) r = consu...
item_
263,761
boolean (PsiBuilder b, int l, Parser _p) { if (!recursion_guard_(b, l, "list_macro")) return false; boolean r; Marker m = enter_section_(b); r = list_macro_0(b, l + 1, _p); r = r && list_macro_1(b, l + 1, _p); exit_section_(b, m, null, r); return r; }
list_macro
263,762
boolean (PsiBuilder b, int l, Parser _p) { if (!recursion_guard_(b, l, "list_macro_0")) return false; boolean r; Marker m = enter_section_(b); r = _p.parse(b, l); while (r) { int c = current_position_(b); if (!_p.parse(b, l)) break; if (!empty_element_parsed_guard_(b, "list_macro_0", c)) break; } exit_section_(b, m, nu...
list_macro_0
263,763
boolean (PsiBuilder b, int l, Parser _p) { if (!recursion_guard_(b, l, "list_macro_1")) return false; while (true) { int c = current_position_(b); if (!list_macro_1_0(b, l + 1, _p)) break; if (!empty_element_parsed_guard_(b, "list_macro_1", c)) break; } return true; }
list_macro_1
263,764
boolean (PsiBuilder b, int l, Parser _p) { if (!recursion_guard_(b, l, "list_macro_1_0")) return false; boolean r; Marker m = enter_section_(b); r = consumeToken(b, SLASH); r = r && list_macro_1_0_1(b, l + 1, _p); exit_section_(b, m, null, r); return r; }
list_macro_1_0
263,765
boolean (PsiBuilder b, int l, Parser _p) { if (!recursion_guard_(b, l, "list_macro_1_0_1")) return false; boolean r; Marker m = enter_section_(b); r = _p.parse(b, l); while (r) { int c = current_position_(b); if (!_p.parse(b, l)) break; if (!empty_element_parsed_guard_(b, "list_macro_1_0_1", c)) break; } exit_section_(...
list_macro_1_0_1
263,766
boolean (PsiBuilder b, int l) { if (!recursion_guard_(b, l, "value_")) return false; if (!nextTokenIs(b, "", BRACKET_LEFT, VALUE)) return false; boolean r; r = bvalue_(b, l + 1); if (!r) r = consumeToken(b, VALUE); return r; }
value_
263,767
boolean (PsiBuilder b, int l) { return value_(b, l + 1); }
parse
263,768
PsiElement (ASTNode node) { IElementType type = node.getElementType(); if (type == ENTRY) { return new IgnoreEntryImpl(node); } else if (type == ENTRY_DIRECTORY) { return new IgnoreEntryDirectoryImpl(node); } else if (type == ENTRY_FILE) { return new IgnoreEntryFileImpl(node); } else if (type == NEGATION) { return new ...
createElement
263,769
void (@NotNull IgnoreEntry o) { visitEntryBase(o); }
visitEntry
263,770
void (@NotNull IgnoreEntryDirectory o) { visitEntryFile(o); }
visitEntryDirectory
263,771
void (@NotNull IgnoreEntryFile o) { visitEntry(o); }
visitEntryFile
263,772
void (@NotNull IgnoreNegation o) { visitPsiElement(o); }
visitNegation
263,773
void (@NotNull IgnoreSyntax o) { visitPsiElement(o); }
visitSyntax
263,774
void (@NotNull IgnoreEntryBase o) { visitPsiElement(o); }
visitEntryBase
263,775
void (@NotNull PsiElement o) { visitElement(o); }
visitPsiElement
263,776
void (@NotNull PsiElementVisitor visitor) { if (visitor instanceof IgnoreVisitor) ((IgnoreVisitor)visitor).visitEntryFile(this); else super.accept(visitor); }
accept
263,777
IgnoreNegation () { return findChildByClass(IgnoreNegation.class); }
getNegation
263,778
void (@NotNull PsiElementVisitor visitor) { if (visitor instanceof IgnoreVisitor) ((IgnoreVisitor)visitor).visitNegation(this); else super.accept(visitor); }
accept
263,779
void (@NotNull PsiElementVisitor visitor) { if (visitor instanceof IgnoreVisitor) ((IgnoreVisitor)visitor).visitEntry(this); else super.accept(visitor); }
accept
263,780
IgnoreNegation () { return findChildByClass(IgnoreNegation.class); }
getNegation
263,781
void (@NotNull PsiElementVisitor visitor) { if (visitor instanceof IgnoreVisitor) ((IgnoreVisitor)visitor).visitSyntax(this); else super.accept(visitor); }
accept
263,782
PsiElement () { return findNotNullChildByType(VALUE); }
getValue
263,783
void (@NotNull PsiElementVisitor visitor) { if (visitor instanceof IgnoreVisitor) ((IgnoreVisitor)visitor).visitEntryDirectory(this); else super.accept(visitor); }
accept
263,784
IgnoreNegation () { return findChildByClass(IgnoreNegation.class); }
getNegation
263,785
int (int ch) { return ZZ_CMAP_A[ZZ_CMAP_Y[ZZ_CMAP_Z[ch>>13]|((ch>>7)&0x3f)]|(ch&0x7f)]; }
ZZ_CMAP
263,786
int (String packed, int offset, int [] result) { int i = 0; /* index in packed string */ int j = offset; /* index in unpacked array */ int l = packed.length(); while (i < l) { int count = packed.charAt(i++); int value = packed.charAt(i++); do result[j++] = value; while (--count > 0); } return j; }
zzUnpackAction
263,787
int (String packed, int offset, int [] result) { int i = 0; /* index in packed string */ int j = offset; /* index in unpacked array */ int l = packed.length(); while (i < l) { int high = packed.charAt(i++) << 16; result[j++] = high | packed.charAt(i++); } return j; }
zzUnpackRowMap
263,788
int (String packed, int offset, int [] result) { int i = 0; /* index in packed string */ int j = offset; /* index in unpacked array */ int l = packed.length(); while (i < l) { int count = packed.charAt(i++); int value = packed.charAt(i++); value--; do result[j++] = value; while (--count > 0); } return j; }
zzUnpackTrans
263,789
int (String packed, int offset, int [] result) { int i = 0; /* index in packed string */ int j = offset; /* index in unpacked array */ int l = packed.length(); while (i < l) { int count = packed.charAt(i++); int value = packed.charAt(i++); do result[j++] = value; while (--count > 0); } return j; }
zzUnpackAttribute
263,790
boolean () { return language == null || language.isSyntaxSupported(); }
isSyntaxSupported
263,791
int () { return zzStartRead; }
getTokenStart
263,792
int () { return getTokenStart() + yylength(); }
getTokenEnd
263,793
void (CharSequence buffer, int start, int end, int initialState) { zzBuffer = buffer; zzCurrentPos = zzMarkedPos = zzStartRead = start; zzAtEOF = false; zzAtBOL = true; zzEndRead = end; yybegin(initialState); }
reset
263,794
int () { return zzLexicalState; }
yystate
263,795
void (int newState) { zzLexicalState = newState; }
yybegin
263,796
CharSequence () { return zzBuffer.subSequence(zzStartRead, zzMarkedPos); }
yytext
263,797
char (int pos) { return zzBuffer.charAt(zzStartRead+pos); }
yycharat
263,798
int () { return zzMarkedPos-zzStartRead; }
yylength
263,799
void (int errorCode) { String message; try { message = ZZ_ERROR_MSG[errorCode]; } catch (ArrayIndexOutOfBoundsException e) { message = ZZ_ERROR_MSG[ZZ_UNKNOWN_ERROR]; } throw new Error(message); }
zzScanError