{-# LANGUAGE EmptyDataDecls, ExistentialQuantification, FlexibleContexts, FlexibleInstances, ForeignFunctionInterface, MultiParamTypeClasses, ScopedTypeVariables, TypeFamilies, TypeSynonymInstances #-} module HROOT.Graf.TGaxis.Interface where import Data.Word import Data.Int import Foreign.C import Foreign.Ptr import FFICXX.Runtime.Cast import HROOT.Graf.TGaxis.RawType import HROOT.Graf.TLine.Interface import HROOT.Core.TAttText.Interface class (ITLine a, ITAttText a) => ITGaxis a where upcastTGaxis :: forall a . (FPtr a, ITGaxis a) => a -> TGaxis upcastTGaxis :: forall a. (FPtr a, ITGaxis a) => a -> TGaxis upcastTGaxis 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 RawTGaxis fh2 :: Ptr RawTGaxis = Ptr (Raw a) -> Ptr RawTGaxis forall a b. Ptr a -> Ptr b castPtr Ptr (Raw a) fh in Ptr (Raw TGaxis) -> TGaxis forall a. FPtr a => Ptr (Raw a) -> a cast_fptr_to_obj Ptr (Raw TGaxis) Ptr RawTGaxis fh2 downcastTGaxis :: forall a . (FPtr a, ITGaxis a) => TGaxis -> a downcastTGaxis :: forall a. (FPtr a, ITGaxis a) => TGaxis -> a downcastTGaxis TGaxis h = let fh :: Ptr (Raw TGaxis) fh = TGaxis -> Ptr (Raw TGaxis) forall a. FPtr a => a -> Ptr (Raw a) get_fptr TGaxis h fh2 :: Ptr (Raw a) fh2 = Ptr RawTGaxis -> Ptr (Raw a) forall a b. Ptr a -> Ptr b castPtr Ptr (Raw TGaxis) Ptr RawTGaxis fh in Ptr (Raw a) -> a forall a. FPtr a => Ptr (Raw a) -> a cast_fptr_to_obj Ptr (Raw a) fh2