#[cfg(feature = "mysql")]
pub mod mysql;
#[cfg(feature = "postgres")]
pub mod postgres;
#[cfg(feature = "sqlite")]
pub mod sqlite;

use serde_json::{ Value as JsonValue};

#[cfg(feature = "mysql")]
use sqlx::mysql::MySqlRow;
#[cfg(feature = "postgres")]
use sqlx::postgres::PgRow;
#[cfg(feature = "sqlite")]
use sqlx::sqlite::SqliteRow;

#[cfg(any(feature = "postgres", feature = "mysql", feature = "sqlite"))]
use crate::common::ColumnBaseInfo;

#[cfg(feature = "mysql")]
pub struct MySqlRowParse {
    pub methods: Vec<fn(&MySqlRow, usize) -> JsonValue>,
    pub columns: Vec<ColumnBaseInfo>,
}
#[cfg(feature = "postgres")]
pub struct PgRowParse {
    pub methods: Vec<fn(&PgRow, usize) -> JsonValue>,
    pub columns: Vec<ColumnBaseInfo>,
}
#[cfg(feature = "sqlite")]
pub struct SqliteRowParse {
    pub methods: Vec<fn(&SqliteRow, usize) -> JsonValue>,
    pub columns: Vec<ColumnBaseInfo>,
}
