Class Comments


  • @Path("2/comments")
    public class Comments
    extends Object
    REST interface for the social networking library (comments).
    • Constructor Detail

      • Comments

        public Comments()
    • Method Detail

      • getAllCommentsByPostId

        @GET
        @Produces("application/json")
        @Path("get-comments-by-post-id")
        public javax.ws.rs.core.Response getAllCommentsByPostId​(@NotNull @QueryParam("key")
                                                                String key)
      • getCommentsUser

        @GET
        @Produces("application/json")
        @Path("get-comments-user")
        public javax.ws.rs.core.Response getCommentsUser()
      • getCommentsUserByTime

        @GET
        @Produces("application/json")
        @Path("get-comments-user-by-time")
        public javax.ws.rs.core.Response getCommentsUserByTime​(@QueryParam("time") @Min(value=0L,message="time cannot be negative")
                                                               long timeInMillis)
                                                        throws javax.validation.ValidationException
        Throws:
        javax.validation.ValidationException
      • writeComment

        @POST
        @Path("comment-post")
        @Consumes("application/json")
        @Produces("application/json")
        public javax.ws.rs.core.Response writeComment​(@NotNull(message="Comment to write is missing")
                                                      CommentInputBean comment)
                                               throws javax.validation.ValidationException
        Create a new comment to a post having as owner the auth token's owner
        Parameters:
        post - The post to be written
        Returns:
        Throws:
        javax.validation.ValidationException