Skip to content

Commit

Permalink
docs: Document SDMLib migration
Browse files Browse the repository at this point in the history
  • Loading branch information
Clashsoft committed Aug 3, 2023
1 parent 09500ad commit 09c934c
Showing 1 changed file with 19 additions and 0 deletions.
19 changes: 19 additions & 0 deletions docs/sdmlib-migration.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
# Migrating from SDMLib

SDMLib syntax can be migrated to fulib decorator syntax with a few regular expressions:

> The examples assume a `ClassModelManager model` parameter.
```regexp
(\w+).(with|create)Attribute\(
model.haveAttribute($1,
(\w+).(with|create)UniDirectional\((\w+), "(\w+)", (ONE|MANY)\)
model.associate($1, "$3", $4, $2, null, 0)
(\w+).(with|create)Bidirectional\((\w+), "(\w+)", (ONE|MANY), "(\w+)", (ONE|MANY)\)
model.associate($1, "$3", $4, $2, "$5", $6)
\)\.withSuperClazz\(
,
```

0 comments on commit 09c934c

Please sign in to comment.