diff options
Diffstat (limited to 'connectivity/source/drivers/file/FNumericFunctions.cxx')
-rw-r--r-- | connectivity/source/drivers/file/FNumericFunctions.cxx | 38 |
1 files changed, 19 insertions, 19 deletions
diff --git a/connectivity/source/drivers/file/FNumericFunctions.cxx b/connectivity/source/drivers/file/FNumericFunctions.cxx index 031905a01999..7800eb6b682f 100644 --- a/connectivity/source/drivers/file/FNumericFunctions.cxx +++ b/connectivity/source/drivers/file/FNumericFunctions.cxx @@ -2,7 +2,7 @@ /************************************************************************* * * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * + * * Copyright 2000, 2010 Oracle and/or its affiliates. * * OpenOffice.org - a multi-platform office productivity suite @@ -40,7 +40,7 @@ ORowSetValue OOp_Abs::operate(const ORowSetValue& lhs) const { if ( lhs.isNull() ) return lhs; - + double nVal(lhs); if ( nVal < 0 ) nVal *= -1.0; @@ -51,14 +51,14 @@ ORowSetValue OOp_Sign::operate(const ORowSetValue& lhs) const { if ( lhs.isNull() ) return lhs; - + sal_Int32 nRet = 0; double nVal(lhs); if ( nVal < 0 ) nRet = -1; else if ( nVal > 0 ) nRet = 1; - + return nRet; } //------------------------------------------------------------------ @@ -74,7 +74,7 @@ ORowSetValue OOp_Floor::operate(const ORowSetValue& lhs) const { if ( lhs.isNull() ) return lhs; - + return floor((double)lhs); } // ----------------------------------------------------------------------------- @@ -82,7 +82,7 @@ ORowSetValue OOp_Ceiling::operate(const ORowSetValue& lhs) const { if ( lhs.isNull() ) return lhs; - + double nVal(lhs); return ceil(nVal); } @@ -105,7 +105,7 @@ ORowSetValue OOp_Exp::operate(const ORowSetValue& lhs) const { if ( lhs.isNull() ) return lhs; - + double nVal(lhs); return exp(nVal); } @@ -114,7 +114,7 @@ ORowSetValue OOp_Ln::operate(const ORowSetValue& lhs) const { if ( lhs.isNull() || static_cast<double>(lhs) < 0.0 ) return lhs; - + double nVal(lhs); nVal = log(nVal); if ( rtl::math::isNan(nVal) ) @@ -128,7 +128,7 @@ ORowSetValue OOp_Log::operate(const ::std::vector<ORowSetValue>& lhs) const return ORowSetValue(); size_t nSize = lhs.size(); double nVal = log( (double)lhs[nSize-1] ); - + if ( nSize == 2 && !lhs[0].isNull() ) nVal /= log((double)lhs[0]); @@ -142,7 +142,7 @@ ORowSetValue OOp_Log10::operate(const ORowSetValue& lhs) const { if ( lhs.isNull() || static_cast<double>(lhs) < 0.0 ) return lhs; - + double nVal = log((double)lhs); if ( rtl::math::isNan(nVal) ) return ORowSetValue(); @@ -162,7 +162,7 @@ ORowSetValue OOp_Sqrt::operate(const ORowSetValue& lhs) const { if ( lhs.isNull() ) return lhs; - + double nVal = sqrt((double)lhs); if ( rtl::math::isNan(nVal) ) return ORowSetValue(); @@ -178,7 +178,7 @@ ORowSetValue OOp_Cos::operate(const ORowSetValue& lhs) const { if ( lhs.isNull() ) return lhs; - + return cos((double)lhs); } // ----------------------------------------------------------------------------- @@ -186,7 +186,7 @@ ORowSetValue OOp_Sin::operate(const ORowSetValue& lhs) const { if ( lhs.isNull() ) return lhs; - + return sin((double)lhs); } // ----------------------------------------------------------------------------- @@ -194,7 +194,7 @@ ORowSetValue OOp_Tan::operate(const ORowSetValue& lhs) const { if ( lhs.isNull() ) return lhs; - + return tan((double)lhs); } // ----------------------------------------------------------------------------- @@ -202,7 +202,7 @@ ORowSetValue OOp_ACos::operate(const ORowSetValue& lhs) const { if ( lhs.isNull() ) return lhs; - + return acos((double)lhs); } // ----------------------------------------------------------------------------- @@ -210,7 +210,7 @@ ORowSetValue OOp_ASin::operate(const ORowSetValue& lhs) const { if ( lhs.isNull() ) return lhs; - + return asin((double)lhs); } // ----------------------------------------------------------------------------- @@ -218,7 +218,7 @@ ORowSetValue OOp_ATan::operate(const ORowSetValue& lhs) const { if ( lhs.isNull() ) return lhs; - + return atan((double)lhs); } // ----------------------------------------------------------------------------- @@ -234,7 +234,7 @@ ORowSetValue OOp_Degrees::operate(const ORowSetValue& lhs) const { if ( lhs.isNull() ) return lhs; - + double nLhs = lhs; return nLhs*180*(1.0/3.141592653589793116); } @@ -243,7 +243,7 @@ ORowSetValue OOp_Radians::operate(const ORowSetValue& lhs) const { if ( lhs.isNull() ) return lhs; - + double nLhs = lhs; return nLhs*3.141592653589793116*(1.0/180.0); } |