How to add nested comments in Java?
To produce a nested comment thread, you first need the comment system to be capable of referring a comment to the ID of a parent comment. This is pretty standard so you likely have that already.
What is a nested comment?
When someone comments on a previous comment, a “nest” is created. The first comment shows normally, but then the replies to the comment are categorized directly underneath the original comment.