Skip to main content

output_as

Function output_as 

Source
pub fn output_as<T: Serialize + JsonlSerialize>(
    data: &T,
    format: &OutputFormat,
) -> Result<bool>
Expand description

Serializes data in the requested output format to stdout. Returns Ok(true) if data was printed (json/yaml/yamls/jsonl), Ok(false) if the caller should handle table output.