@@ -379,39 +379,55 @@ class MailboxACLItem < Struct.new(:user, :rights, :mailbox)
379
379
# The access rights the indicated #user has to the #mailbox.
380
380
end
381
381
382
- # Net::IMAP::Namespace represents a single [RFC-2342] namespace.
382
+ # Net::IMAP::Namespace represents a single namespace contained inside a
383
+ # NAMESPACE response.
383
384
#
384
- # Namespace = nil / "(" 1*( "(" string SP (<"> QUOTED_CHAR <"> /
385
- # nil) *(Namespace_Response_Extension) ")" ) ")"
386
- #
387
- # Namespace_Response_Extension = SP string SP "(" string *(SP string)
388
- # ")"
389
- #
390
- # ==== Fields:
391
- #
392
- # prefix:: Returns the namespace prefix string.
393
- # delim:: Returns nil or the hierarchy delimiter character.
394
- # extensions:: Returns a hash of extension names to extension flag arrays.
385
+ # Returned by Net::IMAP#namespace, contained inside a Namespaces object.
395
386
#
396
387
class Namespace < Struct . new ( :prefix , :delim , :extensions )
388
+ ##
389
+ # method: prefix
390
+ # :call-seq: prefix -> string
391
+ #
392
+ # Returns the namespace prefix string.
393
+
394
+ ##
395
+ # method: delim
396
+ # :call-seq: delim -> single character string or nil
397
+ #
398
+ # Returns a hierarchy delimiter character, if it exists.
399
+
400
+ ##
401
+ # method: extensions
402
+ # :call-seq: extensions -> Hash[String, Array[String]]
403
+ #
404
+ # A hash of parameters mapped to arrays of strings, for extensibility.
405
+ # Extension parameter semantics would be defined by the extension.
397
406
end
398
407
399
- # Net::IMAP::Namespaces represents the response from [RFC-2342] NAMESPACE.
408
+ # Net::IMAP::Namespaces represents a +NAMESPACE+ server response, which
409
+ # contains lists of #personal, #shared, and #other namespaces.
400
410
#
401
- # Namespace_Response = "*" SP "NAMESPACE" SP Namespace SP Namespace SP
402
- # Namespace
403
- #
404
- # ; The first Namespace is the Personal Namespace(s)
405
- # ; The second Namespace is the Other Users' Namespace(s)
406
- # ; The third Namespace is the Shared Namespace(s)
407
- #
408
- # ==== Fields:
409
- #
410
- # personal:: Returns an array of Personal Net::IMAP::Namespace objects.
411
- # other:: Returns an array of Other Users' Net::IMAP::Namespace objects.
412
- # shared:: Returns an array of Shared Net::IMAP::Namespace objects.
411
+ # Net::IMAP#namespace returns a Namespaces object.
413
412
#
414
413
class Namespaces < Struct . new ( :personal , :other , :shared )
414
+ ##
415
+ # method: personal
416
+ # :call-seq: personal -> array of Namespace
417
+ #
418
+ # Returns an array of Personal Namespace objects.
419
+
420
+ ##
421
+ # method: other
422
+ # :call-seq: other -> array of Namespace
423
+ #
424
+ # Returns an array of Other Users' Namespace objects.
425
+
426
+ ##
427
+ # method: shared
428
+ # :call-seq: shared -> array of Namespace
429
+ #
430
+ # Returns an array of Shared Namespace objects.
415
431
end
416
432
417
433
# Net::IMAP::StatusData represents the contents of the STATUS response.
0 commit comments