Buying for a Team? Gift This Course
Wishlisted Wishlist

Please confirm that you want to add Create a Weather App to your Wishlist.

Add to Wishlist

Create a Weather App

Learn how to build your own weather app
3.4 (8 ratings)
Instead of using a simple lifetime average, Udemy calculates a course's star rating by considering a number of different factors such as the number of ratings, the age of ratings, and the likelihood of fraudulent ratings.
1,194 students enrolled
Created by Psan Premarat
Last updated 7/2015
$10 $20 50% off
1 day left at this price!
30-Day Money-Back Guarantee
  • 3 hours on-demand video
  • Full lifetime access
  • Access on mobile and TV
  • Certificate of Completion
Have a coupon?
What Will I Learn?
Learn by example by walking you through real live projects step by step
Learn the fundamentals of Swift
Learn to create an app by example by walking you through real live project step by step
View Curriculum
  • basic knowledge of programming

A lot of the popular weather apps are either full of ads, require too many permissions, or include features that most of us never use. Wouldn't it be great if you could build your own weather app from scratch? Well, in this course you will learn how to do just that!

In this course you'll learn foundational concepts of iOS development while you build a weather app that displays current weather data.

This course will cover building a basic iOS weather application from start to finish. You'll learn how to build a weather app to broaden your understanding of Swift and Cocoa Touch frameworks. We will start by learning foundational concepts like networking and concurrency while building on our existing knowledge of data modeling, Auto Layout and more.

By the end of this course you will have a working weather app. This course will not only teach how to build a weather app, but it will give you a solid foundation in building apps and you will be well on your way to becoming an iOS developer.

Who is the target audience?
  • Anyone who wants to make apps
  • Anyone who want to learn the basics of coding
Students Who Viewed This Course Also Viewed
Curriculum For This Course
Expand All 27 Lectures Collapse All 27 Lectures 03:00:56
Getting Started
1 Lecture 02:55
Simple Data Structures
6 Lectures 40:53
Hardcoding data in the app is a very limited approach and it's time we started pulling in data from external sources. In this video, we look at what a plist is, how we can create them and how we use the data in our apps.
Preview 07:41

To use the information from the plist in our app, we need to create a model. In this video, we go over creating the CurrentWeather struct and setting it up for use.
Weather struct

We have a plist and we have a struct that's built to use data from the plist but no way to connect the two. In this video we look at how we can use the NSBundle class to load in files stored in the app's directory.
NSBundle and the File Directory

In iOS 8, Apple introduced a new feature called Size Classes which along with Auto Layout, allows us to design apps for all screen sizes and orientations. Let's take a look at what size classes are and how we can use them in our apps.

Interface Builder Size Classes

Exploring Size Classes

Bootstrapping the UI
Interacting With Data From the Web
7 Lectures 41:41
We're going to use the weather data from by means of their API or Application Programming Interface. In this video, we go over what an API is and how we use it.
Getting Weather Data

How We Get Data From the Web

To make an HTTP request, the first thing we need is a URL. In this video, we learn about the NSURL class reference and how we can construct our URLs.
URL Construction

Fetching Data

Our network call returns some data in a format known as JSON. Let's take a look at what JSON is and why we're using this particular format.

We often do multiple things at once on our mobile devices but take for granted the computing complexity involved. In this video, we'll start with a history lesson and look at what it means to execute multiple blocks of code simultaneously.
A Look at Concurrency

Now that we know the importance of concurrency and how our code might cause problems, let's sort things out. In this video, we're going to use the NSURLSession collection to write concurrent networking code that should steer us clear of any problems.
Writing Concurrent Networking Code
Managing Complexity
5 Lectures 45:36

In separating our app logic into different structs and classes we're going to make our code more reusable and a lot more readable. Let's start with a class to manage network operations.

Network Operations

The main job of the NetworkOperation class will be to download some JSON from a given URL. Since a network operation is an asynchronous one, we need to implement our method with a callback mechanism using a closure.

Methods with Closures

With two pieces of the puzzle complete, NetworkOperation and CurrentWeather, all we need is a third struct to coordinate between the two.

The three main components of our app are set up but we're not done yet. The CurrentWeather struct is still set up to mostly handle data from the plist. With a few tweaks we can adapt it to handle data from the web.
Modifying CurrentWeather

We've talked about performing tasks in the background but never about how we can return to the main thread when these tasks are done. In this video, we take a look at iOS' preferred way of managing concurrent tasks using Grand Central Dispatch.
Grand Central Dispatch
Weather Icons
5 Lectures 38:10
Adding Icons

Assigning An Icon Image

Streamlining The Icon Enum

Displaying Icons

A typical aspect of fetching data from the Internet is allowing users to refresh the data themselves. Let's start by adding a refresh button to our view. We'll also look at a new Auto Layout concept that will help us adapt our controls to different devices.
Adding Refresh Actions
Refreshing the Data
2 Lectures 08:07
Refresh Button Adjustment

Now that we have a button in place, all we need to do is add a method to refresh the data. We'll also use an activity indicator to let users know the network request is in progress.
Manually Refreshing the Data
1 Lecture 03:34

Course Recap Quiz
3 questions
About the Instructor
4.0 Average rating
29 Reviews
2,608 Students
4 Courses
Software Developer

I am a software developer with over 10 years programming experience and consulting for corporations throughout the U.S. and Europe. I've programmed everything from security systems to music drivers for computer games.

I'm also a co-founder of an App development company. We have developed numerous apps the past 5 years, with many of them soaring to the top of the charts in their particular category.

I love speaking at conferences, user groups and code camps. I also love to teach in classrooms, consult businesses, and train people online, but what I love most is playing video games with my amazing wife.

Report Abuse