I am wondering if is it possible to add method to class without having to rewrite whole class again using Java Poet?
Thanks
I am wondering if is it possible to add method to class without having to rewrite whole class again using Java Poet?
Thanks
Copyright © 2021 Jogjafile Inc.
JavaPoet emits source code, nothing else. It can't consume the source code of an existing class.
You could emit a method with it and insert it into the body of a class some other way, but that's as good as it gets.