Skip to main content

heddle_object_model/object/
mod.rs

1// SPDX-License-Identifier: Apache-2.0
2//! Core object primitives extracted from the monolith.
3
4#[macro_use]
5mod versioned_blob;
6
7mod action_id;
8mod action_operation;
9mod action_struct;
10mod annotated_tag;
11mod audience_tier;
12mod blob;
13pub mod check_evidence;
14pub mod collaboration;
15mod diff;
16mod discussion;
17mod entry_redactions;
18mod entry_visibility;
19mod facet_kind;
20mod frontier_ref;
21mod git_note;
22mod hash;
23mod identifiers;
24mod key_binding;
25pub mod manifest;
26mod operation_id;
27pub mod original_boundary_acceptance;
28mod redaction;
29mod risk_signal;
30mod semantic_change;
31mod semantic_edges;
32mod semantic_graph_query;
33mod semantic_index;
34mod semantic_reverse_deps;
35mod session;
36mod source;
37pub mod source_target;
38pub mod source_target_map;
39mod spool_id;
40mod staleness_core;
41mod state_attachment;
42mod state_attribution;
43mod state_context;
44mod state_core;
45mod state_provenance;
46mod state_review;
47mod state_visibility;
48mod structured_conflict;
49#[cfg(test)]
50mod structured_conflict_tests;
51mod suggestion_core;
52pub mod thread_authority_admission;
53pub mod thread_genesis_admission;
54mod timeline;
55mod tree;
56mod tree_canonical;
57mod tree_diff;
58mod tree_git_layout;
59mod tree_path;
60mod tree_source;
61mod tree_stream;
62pub mod tree_walk;
63mod visibility_tier;
64
65pub use action_id::ActionId;
66pub use action_operation::Operation;
67pub use action_struct::Action;
68pub use annotated_tag::{AnnotatedTag, AnnotatedTagError, AnnotatedTagMarker};
69pub use audience_tier::{AudienceParseError, AudienceTier, visible};
70pub use blob::Blob;
71pub use collaboration::*;
72pub use diff::{DiffKind, FileChange, FileChangeSet};
73pub use discussion::{
74    Discussion, DiscussionError, DiscussionId, DiscussionReference, DiscussionReferenceKind,
75    DiscussionResolution, DiscussionTurn, DiscussionsBlob, generate_discussion_id,
76};
77pub use entry_redactions::EntryRedactions;
78pub use entry_visibility::{EntryVisibility, EntryVisibilityEntry, EntryVisibilityError};
79pub use facet_kind::{FacetKind, SourceHistoryLaws};
80pub use frontier_ref::{
81    GIT_SYNTHETIC_FRONTIER_PREFIX, SYNTHETIC_FRONTIER_PREFIX, SyntheticFrontierName,
82    SyntheticFrontierNameError,
83};
84pub use git_note::{HeddleNote, NoteAttribution, OmittedBreakdown, SignalCounts};
85pub use hash::{ChangeId, ChangeIdParseError, ContentHash, StateId, StateIdParseError};
86pub use identifiers::{
87    MarkerName, RESERVED_REF_SEGMENT, ReservedRefNameError, Scope, ThreadName,
88    is_reserved_heddle_namespace,
89};
90pub use key_binding::{
91    KEY_BINDING_REGISTRY_SIGNING_PAYLOAD_VERSION_TAG, KEY_BINDING_SIGNING_PAYLOAD_VERSION_TAG,
92    KeyBinding, KeyBindingError, KeyBindingRegistry, KeyRole,
93};
94pub use manifest::{
95    BuiltManifest, FsckFinding, FsckOptions, FsckReport, FsckRule, ManifestBinding,
96    ManifestBuildError, ManifestFacet, ManifestKey, ManifestNode, ManifestNodeSource,
97    ManifestObject, ManifestObjectKind, ManifestOwnerKind, PackRangeAudit, PackRangeClaim,
98    PackRecord, build_manifest, expand_manifest, fsck_manifest, fsck_manifest_with,
99    fsck_pack_range,
100};
101pub use operation_id::{OperationId, OperationIdParseError};
102pub use redaction::{
103    PURGE_SIGNING_PAYLOAD_VERSION_TAG, PurgeEvidence, REDACTION_SIGNING_PAYLOAD_VERSION_TAG,
104    Redaction, RedactionError, RedactionsBlob,
105};
106pub use risk_signal::{
107    MAX_REASON_LEN, ProducerId, RiskSignal, RiskSignalBlob, RiskSignalError, RiskSignalKind,
108    SignalAnchor,
109};
110pub use semantic_change::{ChangeImportance, ModificationKind, SemanticChange};
111pub use semantic_edges::{BindingDelta, FileBindingDelta, ResolvedSemanticEdge, SemanticEdgeKind};
112pub use semantic_graph_query::{
113    SemanticGraphQueryKind, SemanticGraphQueryRequest, SemanticGraphQueryResponse, SemanticGraphRef,
114};
115pub use semantic_index::{
116    ByteSpan, ImportBinding, ImportEntry, ImportKindTag, OccurrenceEntry, OccurrenceRole,
117    ScopeEntry, ScopeKind, SemanticEntryKind, SemanticFileFacts, SemanticFileNode,
118    SemanticIndexError, SemanticIndexRoot, SemanticTreeEntry, SemanticTreeNode, SymbolEntry,
119    SymbolKindTag, SymbolNamespace, compute_dir_semantic_digest, compute_file_scaffold_hash,
120    compute_file_semantic_digest, compute_symbol_semantic_hash,
121};
122pub use semantic_reverse_deps::ReverseDependencyIndex;
123pub use session::{Session, SessionSegment, generate_session_id};
124#[cfg(feature = "async-source")]
125pub use source::AsyncObjectSource;
126pub use source::ObjectSource;
127pub use spool_id::{SpoolId, SpoolIdParseError};
128pub use staleness_core::{
129    StalenessStatus, SymbolResolution, annotation_status_for_source,
130    annotation_status_for_source_with_symbol_resolver, extract_line_range, resolve_current_symbol,
131};
132pub use state_attachment::{
133    StateAttachment, StateAttachmentBody, StateAttachmentId, StateAttachmentKind,
134};
135pub use state_attribution::{Agent, Attribution, Principal};
136pub use state_context::{
137    Annotation, AnnotationAnchorStatus, AnnotationKind, AnnotationRevision, AnnotationScope,
138    AnnotationStatus, ContextBlob, ContextError, ContextTarget,
139};
140pub use state_core::{
141    ChangeLineage, ChangeLineageKind, SignatureStatus, State, StateSignature, Status, Verification,
142    parse_commit_extension_headers,
143};
144pub use state_provenance::{FileProvenance, LineSpan, Origin, OriginSet, ProvenanceError};
145pub use state_review::{
146    ReviewKind, ReviewScope, ReviewSignature, ReviewSignatureError, ReviewSignaturesBlob,
147    SymbolAnchor, signing_payload,
148};
149pub use state_visibility::{
150    STATE_VISIBILITY_SIGNING_PAYLOAD_VERSION_TAG, StateVisibility, StateVisibilityBlob,
151    StateVisibilityError,
152};
153pub use structured_conflict::{
154    ConflictError, ConflictRange, ConflictRegion, ConflictSide, StructuredConflict,
155};
156pub use suggestion_core::{
157    ContextSuggestion, ContextSuggestionTier, HIGH_SUGGESTION_THRESHOLD,
158    MAJOR_REWRITE_THRESHOLD_PCT, MEDIUM_SUGGESTION_THRESHOLD, SUGGESTION_WINDOW, SuggestionInputs,
159    SuggestionSignal, score_suggestions,
160};
161pub use timeline::{
162    BranchCreatedV1, CursorMovedV1, NativeToolCallRefV1, TIMELINE_OPERATION_SCHEMA_VERSION,
163    TimelineBranchId, TimelineBranchReason, TimelineCodecError, TimelineCursorMoveReason,
164    TimelineLabel, TimelineOperationBodyV1, TimelineOperationEnvelope, TimelineOperationId,
165    TimelineOperationIdParseError, TimelineOperationKind, TimelineStepId, TimelineToolCallStatus,
166    TimelineToolPayloadMetadata, ToolCallFinishedV1, ToolCallStartedV1,
167};
168pub use tree::{
169    EntryType, FileMode, PartialTree, PartialTreeLeaf, Tree, TreeDecodeError, TreeEntry,
170    TreeEntryTarget, TreeError, TreeScheme, validate_name as validate_tree_entry_name,
171};
172pub use tree_canonical::{
173    TREE_BLOCK_ENCODING_VERSION, TREE_BLOCK_MIN_ENTRIES, TREE_CANONICAL_MAGIC,
174    TREE_DELTA_ANCHOR_INTERVAL, TREE_DELTA_ENCODING_VERSION, TREE_DELTA_HEADER_LEN,
175    TREE_DELTA_MAGIC, TREE_DELTA_MAX_OPS, TREE_ENCODING_VERSION, TREE_HEADER_LEN,
176    TREE_LEAN_ENCODING_VERSION, TREE_LEAN_MAGIC, TREE_REDACTED_ENCODING_VERSION,
177    TREE_REDACTED_HEADER_LEN, TREE_REDACTED_MAGIC, TREE_SALTED_ENCODING_VERSION, TREE_SALTED_MAGIC,
178    TreeDeltaHeader, TreeDeltaOp, TreeHeader, apply_tree_delta, decode_header, decode_lean_prefix,
179    decode_redacted_projection, decode_salted_v4, decode_tree_delta, decode_tree_delta_header,
180    decode_tree_delta_header_prefix, decode_tree_delta_ops, decode_tree_delta_ops_prefix,
181    encode_lean_entry, encode_redacted_projection, encode_tree_delta, is_canonical_tree,
182    is_delta_tree, is_lean_tree, is_redacted_tree, is_salted_tree, is_streamable_tree, tree_delta,
183};
184#[cfg(feature = "async-source")]
185pub use tree_diff::diff_trees_visit_async;
186pub use tree_diff::{diff_trees, diff_trees_visit};
187pub use tree_git_layout::{GitTreeEntryRef, RawGitMode, parse_git_tree};
188#[cfg(feature = "async-source")]
189pub use tree_path::resolve_tree_path_async;
190pub use tree_path::{
191    LeafPolicy, ResolvedTreeTarget, TreePathResolveError, resolve_tree_path, split_path,
192};
193pub use tree_source::{
194    BytesTreeSource, FileTreeSource, OpenedTreeBody, TreeBodyIntegrity, TreeByteSource,
195};
196pub use tree_stream::{
197    TreeEntryReader, TreePage, TreePageLimits, TreeResumeCursor, TreeStreamError,
198};
199pub use tree_walk::{TreeIntegrityEvent, walk_tree_integrity};
200pub use visibility_tier::VisibilityTier;
201
202pub mod thread_replication;