API Design for C++

1st Edition

Authors: Martin Reddy
Paperback ISBN: 9780123850034
eBook ISBN: 9780123850041
Imprint: Morgan Kaufmann
Published Date: 4th February 2011
Page Count: 472
45.95 + applicable tax
36.99 + applicable tax
59.95 + applicable tax
Unavailable
Compatible Not compatible
VitalSource PC, Mac, iPhone & iPad Amazon Kindle eReader
ePub & PDF Apple & PC desktop. Mobile devices (Apple & Android) Amazon Kindle eReader
Mobi Amazon Kindle eReader Anything else

Institutional Access


Description

API Design for C++ provides a comprehensive discussion of Application Programming Interface (API) development, from initial design through implementation, testing, documentation, release, versioning, maintenance, and deprecation. The book focuses on the issues of designing APIs for a single language (C++), which remains one of the most widely used programming languages for large software projects. The book also covers specialized API topics, such as creating scripting and plug-in APIs, with emphasis on API design. A discussion on testing strategies concentrates on automated API testing techniques rather than attempting to include end-user application testing techniques such as GUI testing, system testing, or manual testing. The book will be helpful to new programmers who understand the fundamentals of C++ and who want to advance their design skills, as well as senior engineers and software architects seeking to gain new expertise to complement their existing talents. Three specific groups of readers are targeted: practicing software engineers and architects, technical managers, and students and educators.

Key Features

  • The only book that teaches the strategies of C++ API development, including design, versioning, documentation, testing, scripting, and extensibility.
  • Extensive code examples illustrate each concept, with fully functional examples and working source code for experimentation available online.
  • Covers various API styles and patterns with a focus on practical and efficient designs for large-scale long-term projects.

Readership

All software engineers developing C++ code to be used by other developers, whether via APIs, libraries, device drivers, or other reusable components.

Table of Contents

  • Foreword
  • Preface

    • Why you should read this book
    • Who is the target audience
    • Focusing on C++
    • Conventions
    • Book web site
  • Acknowledgments
  • Author Biography
  • Chapter 1. Introduction

    • Publisher Summary
    • 1.1 What are Application Programming Interfaces?
    • 1.2 What's Different About API Design?
    • 1.3 Why Should you Use APIs?
    • 1.4 When Should you Avoid APIs?
    • 1.5 API Examples
    • 1.6 File Formats and Network Protocols
    • 1.7 About this Book
  • Chapter 2. Qualities

    • Publisher Summary
    • 2.1 Model the Problem Domain
    • 2.2 Hide Implementation Details
    • 2.3 Minimally Complete
    • 2.4 Easy to Use
    • 2.5 Loosely Coupled
    • 2.6 Stable, documented, and tested
  • Chapter 3. Patterns

    • Publisher Summary
    • 3.1 Pimpl Idiom
    • 3.2 Singleton
    • 3.3 Factory Methods
    • 3.4 API Wrapping Patterns
    • 3.5 Observer Pattern
  • Chapter 4. Design

    • Publisher Summary
    • 4.1 A Case for Good Design
    • 4.2 Gathering Functional Requirements
    • 4.3 Creating Use Cases
    • 4.4 Elements of Api Design
    • 4.5 Architecture Design
    • 4.6 Class Design
    • 4.7 Function Design
  • Chapter 5. Styles

    • Publisher Summary
    • 5.1 Flat C APIs
    • 5.2 Object-oriented C++ APIs
    • 5.3 Template-based APIs
    • 5.4 Data-driven APIs
  • Chapter 6. C++ Usage

    • Publisher Summary
    • 6.1 Namespaces
    • 6.2 Constructors and Assignment
    • 6.3 Const Correctness
    • 6.4 Templates
    • 6.5 Operator Overloading
    • 6.6 Function Parameters
    • 6.7 Avoid #define for Constants
    • 6.8 Avoid Using Friends
    • 6.9 Exporting Symbols
    • 6.10 Coding Conventions
  • Chapter 7. Performan

Details

No. of pages:
472
Language:
English
Copyright:
© Morgan Kaufmann 2011
Published:
Imprint:
Morgan Kaufmann
eBook ISBN:
9780123850041
Paperback ISBN:
9780123850034

About the Author

Martin Reddy

Dr. Martin Reddy is the founder and CEO of the software consultancy firm Code Reddy Inc. He holds a Ph.D. in Computer Science and has over 15 years of experience in the software industry. During this time, he has written 3 software patents and has published over 40 professional articles and a book on 3D computer graphics. Dr. Reddy worked for 6 years at Pixar Animation Studios where he was lead engineer for the studio’s in-house animation system. This work involved the design and implementation of various APIs to support several Academy Award-winning and nominated films, such as "Finding Nemo", "The Incredibles", "Cars", "Ratatouille", and "Wall-E." Dr. Reddy currently works for Linden Lab on the Second Life Viewer, an online 3D virtual world that has been used by over 16 million users around the world. His work is currently focused on a radical redesign of the Second Life Viewer, putting in place a suite of robust APIs to enable extensibility and scriptability.

Affiliations and Expertise

CEO, Code Reddy

Reviews

Martin Reddy draws from his experience on large scale, collaborative software projects to present patterns and practices that provide real value to individual developers as well as organizations. API Design for C++ explores often overlooked issues, both technical and non- technical, contributing to successful design decisions that produce high quality, robust, and long-lived APIs. - Eric Gregory, Software Architect, Pixar Animation Studios

"Intended for programmers with intermediate to advanced skills in the C++ programming language, this guide to the building of useful and robust application programming interfaces (APIs) provides practical instruction for software engineers developing systems on which downstream software engineers depend. The work provides a methodical approach to API design covering solution based API design, performance, versioning, documentation, testing, scripting, extensibility and libraries. The work includes numerous illustrations and code examples and access to additional online resources is provided. Reddy is a software development consultant."--Book News, Reference & Research