Class: MsgExtractor::Task

Inherits:
MessageObject show all
Defined in:
lib/msg_extractor/task.rb

Overview

IPM.Task items. Fields come from PSETID_Task named properties.

Constant Summary collapse

PSETID_TASK =
"00062003-0000-0000-c000-000000000046"
LID_START_DATE =
0x8104
LID_DUE_DATE =
0x8105
LID_STATUS =
0x8101
LID_PERCENT_COMPLETE =
0x8102
LID_COMPLETE =
0x811C
LID_OWNER =
0x811F
STATUSES =
{
  0 => :not_started, 1 => :in_progress, 2 => :complete,
  3 => :waiting, 4 => :deferred
}.freeze

Instance Attribute Summary

Attributes inherited from MessageObject

#named, #properties

Instance Method Summary collapse

Methods inherited from MessageObject

#attachments, #bcc, #body, #cc, #date, #headers, #html_body, #initialize, #message_class, #named_value, #recipients, #rtf_body, #save, #sender, #subject, #to

Constructor Details

This class inherits a constructor from MsgExtractor::MessageObject

Instance Method Details

#complete?Boolean

Returns:

  • (Boolean)


22
# File 'lib/msg_extractor/task.rb', line 22

def complete? = named_value(PSETID_TASK, LID_COMPLETE) == true

#due_onObject



19
# File 'lib/msg_extractor/task.rb', line 19

def due_on = named_value(PSETID_TASK, LID_DUE_DATE)

#ownerObject



23
# File 'lib/msg_extractor/task.rb', line 23

def owner = named_value(PSETID_TASK, LID_OWNER)

#percent_completeObject



21
# File 'lib/msg_extractor/task.rb', line 21

def percent_complete = named_value(PSETID_TASK, LID_PERCENT_COMPLETE)

#starts_onObject



18
# File 'lib/msg_extractor/task.rb', line 18

def starts_on = named_value(PSETID_TASK, LID_START_DATE)

#statusObject



20
# File 'lib/msg_extractor/task.rb', line 20

def status = STATUSES[named_value(PSETID_TASK, LID_STATUS)]