class Edrive::Handler

event handlers sample

Public Class Methods

hash2json() click to toggle source

hash to json @return [Proc] proc hash to json

# File lib/edrive/handler.rb, line 11
def hash2json
  ->(hash) { Oj.dump(hash, :compat) }
end
json2hash() click to toggle source

json to hash @return [JSON] proc json to hash

# File lib/edrive/handler.rb, line 17
def json2hash
  ->(json) { Oj.load(json) }
end