Skip to main content

oak_sql/lsp/formatter/
mod.rs

1#![doc = include_str!("readme.md")]
2use crate::language::SqlLanguage;
3
4/// A formatter for SQL source files.
5pub struct SqlFormatter<'config> {
6    config: &'config SqlLanguage,
7}
8
9impl<'config> SqlFormatter<'config> {
10    /// Creates a new `SqlFormatter` with the given language configuration.
11    pub fn new(config: &'config SqlLanguage) -> Self {
12        Self { config }
13    }
14
15    /// Formats a SQL source tree into a string.
16    pub fn format(&self, _node: &oak_core::tree::RedNode<SqlLanguage>) -> String {
17        // TODO: Implement SQL formatting
18        String::new()
19    }
20}