module SQLite3ExtendFunction::Functions::Tan

SQLite3ExtendFunction::Functions::Tan

Public Class Methods

call(x) click to toggle source

@param [Float, Integer] x @return [Float] @raise [SQLite3::SQLException]

# File lib/sqlite3_extend_function/functions/tan.rb, line 11
def call(x)
  Math.tan(Float(x))
rescue ArgumentError
  raise SQLite3::SQLException, "invalid input syntax for type double precision: #{x}"
end