Comments (4)
Thanks. I try to comment synchronize and also 10 times the test case to see the result, the result is very interesting.
I also wonder if need other test case, like read, write, read, write, ...., to simulator the real world access.
from mmkv.
And what do they mean by deprecate this method? Does that mean NSUserDefaults will never lose data on App crashing? No? Well, here comes MMKV.
It's not about NSUserDefaults being slow, it's about keeping efficiency while not losing data.
from mmkv.
Please refer:https://developer.apple.com/library/archive/releasenotes/Foundation/RN-FoundationOlderNotes/index.html#X10_10Notes
see section: -[NSUserDefaults synchronize] Changes
from mmkv.
Apple declared in iOS 10 release note that
Synchronized to avoid losing data if your app crashed
is not needed anymore. I personally highly doubt that.
Well, let's trust that statement. Try this: comment the synchronize
in the baseline code and run again. You can find out that NSUserDefaults is not any faster. What does that tell you?
from mmkv.
Related Issues (20)
- 保存后,马上读能读到,但杀死app后读读不到 HOT 4
- 在模拟器上会crash,真机上运行正常,这是为啥? HOT 2
- android系统上mmkv生成的数据文件在鸿蒙中使用 HOT 2
- mmkv 1.3.5版本不再支持armeabi-v7a ? HOT 1
- 鸿蒙next版本MMKV 取出的数据比保存的数据丢了一个字符 HOT 2
- Importing ArkTS files to JS and TS files is not allowed. <ArkTSCheck> HOT 2
- 鸿蒙版本的MMKV,double、float、int、bool现在不能返回undefined HOT 4
- 鸿蒙版本的MMKV中没有getAll方法 HOT 1
- 能否提供getAll接口,返回Object类型value
- 能否支持类似Android版本的getAll接口 HOT 2
- <MMKV.cpp:331::loadFromFile> fail to mmap [xxxx], Out of memory HOT 5
- Android平台下生成的mmkv文件,在鸿蒙系统下是否可以读取出来,因为后面Android可以升级到鸿蒙需要做数据迁移 HOT 5
- MMKV decodeDouble decodeBool api问题 HOT 1
- iOS 版本的 MMKV 1.2.12 版本,Xcode 15.4 真机运行包错 HOT 1
- MMKV 在 App 重启后丢失数据 HOT 4
- MMKV不支持鸿蒙 next 的api11 吗? HOT 4
- 鸿蒙里只有number类型,mmkv里区分了int32,int64 ,double, float等类型,请问在鸿蒙里mmkv里该如何使用 HOT 2
- [Flutter] [Android] Failed to load dynamic library 'libmmkv.so': dlopen failed: library "libmmkv.so" not found HOT 7
- [Android] Fatal Exception: ... couldn't find "libmmkv.so" HOT 19
- encode with null value == remove key ??? HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from mmkv.