pub trait Reporting {
type Record<'res>: Record
where Self: 'res;
type Reporter<'res>: Iterator<Item = Self::Record<'res>>
where Self: 'res;
// Required method
fn report(&self) -> Self::Reporter<'_>;
// Provided method
fn write_extra_link_format(
&self,
writer: &mut impl Write,
is_first: &mut bool,
) -> Result { ... }
}Expand description
Indicates that this resource can produce output for a .well-known/core resource.
Several trivial implementations (NotReporting for resources that should not show in .well-known/core, ConstantSingleRecordReport for resources with one static record) are available that cover most scenarios in which a custom Handler is implemented.
Required Associated Types§
type Record<'res>: Record where Self: 'res
type Reporter<'res>: Iterator<Item = Self::Record<'res>> where Self: 'res
Required Methods§
Provided Methods§
Sourcefn write_extra_link_format(
&self,
writer: &mut impl Write,
is_first: &mut bool,
) -> Result
fn write_extra_link_format( &self, writer: &mut impl Write, is_first: &mut bool, ) -> Result
Writes additional lines into an output RFC6690 Link Format document
This output is appended to any records produced.
The is_first argument assists both parties in coordination of the , delimiter: Unless
is_first=true, this writer needs to prefix its output with a , (comma) character, and
if it produces any output, it sets *is_first=false.
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.