southpeak / minya Goto Github PK
View Code? Open in Web Editor NEWA simple basic hierarchy for iOS development with Objective-C. It is based on MVCS and KVO.
License: MIT License
A simple basic hierarchy for iOS development with Objective-C. It is based on MVCS and KVO.
License: MIT License
There is so many unnecessary nullability taken,so can we remove unnecessary nullability taken?
Hello! 最近在看您写的MVCS框架 ,KVO模块有个地方不太理解:
[info.observedObject removeObserver:info.observingObject forKeyPath:info.keyPath]; 既然已经移除了kvo 。那下面这段代码看着不是很懂:
NSObject *otherObject = nil;
if (info.observedObject != registeredObject) {
otherObject = info.observedObject;
} else if (info.observingObject != registeredObject) {
otherObject = info.observingObject;
}
NSMutableArray *infosForOtherObject = [otherObject mi_associatedObjectForKey:kMIKVOInfoKey];
[infosForOtherObject removeObject:info];
看了你画的mvcs图,非常棒!现在我有一个疑问,网络请求在MVVM中的标准位置是哪里?是直接放到view model中还是单写一个service类中?
`[[MIMediator sharedMediator] viewControllerWithScene:scene context:self.pipeline.contextForSearch];
[self.navigationController pushViewController:viewController animated:YES];
`
只是参数的向前传递 有没有back之后的向后传递方式,或者用一种全局性的参数传递方式呢,比如说通知。
(void)observeValueForKeyPath:(NSString *)keyPath ofObject:(id)object change:(NSDictionary<NSKeyValueChangeKey,id> *)change context:(void *)context {
__MIKVOInfo *info = (__bridge __MIKVOInfo *)(context);
if (info.changed) {
id newValue = [change valueForKey:NSKeyValueChangeNewKey];
info.changed([newValue isKindOfClass:[NSNull class]] ? nil : newValue);
}
}
报错no type protocol name 'NSKeyValueChangeKey'
是我步骤有问题么
xcode 7.3.1
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.