Class: IMAPProcessor::Connection

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

Overview

A Connection Struct that has imap and capability accessors

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#capabilityObject

Returns the value of attribute capability

Returns:

  • (Object)

    the current value of capability



34
35
36
# File 'lib/imap_processor.rb', line 34

def capability
  @capability
end

#imapObject

Returns the value of attribute imap

Returns:

  • (Object)

    the current value of imap



34
35
36
# File 'lib/imap_processor.rb', line 34

def imap
  @imap
end

Instance Method Details

#idle?Boolean

Does this connection support the IDLE extension?

Returns:

  • (Boolean)


39
40
41
# File 'lib/imap_processor.rb', line 39

def idle?
  capability.include? 'IDLE'
end

#uidplus?Boolean

Does this connection support the UIDPLUS extension?

Returns:

  • (Boolean)


46
47
48
# File 'lib/imap_processor.rb', line 46

def uidplus?
  capability.include? 'UIDPLUS'
end