Class: Weechat::Info

Inherits:
Hook
  • Object
show all
Defined in:
lib/weechat/info.rb

Instance Attribute Summary (collapse)

Attributes inherited from Hook

#callback, #id

Attributes included from Pointer

#ptr

Instance Method Summary (collapse)

Methods inherited from Hook

all, #call, compute_free_id, find_by_id, #hooked?, inherited, init, register, unhook, #unhook, unhook_all, unregister

Methods included from Pointer

#==, #hash, included, #inspect, #to_s

Constructor Details

- (Info) initialize(name, description, &callback)

Returns a new instance of Info



5
6
7
8
9
10
# File 'lib/weechat/info.rb', line 5

def initialize(name, description, &callback)
  super
  @name, @description = name, description
  @callback         = callback
  @ptr              = Weechat.hook_info(name, description, "info_callback", id.to_s)
end

Instance Attribute Details

- (Object) description (readonly)

Returns the value of attribute description



4
5
6
# File 'lib/weechat/info.rb', line 4

def description
  @description
end

- (Object) name (readonly)

Returns the value of attribute name



3
4
5
# File 'lib/weechat/info.rb', line 3

def name
  @name
end