Class Facebooker::MessageThread::Message::Attachment
In: lib/facebooker/models/message_thread.rb
Parent: Object

An attachment can be a photo, a video, or a link

Methods

link?   photo?   video?  

Included Modules

Model

Attributes

caption  [RW] 
description  [RW] 
href  [RW] 
icon  [RW] 
name  [RW] 

Public Instance methods

The Facebook messages API is in beta, this helper method is supposed to fail anytime soon

[Source]

# File lib/facebooker/models/message_thread.rb, line 33
        def link?
          !video? && !photo?
        end

The Facebook messages API is in beta, this helper method is supposed to fail anytime soon

[Source]

# File lib/facebooker/models/message_thread.rb, line 28
        def photo?
          self.href =~ /\Ahttp:\/\/www\.facebook\.com\/photo\.php.*/
        end

The Facebook messages API is in beta, this helper method is supposed to fail anytime soon

[Source]

# File lib/facebooker/models/message_thread.rb, line 23
        def video?
          self.href =~ /\Ahttp:\/\/www\.facebook\.com\/video\/video\.php.*/
        end

[Validate]