code: public WebhookMessageBuilder addFile(String name, File file)
      {
          Checks.notNull(file, "File");
          Checks.notBlank(name, "Name");
          Checks.check(file.exists() && file.canRead(), "File must exist and be readable");
          if (fileIndex >= MAX_FILES)
              throw new IllegalStateException("Cannot add more than " + MAX_FILES + " attachments to a message");
  
          try
          {
              MessageAttachment attachment = new MessageAttachment(name, file);
              files[fileIndex++] = attachment;
              return this;
          }
          catch (IOException ex)
          {
              throw new IllegalArgumentException(ex);
          }
      }
docs: Adds the provided file to the resulting message.
  
  @param  name
  The name to use for this file
  @param  file
  The file to add
  
  @throws IllegalArgumentException
  If the provided file is null, does not exist, or is not readable
  @throws IllegalStateException
  If the file limit has already been reached
  
  @return The current WebhookMessageBuilder for chaining convenience
  
  @see    #resetFiles()