AzureADSamples/NativeClient-Xamarin-iOS — pull request #2 by carlosfigueira (2014-05-19 18:04:54+00:00)
Title: Fix build / runtime breaks in the API definition and struct files

There are several issues which prevent the project to build as is, and some that prevent it from running correctly. I've broken down the PR in two commits: the first just changes the indenting of the ApiDefinitions.cs file, and the second actually has the changes, so they can be reviewed easier (by looking at the [commit directly](https://github.com/carlosfigueira/NativeClient-Xamarin-iOS/commit/9a9c6f357c6e58a87cb465ed3e8ad5fa43753839)).

These are the issues which prevented it from building:
- `ADTokenCacheStoring` wasn't decorated with the `[BaseType]` attribute; added it
- `ADTokenCacheStoring` is a protocol, added the `[Protocol]` decoration to it
- Added the `"__Internal"` parameter to the `[Field]` definitions on the `ADTokenCacheStoring` interface, otherwise it wouldn't build. Per the Xamarin documentation: `If you are linking statically, there is no library to bind to, so you need to use the __Internal name`.
- Moved the `ADCredentialsType` enumeration from the ApiDefinition.cs file to StructsAndEnums.cs.

These are issues which prevented it from running correctly:
- The protocol / interface `IADTokenCacheStoring` is returned by both the context and the settings class; to have it working, the properties need to be defined in the interface type, not in the generated type (search for "If you want to use the MyProtocol in an API" in the [Xamarin doc for binding ObjC libraries](http://docs.xamarin.com/guides/ios/advanced_topics/binding_objective-c/binding_objc_libs/).