Unnamed: 0 int64 0 305k | body stringlengths 7 52.9k | name stringlengths 1 185 |
|---|---|---|
304,400 | void (@NotNull LookupElement element, final @NotNull Lookup lookup, @NotNull Consumer<? super @NotNull LookupElementAction> consumer) { if (element instanceof CustomLiveTemplateLookupElement && ((CustomLiveTemplateLookupElement)element).getCustomLiveTemplate() instanceof ZenCodingTemplate) { PsiFile file = lookup.getPs... | fillActions |
304,401 | Result () { final Project project = lookup.getProject(); ApplicationManager.getApplication().invokeLater(() -> { if (project.isDisposed()) return; final Configurable generatorSpecificConfigurable = generator.createConfigurable(); Configurable configurable = generatorSpecificConfigurable != null ? generatorSpecificConfi... | performLookupAction |
304,402 | Result () { ApplicationManager.getApplication().invokeLater(generator::disableEmmet); return Result.HIDE_LOOKUP; } | performLookupAction |
304,403 | void (@NotNull CompletionParameters parameters, @NotNull ProcessingContext context, @NotNull CompletionResultSet result) { if (LiveTemplateCompletionContributor.shouldShowAllTemplates() || !parameters.isAutoPopup()) { // covered with com.intellij.codeInsight.template.impl.LiveTemplateCompletionContributor return; } Zen... | addCompletions |
304,404 | ZenCodingNode () { return myLeftOperand; } | getLeftOperand |
304,405 | ZenCodingNode () { return myRightOperand; } | getRightOperand |
304,406 | List<GenerationNode> (int numberInIteration, int totalIterations, String surroundedText, CustomTemplateCallback callback, boolean insertSurroundedTextAtTheEnd, GenerationNode parent) { List<GenerationNode> result = new ArrayList<>(); result.addAll(myLeftOperand.expand(numberInIteration, totalIterations, surroundedText,... | expand |
304,407 | List<ZenCodingNode> () { return ContainerUtil.newLinkedList(myLeftOperand, myRightOperand); } | getChildren |
304,408 | String () { return "^"; } | toString |
304,409 | int (CustomTemplateCallback callback) { return myLeftOperand.getApproximateOutputLength(callback) + myRightOperand.getApproximateOutputLength(callback); } | getApproximateOutputLength |
304,410 | List<GenerationNode> (int numberInIteration, int totalIterations, String surroundedText, CustomTemplateCallback callback, boolean insertSurroundedTextAtTheEnd, GenerationNode parent) { return Collections.emptyList(); } | expand |
304,411 | int (@Nullable CustomTemplateCallback callback) { return 0; } | getApproximateOutputLength |
304,412 | String () { return "EMPTY_NODE"; } | toString |
304,413 | List<ZenCodingNode> () { return Collections.emptyList(); } | getChildren |
304,414 | ZenCodingNode () { return myLeftOperand; } | getLeftOperand |
304,415 | int () { return myRightOperand; } | getRightOperand |
304,416 | List<GenerationNode> (int numberInIteration, int totalIterations, String surroundedText, CustomTemplateCallback callback, boolean insertSurroundedTextAtTheEnd, GenerationNode parent) { List<GenerationNode> result = new ArrayList<>(); for (int i = 0; i < myRightOperand; i++) { result.addAll(myLeftOperand.expand(i, myRig... | expand |
304,417 | int (@Nullable CustomTemplateCallback callback) { return myLeftOperand.getApproximateOutputLength(callback) * myRightOperand; } | getApproximateOutputLength |
304,418 | String () { return "*"; } | toString |
304,419 | TemplateToken () { return myTemplateToken; } | getTemplateToken |
304,420 | List<GenerationNode> (int numberInIteration, int totalIterations, String surroundedText, CustomTemplateCallback callback, boolean insertSurroundedTextAtTheEnd, GenerationNode parent) { TemplateToken templateToken = myTemplateToken; String templateKey = templateToken.getKey(); if (myGenerator != null && StringUtil.conta... | expand |
304,421 | String () { String result = myTemplateToken.getKey(); Map<String, String> attributes = myTemplateToken.getAttributes(); if (!attributes.isEmpty()) { result += attributes; } return "Template(" + result + ")"; } | toString |
304,422 | int (@Nullable CustomTemplateCallback callback) { TemplateImpl template = myTemplateToken.getTemplate(); if (template != null) { int result = template.getTemplateText().length(); for (Map.Entry<String, String> attribute : myTemplateToken.getAttributes().entrySet()) { result += attribute.getKey().length() + attribute.ge... | getApproximateOutputLength |
304,423 | ZenCodingNode () { return myNode; } | getNode |
304,424 | String () { return myFilter; } | getFilter |
304,425 | List<GenerationNode> (int numberInIteration, int totalIterations, String surroundedText, CustomTemplateCallback callback, boolean insertSurroundedTextAtTheEnd, GenerationNode parent) { return myNode.expand(numberInIteration, totalIterations, surroundedText, callback, insertSurroundedTextAtTheEnd, parent); } | expand |
304,426 | int (@Nullable CustomTemplateCallback callback) { return myNode.getApproximateOutputLength(callback); } | getApproximateOutputLength |
304,427 | String () { return "Filter(" + myFilter + ")"; } | toString |
304,428 | ZenCodingNode () { return myLeftOperand; } | getLeftOperand |
304,429 | ZenCodingNode () { return myRightOperand; } | getRightOperand |
304,430 | List<ZenCodingNode> () { return ContainerUtil.newLinkedList(myLeftOperand, myRightOperand); } | getChildren |
304,431 | List<GenerationNode> (int numberInIteration, int totalIterations, String surroundedText, CustomTemplateCallback callback, boolean insertSurroundedTextAtTheEnd, GenerationNode parent) { List<GenerationNode> result = new ArrayList<>(); List<GenerationNode> leftNodes = myLeftOperand.expand(numberInIteration, totalIteratio... | expand |
304,432 | String () { return "+"; } | toString |
304,433 | int (CustomTemplateCallback callback) { return myLeftOperand.getApproximateOutputLength(callback) + myRightOperand.getApproximateOutputLength(callback); } | getApproximateOutputLength |
304,434 | List<GenerationNode> (int numberInIteration, int totalIterations, String surroundedText, CustomTemplateCallback callback, boolean insertSurroundedTextAtTheEnd, GenerationNode parent) { final TemplateToken templateToken = new TemplateToken(""); final TemplateImpl template = new TemplateImpl("", myLoremGenerator.generate... | expand |
304,435 | int (@Nullable CustomTemplateCallback callback) { return myWordsCount * 7; } | getApproximateOutputLength |
304,436 | String () { return "Lorem(" + myWordsCount + ")"; } | toString |
304,437 | ZenCodingNode () { return myLeftOperand; } | getLeftOperand |
304,438 | ZenCodingNode () { return myRightOperand; } | getRightOperand |
304,439 | List<ZenCodingNode> () { return ContainerUtil.newLinkedList(myLeftOperand, myRightOperand); } | getChildren |
304,440 | int (@Nullable CustomTemplateCallback callback) { int mul = myLeftOperand instanceof MulOperationNode ? ((MulOperationNode)myLeftOperand).getRightOperand() : 1; return myLeftOperand.getApproximateOutputLength(callback) + (myRightOperand.getApproximateOutputLength(callback) * mul); } | getApproximateOutputLength |
304,441 | List<GenerationNode> (int numberInIteration, int totalIterations, String surroundedText, CustomTemplateCallback callback, boolean insertSurroundedTextAtTheEnd, GenerationNode parent) { if (myLeftOperand instanceof MulOperationNode || (myLeftOperand instanceof UnaryMulOperationNode && surroundedText != null)) { List<Gen... | expand |
304,442 | String () { return ">"; } | toString |
304,443 | boolean () { return myInsertNewLineBetweenNodes; } | isInsertNewLineBetweenNodes |
304,444 | List<GenerationNode> () { return myChildren; } | getChildren |
304,445 | void (GenerationNode child) { child.setParent(this); myChildren.add(child); } | addChild |
304,446 | void (Collection<? extends GenerationNode> children) { for (GenerationNode child : children) { addChild(child); } } | addChildren |
304,447 | boolean () { return myChildren.size() == 0; } | isLeaf |
304,448 | boolean () { if (myTemplateToken != null) { XmlTag tag = myTemplateToken.getXmlTag(); if (tag != null) { return HtmlUtil.isHtmlBlockTag(tag.getName(), true); } } return false; } | isBlockTag |
304,449 | TemplateImpl (@NotNull CustomTemplateCallback callback, @Nullable ZenCodingGenerator generator, @NotNull Collection<ZenCodingFilter> filters, boolean insertSurroundedText, int segmentsLimit) { myContainsSurroundedTextMarker = !(insertSurroundedText && myInsertSurroundedTextAtTheEnd); GenerationNode generationNode = thi... | generate |
304,450 | TemplateImpl (@NotNull TemplateToken token, boolean hasChildren, final CustomTemplateCallback callback, @Nullable ZenCodingGenerator generator) { TemplateImpl template = token.getTemplate(); if (generator != null) { assert template != null; template = generator.generateTemplate(token, hasChildren, callback.getContext()... | invokeTemplate |
304,451 | TemplateImpl (final TemplateToken token, CustomTemplateCallback callback, @Nullable ZenCodingGenerator generator, final boolean hasChildren) { ZenCodingGenerator zenCodingGenerator = ObjectUtils.notNull(generator, XmlZenCodingGeneratorImpl.INSTANCE); Map<String, String> attributes = token.getAttributes(); TemplateImpl ... | invokeXmlTemplate |
304,452 | String (@NotNull String attributeName) { char[] toReplace = {'$', '-', '+', ':'}; StringBuilder builder = new StringBuilder(attributeName.length()); for (int i = 0; i < attributeName.length(); i++) { char c = attributeName.charAt(i); boolean replaced = false; for (char aToReplace : toReplace) { if (c == aToReplace) { b... | prepareVariableName |
304,453 | TemplateImpl (@NotNull TemplateImpl template, Map<String, String> predefinedVarValues, String surroundedText, int segmentsLimit) { LiveTemplateBuilder builder = new LiveTemplateBuilder(EmmetOptions.getInstance().isAddEditPointAtTheEndOfTemplate(), segmentsLimit); if (predefinedVarValues == null && surroundedText == nul... | expandTemplate |
304,454 | XmlTag (@NotNull XmlTag tag) { StringBuilder builder = new StringBuilder(); boolean flag = false; for (PsiElement child : tag.getChildren()) { if (child instanceof XmlToken && XmlTokenType.XML_EMPTY_ELEMENT_END.equals(((XmlToken)child).getTokenType())) { flag = true; break; } builder.append(child.getText()); } if (flag... | expandEmptyTagIfNecessary |
304,455 | int (Project project, CharSequence text, int offset, int start, int end) { PsiFile file = PsiFileFactory.getInstance(project) .createFileFromText("dummy.xml", XmlFileType.INSTANCE, text, LocalTimeCounter.currentTime(), false); PsiElement element = file.findElementAt(offset); if (offset < end && element instanceof XmlTo... | gotoChild |
304,456 | void (TemplateImpl template) { Set<String> segments = new HashSet<>(); for (int i = 0; i < template.getSegmentsCount(); i++) { segments.add(template.getSegmentName(i)); } for (int i = template.getVariableCount() - 1; i >= 0; i--) { String varName = template.getVariableNameAt(i); if (!segments.contains(varName)) { templ... | removeVariablesWhichHasNoSegment |
304,457 | void (@NotNull XmlTag tag, final @NotNull Map<String, String> attributes, @NotNull CustomTemplateCallback callback, boolean isHtml) { // default and implied attributes final String defaultAttributeValue = attributes.get(XmlEmmetParser.DEFAULT_ATTRIBUTE_NAME); if (defaultAttributeValue != null) { attributes.remove(XmlEm... | setAttributeValues |
304,458 | boolean (@Nullable String attributeValue, @NotNull XmlAttribute xmlAttribute, @NotNull CustomTemplateCallback callback) { if (XmlEmmetParser.BOOLEAN_ATTRIBUTE_VALUE.equals(attributeValue)) { return true; } if (StringUtil.isEmpty(attributeValue)) { final XmlAttributeDescriptor descriptor = xmlAttribute.getDescriptor(); ... | isBooleanAttribute |
304,459 | boolean (String xmlAttributeLocalName) { return StringUtil.startsWithChar(xmlAttributeLocalName, '!'); } | isImpliedAttribute |
304,460 | boolean (String attributeValue) { return attributeValue != null && (attributeValue.isEmpty() || ATTRIBUTE_VARIABLE_PATTERN.matcher(attributeValue).matches()); } | isEmptyValue |
304,461 | boolean (CharSequence text, int offset) { int i = offset - 1; while (i >= 0 && Character.isWhitespace(text.charAt(i))) { if (text.charAt(i) == '\n') { return true; } i--; } return i < 0; } | isNewLineBefore |
304,462 | boolean (CharSequence text, int offset) { int i = offset; while (i < text.length() && Character.isWhitespace(text.charAt(i))) { if (text.charAt(i) == '\n') { return true; } i++; } return i == text.length(); } | isNewLineAfter |
304,463 | TemplateToken () { return myTemplateToken; } | getTemplateToken |
304,464 | String () { return mySurroundedText; } | getSurroundedText |
304,465 | void (String surroundedText) { mySurroundedText = surroundedText; } | setSurroundedText |
304,466 | GenerationNode () { return myParent; } | getParent |
304,467 | void (GenerationNode parent) { myParent = parent; } | setParent |
304,468 | String () { return myText; } | getText |
304,469 | List<GenerationNode> (int numberInIteration, int totalIterations, String surroundedText, CustomTemplateCallback callback, boolean insertSurroundedTextAtTheEnd, GenerationNode parent) { final TemplateToken templateToken = new TemplateToken(""); final boolean containsSurroundedTextMarker = ZenCodingUtil.containsSurrounde... | expand |
304,470 | int (@Nullable CustomTemplateCallback callback) { return myText.length(); } | getApproximateOutputLength |
304,471 | String () { return "Text(" + myText + ")"; } | toString |
304,472 | ZenCodingNode () { return myOperand; } | getOperand |
304,473 | List<GenerationNode> (int numberInIteration, int totalIterations, String surroundedText, CustomTemplateCallback callback, boolean insertSurroundedTextAtTheEnd, GenerationNode parent) { if (surroundedText == null) { return myOperand.expand(numberInIteration, totalIterations, null, callback, insertSurroundedTextAtTheEnd,... | expand |
304,474 | int (@Nullable CustomTemplateCallback callback) { return myOperand.getApproximateOutputLength(callback); } | getApproximateOutputLength |
304,475 | String () { return "*"; } | toString |
304,476 | String () { return myText; } | getText |
304,477 | String () { return myText; } | toString |
304,478 | PsiFile () { return myFile; } | getFile |
304,479 | String () { return myFile.getText(); } | getTemplateText |
304,480 | void (PsiFile file) { myFile = file; } | setFile |
304,481 | boolean () { return myForceSingleTag; } | isForceSingleTag |
304,482 | void (@NotNull String templateText, @NotNull PsiFile context) { PsiFile file = PsiFileFactory.getInstance(context.getProject()) .createFileFromText("dummy.html", context.getLanguage(), templateText, false, true); VirtualFile vFile = file.getVirtualFile(); if (vFile != null) { UndoUtil.disableUndoFor(vFile); } setFile(f... | setTemplateText |
304,483 | String () { return myKey; } | getKey |
304,484 | void (@NotNull TemplateImpl template, @NotNull CustomTemplateCallback callback) { myTemplate = template; setTemplateText(createTemplateText(template, callback, getAttributes()), callback.getFile()); } | setTemplate |
304,485 | boolean (@NotNull TemplateImpl template) { for (int i = 0; i < template.getVariableCount(); i++) { String varName = template.getVariableNameAt(i); if (ATTRS.equals(varName)) { return true; } } return false; } | containsAttrsVar |
304,486 | String (@NotNull TemplateImpl template, @NotNull CustomTemplateCallback callback, @NotNull Map<String, String> attributes) { XmlTag dummyRootTag = null; String templateString = template.getString(); if (!containsAttrsVar(template)) { PsiFile dummyFile = PsiFileFactory.getInstance(callback.getProject()) .createFileFromT... | createTemplateText |
304,487 | void (@NotNull XmlTag tag, @NotNull Map<String, String> attributes) { for (Map.Entry<String, String> attribute : attributes.entrySet()) { if (!XmlEmmetParser.DEFAULT_ATTRIBUTE_NAME.equals(attribute.getKey()) && tag.getAttribute(attribute.getKey()) == null) { XmlTag htmlTag = XmlElementFactory.getInstance(tag.getProject... | addMissingAttributes |
304,488 | String () { return "TEMPLATE"; } | toString |
304,489 | int () { return myNumber; } | getNumber |
304,490 | String () { return Integer.toString(myNumber); } | toString |
304,491 | String () { return myText; } | toString |
304,492 | String () { return myText; } | getText |
304,493 | String () { return mySuffix; } | getSuffix |
304,494 | String () { return "|" + mySuffix; } | toString |
304,495 | String () { return myText; } | toString |
304,496 | String () { return myText; } | getText |
304,497 | String () { return myString; } | toString |
304,498 | char () { return mySign; } | getSign |
304,499 | String () { return Character.toString(mySign); } | toString |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.