module Bindings.Libgit2.Remote where
import Foreign.Ptr (Ptr,FunPtr,plusPtr)
import Foreign.Ptr (wordPtrToPtr,castPtrToFunPtr)
import Foreign.Storable
import Foreign.C.Types
import Foreign.C.String (CString,CStringLen,CWString,CWStringLen)
import Foreign.Marshal.Alloc (alloca)
import Foreign.Marshal.Array (peekArray,pokeArray)
import Data.Int
import Data.Word
import Bindings.Libgit2.Common
import Bindings.Libgit2.Repository
import Bindings.Libgit2.Refspec
import Bindings.Libgit2.Net
import Bindings.Libgit2.Indexer
import Bindings.Libgit2.Oid
import Bindings.Libgit2.Types
foreign import ccall "git_remote_new" c'git_remote_new
:: Ptr (Ptr C'git_remote) -> Ptr C'git_repository -> CString -> CString -> CString -> IO (CInt)
foreign import ccall "&git_remote_new" p'git_remote_new
:: FunPtr (Ptr (Ptr C'git_remote) -> Ptr C'git_repository -> CString -> CString -> CString -> IO (CInt))
foreign import ccall "git_remote_load" c'git_remote_load
:: Ptr (Ptr C'git_remote) -> Ptr C'git_repository -> CString -> IO (CInt)
foreign import ccall "&git_remote_load" p'git_remote_load
:: FunPtr (Ptr (Ptr C'git_remote) -> Ptr C'git_repository -> CString -> IO (CInt))
foreign import ccall "git_remote_save" c'git_remote_save
:: Ptr C'git_remote -> IO (CInt)
foreign import ccall "&git_remote_save" p'git_remote_save
:: FunPtr (Ptr C'git_remote -> IO (CInt))
foreign import ccall "git_remote_name" c'git_remote_name
:: Ptr C'git_remote -> IO (CString)
foreign import ccall "&git_remote_name" p'git_remote_name
:: FunPtr (Ptr C'git_remote -> IO (CString))
foreign import ccall "git_remote_url" c'git_remote_url
:: Ptr C'git_remote -> IO (CString)
foreign import ccall "&git_remote_url" p'git_remote_url
:: FunPtr (Ptr C'git_remote -> IO (CString))
foreign import ccall "git_remote_set_fetchspec" c'git_remote_set_fetchspec
:: Ptr C'git_remote -> CString -> IO (CInt)
foreign import ccall "&git_remote_set_fetchspec" p'git_remote_set_fetchspec
:: FunPtr (Ptr C'git_remote -> CString -> IO (CInt))
foreign import ccall "git_remote_fetchspec" c'git_remote_fetchspec
:: Ptr C'git_remote -> IO (Ptr C'git_refspec)
foreign import ccall "&git_remote_fetchspec" p'git_remote_fetchspec
:: FunPtr (Ptr C'git_remote -> IO (Ptr C'git_refspec))
foreign import ccall "git_remote_set_pushspec" c'git_remote_set_pushspec
:: Ptr C'git_remote -> CString -> IO (CInt)
foreign import ccall "&git_remote_set_pushspec" p'git_remote_set_pushspec
:: FunPtr (Ptr C'git_remote -> CString -> IO (CInt))
foreign import ccall "git_remote_pushspec" c'git_remote_pushspec
:: Ptr C'git_remote -> IO (Ptr C'git_refspec)
foreign import ccall "&git_remote_pushspec" p'git_remote_pushspec
:: FunPtr (Ptr C'git_remote -> IO (Ptr C'git_refspec))
foreign import ccall "git_remote_connect" c'git_remote_connect
:: Ptr C'git_remote -> CInt -> IO (CInt)
foreign import ccall "&git_remote_connect" p'git_remote_connect
:: FunPtr (Ptr C'git_remote -> CInt -> IO (CInt))
foreign import ccall "git_remote_ls" c'git_remote_ls
:: Ptr C'git_remote -> CInt -> Ptr () -> IO (CInt)
foreign import ccall "&git_remote_ls" p'git_remote_ls
:: FunPtr (Ptr C'git_remote -> CInt -> Ptr () -> IO (CInt))
foreign import ccall "git_remote_download" c'git_remote_download
:: Ptr C'git_remote -> Ptr CLong -> Ptr C'git_indexer_stats -> IO (CInt)
foreign import ccall "&git_remote_download" p'git_remote_download
:: FunPtr (Ptr C'git_remote -> Ptr CLong -> Ptr C'git_indexer_stats -> IO (CInt))
foreign import ccall "git_remote_connected" c'git_remote_connected
:: Ptr C'git_remote -> IO (CInt)
foreign import ccall "&git_remote_connected" p'git_remote_connected
:: FunPtr (Ptr C'git_remote -> IO (CInt))
foreign import ccall "git_remote_disconnect" c'git_remote_disconnect
:: Ptr C'git_remote -> IO ()
foreign import ccall "&git_remote_disconnect" p'git_remote_disconnect
:: FunPtr (Ptr C'git_remote -> IO ())
foreign import ccall "git_remote_free" c'git_remote_free
:: Ptr C'git_remote -> IO ()
foreign import ccall "&git_remote_free" p'git_remote_free
:: FunPtr (Ptr C'git_remote -> IO ())
type C'git_remote_update_tips_callback = FunPtr (CString -> Ptr C'git_oid -> Ptr C'git_oid -> IO CInt)
foreign import ccall "wrapper" mk'git_remote_update_tips_callback
:: (CString -> Ptr C'git_oid -> Ptr C'git_oid -> IO CInt) -> IO C'git_remote_update_tips_callback
foreign import ccall "dynamic" mK'git_remote_update_tips_callback
:: C'git_remote_update_tips_callback -> (CString -> Ptr C'git_oid -> Ptr C'git_oid -> IO CInt)
foreign import ccall "git_remote_update_tips" c'git_remote_update_tips
:: Ptr C'git_remote -> C'git_remote_update_tips_callback -> IO (CInt)
foreign import ccall "&git_remote_update_tips" p'git_remote_update_tips
:: FunPtr (Ptr C'git_remote -> C'git_remote_update_tips_callback -> IO (CInt))
foreign import ccall "git_remote_valid_url" c'git_remote_valid_url
:: CString -> IO (CInt)
foreign import ccall "&git_remote_valid_url" p'git_remote_valid_url
:: FunPtr (CString -> IO (CInt))
foreign import ccall "git_remote_supported_url" c'git_remote_supported_url
:: CString -> IO (CInt)
foreign import ccall "&git_remote_supported_url" p'git_remote_supported_url
:: FunPtr (CString -> IO (CInt))
foreign import ccall "git_remote_list" c'git_remote_list
:: Ptr C'git_strarray -> Ptr C'git_repository -> IO (CInt)
foreign import ccall "&git_remote_list" p'git_remote_list
:: FunPtr (Ptr C'git_strarray -> Ptr C'git_repository -> IO (CInt))
foreign import ccall "git_remote_add" c'git_remote_add
:: Ptr (Ptr C'git_remote) -> Ptr C'git_repository -> CString -> CString -> IO (CInt)
foreign import ccall "&git_remote_add" p'git_remote_add
:: FunPtr (Ptr (Ptr C'git_remote) -> Ptr C'git_repository -> CString -> CString -> IO (CInt))