PFonseca

Developer

View site on GitHub Statuses Archives

Swift Update 2014-02-09

  • Constants can now be declared without being initialized in local function scope. They must have a set value before first use. For more information, see Constant Declaration.

  • Constant properties can now only assign a value once in an initializer. For more information, see Assigning Constant Properties During Initialization

  • Multiple optional bindings can now appear in a single if statement as a comma-separated list of assignment expressions. For more information, see Optional Binding.

  • A Optional-Chaining Expression must appear within a postfix expression.

  • Protocol casts are no longer limited to @objc protocols.

  • Type casts that can fail at runtime now use the as? or as! operator, and type casts that are guaranteed not to fail use the as operator. For more information, see Type-Casting Operators.

Published on 10/02/2015 at 10h59 by pfonseca, tags ,

How to get iDevice's IMEI

The simplest way to get your IMEI is tap Settings > General > About to see your device's serial number, IMEI/MEID, and ICCID (iOS 6+).


HT4061-iphone_5s-about-003-en

Published on 07/01/2015 at 02h53 by pfonseca, tags

Swift Update 2014-08-18

Swift update with iOS 8 beta 6.

  • Added a new section about Initializer Requirements in protocols.

  • Added a new section about Class-Only Protocols.

  • Assertions can now use string interpolation. Removed a note to the contrary.

  • Updated the Concatenating Strings and Characters section to reflect the fact that String and Character values can no longer be combined with the addition operator (+) or addition assignment operator (+=). These operators are now used only with String values. Use the String type’s append method to append a single Character value onto the end of a string.

  • Added information about the availability attribute to the Declaration Attributes section.

Source: https://developer.apple.com/library/

Published on 07/01/2015 at 02h28 by pfonseca, tags ,

Swift Update 2014-08-04

Swift update with iOS 8 beta 5.

  • Optionals no longer implicitly evaluate to true when they have a value and false when they do not, to avoid confusion when working with optional Bool values. Instead, make an explicit check against nil with the == or != operators to find out if an optional contains a value.

  • Swift now has a Nil Coalescing Operator (a ?? b), which unwraps an optional’s value if it exists, or returns a default value if the optional is nil.

  • Updated and expanded the Comparing Strings section to reflect and demonstrate that string and character comparison and prefix / suffix comparison are now based on Unicode canonical equivalence of extended grapheme clusters.

  • You can now try to set a property’s value, assign to a subscript, or call a mutating method or operator through Optional Chaining. The information about Accessing Properties Through Optional Chaining has been updated accordingly, and the examples of checking for method call success in Calling Methods Through Optional Chaining have been expanded to show how to check for property setting success.

  • Added a new section about Accessing Subscripts of Optional Type through optional chaining.

  • Updated the Accessing and Modifying an Array section to note that you can no longer append a single item to an array with the += operator. Instead, use the append method, or append a single-item array with the += operator.

  • Added a note that the start value a for the Range Operators a...b and a..<b must not be greater than the end value b.

  • Rewrote the Inheritance chapter to remove its introductory coverage of initializer overrides. This chapter now focuses more on the addition of new functionality in a subclass, and the modification of existing functionality with overrides. The chapter’s example of Overriding Property Getters and Setters has been rewritten to show how to override a description property. (The examples of modifying an inherited property’s default value in a subclass initializer have been moved to the Initialization chapter.)

  • Updated the Initializer Inheritance and Overriding section to note that overrides of a designated initializer must now be marked with the override modifier.

  • Updated the Required Initializers section to note that the required modifier is now written before every subclass implementation of a required initializer, and that the requirements for required initializers can now be satisfied by automatically inherited initializers.

  • Infix Operator Functions no longer require the @infix attribute.

  • The @prefix and @postfix attributes for Prefix and Postfix Operators have been replaced by prefix and postfix declaration modifiers.

  • Added a note about the order in which Prefix and Postfix Operators are applied when both a prefix and a postfix operator are applied to the same operand.

  • Operator functions for Compound Assignment Operators no longer use the @assignment attribute when defining the function.

  • The order in which modifiers are specified when defining Custom Operators has changed. You now write prefix operator rather than operator prefix, for example.

  • Added information about the dynamic declaration modifier in Declaration Modifiers.

  • Added information about how type inference works with Literals.

  • Added more information about Curried Functions.

Source: https://developer.apple.com/library/prerelease/ios/documentation/Swift/Conceptual/Swift_Programming_Language/RevisionHistory.html#//apple_ref/doc/uid/TP40014097-CH40-XID_1504

Published on 07/01/2015 at 02h04 by pfonseca, tags ,

Swift Update 2014-07-21

Source: https://developer.apple.com/library/prerelease/ios/documentation/Swift/Conceptual/Swift_Programming_Language/RevisionHistory.html#//apple_ref/doc/uid/TP40014097-CH40-XID_1504

Published on 07/01/2015 at 02h02 by pfonseca, tags ,


Powered by Publify