agi18n agimagechecker amazonaws android arc autolayout blog building cache calabash certificates clean code cocoa cocoapods data binding debugging deployment target drm ebs ec2 errors facebook fix git i18n images instruments interface builder ios iosx enterpise summit ipad iphone iphone5 kotlin libraries like button linking links llvm memory management method swizzling mobile model mvc mvvm nil objective-c optimizations patch patterns performance presentation provisioning profiles restkit runtime rxjava rxswift security shadows streaming svn swift testing tools tutorials uikit uistackview video view xcode

Subscribe to this blog

Tag: ios

Oddities working with images in iOS

Angel G. Olloqui 14 September, 2012

For the last 10 days I have been working in a new library to check iOS images on runtime. I will make another post to explain it in a future, but today I wanted to remark some oddities that I found when working so tightly with the UIImageView class (it is funny that I haven’t realized on most these oddities after almost 3 years working with them)


UIImageView, as any other view in iOS, extends UIView. This characteristic would make everyone think that UIImageView have all the functionality and behave as any other view. However, there are some interesting considerations when working with this component:

Tags: ios, interface builder, images, agimagechecker, debugging, runtime


Restkit addition: Cache-Control

Angel G. Olloqui 15 August, 2012

Today I am not going to explain anything new but to add a small patch to RestKit. If you still haven’t worked with RestKit before give it a try. It is a very useful library to manage connection to external APIs.
RestKit, between many other things, have a feature to set the cache policy that you want to use when interacting with the external WebServices. However, if you take a look to the defined policies, you may see (if nothing has changed since I wrote this post) that none of them give you the option to read the “Cache-Control” header of the HTTP response. And that is exactly what I have added in my pull request https://github.com/RestKit/RestKit/pull/888. Nevertheless, the pull request has not been merged yet, so here you have a temporary solution:

Tags: restkit, libraries, patch, ios, cache


CocoaPods: a great tool for library dependency management

Angel G. Olloqui 05 July, 2012

Have you ever needed to use a third party library which needs other third party libraries and wondered why the hell they are so complicated to integrate within your iOS project? well, if that is your case then you will like this post and you will love CocoaPods.
But first, let me tell you that before writting this article I have worked with it for a couple of months in real projects. Thus, it is long enough to write some experiences that I had with it, but let’s start from the beginning.

What is CocoaPods?

CocoaPods is a tool written in Ruby that allows you to manage library dependencies in Objective-C projects. It is very simple to use, specially if you are used to Ruby Gems. The only thing you have to do is install it in your machine and then create a file called Podfile in your project, which will contain a list with the project dependencies to other libraries. For example:

Tags: ios, cocoapods, libraries, tools


Method Swizzling

Angel G. Olloqui 18 May, 2012

Hoy voy a hablar sobre methodSwizzling, para mí una de las técnicas más apasionantes de Objective-C. Eso sí, aviso para navegantes, estas técnicas son complejas y, según el uso que les des, pueden también ser peligrosas. Vamos a verlo!

Qué es MethodSwizzling?

Probablemente nunca hayas oído hablar de MethodSwizzling antes, o si lo habías hecho, no sepas exactamente qué es o para qué puede servir. Pues bien, ese nombre se usa para referirse simplemente a la técnica de intercambiar métodos en runtime.
Es decir, se trata de que métodos que ya existan sean cambiados por otros nuevos durante ejecución, incluso en clases que no has prgramado tú (del sistema por ejemplo). A nivel conceptual puedes entenderlo como una category o una herencia que reemplaza métodos del padre, pero el MethodSwzzling, al ser en runtime, va mucho mas allá. Ahora veremos por qué....

Tags: objective-c, runtime, ios, method swizzling


Manteniendo compatibilidad con versiones anteriores de iOS

Angel G. Olloqui 08 March, 2011

Es muy habitual encontrarnos con la necesidad de dar soporte a usuarios que no estén actualizados con el último iOS en nuestras aplicaciones iPhone o iPad, pero los SDKs nuevos dan soporte únicamente para un conjunto muy reducido de versiones anteriores, lo que normalmente no es suficiente.

Tags: deployment target, ios, ipad, iphone