Skip to content

Commit e6879c6

Browse files
script3rclaude
andcommitted
Apply cargo fmt formatting
🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <[email protected]>
1 parent c32d6d4 commit e6879c6

File tree

4 files changed

+16
-12
lines changed

4 files changed

+16
-12
lines changed

examples/in_memory.rs

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -43,10 +43,7 @@ fn main() -> anyhow::Result<()> {
4343

4444
// Identity Key: Records with same (name + email) are candidates for merging
4545
// Using from_names() - no need to pre-intern attributes!
46-
ontology.add_identity_key(IdentityKey::from_names(
47-
vec!["name", "email"],
48-
"name_email",
49-
));
46+
ontology.add_identity_key(IdentityKey::from_names(vec!["name", "email"], "name_email"));
5047

5148
// Strong Identifier: SSN uniquely identifies a person
5249
// If two records have different SSNs, they CANNOT be merged

examples/persistent_shard.rs

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -81,10 +81,7 @@ fn main() -> anyhow::Result<()> {
8181

8282
let mut ontology = Ontology::new();
8383

84-
ontology.add_identity_key(IdentityKey::from_names(
85-
vec!["name", "email"],
86-
"name_email",
87-
));
84+
ontology.add_identity_key(IdentityKey::from_names(vec!["name", "email"], "name_email"));
8885

8986
ontology.add_strong_identifier(StrongIdentifier::from_name("ssn", "ssn_unique"));
9087

src/conflicts.rs

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1119,7 +1119,9 @@ impl ConflictDetector {
11191119
// Check constraints across clusters (for unique constraints)
11201120
for constraint in &ontology.constraints {
11211121
match constraint {
1122-
Constraint::Unique { attribute, name, .. } => {
1122+
Constraint::Unique {
1123+
attribute, name, ..
1124+
} => {
11231125
let cross_cluster_violations = Self::check_unique_constraint_across_clusters(
11241126
store, clusters, *attribute, name,
11251127
)?;
@@ -1262,12 +1264,16 @@ impl ConflictDetector {
12621264
let mut violations = Vec::new();
12631265

12641266
match constraint {
1265-
Constraint::Unique { attribute, name, .. } => {
1267+
Constraint::Unique {
1268+
attribute, name, ..
1269+
} => {
12661270
let violations_for_attr =
12671271
Self::check_unique_constraint(store, cluster, *attribute, name)?;
12681272
violations.extend(violations_for_attr);
12691273
}
1270-
Constraint::UniqueWithinPerspective { attribute, name, .. } => {
1274+
Constraint::UniqueWithinPerspective {
1275+
attribute, name, ..
1276+
} => {
12711277
let violations_for_attr = Self::check_unique_within_perspective_constraint(
12721278
store, cluster, *attribute, name,
12731279
)?;

src/lib.rs

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -240,7 +240,11 @@ impl Unirust {
240240
/// Any identity keys, strong identifiers, or constraints created with string-based
241241
/// APIs (e.g., `IdentityKey::from_names`) will have their attribute names automatically
242242
/// interned using the store's interner.
243-
pub fn with_store_and_tuning<S>(mut ontology: Ontology, mut store: S, tuning: StreamingTuning) -> Self
243+
pub fn with_store_and_tuning<S>(
244+
mut ontology: Ontology,
245+
mut store: S,
246+
tuning: StreamingTuning,
247+
) -> Self
244248
where
245249
S: RecordStore + 'static,
246250
{

0 commit comments

Comments
 (0)