pub struct SourceFile {
pub path: SourcePath,
pub language: String,
pub module: SymbolId,
pub hash: ContentHash,
pub lines: u32,
}Expand description
Metadata about one analysed source file. The file’s text is not stored in the model; only its hash, so the model stays small and the corpus can detect drift.
Fields§
§path: SourcePathNormalised path relative to the codebase root.
language: StringFrontend language tag, e.g. rust.
module: SymbolIdId of the module this file defines.
hash: ContentHashHash of the file text (newline-normalised).
lines: u32Number of lines.
Implementations§
Source§impl SourceFile
impl SourceFile
Trait Implementations§
Source§impl Clone for SourceFile
impl Clone for SourceFile
Source§impl Debug for SourceFile
impl Debug for SourceFile
Source§impl<'de> Deserialize<'de> for SourceFile
impl<'de> Deserialize<'de> for SourceFile
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
impl Eq for SourceFile
Source§impl PartialEq for SourceFile
impl PartialEq for SourceFile
Source§impl Serialize for SourceFile
impl Serialize for SourceFile
impl StructuralPartialEq for SourceFile
Auto Trait Implementations§
impl Freeze for SourceFile
impl RefUnwindSafe for SourceFile
impl Send for SourceFile
impl Sync for SourceFile
impl Unpin for SourceFile
impl UnsafeUnpin for SourceFile
impl UnwindSafe for SourceFile
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more