useDynLib(HDF5Array)

import(methods)
importFrom(utils, read.table)
importFrom(tools, file_path_as_absolute)

import(BiocGenerics)
import(S4Vectors)
import(IRanges)
import(DelayedArray)
import(rhdf5)


### - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
### Export S4 classes
###

exportClasses(
    HDF5ArraySeed,
    HDF5Array, HDF5Matrix,
    HDF5RealizationSink,
    TENxMatrixSeed,
    TENxMatrix,
    TENxRealizationSink
)


### - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
### Export S4 methods for generics not defined in HDF5Array
###

exportMethods(
    ## Methods for generics defined in the base package:
    dim, dimnames,

    ## Methods for generics defined in the methods package:
    coerce,

    ## Methods for generics defined in the BiocGenerics package:
    path, "path<-",

    ## Methods for generics defined in the DelayedArray package:
    extract_array, type,
    sparsity, is_sparse, extract_sparse_array,
    read_sparse_block, write_sparse_block, write_block,
    matrixClass, DelayedArray, chunkdim,
    close
)


### - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
### Export non-generic functions
###

export(
    get_h5mread_returned_type, h5mread,
    HDF5ArraySeed,
    HDF5Array,
    setHDF5DumpDir, getHDF5DumpDir,
    setHDF5DumpFile, getHDF5DumpFile, lsHDF5DumpFile,
    setHDF5DumpName, getHDF5DumpName,
    setHDF5DumpChunkLength, getHDF5DumpChunkLength,
    setHDF5DumpChunkShape, getHDF5DumpChunkShape,
    getHDF5DumpChunkDim,
    setHDF5DumpCompressionLevel, getHDF5DumpCompressionLevel,
    appendDatasetCreationToHDF5DumpLog, showHDF5DumpLog,
    HDF5RealizationSink, writeHDF5Array,
    saveHDF5SummarizedExperiment, loadHDF5SummarizedExperiment,
    quickResaveHDF5SummarizedExperiment,
    TENxMatrixSeed,
    TENxMatrix,
    TENxRealizationSink, writeTENxMatrix
)


### - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
### Export S4 generics defined in HDF5Array + export corresponding methods
###

export(
    ## TENxMatrix-class.R:
    extractNonzeroDataByCol
)

### Exactly the same list as above.
exportMethods(
    extractNonzeroDataByCol
)

