Your First ios 7 App. Everything you need to know to build and submit your first ios app. Ash Furrow

Size: px
Start display at page:

Download "Your First ios 7 App. Everything you need to know to build and submit your first ios app. Ash Furrow"

Transcription

1

2 Your First ios 7 App Everything you need to know to build and submit your first ios app. Ash Furrow This book is for sale at This version was published on This is a Leanpub book. Leanpub empowers authors and publishers with the Lean Publishing process. Lean Publishing is the act of publishing an in-progress ebook using lightweight tools and many iterations to get reader feedback, pivot until you have the right book and build traction once you do Ash Furrow

3 To my wife, my greatest inspiration.

4 Contents Introduction Xcode Basic Project App Delegate Storyboard View Controller Other Files

5 Introduction Congratulations! You ve bought my book and that s a great first step toward becoming a proficient ios developer. This chapter will give you a feet-first introduction to the ins and outs of the tools used to write ios apps. We re going to begin with Xcode, then move onto basic Objective-C syntax. We ll take a look at the app delegate and create a very, very small app to poke around. I m going to assume you have some basic knowledge of object-oriented programming. If you don t, Oracle (surprisingly) has a great description of OOP¹ to get you started. We re going to be building an application called Coffee Timer to help users make coffee and tea. Before we start anything, I d like to present the Application Definition Statement. Coffee Timer helps people time coffee and tea to brew delicious beverages. We re going to start out small and augment our application in each chapter until we have something worth submitting to the App Store. Let s get started. Xcode Xcode is the Integrated Development Environment we re going to use to build our apps. Install it from the App Store² and open it up. You ll see the welcome prompt. ¹ ²

6 Introduction 2 Xcode welcome prompt Click on Create a new Xcode project to get started. This will bring up the new project dialogue window.

7 Introduction 3 Xcode new project dialogue Make sure that Application under ios is selected in the left hand pane. We re going to use the Single View Application template. Xcode is going to ask us for some values. We ll give our app a name. This is going to be what s seen under the app icon on the home screen, so it s important to pick a great name. Don t worry you can change this later if you have to. This book is going to focus on writing a timer to help people make coffee, so we ll use the name Coffee Timer for our app. The name you choose for your application will affect some directory names, some class names, as well as the copyright notices at the beginning of your files. I use my name as an Organization Name. This does not affect anything in the App Store at all. A Company Identifier is a required field and the convention is to use a reverse DNS name for your website. My website is ashfurrow.com, so my company identifier is com.ashfurrow again, you can change this later, so don t fret too long. The goal here is just to get started! Additionally, you ll need a class prefix. Objective-C doesn t have namespaces, so it uses prefixes on all the classes. The convention is to use the abbreviation of either your name or the project. Prefixes should be three letters long, since Apple reserves all two-letter prefixes for their own use. We re

8 Introduction 4 going to use CTR (standing for Coffee TimeR ) for our prefix. Finally, select iphone as the device. I ve filled in these values as shown in the next figure. Creating our first project Save the project anywhere. If you want to use git³ to keep track of changes in your project, feel free to check the Create local git repository checkbox in the save dialogue. I won t be covering how to use git in this book. After saving, you ll have a (mostly) empty project. ³

9 Introduction 5 Newly created project Basic Project Awesome! Let s build and run the app. You can either hit the Run button with the Play symbol on it, or hit command-r to run the app. This will compile the code and install the app into the device specified in the Scheme drop down menu. For now, we re not going to worry about running the app on an actual device it s a very complicated process and you re better off diving into code as soon as possible. Just make sure iphone 6.X simulator is selected from the Scheme drop down menu. The Scheme drop down menu is located in the top bar of the Xcode window, to the right of the play and stop buttons. The app is shown here.

10 Introduction 6

11 Introduction 7 This is a pretty boring app so far, but it is an app. You can hit the home button in the simulator (command-shift-home) to see the Home Screen of the simulator and there s your app. Not bad! Let s go back to Xcode to explore the parts of an app that are created for you. App Delegate Take a look at the files list on the left hand side of the Xcode window. You ll see a bunch of files. Let s go through each one, one at a time. Open the Project Navigator (command-1). Project Navigator I should mention that classes in Objective-C are represented by two files: a header and an implementation. When I say header, I mean C header, if you re familiar with C. A header specifies the public methods and properties that other classes should have access to. An implementation file specifies the private properties, as well as the code that implements the object s methods. So when you see the first two files called CTRAppDelegate.h and CTRAppDelegate.m, these two files should be treated as representing different aspects of the same class. Open up the CTRAppDelegate.h file first and take a look.

12 Introduction 8 1 // 2 // CTRAppDelegate.h 3 // Coffee Timer 4 // 5 // Created by Ash Furrow on // Copyright (c) 2013 Ash Furrow. All rights reserved. 7 // 8 9 #import <UIKit/UIKit.h> 10 CTRAppDelegate : UIResponder <UIApplicationDelegate> 12 (strong, nonatomic) UIWindow *window; 14 The group of lines at the top, the comment, is a standard copyright notice Xcode inserts into each file you create. The next line is an #import statement. This imports other header files so we can reference the classes specified in them. This is a lot like #include in C, except you can #import a file more than once without any bad consequences. In this case, we ve imported UIKit/UIKit.h. UIKit is the framework for displaying user interfaces in ios apps. The <angle brackets> around the file mean that it s a library. We need this #import so we can access UIResponder, UIApplicationDelegate, and UIWindow later on. Next, we see the CTRAppDelegate : UIResponder <UIApplicationDelegate>. There are a lot of things going on here, so let s break it down a means that we re declaring the interface for a class. Doing so in a header file means that it s the public interface. The class name is what immediately follows; in our case, the class name is CTRAppDelegate. Next, there s a colon followed by UIResponder. UIResponder is the super class which CTRAppDelegate extends. I m not going to go into the specifics of what UIResponder is right now; just know that the app delegate extends UIResponder. Finally, in the angle brackets, you have UIApplicationDelegate. This is probably the most important part of the line. Inside the angle brackets specify which protocols the class conforms to. Protocols are like interfaces in other languages: they are a guarantee that this object will implement certain methods. Other classes using CTRAppDelegate can expect that it has certain methods. That s actually only mostly true. Protocols may specify optional methods, which is the case with UIApplicationDelegate. I ll discuss protocols in a later chapter and I ll describe what an application delegate is momentarily. First, let s take a look at the rest of the header file. The next line (strong, nonatomic) UIWindow *window;. This means that there is a property called window of a type UIWindow. strong means that it is owned by this class (we ll get into strong and weak keywords in Chapter 7. nonatomic has to do with concurrency. Since

