import(methods)
import(utils)
importFrom(graphics, plot)

importFrom(igraph, graph.data.frame, get.data.frame, layout.kamada.kawai,
                   plot.igraph, igraph.to.graphNEL)


import(BiocGenerics)
import(S4Vectors)
import(IRanges)
import(GenomeInfoDb)
import(GenomicRanges)
import(GenomicFeatures)
importFrom(Rsamtools, asBam)
import(GenomicAlignments)

importFrom(graph, nodeDataDefaults, nodeData,
                  edgeDataDefaults, edgeNames, edgeData, edgemode)

importFrom(Rgraphviz, agopen, buildEdgeList, buildNodeList, from, to)
importMethodsFrom(Rgraphviz, plot)

exportClasses(GeneModel, SplicingGraphs)


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

exportMethods(
    length,
    names,
    show,
    "[",
    "[[",
    elementNROWS,
    unlist,
    seqnames,
    strand,
    seqinfo, "isCircular<-",
    intronsByTranscript,
    plot
)


### - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
### Export non-generic functions (and non-function symbols)
###

export(
    ## sgraph-methods.R:
    slideshow,

    ## rsgedgesByGene-methods.R:
    rsgedges, sgedges2,
    rsgraph, sgraph2,

    ## bubbles-methods.R:
    ASCODE2DESC,

    ## assignReads.R:
    assignReads,
    removeReads,

    ## toy_data.R:
    toy_genes_gff,
    toy_reads_sam,
    toy_reads_bam,
    toy_overlaps
)


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

export(
    ## SplicingGraphs-class.R:
    SplicingGraphs,

    ## plotTranscripts-methods.R:
    plotTranscripts,

    ## sgedgesByGene-methods.R:
    sgedgesByTranscript,
    sgedgesByGene,

    ## txpath-methods.R:
    txpath,
    txweight, "txweight<-",

    ## sgedges-methods.R:
    sgedges,
    sgnodes,
    outdeg, indeg,

    ## sgraph-methods.R:
    sgraph,

    ## rsgedgesByGene-methods.R:
    uninformativeSSids,
    rsgedgesByTranscript,
    rsgedgesByGene,

    ## bubbles-methods.R:
    bubbles,

    ## countReads-methods.R:
    reportReads,
    countReads
)

### Exactly the same list as above.
exportMethods(
    SplicingGraphs,
    plotTranscripts,
    sgedgesByTranscript,
    sgedgesByGene,
    txpath,
    txweight, "txweight<-",
    sgedges,
    sgnodes,
    outdeg, indeg,
    sgraph,
    uninformativeSSids,
    rsgedgesByTranscript,
    rsgedgesByGene,
    bubbles,
    reportReads,
    countReads
)

