Go Mobile with C# and Xamarin

Play Go Mobile with C# and Xamarin

The Discussion

  • User profile image

    The course doesn't appear on MVA

  • User profile image

    @ameser: The content might only be available post the conference perhaps.

  • User profile image

    PLEASE get this video up before Saturday morning!

  • User profile image
    Ron J

    **!! Wrong video. Please post correct content. Thanks

  • User profile image
    Paul Batum

    Its fixed now.

  • User profile image
    Ilias Jennane

    I don't have the iOS designer in VS , is that included in the current version?

  • User profile image

    I find weird that the presenter claims that Objective C is similar to JavaScript, this is totally utterly wrong. Objective C is mostly strongly typed with a few dynamical features.

    You can with Xcode and Clang get code completion for the entire API and similarly Clang will only allow you to give the valid value for a given API, basically the compiler does everything to ensure that you pass the right argument and value type as the code is being written. Then he goes to a bizarre statement that you wouldn't be able to debug Objective C code for some reasons that makes no sense since he seemed confused trying to make any sense.

    I have the feeling that he tried here to over sale his product and just said something completely BS.

  • User profile image

    Could someone post a link to XamarinStore sample app?

  • User profile image
  • User profile image

    @Hakime: You misunderstood him completely and took his comments out of context. He was referring to the particular CIVignette code when it comes to code completion and debugging.

    You are referring to 27:04 in the video when he said:

    "C# really shines over objective C, because we've strongly typed the API with full code completion for these things. It knows what things you can do and you are only allowed to put the values that are valid. In objective C it's a little bit like javascript, you can throw anything its way and maybe it will work, maybe it won't, it's anybody's guess. It's just a dictionary and you can't really track down bugs, I mean you gotta inspect every single property figure out if you've got the right value, the right constant. So with strongly typing we let the compiler do all this work for you."

    The code he wrote in C# was as follows (with full code completion as he showed):

    var vi = new CIVignette()
    Image = CIImage.FromCGImage(tmp.CGImage),
    Radius = 10,
    Intensity = 2

    To do this same thing in objective-c you have to use a key-value dictionary to specify the "property" values of the CIVignette filter That looks like this:

     CIImage *image = [CIImage imageWithCGImage:tmp];
    CIFilter *filter = [CIFilter filterWithName:@"CIVignette"
    keysAndValues:@"image", image,
    @"inputRadius", 10,
    @"inputIntensity", 2, nil];

    Notice that if you misspelled CIVignette, image, inputRadius or inputIntensity you would have a hard time debugging this code finding the exact member you misspelled. Also, the only way to know what keys are valid would be to look at the CIImage documentation.


  • User profile image

    @Hakime, what @atticusalien is what I was getting to.

    In general, many of the Objective-C APIs use the untyped NSDictionary to configure various parameters of the API.    

    There are 475 public APIs in the iOS API that expose NSDictionary as either return values, or parameters.   The keys and the values for these configuration parameters usually require a trip to the documentation.

    Getting the key wrong will make your software not run.   Getting the value of the type wrong might or might not work.  It really depends, you can search bug databases and stackoverflow for examples of both typos causing unexpected behavior in your application.

Add Your 2 Cents