13 Introduction 9 our application won t really be taking advantage of concurrency, using atomic properties would incur a slight overhead. All you need to know is that 99% of the time, when you declare a property referencing another object, it looks like this: (nonatomic, strong) ClassType *propertyname; Finally, there is line. This corresponds to at the beginning of the class. That s it you ve just examined your first Objective-C class! We now know that this is a class named CTRAppDelegate that extends UIResponder and conforms to the UIApplicationDelegate protocol, and that it has one public property called window. But what on Earth is an application delegate? An application delegate, or app delegate, is a special class used by the app. All apps have exactly one app delegate. The app delegate is responsible for being notified about certain important application events, like finishing launching or quitting. It s the job of the app delegate to let the rest of the app know when something important happens. Let s open up the implementation file, CTRAppDelegate.m, so you can see what I mean. These are the existing contents of CTRAppDelegate.m. 1 #import "CTRAppDelegate.h" 2 CTRAppDelegate (BOOL)application:(UIApplication *)application 6 didfinishlaunchingwithoptions:(nsdictionary *)launchoptions 7 { 8 // Override point for customization after application launch. 9 return YES; 10 } (I m omitting the copyright header for the rest of this book.) The first line #imports the header for the implementation file. This is standard for all implementation files. Next, we CTRAppDelegate. This starts the implementation for our object. Next, we have a list of empty methods that Xcode has stubbed out for us. Let s look at what a method looks like. 1 - (BOOL)application:(UIApplication *)application 2 didfinishlaunchingwithoptions:(nsdictionary *)launchoptions The dash means that the method belongs to an instance of the class and not that class itself (class methods have plus signs instead of dashes). In other languages, we d call this an instance method

14 Introduction 10 versus a static method. The value BOOL in between the (parentheses) specifies the return type of the method. The next part gets a little complicated. Objective-C methods mix the method name with the parameters, so you get sort of a named parameter effect. There are two colons in the method name, so there are two parameters. The names of the parameters are application and launchoptions, and their types are UIApplication and NSDictionary respectively. The method name is referenced to as application: didfinishlaunchingwithoptions:. It s a little complicated, but don t get too hung up on it. Later on, when we start to write our own methods and call them, it ll start to make sense. For now, take a look at the list of method names in the implementation file. application: didfinishlaunchingwithoptions: applicationwillresignactive: applicationdidenterbackground: applicationwillenterforeground: applicationdidbecomeactive: applicationwillterminate: Xcode will also have filled these in with descriptions of what each stub does. Application state is a little complicated. Once launched, an app is in the foreground until the user opens another app or returns to the Home Screen. Then it enters the background. From there, it stops executing until opened again, but it s still in memory. In the background, an application will either be returned to the foreground and become the active application again, or it will be terminated. These methods should all be fairly strait forward, except for maybe applicationwillresignactive:. This is called when an application is still in the foreground, but isn t actively being used by the user. The best example is when someone double-taps their Home Button to make the multitasking tray appear or when you recieve a phone call. The application is still in the foreground, but not actively responding to user events. Why would you care? Well, games and videos should pause and OpenGL should throttle down its frame rate. Other than that, it s not terribly important. So that s what an app delegate does out of the box: it responds to application events. For now, it won t matter much, but the app delegate is a central component of any application and deserves a good overview. Let s throw some logging information into the app and re-run it. Add the following logging information to your methods.

15 Introduction (BOOL)application:(UIApplication *)application 2 didfinishlaunchingwithoptions:(nsdictionary *)launchoptions 3 { 4 NSLog(@"Application has launched."); 5 6 return YES; 7 } (void)applicationwillresignactive:(uiapplication *)application 10 { 11 NSLog(@"Application has resigned active."); 12 } (void)applicationdidenterbackground:(uiapplication *)application 15 { 16 NSLog(@"Application has entered background."); 17 } (void)applicationwillenterforeground:(uiapplication *)application 20 { 21 NSLog(@"Application has entered foreground."); 22 } Re-run the app and play with it. Click the Home Button (command-shift-h). Double-click it. See how the application moves from foreground to background. Logging information will be displayed in the console, which will be opened for you when something is printed there.

16 Introduction 12 Logging console Storyboard Next comes the fun part: the Storyboard. The Storyboard visually lays out everything the user is going to see and interact with inside of your app. For now, the storyboard looks a little boring.

17 Introduction 13 Main Storyboard Your main storyboard is named MainStoryboard.storyboard in Xcode. Click it once to open it. The first thing I want you to do, and this is very important, is to open the File Inspector in the right hand pane (comand-alt-1) and find the checkbox labelled Use Autolayout to uncheck it. Autolayout is this hot new technology from Apple that s pretty complicated to use in practice, so we re going to stick with the older way of doing things for now. You ll thank me later. Feel free to explore around the Storyboard. Notice the buttons to zoom in and out. These will be handy once the Storyboard becomes larger. Notice the hierarchy of the Storyboard on the left hand side. You can hide it with the arrow on the left useful for developing on smaller screens. The View Controller is the parent of the View, as you might expect. Click on view controller in the hierarchy, then open the Identity inspector (command-alt-3). The Identity Inspect can also be shown by opening the View menu, then selecting Utilities and clicking Identity Inspector. What s that? The Custom Class is set as CTRViewController. Interesting that s the name of the other class Xcode created for us.

