Trait cmake_file_api::objects::Object

source ·
pub trait Object {
    // Required methods
    fn kind() -> ObjectKind;
    fn major() -> u32;

    // Provided method
    fn resolve_references(&mut self, _: &Reader) -> Result<(), ReaderError> { ... }
}

Required Methods§

Provided Methods§

source

fn resolve_references(&mut self, _: &Reader) -> Result<(), ReaderError>

Resolve references in the object

Some objects contain references to other json files. This method is called after the object is deserialized to resolve these references. Currently only the codemodel-v2 object has references (targets, directories) that need to be resolved.

§Errors

ReaderError::IO: if an IO error occurs while reading the object file ReaderError::Parse: if an error occurs while parsing the object file

Object Safety§

This trait is not object safe.

Implementors§