//! ref: composer/src/Composer/IO/NullIO.php use shirabe_php_shim::PhpMixed; use crate::io::base_io::BaseIO; use crate::io::io_interface::IOInterface; #[derive(Debug)] pub struct NullIO { inner: BaseIO, } impl IOInterface for NullIO { fn is_interactive(&self) -> bool { false } fn is_verbose(&self) -> bool { false } fn is_very_verbose(&self) -> bool { false } fn is_debug(&self) -> bool { false } fn is_decorated(&self) -> bool { false } fn write(&self, _messages: PhpMixed, _newline: bool, _verbosity: i64) { } fn write_error(&self, _messages: PhpMixed, _newline: bool, _verbosity: i64) { } fn overwrite(&self, _messages: PhpMixed, _newline: bool, _size: Option, _verbosity: i64) { } fn overwrite_error(&self, _messages: PhpMixed, _newline: bool, _size: Option, _verbosity: i64) { } fn ask(&self, _question: String, default: PhpMixed) -> PhpMixed { default } fn ask_confirmation(&self, _question: String, default: bool) -> bool { default } fn ask_and_validate(&self, _question: String, _validator: Box PhpMixed>, _attempts: Option, default: PhpMixed) -> PhpMixed { default } fn ask_and_hide_answer(&self, _question: String) -> Option { None } fn select(&self, _question: String, _choices: Vec, default: PhpMixed, _attempts: PhpMixed, _error_message: String, _multiselect: bool) -> PhpMixed { default } }