Class: SDM::WorkflowRole
- Inherits:
-
Object
- Object
- SDM::WorkflowRole
- Defined in:
- lib/models/porcelain.rb
Overview
WorkflowRole links a role to a workflow. The linked roles indicate which roles a user must be a part of to request access to a resource via the workflow.
Instance Attribute Summary collapse
-
#id ⇒ Object
Unique identifier of the WorkflowRole.
-
#role_id ⇒ Object
The role id.
-
#workflow_id ⇒ Object
The workflow id.
Instance Method Summary collapse
-
#initialize(id: nil, role_id: nil, workflow_id: nil) ⇒ WorkflowRole
constructor
A new instance of WorkflowRole.
- #to_json(options = {}) ⇒ Object
Constructor Details
#initialize(id: nil, role_id: nil, workflow_id: nil) ⇒ WorkflowRole
Returns a new instance of WorkflowRole.
11488 11489 11490 11491 11492 11493 11494 11495 11496 |
# File 'lib/models/porcelain.rb', line 11488 def initialize( id: nil, role_id: nil, workflow_id: nil ) @id = id == nil ? "" : id @role_id = role_id == nil ? "" : role_id @workflow_id = workflow_id == nil ? "" : workflow_id end |
Instance Attribute Details
#id ⇒ Object
Unique identifier of the WorkflowRole.
11482 11483 11484 |
# File 'lib/models/porcelain.rb', line 11482 def id @id end |
#role_id ⇒ Object
The role id.
11484 11485 11486 |
# File 'lib/models/porcelain.rb', line 11484 def role_id @role_id end |
#workflow_id ⇒ Object
The workflow id.
11486 11487 11488 |
# File 'lib/models/porcelain.rb', line 11486 def workflow_id @workflow_id end |
Instance Method Details
#to_json(options = {}) ⇒ Object
11498 11499 11500 11501 11502 11503 11504 |
# File 'lib/models/porcelain.rb', line 11498 def to_json( = {}) hash = {} self.instance_variables.each do |var| hash[var.id2name.delete_prefix("@")] = self.instance_variable_get var end hash.to_json end |