Initial commit

This commit is contained in:
Jeehoon Kang
2020-03-17 17:31:16 +09:00
commit b929dc334d
54 changed files with 4368 additions and 0 deletions

18
src/write_base.rs Normal file
View File

@@ -0,0 +1,18 @@
use std::io::{Result, Write};
#[inline]
pub fn write_indent(indent: usize, write: &mut dyn Write) -> Result<()> {
write!(write, "{}", " ".repeat(indent))
}
pub trait WriteLine {
fn write_line(&self, indent: usize, write: &mut dyn Write) -> Result<()>;
}
pub trait WriteString {
fn write_string(&self) -> String;
}
pub trait WriteOp {
fn write_operation(&self) -> String;
}