# Submodules
from microbiorust import gbk as gbk
from microbiorust import embl as embl
from microbiorust import align as align
from microbiorust import seqmetrics as seqmetrics
from microbiorust import blast as blast

# Top-level functions re-exported from submodules
from microbiorust.gbk import (
    parse_gbk as parse_gbk,
    gbk_to_faa as gbk_to_faa,
    gbk_to_fna as gbk_to_fna,
    gbk_to_ffn as gbk_to_ffn,
    gbk_to_faa_count as gbk_to_faa_count,
    gbk_to_gff as gbk_to_gff,
)
from microbiorust.embl import (
    parse_embl as parse_embl,
    embl_to_faa as embl_to_faa,
    embl_to_fna as embl_to_fna,
    embl_to_ffn as embl_to_ffn,
    embl_to_gff as embl_to_gff,
)
# add align, seqmetrics, blast the same way

# Classes
class PyRecord:
    def id(self) -> str: ...
    def sequence(self) -> str: ...
    def locus_tag(self) -> list[str]: ...
    def sequences(self) -> SequenceCollection: ...
    def features(self) -> FeatureCollection: ...
    def __repr__(self) -> str: ...
    def __getitem__(self, tag: str) -> PyFeatureInfo | PySequenceInfo: ...
class PyFeatureInfo:
    locus_tag: str                  # #[pyo3(get)] fields become properties
    gene: str | None
    product: str | None
    start: int | None               # u32 → int
    stop: int | None                # u32 → int
    strand: int | None              # i8 → int
    codon_start: int | None         # u8 → int
    extras: list[str]
    def __repr__(self) -> str: ...
class PySequenceInfo:
    locus_tag: str                  # #[pyo3(get)] fields become properties
    faa: str | None
    ffn: str | None
    extras: list[str]
    def __repr__(self) -> str: ...
class RecordCollection:
    def __new__(cls) -> RecordCollection: ...
    def __len__(self) -> int: ...
    def __contains__(self, id: str) -> bool: ...
    def __repr__(self) -> str: ...
    def __getitem__(self, record_id: str) -> PyRecord: ...
    def __iter__(self) -> LocusTagIterator: ...
    def keys(self) -> list[str]: ...
    def insert(self, record_id: str, record: PyRecord) -> None: ...
    def write_faa(self, filename: str) -> tuple[str, int]: ...  # (filename, count)
    def write_ffn(self, filename: str) -> tuple[str, int]: ...  # (filename, count)
    def write_fna(self, filename: str) -> tuple[str, int]: ...  # (filename, count)
class FeatureCollection: 
    def __len__(self) -> int: ...
    def __contains__(self, tag: str) -> bool: ...
    def __repr__(self) -> str: ...
    def __getitem__(self, tag: str) -> PyFeatureInfo: ...
    def keys(self) -> list[str]: ...
    def __iter__(self) -> LocusTagIterator: ...
class SequenceCollection:
    def __len__(self) -> int: ...
    def __contains__(self, tag: str) -> bool: ...
    def __repr__(self) -> str: ...
    def __getitem__(self, tag: str) -> PySequenceInfo: ...
    def keys(self) -> list[str]: ...
    def __iter__(self) -> LocusTagIterator: ...
class LocusTagIterator: 
    def __iter__(self) -> LocusTagIterator: ...
    def __next__(self) -> str: ...
