Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
为
Applications
增加部分Java友好API。注意:这可能是不兼容的。
旧API中可能存在大量Lambda表达式是需要返回
Unit.INSTANCE
或者需要通过Lambdas
来获取一个suspend
兼容函数的,例如更新后则可以使用与Java Lambda相近的方式:
但是旧方法将不再支持(兼容),因此这有可能是二进制不兼容的。
Applications.simbotApplication(...)
同理。Applications.buildSimbotApplication
所得到的ApplicationDslBuilder
中的API有所调整,其config
和build
API将会提供Java友好的Lambda使用方式。但是,其中
config
的参数类型被变更,因此说仅保证对Kotlin的源码兼容,且不是二进制兼容的。