Replaced AnyObjects with T

thanks to
http://practicalswift.com/2014/06/14/the-swift-standard-library-list-of-built-in-functions/
i replaced a lot of the ObjC AnyObject stuff with the
generic/type-safe-compatible Swift functions