Unnamed: 0 int64 0 305k | body stringlengths 7 52.9k | name stringlengths 1 185 |
|---|---|---|
248,500 | String () { return "Region '" + myProvider.getPlaceholderText(myStartElement.getText()) + "'"; } | toString |
248,501 | Collection<StructureViewTreeElement> (@NotNull PsiElement rootElement, @NotNull Collection<StructureViewTreeElement> originalElements) { if (rootElement instanceof PsiFileEx && !((PsiFileEx)rootElement).isContentsLoaded() || rootElement instanceof StubBasedPsiElement && ((StubBasedPsiElement<?>)rootElement).getStub() !... | groupByCustomRegions |
248,502 | TextRange (@NotNull PsiElement element) { PsiElement first = element.getFirstChild(); if (!(element instanceof PsiFile) && first instanceof PsiComment && !first.textContains('\n')) { PsiElement next = first.getNextSibling(); if (next instanceof PsiWhiteSpace) next = next.getNextSibling(); if (next != null) { return new... | getTextRange |
248,503 | Collection<CustomRegionTreeElement> (@NotNull PsiElement rootElement, @NotNull Set<? extends TextRange> ranges) { TextRange rootRange = getTextRange(rootElement); Iterator<PsiElement> iterator = SyntaxTraverser.psiTraverser(rootElement) .filter(element -> isCustomRegionCommentCandidate(element) && rootRange.contains(el... | collectCustomRegions |
248,504 | CustomFoldingProvider (@NotNull PsiElement element) { ASTNode node = element.getNode(); if (node != null) { for (CustomFoldingProvider provider : CustomFoldingProvider.getAllProviders()) { if (provider.isCustomRegionStart(node.getText())) { return provider; } } } return null; } | getProvider |
248,505 | boolean (@NotNull PsiElement element, @NotNull Set<? extends TextRange> ranges) { for (TextRange range : ranges) { TextRange elementRange = element.getTextRange(); if (range.contains(elementRange.getStartOffset()) || range.contains(elementRange.getEndOffset())) { return true; } } return false; } | isInsideRanges |
248,506 | boolean (@NotNull PsiElement element) { Language language = element.getLanguage(); if (!Language.ANY.is(language)) { for (FoldingBuilder builder : LanguageFolding.INSTANCE.allForLanguage(language)) { if (builder instanceof CustomFoldingBuilder) { return ((CustomFoldingBuilder)builder).isCustomFoldingCandidate(element);... | isCustomRegionCommentCandidate |
248,507 | boolean () { return false; } | isOutdated |
248,508 | StructureView () { StructureViewDescriptor descriptor = ArrayUtil.getFirstElement(myStructureViews); return descriptor == null ? null : descriptor.structureView; } | getSelectedStructureView |
248,509 | boolean (final boolean requestFocus) { StructureView view = getSelectedStructureView(); return view != null && view.navigateToSelectedElement(requestFocus); } | navigateToSelectedElement |
248,510 | JComponent () { StructureView view = getSelectedStructureView(); return view == null ? null : view.getComponent(); } | getComponent |
248,511 | void () { } | dispose |
248,512 | void () { StructureView view = getSelectedStructureView(); if (view != null) view.centerSelectedRow(); } | centerSelectedRow |
248,513 | void () { for (StructureViewDescriptor descriptor : myStructureViews) { descriptor.structureView.restoreState(); } } | restoreState |
248,514 | void () { for (StructureViewDescriptor descriptor : myStructureViews) { descriptor.structureView.storeState(); } } | storeState |
248,515 | void () { for (StructureViewDescriptor descriptor : myStructureViews) { descriptor.structureView.disableStoreState(); } } | disableStoreState |
248,516 | StructureViewModel () { StructureView view = getSelectedStructureView(); if (view != null) return view.getTreeModel(); class M extends TextEditorBasedStructureViewModel implements StructureViewTreeElement, ItemPresentation { M() { super(null, null);} @NotNull @Override public StructureViewTreeElement getRoot() { return... | getTreeModel |
248,517 | StructureViewTreeElement () { return myTreeElement; } | getWrappedElement |
248,518 | V () { return (V)myTreeElement.getValue(); } | getValue |
248,519 | ItemPresentation () { return myTreeElement.getPresentation(); } | getPresentation |
248,520 | void (final boolean requestFocus) { Navigatable navigatable = getNavigatableInTemplateLanguageFile(); if (navigatable != null) { navigatable.navigate(requestFocus); } } | navigate |
248,521 | Navigatable () { PsiElement element = (PsiElement)myTreeElement.getValue(); if (element == null) return null; int offset = element.getTextRange().getStartOffset(); final Language dataLanguage = ((TemplateLanguageFileViewProvider)myMainFile.getViewProvider()).getTemplateDataLanguage(); final PsiFile dataFile = myMainFil... | getNavigatableInTemplateLanguageFile |
248,522 | boolean () { return getNavigatableInTemplateLanguageFile() != null; } | canNavigate |
248,523 | boolean () { return canNavigate(); } | canNavigateToSource |
248,524 | ItemPresentation () { return this; } | getPresentation |
248,525 | Object () { return String.valueOf(getElement()); } | getKey |
248,526 | Icon (boolean open) { final PsiElement element = getElement(); if (element != null) { int flags = Iconable.ICON_FLAG_READ_STATUS; if (!(element instanceof PsiFile) || !element.isWritable()) flags |= Iconable.ICON_FLAG_VISIBILITY; return element.getIcon(flags); } else { return null; } } | getIcon |
248,527 | T () { return getElement(); } | getValue |
248,528 | boolean () { return false; } | isSearchInLocationString |
248,529 | String () { final T element = getElement(); return element != null ? element.toString() : ""; } | toString |
248,530 | List<StructureViewTreeElement> () { return doGetChildren(false); } | getChildrenWithoutCustomRegions |
248,531 | List<StructureViewTreeElement> (boolean withCustomRegions) { T element = getElement(); return element == null ? Collections.emptyList() : mergeWithExtensions(element, getChildrenBase(), withCustomRegions); } | doGetChildren |
248,532 | void (boolean requestFocus) { T element = getElement(); if (element != null) { ((Navigatable)element).navigate(requestFocus); } } | navigate |
248,533 | boolean () { final T element = getElement(); return element instanceof Navigatable && ((Navigatable)element).canNavigate(); } | canNavigate |
248,534 | boolean () { return canNavigate(); } | canNavigateToSource |
248,535 | boolean (final Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; final PsiTreeElementBase that = (PsiTreeElementBase)o; T value = getValue(); return value == null ? that.getValue() == null : value.equals(that.getValue()); } | equals |
248,536 | int () { T value = getValue(); return value == null ? 0 : value.hashCode(); } | hashCode |
248,537 | boolean () { return getElement() != null; } | isValid |
248,538 | List<StructureViewTreeElement> (@NotNull PsiElement element, @NotNull Collection<StructureViewTreeElement> baseChildren, boolean withCustomRegions) { List<StructureViewTreeElement> result = new ArrayList<>(withCustomRegions ? CustomRegionStructureUtil.groupByCustomRegions(element, baseChildren) : baseChildren); Structu... | mergeWithExtensions |
248,539 | StructureViewBuilder (@NotNull final FileType fileType, @NotNull final VirtualFile file, @NotNull final Project project) { if (!(fileType instanceof LanguageFileType)) return null; final PsiFile psiFile = PsiManager.getInstance(project).findFile(file); if (psiFile == null) return null; final PsiStructureViewFactory fac... | getStructureViewBuilder |
248,540 | String (@NotNull List<String> callArgs) { List<String> preparedCallArgs = CommandLineUtil.toCommandLine(callArgs); String firstArg = preparedCallArgs.remove(0); preparedCallArgs.add(0, CommandLineUtil.escapeParameterOnWindows(firstArg, false)); // for CMD we would like to add extra double quotes for the actual command ... | prepareCallArgs |
248,541 | Url (@NotNull String subPath) { String newPath = path.isEmpty() && authority == null ? subPath : StringUtil.trimEnd(path, '/') + "/" + subPath; return new UrlImpl(scheme, authority, newPath, parameters); } | resolve |
248,542 | Url (@NotNull Map<String, String> parameters) { if (parameters.isEmpty()) { return this; } StringBuilder builder = new StringBuilder(); if (this.parameters == null) { builder.append('?'); } else { builder.append(this.parameters); builder.append('&'); } Urls.encodeParameters(parameters, builder); return new UrlImpl(sche... | addParameters |
248,543 | String () { if (decodedPath == null) { decodedPath = URLUtil.unescapePercentSequences(path); } return decodedPath; } | getPath |
248,544 | boolean () { return URLUtil.FILE_PROTOCOL.equals(scheme); } | isInLocalFileSystem |
248,545 | String () { StringBuilder builder = new StringBuilder(); if (scheme != null) { builder.append(scheme); if (authority == null) { builder.append(':'); } else { builder.append(URLUtil.SCHEME_SEPARATOR); } if (authority != null) { builder.append(authority); } } builder.append(getPath()); if (parameters != null) { builder.a... | toDecodedForm |
248,546 | String () { if (externalForm != null) { return externalForm; } // relative path - special url, encoding is not required // authority is null in case of URI if ((authority == null || (!path.isEmpty() && path.charAt(0) != '/')) && !isInLocalFileSystem()) { return toDecodedForm(); } String result = (StringUtil.isEmpty(aut... | toExternalForm |
248,547 | Url () { if (parameters == null) { return this; } else if (withoutParameters == null) { withoutParameters = new UrlImpl(scheme, authority, path, null); } return withoutParameters; } | trimParameters |
248,548 | String () { return toExternalForm(); } | toString |
248,549 | boolean (Object o) { if (this == o) return true; if (!(o instanceof UrlImpl url)) return false; return StringUtil.equals(scheme, url.scheme) && StringUtil.equals(authority, url.authority) && getPath().equals(url.getPath()) && StringUtil.equals(parameters, url.parameters); } | equals |
248,550 | boolean (@Nullable Url o) { if (this == o) return true; if (!(o instanceof UrlImpl url)) return false; return StringUtil.equalsIgnoreCase(scheme, url.scheme) && StringUtil.equalsIgnoreCase(authority, url.authority) && getPath().equalsIgnoreCase(url.getPath()) && StringUtil.equalsIgnoreCase(parameters, url.parameters); ... | equalsIgnoreCase |
248,551 | boolean (@Nullable Url url) { return url != null && equals(url.trimParameters()); } | equalsIgnoreParameters |
248,552 | int (boolean caseSensitive) { int result = stringHashCode(scheme, caseSensitive); result = 31 * result + stringHashCode(authority, caseSensitive); result = 31 * result + stringHashCode(getPath(), caseSensitive); result = 31 * result + stringHashCode(parameters, caseSensitive); return result; } | computeHashCode |
248,553 | int (@Nullable CharSequence string, boolean caseSensitive) { return string == null ? 0 : (caseSensitive ? string.hashCode() : StringUtil.stringHashCodeInsensitive(string)); } | stringHashCode |
248,554 | int () { return computeHashCode(true); } | hashCode |
248,555 | int () { return computeHashCode(false); } | hashCodeCaseInsensitive |
248,556 | Url (@NotNull String name) { StringBuilder result = new StringBuilder(); String parameters = this.parameters; if (parameters == null) return this; if (parameters.startsWith("?")) { parameters = StringUtil.trimStart(parameters, "?"); result.append("?"); } boolean added = false; for (String s : parameters.split("&")) { S... | removeParameter |
248,557 | Url (@NotNull String subPath) { return new LocalFileUrl(path.isEmpty() ? subPath : (path + "/" + subPath)); } | resolve |
248,558 | Url (@NotNull Map<String, String> parameters) { throw new UnsupportedOperationException("File URL doesn't support parameters"); } | addParameters |
248,559 | String () { return path; } | getPath |
248,560 | boolean () { return true; } | isInLocalFileSystem |
248,561 | String () { return path; } | toDecodedForm |
248,562 | String () { return path; } | toExternalForm |
248,563 | Url () { return this; } | trimParameters |
248,564 | String () { return toExternalForm(); } | toString |
248,565 | boolean (Object o) { return this == o || ((o instanceof LocalFileUrl) && path.equals(((LocalFileUrl)o).path)); } | equals |
248,566 | boolean (@Nullable Url o) { return this == o || ((o instanceof LocalFileUrl) && path.equalsIgnoreCase(((LocalFileUrl)o).path)); } | equalsIgnoreCase |
248,567 | boolean (@Nullable Url url) { return equals(url); } | equalsIgnoreParameters |
248,568 | int () { return path.hashCode(); } | hashCode |
248,569 | int () { return StringUtil.stringHashCodeInsensitive(path); } | hashCodeCaseInsensitive |
248,570 | IoService () { return ApplicationManager.getApplication().getService(IoService.class); } | getInstance |
248,571 | void (long increment) { myIndicator.checkCanceled(); if (increment > 0) { count += increment; if(!myIndicator.isIndeterminate()) myIndicator.setFraction((double)count / myAvailable); } } | updateProgress |
248,572 | boolean (String host, int port) { if (isLocalhost(host)) { return !canBindToLocalSocket(host, port); } else { return canConnectToRemoteSocket(host, port); } } | canConnectToSocket |
248,573 | InetAddress () { return InetAddress.getLoopbackAddress(); } | getLoopbackAddress |
248,574 | boolean (@NotNull @NlsSafe String hostName) { return hostName.equalsIgnoreCase("localhost") || hostName.equals("127.0.0.1") || hostName.equals("::1"); } | isLocalhost |
248,575 | boolean (String host, int port) { try (ServerSocket socket = new ServerSocket()) { //it looks like this flag should be set but it leads to incorrect results for NodeJS under Windows //socket.setReuseAddress(true); socket.bind(new InetSocketAddress(host, port)); return true; } catch (IOException e) { LOG.debug(e); retur... | canBindToLocalSocket |
248,576 | boolean (String host, int port) { try { Socket socket = new Socket(host, port); socket.close(); return true; } catch (IOException ignored) { return false; } } | canConnectToRemoteSocket |
248,577 | int (int defaultPort) { try { return findAvailableSocketPort(); } catch (IOException ignored) { return defaultPort; } } | tryToFindAvailableSocketPort |
248,578 | int () { return tryToFindAvailableSocketPort(-1); } | tryToFindAvailableSocketPort |
248,579 | String () { // HACK for Windows with ipv6 @NlsSafe String localHostString = "localhost"; try { final InetAddress localHost = InetAddress.getByName(localHostString); if ((localHost.getAddress().length != 4 && SystemInfo.isWindows) || (localHost.getAddress().length == 4 && SystemInfo.isMac)) { localHostString = "127.0.0.... | getLocalHostString |
248,580 | void (ProgressIndicator indicator, long downloadSpeed, long bytesDownloaded, long contentLength, boolean progressDescription) { double fraction = (double)bytesDownloaded / contentLength; if (progressDescription) { int rankForContentLength = StringUtilRt.rankForFileSize(contentLength); String formattedDownloadSpeed = St... | updateIndicator |
248,581 | boolean () { return SystemProperties.getBooleanProperty("jsse.enableSNIExtension", true); } | isSniEnabled |
248,582 | ProxySelector (@Nullable String pacUrlForUse) { return IoService.getInstance().getProxySelector(pacUrlForUse); } | getProxySelector |
248,583 | ValidHostInfo (@NotNull String host) { try { HostAndPort parsedHost = HostAndPort.fromString(host); if (parsedHost.hasPort()) { return ValidHostInfo.INVALID; } host = parsedHost.getHost(); try { InetAddresses.forString(host); return ValidHostInfo.VALID; } catch (IllegalArgumentException e) { // it is not an IPv4 or IPv... | isValidHost |
248,584 | IOException () { final Throwable cause = getCause(); return cause instanceof IOException ? (IOException)cause : new IOException(this); } | toIOException |
248,585 | boolean () { return Registry.is(RUN_PROCESSES_WITH_PTY); } | isEnabled |
248,586 | PtyCommandLine (boolean useCygwinLaunch) { myOptionsBuilder.useCygwinLaunch(useCygwinLaunch); return this; } | withUseCygwinLaunch |
248,587 | PtyCommandLine (boolean consoleMode) { myOptionsBuilder.consoleMode(consoleMode); return this; } | withConsoleMode |
248,588 | boolean () { return myOptionsBuilder.consoleMode(); } | isConsoleMode |
248,589 | PtyCommandLine (int initialColumns) { myOptionsBuilder.initialColumns(initialColumns); return this; } | withInitialColumns |
248,590 | PtyCommandLine (int initialRows) { myOptionsBuilder.initialRows(initialRows); return this; } | withInitialRows |
248,591 | PtyCommandLine (@NotNull LocalPtyOptions options) { myOptionsBuilder.set(options); return this; } | withOptions |
248,592 | PtyCommandLine (boolean unixOpenTtyToPreserveOutputAfterTermination) { myUnixOpenTtyToPreserveOutputAfterTermination = unixOpenTtyToPreserveOutputAfterTermination; return this; } | withUnixOpenTtyToPreserveOutputAfterTermination |
248,593 | String () { Application app = ApplicationManager.getApplication(); File logFile = app != null && app.isEAP() ? new File(PathManager.getLogPath(), "pty.log") : null; if (logFile != null && logFile.exists()) { try { return FileUtil.loadFile(logFile); } catch (Exception e) { return "Unable to retrieve pty log: " + e.getMe... | loadLogFile |
248,594 | LocalPtyOptions () { return myOptionsBuilder.build(); } | getPtyOptions |
248,595 | LocalPtyOptions () { return LocalPtyOptions.DEFAULT.builder() .consoleMode(true) .useWinConPty(LocalPtyOptions.shouldUseWinConPty()) .build(); } | getDefaultPtyOptions |
248,596 | CompositeParameterTargetedValue (@NotNull String value) { myValues.add(new ParameterTargetValuePart.Const(value)); return this; } | addLocalPart |
248,597 | CompositeParameterTargetedValue (@NotNull String localPath) { myValues.add(new ParameterTargetValuePart.Path(localPath)); return this; } | addPathPart |
248,598 | CompositeParameterTargetedValue () { myValues.add(ParameterTargetValuePart.PathSeparator.INSTANCE); return this; } | addPathSeparator |
248,599 | CompositeParameterTargetedValue (@NotNull File file) { myValues.add(new ParameterTargetValuePart.Path(file)); return this; } | addPathPart |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.