简体   繁体   中英

How do I make a write operation in Realm (iOS) synchronous?

As part of an two step analysis process, I need data to be written to the persistent storage prior to the second step beginning. If I do this asynchronously via fina grain notifications its a bit messy. It would be great two do it in-line in one function.

Is it possible to make a Realm().write { } opperations synchronous? The second step will need to read this data back.

Realm.write(_:) 同步的。

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM