Class: BPMN::BoundaryEvent
- Defined in:
- lib/bpmn/event.rb
Instance Attribute Summary collapse
-
#attached_to ⇒ Object
Returns the value of attribute attached_to.
-
#attached_to_ref ⇒ Object
Returns the value of attribute attached_to_ref.
-
#cancel_activity ⇒ Object
Returns the value of attribute cancel_activity.
Attributes inherited from Event
Attributes inherited from Step
#default, #default_ref, #incoming, #outgoing
Attributes inherited from Element
#extension_elements, #id, #name
Instance Method Summary collapse
- #execute(execution) ⇒ Object
-
#initialize(attributes = {}) ⇒ BoundaryEvent
constructor
A new instance of BoundaryEvent.
- #is_catching? ⇒ Boolean
- #signal(execution) ⇒ Object
Methods inherited from Event
#conditional_event_definition, #error_event_definition, #error_event_definitions, #escalation_event_definition, #event_definition_ids, #is_conditional?, #is_error?, #is_escalation?, #is_message?, #is_none?, #is_signal?, #is_terminate?, #is_throwing?, #is_timer?, #message_event_definitions, #signal_event_definitions, #terminate_event_definition, #timer_event_definition
Methods inherited from Step
#converging?, #diverging?, #input_mappings, #leave, #outgoing_flows, #output_mappings
Methods inherited from Element
Constructor Details
#initialize(attributes = {}) ⇒ BoundaryEvent
Returns a new instance of BoundaryEvent.
157 158 159 160 161 162 163 164 165 |
# File 'lib/bpmn/event.rb', line 157 def initialize(attributes = {}) super(attributes.except(:attached_to_ref, :cancel_activity)) @attached_to_ref = attributes[:attached_to_ref] @cancel_activity = true if attributes[:cancel_activity].present? @cancel_activity = attributes[:cancel_activity] == "false" ? false : true end end |
Instance Attribute Details
#attached_to ⇒ Object
Returns the value of attribute attached_to.
155 156 157 |
# File 'lib/bpmn/event.rb', line 155 def attached_to @attached_to end |
#attached_to_ref ⇒ Object
Returns the value of attribute attached_to_ref.
155 156 157 |
# File 'lib/bpmn/event.rb', line 155 def attached_to_ref @attached_to_ref end |
#cancel_activity ⇒ Object
Returns the value of attribute cancel_activity.
155 156 157 |
# File 'lib/bpmn/event.rb', line 155 def cancel_activity @cancel_activity end |
Instance Method Details
#execute(execution) ⇒ Object
171 172 173 174 |
# File 'lib/bpmn/event.rb', line 171 def execute(execution) super execution.wait end |
#is_catching? ⇒ Boolean
167 168 169 |
# File 'lib/bpmn/event.rb', line 167 def is_catching? true end |
#signal(execution) ⇒ Object
176 177 178 179 |
# File 'lib/bpmn/event.rb', line 176 def signal(execution) execution.attached_to.terminate if cancel_activity leave(execution) end |