MCPcopy Create free account
hub / github.com/atomicdotdev/atomic / both

Method both

atomic-core/src/change/format_v3/sections.rs:551–573  ·  view source on GitHub ↗

Create a pair with both GRAPH and SEMANTIC sections. # Arguments `path` - File path (used in both sections). `ops` - Compact graph operations. `file_ops` - Semantic operations. `content_start` - Start of content range. `content_end` - End of content range.

(
        path: String,
        ops: Vec<CompactGraphOp>,
        file_ops: FileOps,
        content_start: u64,
        content_end: u64,
    )

Source from the content-addressed store, hash-verified

549 /// * `content_start` - Start of content range.
550 /// * `content_end` - End of content range.
551 pub fn both(
552 path: String,
553 ops: Vec<CompactGraphOp>,
554 file_ops: FileOps,
555 content_start: u64,
556 content_end: u64,
557 ) -> Self {
558 Self {
559 graph: Some(GraphSectionPayload::new(
560 path.clone(),
561 ops,
562 content_start,
563 content_end,
564 )),
565 semantic: Some(SemanticSectionPayload::new(
566 path.clone(),
567 file_ops,
568 content_start,
569 content_end,
570 )),
571 path,
572 }
573 }
574
575 /// Create a pair with only a GRAPH section (no semantic layer).
576 ///

Callers

nothing calls this directly

Calls 1

cloneMethod · 0.45

Tested by

no test coverage detected