Hola, Apple

1

Hablemos de iOS

2

Conozcamos XCode

3

驴Necesito un iPhone para ser iOS Developer?

Tu primera app en iOS

4

隆Hola, Mundo Apple!

5

Navegaci贸n con UINavigationController

6

Modales en la navegaci贸n

7

Utilizando controles en c贸digo

8

Autolayout vs SwiftUI

9

Autolayout

10

Listas con UITableView

11

Celdas personalizadas para nuestras listas.

12

Persistencia: UserDefaults

Manejo de dependencias

13

CocoaPods

14

Carthage

Servicios Web

15

Primeros pasos para consumir servicios

16

Afinando detalles para consumir servicios

17

Convirtiendo los JSON a modelos

18

Alamofire

Proyecto: PlatziTweets

19

Bienvenido a PlatziTweets

20

Configurando Proyecto

21

Dise帽ando vistas iniciales

22

Configuraci贸n de vistas iniciales

23

Configuraci贸n de registro

24

Descripci贸n de la API de PlatziTweets

25

Conexi贸n de la API y Autenticaci贸n

26

Registro de usuarios

27

Dise帽o del Tweet

28

Obteniendo Tweets

29

Creaci贸n de vista para publicar Tweets

30

Publicando Tweets

31

Borrando Tweets

32

Integraci贸n de la c谩mara

33

Conexi贸n con Firebase

34

Configuraci贸n de XCode para correr app

35

Subir imagen a Firebase

36

Publicar Tweet con imagen

37

Tomando Videos para el Tweet

38

Publicar Tweet con video

39

Detalles del video

40

Accediendo al GPS

41

Implementando mapas con MapsKit

42

Mostrando todos los estudiantes en el mapa

43

Retos del proyecto

En producci贸n

44

Enviar a pruebas con Firebase Distribution

45

Enviar tu aplicaci贸n a APP Store Connect

46

Distribuci贸n de tu app con TestFlight

iOS Avanzado

47

Dark Mode

48

SwiftUI

49

Terminando detalles de una vista con SwiftUI

50

Objective-C

Hola, iOS Developer

51

Felicidades

52

Expert Session: 隆nuevo espacio para resolver tus dudas sobre el desarrollo de Apps para iOS!

You don't have access to this class

Keep learning! Join and start boosting your career

Aprovecha el precio especial y haz tu profesi贸n a prueba de IA

Antes: $249

Currency
$209
Suscr铆bete

Termina en:

1 D铆as
17 Hrs
28 Min
29 Seg

Objective-C

50/52
Resources

Why learn Objective-C in a Swift-dominated world?

Although Swift dominates iOS development in today's landscape, learning Objective-C is still relevant and can be the key to a job as an iOS developer. Despite the fact that Objective-C, a programming language created over 40 years ago, may seem old-fashioned, it is still necessary to understand the structure behind many older apps and have an edge in the job market. Mastering Objective-C will allow you not only to create apps, but also to understand and modify legacy applications that might be composed of both languages.

How to create a basic Objective-C project?

To start your journey in Objective-C, creating a new project is essential. Here we show you a step-by-step to prepare the ground:

  1. Create a new project:

    • Select the "Single View App" template.
    • Choose Objective-C as the language.
    • Save the project in an accessible place, such as the desktop.
  2. Project structure in Objective-C:

    • Files are divided into .h for the public interface and .m for the implementation.
    • It includes AppDelegate and ViewController similar to Swift projects.

When creating a new project, you will notice that there are more files than in Swift, due to the separate use of interface and implementation files, which can be overwhelming at first. However, having this clear structure is crucial for understanding how the different parts of the code relate to each other.

How to work with interfaces and classes in Objective-C?

Objective-C has some notable differences from Swift in the way interfaces and classes are handled. For starters, it's important to understand how these connections are established in your code:

  • Use @interface and @implementation to define classes.
  • Methods and properties should be declared in the .h file and defined in the .m file.

One aspect that stands out is the use of the asterisk ( * ) as a memory pointer, necessary for the declaration of variables.

Example of connection with an outlet in Objective-C

@interface ViewController : UIViewController@property (nonatomic, weak) IBOutlet UITableView *tableView;@end
@implementation ViewController- (void)viewDidLoad { [super super viewDidLoad]; [self setupUI];}
 -(void)setupUI { self.tableView.dataSource = self;}@end

Here is an important difference with Swift in terms of interface handling: in Objective-C, you need to manually implement many of the features that in Swift are automatically configured.

How to manage tables and cells in Objective-C?

Creating a basic user interface with tables in Objective-C is not much different from Swift, once you understand the basics. Here's a quick guide to setting up a table:

  1. Add TableView from Storyboard:

    • Drag a TableView from the object library to your screen.
    • Define constraints to position it properly.
  2. Implement datasource methods:

    • Implement UITableViewDataSource in the .h file.
    • Add methods in the .m to define the number of rows and cell characteristics.

Code to manage cells

-(NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section { return 10; // Number of cells}
 -(UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath { UITableViewCell *cell = [tableView dequeueReusableCellWithIdentifier:@"CellID" forIndexPath:indexPath]; cell.textLabel.text = @"I am a cell"; return cell;}

This example highlights the use of Swift-like methods, but with a syntax that reflects the age and unique features of Objective-C.

What are the challenges and benefits of learning Objective-C?

Learning Objective-C can be challenging due to its different syntax and approaches than Swift, but its benefits include:

  • Access to legacy software: Many existing applications still work with Objective-C.
  • Expanding your skills: It makes you a more versatile and competitive developer.
  • Understanding the origins of iOS: It gives you a deeper understanding of the Apple ecosystem.

The path to mastering Objective-C is both a challenge and an opportunity for personal and professional growth. Although at first you may be scared by its structure and fine details, such as the need to handle pointers and differentiate between interface and implementation files, facing these challenges will help you grow as a developer, better preparing you for the iOS job market.

Contributions 4

Questions 0

Sort by:

Want to see more contributions, questions and answers from the community?

Todo proyecto con m谩s de 3 a帽os (probablemente hasta de 2) de desarrollo les puedo asegurar que todav铆a tiene algo de Objective-C en sus entra帽as. Lo mejor es conocer ambos lenguajes pero darle prioridad a Swift

馃槄Me desesper茅 solo con ver el c贸digo

  • punto y coma porque es un lenguaje antiguo 馃槀

馃

Si es correcto en donde yo laboraba ten铆an aplicaciones aun con objective-c