/** * Add new {@link Post} to the topic. * The method sets Posts.topic field to this Topic. * * @param post post to add */ public void addPost(Post post) { setModificationDate(post.getCreationDate()); post.setTopic(this); this.posts.add(post); }
/** * Add new {@link Post} to the topic. * The method sets Posts.topic field to this Topic. * * @param post post to add */ public void addPost(Post post) { setModificationDate(post.getCreationDate()); post.setTopic(this); this.posts.add(post); }