U:RDoc::AnyMethod[iI" fetch:EFI"Net::IMAP#fetch;TF: publico:RDoc::Markup::Document: @parts[o:RDoc::Markup::Paragraph; [I"FSends a FETCH command to retrieve data associated with a message ;TI"in the mailbox.;To:RDoc::Markup::BlankLineo; ; [ I"EThe +set+ parameter is a number or a range between two numbers, ;TI"Eor an array of those. The number is a message sequence number, ;TI"Fwhere -1 represents a '*' for use in range notation like 100..-1 ;TI"Cbeing interpreted as '100:*'. Beware that the +exclude_end?+ ;TI"Bproperty of a Range object is ignored, and the contents of a ;TI"Frange are independent of the order of the range endpoints as per ;TI"Bthe protocol specification, so 1...5, 5..1 and 5...1 are all ;TI"equivalent to 1..5.;T@o; ; [I"D+attr+ is a list of attributes to fetch; see the documentation ;TI"=for Net::IMAP::FetchData for a list of valid attributes.;T@o; ; [I"AThe return value is an array of Net::IMAP::FetchData or nil ;TI"A(instead of an empty array) if there is no matching message.;T@o; ; [I"For example:;T@o:RDoc::Markup::Verbatim; [I"p imap.fetch(6..8, "UID") ;TI"@#=> [#98}>, \\ ;TI"@ #99}>, \\ ;TI"> #100}>] ;TI"6p imap.fetch(6, "BODY[HEADER.FIELDS (SUBJECT)]") ;TI"l#=> [#"Subject: test\r\n\r\n"}>] ;TI"Cdata = imap.uid_fetch(98, ["RFC822.SIZE", "INTERNALDATE"])[0] ;TI"p data.seqno ;TI" #=> 6 ;TI" p data.attr["RFC822.SIZE"] ;TI" #=> 611 ;TI"!p data.attr["INTERNALDATE"] ;TI"&#=> "12-Oct-2000 22:40:59 +0900" ;TI"p data.attr["UID"] ;TI" #=> 98;T: @format0: @fileI"lib/net/imap.rb;T:0@omit_headings_from_table_of_contents_below000[I"(set, attr);T@6FI" IMAP;TcRDoc::NormalClass00