Exemplo n.º 1
0
 /* Checks if a comment belongs to this Post or to its root post
 RECURSIVE untill no rootPost encountered
 invoced in blog.scala.html */
 public boolean belongsToComment(Comment c) {
   if (c.post.equals(this)) return true;
   if (rootPost == null) return false;
   if (rootPost.belongsToComment(c)) return true;
   return false;
 }