{-# LANGUAGE EmptyDataDecls, ExistentialQuantification, FlexibleContexts, FlexibleInstances, ForeignFunctionInterface, MultiParamTypeClasses, ScopedTypeVariables, TypeFamilies, TypeSynonymInstances #-} module HROOT.Hist.TGraphBentErrors.Interface where import Data.Word import Data.Int import Foreign.C import Foreign.Ptr import FFICXX.Runtime.Cast import HROOT.Hist.TGraphBentErrors.RawType import HROOT.Hist.TGraph.Interface class (ITGraph a) => ITGraphBentErrors a where upcastTGraphBentErrors :: forall a . (FPtr a, ITGraphBentErrors a) => a -> TGraphBentErrors upcastTGraphBentErrors :: forall a. (FPtr a, ITGraphBentErrors a) => a -> TGraphBentErrors upcastTGraphBentErrors a h = let fh :: Ptr (Raw a) fh = a -> Ptr (Raw a) forall a. FPtr a => a -> Ptr (Raw a) get_fptr a h Ptr RawTGraphBentErrors fh2 :: Ptr RawTGraphBentErrors = Ptr (Raw a) -> Ptr RawTGraphBentErrors forall a b. Ptr a -> Ptr b castPtr Ptr (Raw a) fh in Ptr (Raw TGraphBentErrors) -> TGraphBentErrors forall a. FPtr a => Ptr (Raw a) -> a cast_fptr_to_obj Ptr (Raw TGraphBentErrors) Ptr RawTGraphBentErrors fh2 downcastTGraphBentErrors :: forall a . (FPtr a, ITGraphBentErrors a) => TGraphBentErrors -> a downcastTGraphBentErrors :: forall a. (FPtr a, ITGraphBentErrors a) => TGraphBentErrors -> a downcastTGraphBentErrors TGraphBentErrors h = let fh :: Ptr (Raw TGraphBentErrors) fh = TGraphBentErrors -> Ptr (Raw TGraphBentErrors) forall a. FPtr a => a -> Ptr (Raw a) get_fptr TGraphBentErrors h fh2 :: Ptr (Raw a) fh2 = Ptr RawTGraphBentErrors -> Ptr (Raw a) forall a b. Ptr a -> Ptr b castPtr Ptr (Raw TGraphBentErrors) Ptr RawTGraphBentErrors fh in Ptr (Raw a) -> a forall a. FPtr a => Ptr (Raw a) -> a cast_fptr_to_obj Ptr (Raw a) fh2