Skip to content

Commit 22438f4

Browse files
committed
README: updated initial example #56
1 parent 1a05a07 commit 22438f4

File tree

1 file changed

+6
-3
lines changed

1 file changed

+6
-3
lines changed

README.md

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -43,12 +43,15 @@ Feature Highlights
4343
What does using ObjectBox in Python look like?
4444

4545
```python
46-
import objectbox
46+
from objectbox import *
4747

48-
# from mypackage.model import Person
48+
@Entity()
49+
class Person:
50+
id = Id
51+
name = String
4952

5053
# The ObjectBox Store represents a database; keep it around...
51-
store = objectbox.Store(model=model)
54+
store = Store()
5255

5356
# Get a box for the "Person" entity; a Box is the main interaction point with objects and the database.
5457
box = store.box(Person)

0 commit comments

Comments
 (0)