Skip to main content

ViewerBackend

Trait ViewerBackend 

Source
pub trait ViewerBackend {
    // Required methods
    fn name(&self) -> &str;
    fn description(&self) -> &str;
    fn is_available(&self) -> bool;
    fn open(&self, content: &str) -> CoreResult<()>;

    // Provided method
    fn availability_hint(&self) -> Option<String> { ... }
}
Expand description

A pluggable backend that can render collected proposal artifacts.

Required Methods§

Source

fn name(&self) -> &str

Stable CLI/backend identifier.

Source

fn description(&self) -> &str

Human-readable summary shown in prompts and help.

Source

fn is_available(&self) -> bool

Whether the viewer can run in the current environment.

Source

fn open(&self, content: &str) -> CoreResult<()>

Open or render the provided proposal content.

Provided Methods§

Source

fn availability_hint(&self) -> Option<String>

Detailed hint shown when the viewer is unavailable.

Returns None if is_available() is true or no specific guidance exists.

Implementors§