Class Meme

java.lang.Object
me.memerator.api.object.Meme

public class Meme
extends Object
  • Constructor Details

    • Meme

      public Meme​(org.json.JSONObject items)
  • Method Details

    • getMemeId

      public String getMemeId()
      Returns:
      the meme's ID.
    • getCaption

      @Nullable public @Nullable String getCaption()
      Returns:
      the caption, if there is one.
    • getImageUrl

      public String getImageUrl()
      Returns:
      the URL of the image.
    • getTotalRatings

      public int getTotalRatings()
      Returns:
      the total amount of ratings.
    • getAverageRating

      public Float getAverageRating()
      Returns:
      the average rating.
    • getTimestamp

      public Instant getTimestamp()
      Returns:
      The timestamp as an instant
    • getTimeAgoFormatted

      public String getTimeAgoFormatted()
      Returns:
      the time string that appears on the website
    • getAuthor

      public User getAuthor()
      Returns:
      the author of this meme
    • getMemeUrl

      public String getMemeUrl()
      Returns:
      the URL to the meme
    • isDisabled

      public boolean isDisabled()
      Usually, the only people who can see disabled memes are Staff and the owners of the meme. This will most likely always be false.
      Returns:
      the meme disabled status.
    • getComments

      public List<Comment> getComments()
      Returns:
      the comments for this meme
    • getAgeRating

      public Age getAgeRating()
      Returns the Age as an Age enum
      Returns:
      the Age
    • getRatings

      public List<Rating> getRatings()
      Gets the ratings on this meme. Requirements for a response: 1) Be Pro 2) Be the owner of the meme
      Returns:
      a list of ratings
    • disable

      public void disable()
      Disables this meme. Meme owner only.
    • enable

      public void enable()
      Enable this meme. Meme owner only.
    • setCaption

      public void setCaption​(String newcaption)
      Set the caption
      Parameters:
      newcaption - the caption to set