#  Calling the dynamic library
useDynLib(csaw, .registration=TRUE, .fixes="cxx_")

#  All functions exported, arranged by sequence of usage.
export(csawUsersGuide,
	readParam, 
	correlateReads, maximizeCcf, profileSites, wwhm,
	getPESizes, 
	regionCounts, windowCounts, strandedCounts,
	getWidths, scaledAverage, findMaxima, filterWindows, scaleControlFilter,
    mergeWindows, combineTests, getBestTest, empiricalFDR, mixedClusters,
    clusterFDR, controlClusterFDR, clusterWindows,
	consolidateSizes, upweightSummit, consolidateClusters,
	combineOverlaps, getBestOverlaps, summitOverlaps, empiricalOverlaps, mixedOverlaps,
	detailRanges,
	checkBimodality,
	extractReads)

#  Importing required packages
import(GenomicRanges, SummarizedExperiment, Rsamtools,
	S4Vectors, IRanges, GenomeInfoDb,
    BiocParallel,
	edgeR, 
	methods, Rhtslib)

importFrom("GenomicFeatures", exonsBy)
importFrom("AnnotationDbi", select)
importFrom("limma", loessFit)
importFrom("stats", p.adjust, weighted.mean)
importFrom("Rcpp", sourceCpp)

#  Exporting classes and methods
exportClasses(
	readParam
)

exportMethods(
	show, "$", reform, normOffsets, asDGEList
)

