Sha256: 2114954d5b80fd2d19716ddb3cfde22cf31d203818fe1bfbe089677ace1645c7

Contents?: true

Size: 255 Bytes

Versions: 6

Compression:

Stored size: 255 Bytes

Contents

module NCMB
  class Increment
    include NCMB
    
    def initialize(amount = 1)
      @amount = amount
    end
    
    def to_json(a)
      "{\"__op\": \"Increment\", \"amount\": #{@amount}}"
    end
    
    def amount
      @amount
    end
  end
end

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
ncmb-ruby-client-0.1.3 lib/ncmb/increment.rb
ncmb-ruby-client-0.1.2 lib/ncmb/increment.rb
ncmb-ruby-client-0.1.1 lib/ncmb/increment.rb
ncmb-ruby-client-0.1.0 lib/ncmb/increment.rb
ncmb-ruby-client-0.0.9 lib/ncmb/increment.rb
ncmb-ruby-client-0.0.8 lib/ncmb/increment.rb