18 Introduction 14 View Controller In fact, when ios unpacks your Storyboard, it uses the value in the Custom Class to know which class to instantiate. Let s explore the view controller files, then we ll come back to how it interacts with the Storyboard. The CTRViewController.h file is pretty boring. CTRViewController : UIViewController 2 It has no public properties or methods. All it specifies is the superclass of our view controller, UIViewController. Let s take a look at the implementation file. CTRViewController () 2 4 CTRViewController (void)viewdidload 8 { 9 [super viewdidload]; 10 // Do any additional setup after loading the view, typically from a nib. 11 } (void)didreceivememorywarning 14 { 15 [super didreceivememorywarning]; 16 // Dispose of any resources that can be recreated. 17 } 18 Very interesting! We ve got a re-declaration of our interface. Since this is in the implementation file, this is where we ll put any private property declarations. We don t need to declare our private methods, a practice that s sometimes held over from the days of C. block in the implementation file is only for private properties. The implementation itself contains two method stubs: viewdidload and didreceivememorywarning. We ll ignore the latter and focus on the former. When the Storyboard wakes up to be shown to the user, it needs to load a view controller. The class it uses for that view controller is set by the Custom Class property in the Storyboard, like we saw

19 Introduction 15 earlier. Once the view controller loads the view, it calls viewdidload on the controller. This is the developer s opportunity to customize the view before it s first displayed to the user. Let me show you what I mean. Replace the viewdidload implementation with this one: 1 - (void)viewdidload 2 { 3 [super viewdidload]; 4 5 NSLog(@"View is loaded."); 6 7 self.view.backgroundcolor = [UIColor orangecolor]; 8 } This will add some logging and change the background colour of the view controller s view. Indeed, our console output looks like the following: 1 Coffee Timer[10054:c07] Application has launched. 2 Coffee Timer[10054:c07] View is loaded. And indeed, the background colour of the view is now orange.

20 Introduction 16

21 Introduction 17 Other Files Those are the main files that you ll work with 99% of the time in Xcode. However, you can open the Supporting Files folder in the Files pane to see some behind the scenes action. The Coffee Timer-Info.plist is the file that specifies a lot of the metadata about our app. These are values like our version number, which interface orientations we support, and the default language. You don t change these very often. We also have InfoPlist.strings. We ll talk more about this in Chapter 9, but it basically allows your app to have a different name in different languages. Next is super-interesting: main.m. If you re familiar with C, this is the main.c equivalent. 1 #import <UIKit/UIKit.h> 2 3 #import "CTRAppDelegate.h" 4 5 int main(int argc, char *argv[]) 6 { { 8 return UIApplicationMain(argc, argv, nil, 9 NSStringFromClass([CTRAppDelegate class])); 10 } 11 } You don t need to understand what s going on, but the gist is that the call to UIApplicationMain() starts your app and does not return until the application terminates. Next we have Coffee Timer-Prefix.pch. This is the precompiled header. It s basically a header file that s automatically #imported in every file. That means global C macros can be defined here. Finally, We have Default.png, Default@2x.png, and Default-568h@2x.png. These are the default, retina default, and tall screen retina default files, respectively. These are the launch images for the app and are black by default. That s it! You ve created your first Xcode project and explored every nook and cranny of it. It s not important to understand every piece we re going to do more in-depth exploring in the next chapter. What s important is that you re familiar with the over-arching concepts: what the app delegate is and what it s for, that views are laid out in the Storyboard, and that code to modify views goes in the view controller.

Building Mapping Apps for ios With Swift

Building Mapping Apps for ios With Swift Building Mapping Apps for ios With Swift Jeff Linwood This book is for sale at http://leanpub.com/buildingmappingappsforioswithswift This version was published on 2017-09-09 This is a Leanpub book. Leanpub

More information

1 Build Your First App. The way to get started is to quit talking and begin doing. Walt Disney

1 Build Your First App. The way to get started is to quit talking and begin doing. Walt Disney 1 Build Your First App The way to get started is to quit talking and begin doing. Walt Disney Copyright 2015 AppCoda Limited All rights reserved. Please do not distribute or share without permission. No

More information

My First iphone App (for Xcode version 6.4)

My First iphone App (for Xcode version 6.4) My First iphone App (for Xcode version 6.4) 1. Tutorial Overview In this tutorial, you re going to create a very simple application on the iphone or ipod Touch. It has a text field, a label, and a button

More information

src3/bettertextfield/bettertextfield/appdelegate.h // AppDelegate.h // BetterTextField

src3/bettertextfield/bettertextfield/appdelegate.h // AppDelegate.h // BetterTextField src3/bettertextfield/bettertextfield/appdelegate.h 1 1 1 1 AppDelegate.h BetterTextField Created by Tommy MacWilliam on 3/7/ Copyright (c) 2012 MyCompanyName. All rights reserved. #import

More information

Registering for the Apple Developer Program

Registering for the Apple Developer Program It isn t necessary to be a member of the Apple Developer Program if you don t intend to submit apps to the App Stores, or don t need the cloud-dependent features. We strongly recommend joining, though,

More information

Functional Reactive Programming on ios

Functional Reactive Programming on ios Functional Reactive Programming on ios Functional reactive programming introduction using ReactiveCocoa Ash Furrow This book is for sale at http://leanpub.com/iosfrp This version was published on 2016-05-28

More information

Document Version Date: 1st March, 2015

Document Version Date: 1st March, 2015 7 Minute Fitness: ios(swift) Application Document Version 1.0.1 Date: 1st March, 2015 2 [7 MINUTE FITNESS: APP DOCUMENTATION] Important Notes:... 5 AppDelegate Class Reference... 6 Tasks... 6 Instance

More information

iphone App Basics iphone and ipod touch Development Fall 2009 Lecture 5

iphone App Basics iphone and ipod touch Development Fall 2009 Lecture 5 iphone App Basics iphone and ipod touch Development Fall 2009 Lecture 5 Questions? Announcements Assignment #1 due this evening by 11:59pm Remember, if you wish to use a free late you must email me before

More information

My First iphone App. 1. Tutorial Overview

My First iphone App. 1. Tutorial Overview My First iphone App 1. Tutorial Overview In this tutorial, you re going to create a very simple application on the iphone or ipod Touch. It has a text field, a label, and a button. You can type your name

More information

CS193P: HelloPoly Walkthrough

CS193P: HelloPoly Walkthrough CS193P: HelloPoly Walkthrough Overview The goal of this walkthrough is to give you a fairly step by step path through building a simple Cocoa Touch application. You are encouraged to follow the walkthrough,

More information

Learn to make desktop LE

Learn to make desktop LE HACKING WITH SWIFT COMPLETE TUTORIAL COURSE Learn to make desktop LE P apps with real-worldam S Swift projects REEPaul Hudson F Project 1 Storm Viewer Get started coding in Swift by making an image viewer

More information

iphone Programming Touch, Sound, and More! Norman McEntire Founder Servin Flashlight CodeTour TouchCount CodeTour

iphone Programming Touch, Sound, and More! Norman McEntire Founder Servin Flashlight CodeTour TouchCount CodeTour iphone Programming Touch, Sound, and More! Norman McEntire Founder Servin 1 Legal Info iphone is a trademark of Apple Inc. Servin is a trademark of Servin Corporation 2 Welcome Welcome! Thank you! My promise

More information

iphone Programming Patrick H. Madden SUNY Binghamton Computer Science Department

iphone Programming Patrick H. Madden SUNY Binghamton Computer Science Department iphone Programming Patrick H. Madden SUNY Binghamton Computer Science Department pmadden@acm.org http://optimal.cs.binghamton.edu General Outline Overview of the tools, and where to get more information

More information

Object-Oriented Programming in Objective-C

Object-Oriented Programming in Objective-C In order to build the powerful, complex, and attractive apps that people want today, you need more complex tools than a keyboard and an empty file. In this section, you visit some of the concepts behind

More information

The name of our class will be Yo. Type that in where it says Class Name. Don t hit the OK button yet.

The name of our class will be Yo. Type that in where it says Class Name. Don t hit the OK button yet. Mr G s Java Jive #2: Yo! Our First Program With this handout you ll write your first program, which we ll call Yo. Programs, Classes, and Objects, Oh My! People regularly refer to Java as a language that

More information

Navigation bar (Xcode version 4.5.2) 1. Create a new project. From the Xcode menu, select File > New > Project

Navigation bar (Xcode version 4.5.2) 1. Create a new project. From the Xcode menu, select File > New > Project Navigation bar (Xcode version 4.5.2) 1. Create a new project. From the Xcode menu, select File > New > Project Choose the Single View Application template Click Next. In the Choose options for your new

More information

Social Pinboard: ios(swift) Application

Social Pinboard: ios(swift) Application Social Pinboard: ios(swift) Application Document Version 1.0.1 Date: 15 th May, 2015 2 [SOCIAL PINBOARD: APP DOCUMENTATION] Important Notes:... 5 AppDelegate Class Reference... 6 Tasks... 6 Instance Methods...

More information

My First Cocoa Program

My First Cocoa Program My First Cocoa Program 1. Tutorial Overview In this tutorial, you re going to create a very simple Cocoa application for the Mac. Unlike a line-command program, a Cocoa program uses a graphical window

More information

Beginning Mac Programming

Beginning Mac Programming Extracted from: Beginning Mac Programming Develop with Objective-C and Cocoa This PDF file contains pages extracted from Beginning Mac Programming, published by the Pragmatic Bookshelf. For more information

More information

S A M P L E C H A P T E R

S A M P L E C H A P T E R SAMPLE CHAPTER Anyone Can Create an App by Wendy L. Wise Chapter 2 Copyright 2017 Manning Publications brief contents PART 1 YOUR VERY FIRST APP...1 1 Getting started 3 2 Building your first app 14 3 Your

More information

Hello! ios Development

Hello! ios Development SAMPLE CHAPTER Hello! ios Development by Lou Franco Eitan Mendelowitz Chapter 1 Copyright 2013 Manning Publications Brief contents PART 1 HELLO! IPHONE 1 1 Hello! iphone 3 2 Thinking like an iphone developer

More information

imate: ios Application

imate: ios Application imate: ios Application Document Version 1.0.1 Date: 27 th May, 2014 2 [IMATE: IOS APPLICATION] Contents AppDelegate Class Reference... 4 Tasks... 4 Properties... 4 Instance Methods... 4 ChatMenuViewController

More information

lecture 10 UI/UX and Programmatic Design cs : spring 2018

lecture 10 UI/UX and Programmatic Design cs : spring 2018 lecture 10 UI/UX and Programmatic Design cs198-001 : spring 2018 1 Announcements custom app progress form due before lab (~1 minute) will be released after lecture only 2 labs left (both very important)

More information

Learn to make ios apps

Learn to make ios apps HACKING WITH SWIFT PROJECTS 1-39 Learn to make ios apps E L P with real projects SAM E E FR Paul Hudson Project 1 Storm Viewer Get started coding in Swift by making an image viewer app and learning key

More information

Java Program Structure and Eclipse. Overview. Eclipse Projects and Project Structure. COMP 210: Object-Oriented Programming Lecture Notes 1

Java Program Structure and Eclipse. Overview. Eclipse Projects and Project Structure. COMP 210: Object-Oriented Programming Lecture Notes 1 COMP 210: Object-Oriented Programming Lecture Notes 1 Java Program Structure and Eclipse Robert Utterback In these notes we talk about the basic structure of Java-based OOP programs and how to setup and

More information

Learn Linux in a Month of Lunches by Steven Ovadia

Learn Linux in a Month of Lunches by Steven Ovadia Learn Linux in a Month of Lunches by Steven Ovadia Sample Chapter 17 Copyright 2017 Manning Publications brief contents PART 1 GETTING LINUX UP AND RUNNING... 1 1 Before you begin 3 2 Getting to know Linux

More information

News- ipad: ios(swift) Application

News- ipad: ios(swift) Application News- ipad: ios(swift) Application Document Version 1.0.1 Date: 9 th Nov, 2014 2 [NEWS- IPAD: APP DOCUMENTATION] Important Notes:... 6 AppDelegate Class Reference... 7 Tasks... 7 Instance Methods... 7

More information

My First Command-Line Program

My First Command-Line Program 1. Tutorial Overview My First Command-Line Program In this tutorial, you re going to create a very simple command-line application that runs in a window. Unlike a graphical user interface application where

More information

COMP327 Mobile Computing Session: Lecture Set 1a - Swift Introduction and the Foundation Framework Part 2

COMP327 Mobile Computing Session: Lecture Set 1a - Swift Introduction and the Foundation Framework Part 2 COMP327 Mobile Computing Session: 2018-2019 Lecture Set 1a - Swift Introduction and the Foundation Framework Part 2 73 Other Swift Guard Already seen that for optionals it may be necessary to test that

More information

The MVC Design Pattern

The MVC Design Pattern The MVC Design Pattern The structure of iphone applications is based on the Model-View-Controller (MVC) design pattern because it benefits object-oriented programs in several ways. MVC based programs tend

More information

Cocoa Programming A Quick-Start Guide for Developers

Cocoa Programming A Quick-Start Guide for Developers Extracted from: Cocoa Programming A Quick-Start Guide for Developers This PDF file contains pages extracted from Cocoa Programming, published by the Pragmatic Bookshelf. For more information or to purchase

More information

Lesson 10A OOP Fundamentals. By John B. Owen All rights reserved 2011, revised 2014

Lesson 10A OOP Fundamentals. By John B. Owen All rights reserved 2011, revised 2014 Lesson 10A OOP Fundamentals By John B. Owen All rights reserved 2011, revised 2014 Table of Contents Objectives Definition Pointers vs containers Object vs primitives Constructors Methods Object class

More information

This book is about using Visual Basic for Applications (VBA), which is a

This book is about using Visual Basic for Applications (VBA), which is a In This Chapter Describing Access Discovering VBA Seeing where VBA lurks Understanding how VBA works Chapter 1 Where VBA Fits In This book is about using Visual Basic for Applications (VBA), which is a

More information

In the first class, you'll learn how to create a simple single-view app, following a 3-step process:

In the first class, you'll learn how to create a simple single-view app, following a 3-step process: Class 1 In the first class, you'll learn how to create a simple single-view app, following a 3-step process: 1. Design the app's user interface (UI) in Xcode's storyboard. 2. Open the assistant editor,

More information

Appeasing the Tiki Gods

Appeasing the Tiki Gods Chapter 2 Appeasing the Tiki Gods As you re probably well aware, it has become something of a tradition to call the first project in any book on programming Hello, World. We considered breaking with this

More information

SharePoint 2010 Site Owner s Manual by Yvonne M. Harryman

SharePoint 2010 Site Owner s Manual by Yvonne M. Harryman SharePoint 2010 Site Owner s Manual by Yvonne M. Harryman Chapter 9 Copyright 2012 Manning Publications Brief contents PART 1 GETTING STARTED WITH SHAREPOINT 1 1 Leveraging the power of SharePoint 3 2

More information

Docker for Sysadmins: Linux Windows VMware

Docker for Sysadmins: Linux Windows VMware Docker for Sysadmins: Linux Windows VMware Getting started with Docker from the perspective of sysadmins and VM admins Nigel Poulton This book is for sale at http://leanpub.com/dockerforsysadmins This

More information

due by noon ET on Wed 4/4 Note that submitting this project s Google form will take some time; best not to wait until the last minute!

due by noon ET on Wed 4/4 Note that submitting this project s Google form will take some time; best not to wait until the last minute! ios: Setup Hello, World: ios Edition due by noon ET on Wed 4/4 Note that submitting this project s Google form will take some time; best not to wait until the last minute! Ingredients. Objective- C Xcode

More information

Programming for Kids

Programming for Kids Programming for Kids Peter Armstrong This book is for sale at http://leanpub.com/programmingforkids This version was published on 2016-05-08 This is a Leanpub book. Leanpub empowers authors and publishers

More information

Structuring an App Copyright 2013 Apple Inc. All Rights Reserved.

Structuring an App Copyright 2013 Apple Inc. All Rights Reserved. Structuring an App App Development Process (page 30) Designing a User Interface (page 36) Defining the Interaction (page 42) Tutorial: Storyboards (page 47) 29 App Development Process Although the task

More information

Programming Robots with ROS, Morgan Quigley, Brian Gerkey & William D. Smart

Programming Robots with ROS, Morgan Quigley, Brian Gerkey & William D. Smart Programming Robots with ROS, Morgan Quigley, Brian Gerkey & William D. Smart O Reilly December 2015 CHAPTER 23 Using C++ in ROS We chose to use Python for this book for a number of reasons. First, it s

More information

S A M P L E C H A P T E R

S A M P L E C H A P T E R SAMPLE CHAPTER Anyone Can Create an App by Wendy L. Wise Chapter 5 Copyright 2017 Manning Publications brief contents PART 1 YOUR VERY FIRST APP...1 1 Getting started 3 2 Building your first app 14 3 Your

More information

ios 9 SDK Development

ios 9 SDK Development Extracted from: ios 9 SDK Development Creating iphone and ipad Apps with Swift This PDF file contains pages extracted from ios 9 SDK Development, published by the Pragmatic Bookshelf. For more information

More information

Azure Developer Immersion Getting Started

Azure Developer Immersion Getting Started Azure Developer Immersion Getting Started In this walkthrough, you will get connected to Microsoft Azure and Visual Studio Team Services. You will also get the code and supporting files you need onto your

More information

lectures/2/src2/nib1/nib1/appdelegate.h // AppDelegate.h // Nib1 // David J. Malan // Harvard University //

lectures/2/src2/nib1/nib1/appdelegate.h // AppDelegate.h // Nib1 // David J. Malan // Harvard University // lectures/2/src2/nib1/nib1/appdelegate.h 1 1 1 1 1 1 1 1 1 2 AppDelegate.h Nib1 David J. Malan Harvard University malan@harvard.edu Demonstrates a Single View Application implemented with a nib, plus IBAction

More information

Computer Basics: Step-by-Step Guide (Session 2)

Computer Basics: Step-by-Step Guide (Session 2) Table of Contents Computer Basics: Step-by-Step Guide (Session 2) ABOUT PROGRAMS AND OPERATING SYSTEMS... 2 THE WINDOWS 7 DESKTOP... 3 TWO WAYS TO OPEN A PROGRAM... 4 DESKTOP ICON... 4 START MENU... 5

More information

Produced by. Design Patterns. MSc in Computer Science. Eamonn de Leastar

Produced by. Design Patterns. MSc in Computer Science. Eamonn de Leastar Design Patterns MSc in Computer Science Produced by Eamonn de Leastar (edeleastar@wit.ie) Department of Computing, Maths & Physics Waterford Institute of Technology http://www.wit.ie http://elearning.wit.ie

More information

This is a book about using Visual Basic for Applications (VBA), which is a

This is a book about using Visual Basic for Applications (VBA), which is a 01b_574116 ch01.qxd 7/27/04 9:04 PM Page 9 Chapter 1 Where VBA Fits In In This Chapter Describing Access Discovering VBA Seeing where VBA lurks Understanding how VBA works This is a book about using Visual

More information

COMPLETE TUTORIAL COURSE. Learn to make tvos LE. apps with real-worldam S F

COMPLETE TUTORIAL COURSE. Learn to make tvos LE. apps with real-worldam S F HACKING WITH SWIFT COMPLETE TUTORIAL COURSE Learn to make tvos LE P apps with real-worldam S Swift projects REEPaul Hudson F Project 1 Randomly Beautiful 2 www.hackingwithswift.com Setting up In this first

More information

COPYRIGHTED MATERIAL. 1Hello ios! A Suitable Mac. ios Developer Essentials

COPYRIGHTED MATERIAL. 1Hello ios! A Suitable Mac. ios Developer Essentials 1Hello ios! Hello and welcome to the exciting world of ios application development. ios is Apple s operating system for mobile devices; the current version as of writing this book is 5.0. It was originally

More information

Developing Applications for ios

Developing Applications for ios Developing Applications for ios Lab 2: RPN Calculator App (1 of 3) Radu Ionescu raducu.ionescu@gmail.com Faculty of Mathematics and Computer Science University of Bucharest Task 1 Task: Create a new application

More information

Stanford CS193p. Developing Applications for ios Fall Stanford CS193p. Fall 2013

Stanford CS193p. Developing Applications for ios Fall Stanford CS193p. Fall 2013 Developing Applications for ios -14 Today What is this class all about? Description Prerequisites Homework / Final Project ios Overview What s in ios? MVC Object-Oriented Design Concept Objective C (Time

More information

Arduino IDE Friday, 26 October 2018

Arduino IDE Friday, 26 October 2018 Arduino IDE Friday, 26 October 2018 12:38 PM Looking Under The Hood Of The Arduino IDE FIND THE ARDUINO IDE DOWNLOAD First, jump on the internet with your favorite browser, and navigate to www.arduino.cc.

More information

It s possible to get your inbox to zero and keep it there, even if you get hundreds of s a day.

It s possible to get your  inbox to zero and keep it there, even if you get hundreds of  s a day. It s possible to get your email inbox to zero and keep it there, even if you get hundreds of emails a day. It s not super complicated, though it does take effort and discipline. Many people simply need

More information

Learn to make watchosle

Learn to make watchosle HACKING WITH SWIFT COMPLETE TUTORIAL COURSE Learn to make watchosle P apps with real-worldam S Swift projects REEPaul Hudson F Project 1 NoteDictate 2 www.hackingwithswift.com Setting up In this project

More information

XP: Backup Your Important Files for Safety

XP: Backup Your Important Files for Safety XP: Backup Your Important Files for Safety X 380 / 1 Protect Your Personal Files Against Accidental Loss with XP s Backup Wizard Your computer contains a great many important files, but when it comes to

More information

If Statements, For Loops, Functions

If Statements, For Loops, Functions Fundamentals of Programming If Statements, For Loops, Functions Table of Contents Hello World Types of Variables Integers and Floats String Boolean Relational Operators Lists Conditionals If and Else Statements

More information

Git Workbook. Self-Study Guide to Git. Lorna Mitchell. This book is for sale at

Git Workbook. Self-Study Guide to Git. Lorna Mitchell. This book is for sale at Git Workbook Self-Study Guide to Git Lorna Mitchell This book is for sale at http://leanpub.com/gitworkbook This version was published on 2018-01-15 This is a Leanpub book. Leanpub empowers authors and

More information

Essay & Assignment Preparation using MindGenius

Essay & Assignment Preparation using MindGenius Essay & Assignment Preparation using MindGenius This workshop is aimed at those of you who struggle gathering and sorting information when beginning to write an essay. Using MindGenius you can plan essays

More information

Importing source database objects from a database

Importing source database objects from a database Importing source database objects from a database We are now at the point where we can finally import our source database objects, source database objects. We ll walk through the process of importing from

More information

A. Outlook Web App -

A. Outlook Web App - A. Outlook Web App - Email 1. Outlook Web App (OWA) Vs. Outlook Outlook refers to an application that is physically installed on a computer. Whereas a Web Application is something that is not installed

More information

Installing and getting started with Xcode for Mac OS.

Installing and getting started with Xcode for Mac OS. Installing and getting started with Xcode for Mac OS. 1. Go to the Mac App store. Do a search for Xcode. Then download and install it. (It s free.) Give it some time it may take a while. (A recent update

More information

Access Intermediate

Access Intermediate Access 2013 - Intermediate 103-134 Advanced Queries Quick Links Overview Pages AC124 AC125 Selecting Fields Pages AC125 AC128 AC129 AC131 AC238 Sorting Results Pages AC131 AC136 Specifying Criteria Pages

More information

Term Definition Introduced in: This option, located within the View tab, provides a variety of options to choose when sorting and grouping Arrangement

Term Definition Introduced in: This option, located within the View tab, provides a variety of options to choose when sorting and grouping Arrangement 60 Minutes of Outlook Secrets Term Definition Introduced in: This option, located within the View tab, provides a variety of options to choose when sorting and grouping Arrangement messages. Module 2 Assign

More information

IAT 445 Lab 10. Special Topics in Unity. Lanz Singbeil

IAT 445 Lab 10. Special Topics in Unity. Lanz Singbeil IAT 445 Lab 10 Special Topics in Unity Special Topics in Unity We ll be briefly going over the following concepts. They are covered in more detail in your Watkins textbook: Setting up Fog Effects and a

More information

Welcome To Account Manager 2.0

Welcome To Account Manager 2.0 Account Manager 2.0 Manage Unlimited FileMaker Servers, Databases, Privileges, and Users Effortlessly! The ultimate tool for FileMaker Database Administrators. Welcome To Account Manager 2.0 What Is Account

More information

Getting Started. 1 by Conner Irwin

Getting Started. 1 by Conner Irwin If you are a fan of the.net family of languages C#, Visual Basic, and so forth and you own a copy of AGK, then you ve got a new toy to play with. The AGK Wrapper for.net is an open source project that

More information

printf( Please enter another number: ); scanf( %d, &num2);

printf( Please enter another number: ); scanf( %d, &num2); CIT 593 Intro to Computer Systems Lecture #13 (11/1/12) Now that we've looked at how an assembly language program runs on a computer, we're ready to move up a level and start working with more powerful

More information

CS193E: Temperature Converter Walkthrough

CS193E: Temperature Converter Walkthrough CS193E: Temperature Converter Walkthrough The goal of this walkthrough is to give you a fairly step by step path through building a simple Cocoa application. You are encouraged to follow the walkthrough,

More information

CIS 45, The Introduction. What is a database? What is data? What is information?

CIS 45, The Introduction. What is a database? What is data? What is information? CIS 45, The Introduction I have traveled the length and breadth of this country and talked with the best people, and I can assure you that data processing is a fad that won t last out the year. The editor

More information

Intro. Scheme Basics. scm> 5 5. scm>

Intro. Scheme Basics. scm> 5 5. scm> Intro Let s take some time to talk about LISP. It stands for LISt Processing a way of coding using only lists! It sounds pretty radical, and it is. There are lots of cool things to know about LISP; if

More information

Kotlin for Android Developers

Kotlin for Android Developers Kotlin for Android Developers Learn Kotlin the easy way while developing an Android App Antonio Leiva This book is for sale at http://leanpub.com/kotlin-for-android-developers This version was published

More information

Oracle Cloud. Content and Experience Cloud Android Mobile Help E

Oracle Cloud. Content and Experience Cloud Android Mobile Help E Oracle Cloud Content and Experience Cloud Android Mobile Help E82091-01 Februrary 2017 Oracle Cloud Content and Experience Cloud Android Mobile Help, E82091-01 Copyright 2017, Oracle and/or its affiliates.

More information

iphone Application Tutorial

iphone Application Tutorial iphone Application Tutorial 2008-06-09 Apple Inc. 2008 Apple Inc. All rights reserved. No part of this publication may be reproduced, stored in a retrieval system, or transmitted, in any form or by any

More information

1. Introduction EE108A. Lab 1: Combinational Logic: Extension of the Tic Tac Toe Game

1. Introduction EE108A. Lab 1: Combinational Logic: Extension of the Tic Tac Toe Game EE108A Lab 1: Combinational Logic: Extension of the Tic Tac Toe Game 1. Introduction Objective This lab is designed to familiarize you with the process of designing, verifying, and implementing a combinational

More information

MAXQDA and Chapter 9 Coding Schemes

MAXQDA and Chapter 9 Coding Schemes MAXQDA and Chapter 9 Coding Schemes Chapter 9 discusses how the structures of coding schemes, alternate groupings are key to moving forward with analysis. The nature and structures of the coding scheme

More information

AVAudioPlayer. avtouch Application

AVAudioPlayer. avtouch Application AVAudioPlayer avtouch Application iphone Application Index 1. iphone Application 1) iphone Application 2) iphone Application Main Method 3) iphone Application nib(.xib) 2. avtouch Application 1) avtouch

