[ 
https://issues.apache.org/jira/browse/GROOVY-11655?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17949788#comment-17949788
 ] 

ASF GitHub Bot commented on GROOVY-11655:
-----------------------------------------

codecov-commenter commented on PR #2215:
URL: https://github.com/apache/groovy/pull/2215#issuecomment-2855268053

   ## 
[Codecov](https://app.codecov.io/gh/apache/groovy/pull/2215?dropdown=coverage&src=pr&el=h1&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache)
 Report
   Attention: Patch coverage is `58.82353%` with `7 lines` in your changes 
missing coverage. Please review.
   > Project coverage is 68.9897%. Comparing base 
[(`f1b3f72`)](https://app.codecov.io/gh/apache/groovy/commit/f1b3f727ed9a94ab314241449ae875cf7355ffe8?dropdown=coverage&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache)
 to head 
[(`155f5b8`)](https://app.codecov.io/gh/apache/groovy/commit/155f5b876bce4062f212b31002267f038dbcd873?dropdown=coverage&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache).
   
   | [Files with missing 
lines](https://app.codecov.io/gh/apache/groovy/pull/2215?dropdown=coverage&src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache)
 | Patch % | Lines |
   |---|---|---|
   | 
[...g/codehaus/groovy/runtime/StringGroovyMethods.java](https://app.codecov.io/gh/apache/groovy/pull/2215?src=pr&el=tree&filepath=src%2Fmain%2Fjava%2Forg%2Fcodehaus%2Fgroovy%2Fruntime%2FStringGroovyMethods.java&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache#diff-c3JjL21haW4vamF2YS9vcmcvY29kZWhhdXMvZ3Jvb3Z5L3J1bnRpbWUvU3RyaW5nR3Jvb3Z5TWV0aG9kcy5qYXZh)
 | 58.8235% | [6 Missing and 1 partial :warning: 
](https://app.codecov.io/gh/apache/groovy/pull/2215?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache)
 |
   
   <details><summary>Additional details and impacted files</summary>
   
   
   [![Impacted file tree 
graph](https://app.codecov.io/gh/apache/groovy/pull/2215/graphs/tree.svg?width=650&height=150&src=pr&token=1r45138NfQ&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache)](https://app.codecov.io/gh/apache/groovy/pull/2215?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache)
   
   ```diff
   @@                Coverage Diff                 @@
   ##               master      #2215        +/-   ##
   ==================================================
   + Coverage     68.9851%   68.9897%   +0.0046%     
   - Complexity      29623      29631         +8     
   ==================================================
     Files            1423       1423                
     Lines          114216     114233        +17     
     Branches        19810      19811         +1     
   ==================================================
   + Hits            78792      78809        +17     
   - Misses          28803      28805         +2     
   + Partials         6621       6619         -2     
   ```
   
   | [Files with missing 
lines](https://app.codecov.io/gh/apache/groovy/pull/2215?dropdown=coverage&src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache)
 | Coverage Δ | |
   |---|---|---|
   | 
[...g/codehaus/groovy/runtime/StringGroovyMethods.java](https://app.codecov.io/gh/apache/groovy/pull/2215?src=pr&el=tree&filepath=src%2Fmain%2Fjava%2Forg%2Fcodehaus%2Fgroovy%2Fruntime%2FStringGroovyMethods.java&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache#diff-c3JjL21haW4vamF2YS9vcmcvY29kZWhhdXMvZ3Jvb3Z5L3J1bnRpbWUvU3RyaW5nR3Jvb3Z5TWV0aG9kcy5qYXZh)
 | `82.7586% <58.8235%> (-0.4007%)` | :arrow_down: |
   
   ... and [3 files with indirect coverage 
changes](https://app.codecov.io/gh/apache/groovy/pull/2215/indirect-changes?src=pr&el=tree-more&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache)
   
   </details>
   <details><summary> :rocket: New features to boost your workflow: </summary>
   
   - :snowflake: [Test 
Analytics](https://docs.codecov.com/docs/test-analytics): Detect flaky tests, 
report on failures, and find test suite problems.
   - :package: [JS Bundle 
Analysis](https://docs.codecov.com/docs/javascript-bundle-analysis): Save 
yourself from yourself by tracking and limiting bundle sizes in JS merges.
   </details>




> Create extension method to make StringBuilder like a stack
> ----------------------------------------------------------
>
>                 Key: GROOVY-11655
>                 URL: https://issues.apache.org/jira/browse/GROOVY-11655
>             Project: Groovy
>          Issue Type: New Feature
>            Reporter: John
>            Priority: Major
>
> for leetcode problem: 
> [https://leetcode.com/problems/design-a-text-editor/description/]
> the java code below,  suppose StringBuilder to be a contain of chars , 
> meanwhile as a stack.
>  
> {code:java}
> class TextEditor {
>     private final StringBuilder left = new StringBuilder(); 
>     private final StringBuilder right = new StringBuilder(); 
>     public void addText(String text) {
>         left.append(text); 
>     }
>     public int deleteText(int k) {
>         k = Math.min(k, left.length());
>         left.setLength(left.length() - k); 
>         return k;
>     }
>     public String cursorLeft(int k) {
>         while (k > 0 && !left.isEmpty()) {
>             right.append(left.charAt(left.length() - 1)); 
>             left.setLength(left.length() - 1);
>             k--;
>         }
>         return text();
>     }
>     public String cursorRight(int k) {
>         while (k > 0 && !right.isEmpty()) {
>             left.append(right.charAt(right.length() - 1)); 
>             right.setLength(right.length() - 1);
>             k--;
>         }
>         return text();
>     }
>     private String text() {
>         
>         return left.substring(Math.max(left.length() - 10, 0));
>     }
> }
> {code}
>  
>  



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to