Sha256: 260895436a6bc8c3264167d91ce1670ec6fb5e40b89c4de9ba1ac706d0c52e51

Contents?: true

Size: 456 Bytes

Versions: 29

Compression:

Stored size: 456 Bytes

Contents

# Author::    Eric Crane  (mailto:eric.crane@mac.com)
# Copyright:: Copyright (c) 2019 Eric Crane.  All rights reserved.
#
# Multiplication operator.
#

module Gloo
  module Expr
    class OpMult < Gloo::Core::Op

      #
      # Perform the operation and return the result.
      #
      def perform( left, right )
        return left * right.to_i if left.is_a? Integer

        return left * right.to_f if left.is_a? Numeric
      end

    end
  end
end

Version data entries

29 entries across 29 versions & 1 rubygems

Version Path
gloo-3.5.0 lib/gloo/expr/op_mult.rb
gloo-3.4.1 lib/gloo/expr/op_mult.rb
gloo-3.4.0 lib/gloo/expr/op_mult.rb
gloo-3.3.0 lib/gloo/expr/op_mult.rb
gloo-3.2.0 lib/gloo/expr/op_mult.rb
gloo-3.1.1 lib/gloo/expr/op_mult.rb
gloo-3.1.0 lib/gloo/expr/op_mult.rb
gloo-3.0.1 lib/gloo/expr/op_mult.rb
gloo-3.0.0 lib/gloo/expr/op_mult.rb
gloo-2.5.0 lib/gloo/expr/op_mult.rb
gloo-2.4.3 lib/gloo/expr/op_mult.rb
gloo-2.4.2 lib/gloo/expr/op_mult.rb
gloo-2.4.1 lib/gloo/expr/op_mult.rb
gloo-2.4.0 lib/gloo/expr/op_mult.rb
gloo-2.3.1 lib/gloo/expr/op_mult.rb
gloo-2.2.0 lib/gloo/expr/op_mult.rb
gloo-2.1.0 lib/gloo/expr/op_mult.rb
gloo-2.0.2 lib/gloo/expr/op_mult.rb
gloo-2.0.1 lib/gloo/expr/op_mult.rb
gloo-2.0.0 lib/gloo/expr/op_mult.rb