More information

Essay & Assignment Preparation using MindGenius

Essay & Assignment Preparation using MindGenius Essay & Assignment Preparation using MindGenius This workshop is aimed at those of you who struggle gathering and sorting information when beginning to write an essay. Using MindGenius you can plan essays

More information

CS354 gdb Tutorial Written by Chris Feilbach

CS354 gdb Tutorial Written by Chris Feilbach CS354 gdb Tutorial Written by Chris Feilbach Purpose This tutorial aims to show you the basics of using gdb to debug C programs. gdb is the GNU debugger, and is provided on systems that

More information

Lecture 05 I/O statements Printf, Scanf Simple statements, Compound statements

Lecture 05 I/O statements Printf, Scanf Simple statements, Compound statements Programming, Data Structures and Algorithms Prof. Shankar Balachandran Department of Computer Science and Engineering Indian Institute of Technology, Madras Lecture 05 I/O statements Printf, Scanf Simple

More information

Setting Up Your ios Development Environment. For Mac OS X (Mountain Lion) v1.0. By GoNorthWest. 5 February 2013

Setting Up Your ios Development Environment. For Mac OS X (Mountain Lion) v1.0. By GoNorthWest. 5 February 2013 Setting Up Your ios Development Environment For Mac OS X (Mountain Lion) v1.0 By GoNorthWest 5 February 2013 Setting up the Apple ios development environment, which consists of Xcode and the ios SDK (Software

More information

Objective-C. Stanford CS193p Fall 2013

Objective-C. Stanford CS193p Fall 2013 New language to learn! Strict superset of C Adds syntax for classes, methods, etc. A few things to think differently about (e.g. properties, dynamic binding) Most important concept to understand today:

More information

Lab: Supplying Inputs to Programs

Lab: Supplying Inputs to Programs Steven Zeil May 25, 2013 Contents 1 Running the Program 2 2 Supplying Standard Input 4 3 Command Line Parameters 4 1 In this lab, we will look at some of the different ways that basic I/O information can

More information

Shorthand for values: variables

Shorthand for values: variables Chapter 2 Shorthand for values: variables 2.1 Defining a variable You ve typed a lot of expressions into the computer involving pictures, but every time you need a different picture, you ve needed to find

More information

ios Mobile Development

ios Mobile Development ios Mobile Development Today UITextView Scrollable, editable/selectable view of a mutable attributed string. View Controller Lifecycle Finding out what s happening as a VC is created, hooked up to the

More information

How to approach a computational problem

How to approach a computational problem How to approach a computational problem A lot of people find computer programming difficult, especially when they first get started with it. Sometimes the problems are problems specifically related to

More information

Mount Points Mount Points is a super simple tool for connecting objects together and managing those relationships.

Mount Points Mount Points is a super simple tool for connecting objects together and managing those relationships. Mount Points Mount Points is a super simple tool for connecting objects together and managing those relationships. With Mount Points, you can simply drag two objects together and when their mount points

More information

Application Development in ios 7

Application Development in ios 7 Application Development in ios 7 Kyle Begeman Chapter No. 1 "Xcode 5 A Developer's Ultimate Tool" In this package, you will find: A Biography of the author of the book A preview chapter from the book,

More information

The Laravel Survival Guide

The Laravel Survival Guide The Laravel Survival Guide Tony Lea This book is for sale at http://leanpub.com/laravelsurvivalguide This version was published on 2016-09-12 This is a Leanpub book. Leanpub empowers authors and publishers

More information

IOS - TEXT FIELD. Use of Text Field. Important Properties of Text Field. Updating Properties in xib

IOS - TEXT FIELD. Use of Text Field. Important Properties of Text Field. Updating Properties in xib IOS - TEXT FIELD http://www.tutorialspoint.com/ios/ios_ui_elements_text_field.htm Copyright tutorialspoint.com Use of Text Field A text field is a UI element that enables the app to get user input. A UITextfield

More information

Your First iphone Application

Your First iphone Application Your First iphone Application General 2009-01-06 Apple Inc. 2009 Apple Inc. All rights reserved. No part of this publication may be reproduced, stored in a retrieval system, or transmitted, in any form

More information

View Controller Lifecycle

View Controller Lifecycle View Controller Lifecycle View Controllers have a Lifecycle A sequence of messages is sent to them as they progress through it Why does this matter? You very commonly override these methods to do certain

More information

Your First Windows Form

Your First Windows Form Your First Windows Form From now on, we re going to be creating Windows Forms Applications, rather than Console Applications. Windows Forms Applications make use of something called a Form. The Form is

More information

Using GitHub to Share with SparkFun a

Using GitHub to Share with SparkFun a Using GitHub to Share with SparkFun a learn.sparkfun.com tutorial Available online at: http://sfe.io/t52 Contents Introduction Gitting Started Forking a Repository Committing, Pushing and Pulling Syncing

More information

Access Intermediate

Access Intermediate Access 2010 - Intermediate 103-134 Advanced Queries Quick Links Overview Pages AC116 AC117 Selecting Fields Pages AC118 AC119 AC122 Sorting Results Pages AC125 AC126 Specifying Criteria Pages AC132 AC134

More information

Lab 9: Pointers and arrays

Lab 9: Pointers and arrays CMSC160 Intro to Algorithmic Design Blaheta Lab 9: Pointers and arrays 3 Nov 2011 As promised, we ll spend today working on using pointers and arrays, leading up to a game you ll write that heavily involves

More information

How to Get Your Inbox to Zero Every Day

How to Get Your Inbox to Zero Every Day How to Get Your Inbox to Zero Every Day MATT PERMAN WHATSBESTNEXT.COM It s possible to get your email inbox to zero and keep it there, even if you get hundreds of emails a day. It s not super complicated,

More information

CS664 Compiler Theory and Design LIU 1 of 16 ANTLR. Christopher League* 17 February Figure 1: ANTLR plugin installer

CS664 Compiler Theory and Design LIU 1 of 16 ANTLR. Christopher League* 17 February Figure 1: ANTLR plugin installer CS664 Compiler Theory and Design LIU 1 of 16 ANTLR Christopher League* 17 February 2016 ANTLR is a parser generator. There are other similar tools, such as yacc, flex, bison, etc. We ll be using ANTLR

More information

SharePoint 2013 Site Owner

SharePoint 2013 Site Owner SharePoint 2013 Site Owner Effective Content and Document Collaboration with Axalta Teams 9 May 2014 Instructor: Jason Christie Site Owner Course Topics to be Covered Content Management Creating and configuring

More information

CMSC 201 Fall 2016 Lab 09 Advanced Debugging

CMSC 201 Fall 2016 Lab 09 Advanced Debugging CMSC 201 Fall 2016 Lab 09 Advanced Debugging Assignment: Lab 09 Advanced Debugging Due Date: During discussion Value: 10 points Part 1: Introduction to Errors Throughout this semester, we have been working

More information