Skip to content
This repository was archived by the owner on Oct 10, 2024. It is now read-only.

API for creating a CodeBlock Statement directly #852

Open
anantharaman93 opened this issue Sep 10, 2021 · 2 comments
Open

API for creating a CodeBlock Statement directly #852

anantharaman93 opened this issue Sep 10, 2021 · 2 comments

Comments

@anantharaman93
Copy link

Similar to how CodeBlock.of(...) which is equitant to CodeBlock.builder().add(...).build() is provided, kindly consider providing CodeBlock.ofStatement(...) which is equivalent to CodeBlock.builder().addStatement("...").build()

@baiyanlali
Copy link

We tried to add a static method in CodeBlock to creating a CodeBlockStatement directly. Please check it out #875

@wyyfffff
Copy link

We modify the code by add method of(CodeBlock codeBlock) and ofStatement(CodeBlock codeBlock)

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants