Barcodes with iOS - Oliver Drobnik

Barcodes with iOS

Bringing together the digital and physical worlds

(Autor)

Buch | Softcover
248 Seiten
2015
Manning Publications (Verlag)
978-1-61729-215-6 (ISBN)
38,40 inkl. MwSt
  • Titel ist leider vergriffen;
    keine Neuauflage
  • Artikel merken
Barcodes with iOS is the first and only book that comprehensively addresses barcode technology for the iOS developer. It offers an introduction to commonly used formats, such as ISBN and UPC codes, and provides real-world examples that teach you how to integrate code scanning and generation into your apps. This book consolidates information about applicable Apple frameworks in one place so you can quickly add native barcode support to your existing enterprise apps or start building new apps that help bring together the physical and digital worlds.
Barcodes have been on product packaging for 40 years. As long as there are physical products sold, barcodes will continue to be used because of the maturity and inexpensiveness of the technology. Apple added into the latest release of their mobile iOS operating system all the necessary technologies needed to work with barcodes. For the first time, developers can now make apps that scan barcodes and print them on displays or paper, without needing to license complicated or expensive third-party code libraries.

Barcodes are a universally-accepted way to track and share information about products, applications, and businesses. Until recently, however, it's been difficult for iOS developers to take advantage of them without licensing complicated or expensive third-party libraries.

With iOS7, Apple has added all the necessary components to make apps that scan, display, and print barcodes. Barcodes with iOS 7 is the first and only book that comprehensively addresses barcode technology for the iOS developer. It introduces commonly used formats, such as ISBN and UPC codes and provides real world examples that show how to integrate code scanning and generation into apps.

This book consolidates information about applicable Apple frameworks in one place so readers can quickly add native barcode support to their existing enterprise apps or start building new apps that help bring together the physical and digital worlds.
The topic of barcodes serves as the common thread running through the chapters of this book, but you can dive into specific chapters to learn about particular technologies. Here’s a quick overview of what you will find in each of the chapters.

Chapter 1 introduces you to the barcode types that are natively supported starting with iOS 7. You’ll become a barcode guru and be able to hold your own in any conversation about barcodes, their promises, and their limitations. If you like a good story, flip to appendix A, which recounts the curious history of the mother of all barcodes: the UPC.

Chapter 2 gives you a solid introduction to AV Foundation media capture. You’ll become familiar with the components of this framework, which we’ll use to build a camera app.

Chapter 3 introduces you to the metadata detectors for scanning barcodes, building on the camera preview from chapter 2. At this point, you’ll have a reusable barcode scanner that you can employ in all your apps.

Chapter 4 deals with Apple’s main reason for pushing forward with barcode support in iOS: Passbook. You’ll learn how to generate Passbook tickets with Ruby and how to validate them in an iOS app without the need for server infrastructure.

Chapter 5 looks at how you can generate your own barcodes for display on devices and how you can print them to physical media via AirPrint. You’ll learn about the use of Core Image for generating QR Codes and BarCodeKit for all kinds of 1D barcodes.

Chapter 6 dives into retrieving metadata for scanned barcodes, in particular how to use NSURLSession for creating a web service wrapper. The second half of this chapter is about creating a custom NSURLProtocol and how to stub network requests for unit testing without the need to call an actual server over the internet.

Chapter 7 then rounds out the book by adding contextual information about the user who’s scanning barcodes. Core Location and iBeacons let you magically adapt your app’s UI to your user’s needs.

Three appendixes provide additional background and other useful information.

This book is written for readers with a working knowledge of Objective-C and iOS app development.

Oliver Drobnik is a full time iOS and Mac developer. He runs a software development company and maintains several well-known Open Source projects.

preface
acknowledgments
about this book
about the cover illustration

