# Load the shared object
useDynLib(HIBAG,
	HIBAG_Init, HIBAG_AlleleStrand, HIBAG_AlleleStrand2, HIBAG_BEDFlag, HIBAG_ConvBED,
    HIBAG_Clear_GPU, HIBAG_Close, HIBAG_Confusion, HIBAG_Distance,
    HIBAG_GetNumClassifiers, HIBAG_GetClassifierList, HIBAG_GetLastClassifierInfo,
    HIBAG_New, HIBAG_NewClassifiers, HIBAG_NewClassifierHaplo,
    HIBAG_SortAlleleStr, HIBAG_Kernel_Version, HIBAG_Kernel_SetTarget,
    HIBAG_Predict_Resp, HIBAG_Predict_Dosage, HIBAG_Predict_Resp_Prob,
    HIBAG_Training, HIBAG_SeqMerge, HIBAG_SeqRmDot,
    HIBAG_bgzip_create,
    HIBAG_SumList, HIBAG_UpdateAddProbW, HIBAG_NormalizeProb
)

# Export function names
exportPattern("^[^\\.|HIBAG]")
export(.onAttach)
export(.onLoad)

# Imports
import(methods)
importFrom(RcppParallel, RcppParallelLibs, defaultNumThreads)
import(stats)
importFrom(graphics, abline, plot, text)
importFrom(utils, read.table, write.table, str, packageVersion)

# Registering S3 methods
S3method(plot, hlaAttrBagClass)
S3method(plot, hlaAttrBagObj)
S3method(predict, hlaAttrBagClass)
S3method(print, hlaAttrBagClass)
S3method(print, hlaAttrBagObj)
S3method(summary, hlaAttrBagClass)
S3method(summary, hlaAttrBagObj)
S3method(summary, hlaAlleleClass)
S3method(print, hlaAlleleClass)
S3method(summary, hlaAASeqClass)
S3method(summary, hlaSNPGenoClass)
S3method(print, hlaSNPGenoClass)
S3method(hlaAssocTest, hlaAlleleClass)
S3method(hlaAssocTest, hlaAASeqClass)
