Trait dipstick::Prefixed

source ·
pub trait Prefixed {
    fn get_prefixes(&self) -> &NameParts;
    fn add_prefix<S: Into<String>>(&self, name: S) -> Self;
    fn add_name<S: Into<String>>(&self, name: S) -> Self;
    fn named<S: Into<String>>(&self, name: S) -> Self;

    fn prefix_append<S: Into<MetricName>>(&self, name: S) -> MetricName { ... }
    fn prefix_prepend<S: Into<MetricName>>(&self, name: S) -> MetricName { ... }
}
Expand description

Name operations support.

Required Methods§

Returns namespace of component.

👎Deprecated since 0.7.2: Use named() or add_name()

Append a name to the existing names. Return a clone of the component with the updated names.

Append a name to the existing names. Return a clone of the component with the updated names.

Replace any existing names with a single name. Return a clone of the component with the new name. If multiple names are required, add_name may also be used.

Provided Methods§

Append any name parts to the name’s namespace.

Prepend any name parts to the name’s namespace.

Implementors§