Class: Weechat::IRC::Message::CTCP

Inherits:
Weechat::IRC::Message show all
Defined in:
lib/weechat/irc/message.rb

Instance Attribute Summary (collapse)

Attributes inherited from Weechat::IRC::Message

#command, #params, #prefix

Instance Method Summary (collapse)

Methods inherited from Weechat::IRC::Message

parse_message, #to_ctcp

Constructor Details

- (CTCP) initialize(*args)



69
70
71
72
73
74
75
# File 'lib/weechat/irc/message.rb', line 69

def initialize(*args)
  super
  @receiver = @params.first
  parts = @params.last[1..-2].split(" ")
  @ctcp_command = parts.first
  @ctcp_param = parts[1..-1].join(" ")
end

Instance Attribute Details

- (Object) ctcp_command (readonly)

Returns the value of attribute ctcp_command



66
67
68
# File 'lib/weechat/irc/message.rb', line 66

def ctcp_command
  @ctcp_command
end

- (Object) ctcp_param (readonly)

Returns the value of attribute ctcp_param



67
68
69
# File 'lib/weechat/irc/message.rb', line 67

def ctcp_param
  @ctcp_param
end

- (Object) receiver (readonly)

Returns the value of attribute receiver



65
66
67
# File 'lib/weechat/irc/message.rb', line 65

def receiver
  @receiver
end

Instance Method Details

- (Boolean) ctcp?



77
78
79
# File 'lib/weechat/irc/message.rb', line 77

def ctcp?
  true
end