{-# OPTIONS_GHC -Wall #-} {-# OPTIONS_GHC -fno-warn-unused-imports #-} {-# OPTIONS_GHC -fno-warn-orphans #-} {-# Language ForeignFunctionInterface #-} {-# Language FlexibleInstances #-} {-# Language MultiParamTypeClasses #-} module Casadi.Wrappers.Classes.SundialsIntegrator ( SundialsIntegrator, SundialsIntegratorClass(..), sundialsIntegrator, sundialsIntegrator_checkNode, sundialsIntegrator_setStopTime, ) where import Prelude hiding ( Functor ) import Data.Vector ( Vector ) import Foreign.C.Types import Foreign.Ptr ( Ptr ) import Foreign.ForeignPtr ( newForeignPtr ) import System.IO.Unsafe ( unsafePerformIO ) -- for show instances import Casadi.Wrappers.Classes.PrintableObject import Casadi.Wrappers.CToolsInstances ( ) import Casadi.Wrappers.Data import Casadi.Wrappers.Enums import Casadi.MarshalTypes ( CppVec, StdString' ) -- StdOstream' import Casadi.Marshal ( Marshal(..), withMarshal ) import Casadi.WrapReturn ( WrapReturn(..) ) instance Show SundialsIntegrator where show = unsafePerformIO . printableObject_getDescription -- direct wrapper foreign import ccall unsafe "CasADi__SundialsIntegrator__checkNode" c_CasADi__SundialsIntegrator__checkNode :: Ptr SundialsIntegrator' -> IO CInt casADi__SundialsIntegrator__checkNode :: SundialsIntegrator -> IO Bool casADi__SundialsIntegrator__checkNode x0 = withMarshal x0 $ \x0' -> c_CasADi__SundialsIntegrator__checkNode x0' >>= wrapReturn -- classy wrapper {-| >Check if the node is pointing to the right type of object. -} sundialsIntegrator_checkNode :: SundialsIntegratorClass a => a -> IO Bool sundialsIntegrator_checkNode x = casADi__SundialsIntegrator__checkNode (castSundialsIntegrator x) -- direct wrapper foreign import ccall unsafe "CasADi__SundialsIntegrator__setStopTime" c_CasADi__SundialsIntegrator__setStopTime :: Ptr SundialsIntegrator' -> CDouble -> IO () casADi__SundialsIntegrator__setStopTime :: SundialsIntegrator -> Double -> IO () casADi__SundialsIntegrator__setStopTime x0 x1 = withMarshal x0 $ \x0' -> withMarshal x1 $ \x1' -> c_CasADi__SundialsIntegrator__setStopTime x0' x1' >>= wrapReturn -- classy wrapper {-| >Set a stop time for the forward integration. -} sundialsIntegrator_setStopTime :: SundialsIntegratorClass a => a -> Double -> IO () sundialsIntegrator_setStopTime x = casADi__SundialsIntegrator__setStopTime (castSundialsIntegrator x) -- direct wrapper foreign import ccall unsafe "CasADi__SundialsIntegrator__SundialsIntegrator" c_CasADi__SundialsIntegrator__SundialsIntegrator :: IO (Ptr SundialsIntegrator') casADi__SundialsIntegrator__SundialsIntegrator :: IO SundialsIntegrator casADi__SundialsIntegrator__SundialsIntegrator = c_CasADi__SundialsIntegrator__SundialsIntegrator >>= wrapReturn -- classy wrapper {-| >Default constructor. -} sundialsIntegrator :: IO SundialsIntegrator sundialsIntegrator = casADi__SundialsIntegrator__SundialsIntegrator