Companion object with return type #1678
Replies: 3 comments
|
Not clear what you've tried so far and what didn't work for you. |
0 replies
|
So far I have tried to use TypeSpec.companionObjectBuilder() but the building chain does not provide a way to specify a type |
0 replies
|
Nevermind I was not headed in the right direction. I'll use TypeSpec.objectBuilder instead |
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Is your feature request related to a problem? Please describe.
I am trying to generate a singleton class using companion object
Describe the solution you'd like
I'd like to be able to output the correct companion object definition
Describe alternatives you've considered
None atm
Additional context
Example
Singleton Holder class => https://bladecoder.medium.com/kotlin-singletons-with-argument-194ef06edd9e
All reactions