Class: Dor::Workflow::Response::Process

Inherits:
Object
  • Object
show all
Defined in:
lib/dor/models/response/process.rb

Overview

Represents the status of an object doing a workflow process

Instance Method Summary collapse

Constructor Details

#initialize(parent:, **attributes) ⇒ Process

Returns a new instance of Process.



10
11
12
13
# File 'lib/dor/models/response/process.rb', line 10

def initialize(parent:, **attributes)
  @parent = parent
  @attributes = attributes
end

Instance Method Details

#attemptsObject



31
32
33
# File 'lib/dor/models/response/process.rb', line 31

def attempts
  @attributes[:attempts].presence
end

#datetimeObject



23
24
25
# File 'lib/dor/models/response/process.rb', line 23

def datetime
  @attributes[:datetime].presence
end

#elapsedObject



27
28
29
# File 'lib/dor/models/response/process.rb', line 27

def elapsed
  @attributes[:elapsed].presence
end

#error_messageObject



43
44
45
# File 'lib/dor/models/response/process.rb', line 43

def error_message
  @attributes[:errorMessage].presence
end

#lifecycleObject



35
36
37
# File 'lib/dor/models/response/process.rb', line 35

def lifecycle
  @attributes[:lifecycle].presence
end

#nameObject



15
16
17
# File 'lib/dor/models/response/process.rb', line 15

def name
  @attributes[:name].presence
end

#noteObject



39
40
41
# File 'lib/dor/models/response/process.rb', line 39

def note
  @attributes[:note].presence
end

#statusObject



19
20
21
# File 'lib/dor/models/response/process.rb', line 19

def status
  @attributes[:status].presence
end