Skip to content

Improve performance in ConsoleProgressBarConsumer.accept - #106

Merged
ctongfei merged 1 commit into
ctongfei:0.9.3from
heroesleo65:improve_console_consumer
Jul 7, 2021
Merged

ctongfei merged 1 commit into
ctongfei:0.9.3from
heroesleo65:improve_console_consumer

Conversation

@heroesleo65

Copy link
Copy Markdown
Contributor

StringDisplayUtils.trimDisplayLength(str, max_display_len) to select string with minimal of total display length this str and given max_display_len. I mean that calculate display length of string is unnecessary. This idea is using in InteractiveConsoleProgressBarConsumer (

String s = StringDisplayUtils.trimDisplayLength(str, getMaxRenderedLength());
)

@ctongfei

ctongfei commented Jul 7, 2021

Copy link
Copy Markdown
Owner

Yeah you are right. The code is completely redundant. Thanks!

@ctongfei
ctongfei changed the base branch from main to 0.9.3 July 7, 2021 05:01
@ctongfei
ctongfei merged commit a9c99a0 into ctongfei:0.9.3 Jul 7, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants