问题
I'm pretty new to MvvmCross and understand that successful use of the framework relies on specific naming conventions in some areas. I have been looking around trying to find information on these naming conventions, but apart from figuring some of them out from watching various videos, I haven't been able to find anything that explains all the requirements in one place. Any suggestions?
回答1:
The naming conventions used:
- in bindings are in https://github.com/MvvmCross/MvvmCross/wiki/Customising-using-App-and-Setup#registering-custom-bindings
- in View-ViewModel lookup are in https://github.com/MvvmCross/MvvmCross/wiki/Customising-using-App-and-Setup#overriding-view-viewmodel-associations
- the default IoC setup - using the postfix "Service" is described in https://github.com/MvvmCross/MvvmCross/wiki/Service-Location-and-Inversion-of-Control#bulk-registration-by-convention
- the registration of ValueConverters is described in https://github.com/MvvmCross/MvvmCross/wiki/Value-Converters#referencing-value-converters-in-touch-and-droid
The MvvmCross manifesto - https://github.com/MvvmCross/MvvmCross/wiki/The-MvvmCross-Manifesto - doesn't force any of these conventions on you - you can override this and use your own convention schemes or use your a different mechanism for anything you want to do.
来源:https://stackoverflow.com/questions/22738780/mvvmcross-naming-conventions