1 Barcodes, iOS, and you
1.1 The evolution of barcodes
1.2 Barcode symbologies in iOS
1.3 Summary 16
2 Media capture with AV Foundation
2.1 Introducing AV Foundation
2.2 Building a camera app
2.3 Summary
3 Scanning barcodes
3.1 Metadata detection in AV Foundation
3.2 Building a QR Code scanner
3.3 Summary
4 Passbook, Apple’s digital wallet
4.1 Barcodes in Passbook
4.2 Producing digital passes for your users
4.3 Validating passes
4.4 Summary
5 Generating barcodes
5.1 Producing barcodes for display or print
5.2 Generating 2D barcodes
5.3 Generating 1D barcodes
5.4 Summary
6 Getting metadata for barcodes
6.1 Modern networking with NSURLSession
6.2 Unit-testing network operations
6.3 Summary
7 Putting barcodes in context
7.1 Understanding multiple layers of context
7.2 Building a YardSale app
7.3 Geofencing store locations
7.4 Enhancing the in-store UI with iBeacons
7.5 Summary

appendix A History of the UPC
appendix B GTIN prefix ranges
appendix C GS1-128 application identifiers
index

When Apple released the first beta of iOS 7 at WWDC 2013, I scoured through the API changes looking for anything out of the ordinary. That’s when I noticed the unexpected addition of new APIs pertaining to barcodes. At that time, barcodes were little more than visual noise to me, a necessity of modern commerce but of no value to me as a consumer or app developer. Why would Apple devote precious resources to implementing functionality for that? Several third-party libraries for barcode scanning were available at that time. Some were commercial offerings too expensive for casual use. Others were open source projects requiring a great deal of work to understand or implement in your own apps. By adding support for barcodes within the iOS SDK, Apple made the technology accessible to all developers equally. Apple was sending a message: barcodes are important to us. This paradigm shift inspired me to learn all I could about barcode technologies. I began to research the barcode types supported by iOS and their capabilities and limitations, and all the new related iOS APIs. A mere month after WWDC 2013, I was contacted by Manning. They’d found me via my blog (cocoanetics.com) and inquired if I would be interested in writing an iOS book for them. They could not have contacted me at a more perfect moment! I was willing, able, and inspired to write, for more than a year, the book you’re now holding. June 2014 marked the 40-year anniversary of the first barcode being scanned at a point of sale. In other words, barcodes are a nearly ubiquitous, mature technology. The UPC you’ll find on all products sold in your supermarket was just the beginning. Just look at any Apple product box. You’ll find several barcodes on the stickers offering additional information such as the device’s serial number. Since October 2013, all iPhones can be used to scan barcodes. Together with always-on mobile internet and built-in device sensors, this enables a new breed of product-centric apps that weren’t feasible before. After reading this book, you’ll be able to build the exciting new apps that are bringing together the digital and physical worlds.

This book is intended for intermediate-level iOS developers who know their way around Xcode and have built a few apps already. This allows me to provide instructions in a terse, tutorial-like style, as readers of my blog, cocoanetics.com, have come to appreciate. By focusing on a more experienced audience, I don’t have to waste your time with iOS development basics that are well covered in other books.

Verlagsort New York
Sprache englisch
Maße 189 x 235 mm
Gewicht 436 g
Einbandart kartoniert
Themenwelt Informatik Programmiersprachen / -werkzeuge Mac / Cocoa Programmierung
Mathematik / Informatik Informatik Web / Internet
Informatik Weitere Themen Smartphones / Tablets
Schlagworte Apple iOS • Barcodes • iOS 7
ISBN-10 1-61729-215-X / 161729215X
ISBN-13 978-1-61729-215-6 / 9781617292156
Zustand Neuware
Haben Sie eine Frage zum Produkt?
Mehr entdecken
aus dem Bereich
Apps programmieren für macOS, iOS, watchOS und tvOS

von Thomas Sillmann

Buch (2023)
Carl Hanser (Verlag)
59,99
Das umfassende Handbuch. Apps entwickeln für iOS, macOS und tvOS. …

von Michael Kofler

Buch | Hardcover (2019)
Rheinwerk (Verlag)
49,90
The Big Nerd Ranch Guide

von Mikey Ward; Matthew Mathias; John Gallagher

Buch | Softcover (2020)
Big Nerd Ranch Guides (Verlag)
48,75