Class: TentClient::PostAttachment
- Inherits:
-
Object
- Object
- TentClient::PostAttachment
- Defined in:
- lib/tent-client/post_attachment.rb
Instance Method Summary collapse
- #get(post_id, filename, type) ⇒ Object
-
#initialize(client) ⇒ PostAttachment
constructor
A new instance of PostAttachment.
Constructor Details
#initialize(client) ⇒ PostAttachment
Returns a new instance of PostAttachment.
3 4 5 |
# File 'lib/tent-client/post_attachment.rb', line 3 def initialize(client) @client = client end |
Instance Method Details
#get(post_id, filename, type) ⇒ Object
7 8 9 |
# File 'lib/tent-client/post_attachment.rb', line 7 def get(post_id, filename, type) @client.http.get("posts/#{post_id}/attachments/#{filename}", {}, { 'Accept' => type }) end |