Class: Net::NNTPBodyResponse

Inherits:
NNTPLongResponse show all
Includes:
NNTPBodyParser, NNTPStatResponseParser
Defined in:
lib/net/nntp/response/responses.rb

Constant Summary

Constants included from NNTPStatResponseParser

Net::NNTPStatResponseParser::PARSE_RE

Instance Attribute Summary collapse

Attributes included from NNTPStatResponseParser

#article_num, #message_id

Attributes inherited from NNTPLongResponse

#raw_data

Instance Method Summary collapse

Methods included from NNTPBodyParser

#parse_body

Methods included from NNTPStatResponseParser

#parse

Instance Attribute Details

#bodyString (readonly)

Returns the selected body

Returns:

  • (String)

    the selected body


62
63
64
# File 'lib/net/nntp/response/responses.rb', line 62

def body
  @body
end

Instance Method Details

#handle_long_response(data) ⇒ Object


68
69
70
71
# File 'lib/net/nntp/response/responses.rb', line 68

def handle_long_response(data)
    super(data)
    @body = parse_body(data)
end

#has_long_response?Boolean

Returns:

  • (Boolean)

64
65
66
# File 'lib/net/nntp/response/responses.rb', line 64

def has_long_response?
  @code == 222
end