Class: Weechat::PrintedLine

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

Overview

Details about a single line that has been printed in a buffer. Used by the Hooks::Print hook

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(buffer, date, tags, displayed, highlight, prefix, message) ⇒ PrintedLine

Returns a new instance of PrintedLine



21
22
23
24
# File 'lib/weechat.rb', line 21

def initialize(buffer, date, tags, displayed, highlight, prefix, message)
  @buffer, @date, @tags, @displayed, @highlight = buffer, date, tags, displayed, highlight
  @prefix, @message = prefix, message
end

Instance Attribute Details

#bufferBuffer (readonly)

Returns The buffer the line was printed on

Returns:

  • (Buffer)

    The buffer the line was printed on



27
28
29
# File 'lib/weechat.rb', line 27

def buffer
  @buffer
end

#dateTime (readonly)

Returns The date the line was printed

Returns:

  • (Time)

    The date the line was printed



29
30
31
# File 'lib/weechat.rb', line 29

def date
  @date
end

#displayedBoolean (readonly)

Returns True if line was displayed, false if it was filtered

Returns:

  • (Boolean)

    True if line was displayed, false if it was filtered



33
34
35
# File 'lib/weechat.rb', line 33

def displayed
  @displayed
end

#highlightBoolean (readonly)

Returns Whether the line was highlighted

Returns:

  • (Boolean)

    Whether the line was highlighted



35
36
37
# File 'lib/weechat.rb', line 35

def highlight
  @highlight
end

#messageString (readonly)

Returns The message text

Returns:

  • (String)

    The message text



41
42
43
# File 'lib/weechat.rb', line 41

def message
  @message
end

#prefixString (readonly)

Returns The prefix of the message TODO give example

Returns:

  • (String)

    The prefix of the message TODO give example



38
39
40
# File 'lib/weechat.rb', line 38

def prefix
  @prefix
end

#tagsArray<String> (readonly)

Returns The tags the line has TODO what is this?

Returns:

  • (Array<String>)

    The tags the line has TODO what is this?



31
32
33
# File 'lib/weechat.rb', line 31

def tags
  @tags
end