Class: Operaton::Bpm::Client::Task::SortingDto
- Inherits:
-
Object
- Object
- Operaton::Bpm::Client::Task::SortingDto
- Defined in:
- lib/operaton/bpm/client/task/sorting_dto.rb
Overview
Mirrors org.operaton.bpm.client.task.SortingDto
Instance Attribute Summary collapse
-
#sort_by ⇒ Object
Returns the value of attribute sort_by.
-
#sort_order ⇒ Object
Returns the value of attribute sort_order.
Class Method Summary collapse
Instance Method Summary collapse
Instance Attribute Details
#sort_by ⇒ Object
Returns the value of attribute sort_by.
9 10 11 |
# File 'lib/operaton/bpm/client/task/sorting_dto.rb', line 9 def sort_by @sort_by end |
#sort_order ⇒ Object
Returns the value of attribute sort_order.
9 10 11 |
# File 'lib/operaton/bpm/client/task/sorting_dto.rb', line 9 def sort_order @sort_order end |
Class Method Details
.from_ordering_property(property) ⇒ Object
18 19 20 |
# File 'lib/operaton/bpm/client/task/sorting_dto.rb', line 18 def self.from_ordering_property(property) of(property.field, property.direction) end |
.of(sort_by, sort_order) ⇒ Object
11 12 13 14 15 16 |
# File 'lib/operaton/bpm/client/task/sorting_dto.rb', line 11 def self.of(sort_by, sort_order) dto = new dto.sort_by = sort_by dto.sort_order = sort_order dto end |
Instance Method Details
#as_json ⇒ Object
22 23 24 |
# File 'lib/operaton/bpm/client/task/sorting_dto.rb', line 22 def as_json { "sortBy" => sort_by, "sortOrder" => sort_order } end |