Sha256: f1eb6d638fddb08c397b5c65e1777840aa6440c90da31a143606b5c1982a2d81
Contents?: true
Size: 819 Bytes
Versions: 13
Compression:
Stored size: 819 Bytes
Contents
# frozen_string_literal: true # # Copyright (c) 2019-present, Blue Marble Payroll, LLC # # This source code is licensed under the MIT license found in the # LICENSE file in the root directory of this source tree. # require_relative 'sorters/ascending' require_relative 'sorters/descending' module Dbee class Query # Top-level class that allows for the making of sorters. For example, you can call this as: # - Sorters.make(key_path: 'id', direction: :ascending) # - Sorters.make(key_path: 'id') # - Sorters.make(key_path: 'id', direction: :descending) class Sorters acts_as_hashable_factory type_key 'direction' register '', Ascending # Default if type is blank. register 'ascending', Ascending register 'descending', Descending end end end
Version data entries
13 entries across 13 versions & 1 rubygems