Object-oriented programming (OOP) Books
O'Reilly Media Effective Modern C
Book SynopsisComing to grips with C++11 and C++14 is more than a matter of familiarizing yourself with the features they introduce. The challenge is learning to use those features effectively - so that your software is correct, efficient, maintainable, and portable. That's where this practical book comes in.
£35.99
Pearson Education (US) Design Patterns
Book SynopsisDr. Erich Gamma is technical director at the Software Technology Center of Object Technology International in Zurich, Switzerland. Dr. Richard Helm is a member of the Object Technology Practice Group in the IBM Consulting Group in Sydney, Australia. Dr. Ralph Johnson is a faculty member at the University of Illinois at Urbana-Champaign's Computer Science Department. John Vlissides is a member of the research staff at the IBM T. J. Watson Research Center in Hawthorne, New York. He has practiced object-oriented technology for more than a decade as a designer, implementer, researcher, lecturer, and consultant. In addition to co-authoring Design Patterns: Elements of Reusable Object-Oriented Software, he is co-editor of the book Pattern Languages of Program Design 2 (both from Addison-Wesley). He and the other co-authors of Design Patterns are recipients of the 1998 Dr. Dobb's Journal Excellence in Programming Award. 020163Table of Contents 1. Introduction. 2. A Case Study: Designing a Document Editor. 3. Creational Patterns. 4. Structural Pattern. 5. Behavioral Patterns. 6. Conclusion. Appendix A: Glossary. Appendix B: Guide to Notation. Appendix C: Foundation Classes. Bibliography. Index.
£44.09
Pearson Education (US) Refactoring
Book SynopsisMartin Fowler is Chief Scientist at ThoughtWorks. He describes himself as an author, speaker, consultant and general loud-mouth on software development. Fowler concentrates on designing enterprise software: exploring what makes a good design and what practices are needed to create one.Table of Contents Preface 1. Refactoring, a First Example 2. Principles in Refactoring 3. Bad Smells in Code 4. Building Tests 5. Toward a Catalog of Refactorings 6. Composing Methods 7. Moving Features between Objects 8. Organizing Data 9. Simplifying Conditional Expressions 10. Making Method Calls Simpler 11. Dealing with Generalization 12. Big Refactorings 13. Refactoring, Reuse, and Reality 14. Refactoring Tools 15. Putting It All Together
£43.19
Pearson Education (US) Tour of C A
Book SynopsisBjarne Stroustrup is the designer and original implementer of C++ and the author of Programming: Principles and Practice Using C++, Second Edition, and The C++ Programming Language, Fourth Edition, among others. Currently a professor at Columbia University, he has previously worked at AT&T Bell Labs, Texas A&M University, and Morgan Stanley. He is the recipient of numerous honors, including The National Academy of Engineering's Charles Stark Draper Prize for Engineering for conceptualizing and developing the C++ programming language. Dr. Stroustrup is a member of the National Academy of Engineering, a fellow of IEEE, ACM, CHM, and Churchill College Cambridge.Table of ContentsPreface xi Chapter 1: The Basics 11.1 Introduction 11.2 Programs 21.3 Functions 41.4 Types, Variables, and Arithmetic 51.5 Scope and Lifetime 91.6 Constants 101.7 Pointers, Arrays, and References 111.8 Tests 141.9 Mapping to Hardware 161.10 Advice 19 Chapter 2: User-Defined Types 212.1 Introduction 212.2 Structures 222.3 Classes 232.4 Enumerations 252.5 Unions 272.6 Advice 28 Chapter 3: Modularity 293.1 Introduction 293.2 Separate Compilation 303.3 Namespaces 353.4 Function Arguments and Return Values 373.5 Advice 42 Chapter 4: Error Handling 434.1 Introduction 434.2 Exceptions 444.3 Invariants 454.4 Error-Handling Alternatives 474.5 Assertions 484.6 Advice 51 Chapter 5: Classes 535.1 Introduction 535.2 Concrete Types 545.3 Abstract Types 605.4 Virtual Functions 625.5 Class Hierarchies 635.6 Advice 69 Chapter 6: Essential Operations 716.1 Introduction 716.2 Copy and Move 746.3 Resource Management 786.4 Operator Overloading 806.5 Conventional Operations 816.6 User-Defined Literals 846.7 Advice 85 Chapter 7: Templates 877.1 Introduction 877.2 Parameterized Types 887.3 Parameterized Operations 937.4 Template Mechanisms 997.5 Advice 102 Chapter 8: Concepts and Generic Programming 1038.1 Introduction 1038.2 Concepts 1048.3 Generic Programming 1128.4 Variadic Templates 1148.5 Template Compilation Model 1178.6 Advice 117 Chapter 9: Library Overview 1199.1 Introduction 1199.2 Standard-Library Components 1209.3 Standard-Library Organization 1219.4 Advice 124 Chapter 10: Strings and Regular Expressions 12510.1 Introduction 12510.2 Strings 12510.3 String Views 12810.4 Regular Expressions 13010.5 Advice 136 Chapter 11: Input and Output 13711.1 Introduction 13711.2 Output 13811.3 Input 13911.4 I/O State 14111.5 I/O of User-Defined Types 14111.6 Output Formatting 14311.7 Streams 14611.8 C-style I/O 14911.9 File System 15011.10 Advice 154 Chapter 12: Containers 15712.1 Introduction 15712.2 vector 15812.3 list 16212.4 forward_list 16412.5 map 16412.6 unordered_map 16512.7 Allocators 16712.8 Container Overview 16812.9 Advice 170 Chapter 13: Algorithms 17313.1 Introduction 17313.2 Use of Iterators 17513.3 Iterator Types 17813.4 Use of Predicates 18113.5 Algorithm Overview 18113.6 Parallel Algorithms 18313.7 Advice 183 Chapter 14: Ranges 18514.1 Introduction 18514.2 Views 18614.3 Generators 18814.4 Pipelines 18814.5 Concepts Overview 19014.6 Advice 194 Chapter 15: Pointers and Containers 19515.1 Introduction 19515.2 Pointers 19615.3 Containers 20115.4 Alternatives 20815.5 Advice 212 Chapter 16: Utilities 21316.1 Introduction 21316.2 Time 21416.3 Function Adaption 21616.4 Type Functions 21716.5 source_location 22216.6 move() and forward() 22316.7 Bit Manipulation 22416.8 Exiting a Program 22516.9 Advice 225 Chapter 17: Numerics 22717.1 Introduction 22717.2 Mathematical Functions 22817.3 Numerical Algorithms 22917.4 Complex Numbers 23017.5 Random Numbers 23117.6 Vector Arithmetic 23317.7 Numeric Limits 23417.8 Type Aliases 23417.9 Mathematical Constants 23417.10 Advice 235 Chapter 18: Concurrency 23718.1 Introduction 23718.2 Tasks and threads 23818.3 Sharing Data 24118.4 Waiting for Events 24318.5 Communicating Tasks 24518.6 Coroutines 25018.8 Advice 253 Chapter 19: History and Compatibility 25519.1 History 25519.2 C++ Feature Evolution 26319.3 C/C++ Compatibility 26819.4 Bibliography 27119.5 Advice 274 Appendix: Module std 277A.1 Introduction 277A.2 Use What Your Implementation Offers 278A.3 Use Headers 278A.4 Make Your Own module std 278A.5 Advice 279 Index 281
£26.99
Pearson Education (US) Programming in C
Book SynopsisTable of Contents Introduction 1 1 Some Fundamentals 5 Programming 5 Higher-Level Languages 5 Operating Systems 6 Compiling Programs 7 Integrated Development Environments 10 Language Interpreters 10 2 Compiling and Running Your First Program 11 Compiling Your Program 12 Running Your Program 12 Understanding Your First Program 13 Displaying the Values of Variables 15 Comments 17 Exercises 19 3 Variables, Data Types, and Arithmetic Expressions 21 Understanding Data Types and Constants 21 The Integer Type int 22 The Floating Number Type float 23 The Extended Precision Type double 23 The Single Character Type char 24 The Boolean Data Type _Bool 24 Type Specifiers: long, long long, short, unsigned, and signed 26 Working with Variables 29 Working with Arithmetic Expressions 30 Integer Arithmetic and the Unary Minus Operator 33 Combining Operations with Assignment: The Assignment Operators 39 Types _Complex and _Imaginary 40 Exercises 40 4 Program Looping 43 Triangular Numbers 43 The for Statement 44 Relational Operators 46 Aligning Output 50 Program Input 51 Nested for Loops 53 for Loop Variants 55 The while Statement 56 The do Statement 60 The break Statement 62 The continue Statement 62 Exercises 63 5 Making Decisions 65 The if Statement 65 The if-else Construct 69 Compound Relational Tests 72 Nested if Statements 74 The else if Construct 76 The switch Statement 83 Boolean Variables 86 The Conditional Operator 90 Exercises 92 6 Working with Arrays 95 Defining an Array 96 Using Array Elements as Counters 100 Generating Fibonacci Numbers 103 Using an Array to Generate Prime Numbers 104 Initializing Arrays 106 Character Arrays 108 Base Conversion Using Arrays 109 The const Qualifier 111 Multidimensional Arrays 113 Variable Length Arrays 115 Exercises 117 7 Working with Functions 119 Defining a Function 119 Arguments and Local Variables 123 Function Prototype Declaration 124 Automatic Local Variables 124 Returning Function Results 126 Functions Calling Functions Calling... 130 Declaring Return Types and Argument Types 133 Checking Function Arguments 135 Top-Down Programming 137 Functions and Arrays 137 Assignment Operators 141 Sorting Arrays 143 Multidimensional Arrays 146 Global Variables 151 Automatic and Static Variables 155 Recursive Functions 158 Exercises 161 8 Working with Structures 163 The Basics of Structures 163 A Structure for Storing the Date 164 Using Structures in Expressions 166 Functions and Structures 169 A Structure for Storing the Time 175 Initializing Structures 178 Compound Literals 178 Arrays of Structures 180 Structures Containing Structures 183 Structures Containing Arrays 185 Structure Variants 189 Exercises 190 9 Character Strings 193 Revisiting the Basics of Strings 193 Arrays of Characters 194 Variable-Length Character Strings 197 Initializing and Displaying Character Strings 199 Testing Two Character Strings for Equality 202 Inputting Character Strings 204 Single-Character Input 206 The Null String 211 Escape Characters 215 More on Constant Strings 217 Character Strings, Structures, and Arrays 218 A Better Search Method 221 Character Operations 226 Exercises 229 10 Pointers 233 Pointers and Indirection 233 Defining a Pointer Variable 234 Using Pointers in Expressions 237 Working with Pointers and Structures 239 Structures Containing Pointers 241 Linked Lists 243 The Keyword const and Pointers 251 Pointers and Functions 252 Pointers and Arrays 258 A Slight Digression About Program Optimization 262 Is It an Array or Is It a Pointer? 262 Pointers to Character Strings 264 Constant Character Strings and Pointers 266 The Increment and Decrement Operators Revisited 267 Operations on Pointers 271 Pointers to Functions 272 Pointers and Memory Addresses 273 Exercises 275 11 Operations on Bits 277 The Basics of Bits 277 Bit Operators 278 The Bitwise AND Operator 279 The Bitwise Inclusive-OR Operator 281 The Bitwise Exclusive-OR Operator 282 The Ones Complement Operator 283 The Left Shift Operator 285 The Right Shift Operator 286 A Shift Function 286 Rotating Bits 288 Bit Fields 291 Exercises 295 12 The Preprocessor 297 The #define Statement 297 Program Extendability 301 Program Portability 302 More Advanced Types of Definitions 304 The # Operator 309 The ## Operator 310 The #include Statement 311 System Include Files 313 Conditional Compilation 314 The #ifdef, #endif, #else, and #ifndef Statements 314 The #if and #elif Preprocessor Statements 316 The #undef Statement 317 Exercises 318 13 Extending Data Types with the Enumerated Data Type, Type Definitions, and Data Type Conversions 319 Enumerated Data Types 319 The typedef Statement 323 Data Type Conversions 325 Sign Extension 327 Argument Conversion 328 Exercises 329 14 Working with Larger Programs 331 Dividing Your Program into Multiple Files 331 Compiling Multiple Source Files from the Command Line 332 Communication Between Modules 334 External Variables 334 Static Versus Extern Variables and Functions 337 Using Header Files Effectively 339 Other Utilities for Working with Larger Programs 341 The make Utility 341 The cvs Utility 343 Unix Utilities: ar, grep, sed, and so on 343 15 Input and Output Operations in C 345 Character I/O: getchar() and putchar() 346 Formatted I/O: printf() and scanf() 346 The printf() Function 346 The scanf() Function 353 Input and Output Operations with Files 358 Redirecting I/O to a File 358 End of File 361 Special Functions for Working with Files 362 The fopen Function 362 The getc() and putc() Functions 364 The fclose() Function 365 The feof Function 367 The fprintf() and fscanf() Functions 367 The fgets() and fputs() Functions 367 stdin, stdout, and stderr 368 The exit() Function 369 Renaming and Removing Files 370 Exercises 371 16 Miscellaneous and Advanced Features 373 Miscellaneous Language Statements 373 The goto Statement 373 The null Statement 374 Working with Unions 375 The Comma Operator 378 Type Qualifiers 379 The register Qualifier 379 The volatile Qualifier 379 The restrict Qualifier 379 Command-line Arguments 380 Dynamic Memory Allocation 384 The calloc() and malloc() Functions 385 The sizeof Operator 385 The free Function 387 Exercises 389 17 Debugging Programs 391 Debugging with the Preprocessor 391 Debugging Programs with gdb 397 Working with Variables 400 Source File Display 401 Controlling Program Execution 402 Getting a Stack Trace 406 Calling Functions and Setting Arrays and Structures 407 Getting Help with gdb Commands 408 Odds and Ends 410 18 Object-Oriented Programming 413 What Is an Object Anyway? 413 Instances and Methods 414 Writing a C Program to Work with Fractions 416 Defining an Objective-C Class to Work with Fractions 417 Defining a C++ Class to Work with Fractions 421 Defining a C# Class to Work with Fractions 424 A C Language Summary 427 B The Standard C Library 471 C Compiling Programs with gcc 495 D Common Programming Mistakes 499 E Resources 505 TOC, 9780321776419, 7/28/2014
£33.29
Pearson Education (US) UML Distilled
Book SynopsisMartin Fowler is an independent consultant who has applied objects to pressing business problems for more than a decade. He has consulted on systems in fields such as health care, financial trading, and corporate finance. His clients include Chrysler, Citibank, UK National Health Service, Andersen Consulting, and Netscape Communications. In addition, Fowler is a regular speaker on objects, the Unified Modeling Language, and patterns. Table of Contents Preface. Why bother with the UML? Structure of the book. Changes for the Third Edition. Acknowledgements. 1. Introduction. What Is the UML? Ways of Using the UML. How We Got to the UML. Notations and Meta-Models. UML Diagrams. What is Legal UML? The Meaning of UML. UML is not enough. Where to Start with the UML. Looking for More Information. 2. Development Process. Iterative and Waterfall Processes. Predictive and Adaptive Planning. Agile Processes. Rational Unified Process. Fitting a Process to a Project. Fitting the UML into a process. Understanding Legacy Code. Choosing a Development Process. Where to Find Out More. 3. Class Diagrams: The Essentials. Properties. Attributes. Associations. Multiplicity. Programming Interpretation of Properties. Bi-directional Associations. Operations. Generalization. Notes and Comments. Dependency. Constraint Rules. When to Use Class Diagrams. Where to Find Out More. 4. Sequence Diagrams. Creating and deleting participants. Loops, conditionals and the like. Synchronous and Asynchronous Calls. When to use Sequence Diagrams. 5. Class Diagrams: Advanced Concepts. Keywords. Responsibilities. Static Operations and Attributes. Aggregation and Composition. Derived Properties. Interfaces and Abstract Classes. Read Only and Frozen. Reference Objects and Value Objects. Qualified Associations. Classification and Generalization. Multiple and Dynamic Classification. Association Class. Template (Parameterized) Class. Enumerations. Active Class. Visibility. Messages. 6. Object Diagrams. When to use Object Diagrams. 7. Package Diagrams. Packages and Dependencies. Package Aspects. Implementing Packages. Where to Find Out More. When to Use Package Diagrams. 8. Deployment Diagrams. When to use deployment diagrams. 9. Use Cases. Content of a Use Case. Use Case Diagrams. Levels of Use Cases. Use cases and features (or stories). When to Use Use Cases. Where to Find Out More. 10. State Machine Diagrams. Internal Activities. Activity States. Superstates. Concurrent States. Implementing State Diagrams. When to Use State Diagrams. Where to Find Out More. 11. Activity Diagrams. Decomposing an action. Partitions. Signals. Tokens. Flows and Edges. Pins and Transformations. Expansion Regions. Flow Final. Join Specifications. And there's more. When to Use Activity Diagrams. Where to Find Out More. 12. Communication Diagrams. When to use Communication Diagrams. 13. Composite Structures. When to Use Composite Structures. 14. Component Diagrams. When to use Component Diagrams. 15. Collaborations. When to Use Collaborations. 16. Interaction Overview Diagrams. When to use Interaction Overview Diagrams. 17. Timing Diagrams. When to use Timing Diagrams. Appendix A Changes between UML Versions. Revisions to the UML. Changes in UML Distilled. Changes from UML 1.0 to 1.1. Type and Implementation Class. Complete and Incomplete Discriminator Constraints. Composition. Immutability and Frozen. Returns on Sequence Diagrams. Use of the Term "Role". Changes from UML 1.2 (and 1.1) to 1.3 (and 1.5). Use Cases. Activity Diagrams. Changes from UML 1.3 to 1.4. Changes from UML 1.4. to 1.5. From UML 1.x to UML 2.0. Class Diagrams (Basic). Interaction Diagrams. Class Diagrams (Advanced). State Diagrams. Activity Diagrams. Bibliography. Index.
£33.29
Pearson Education (US) SysML Distilled
Book SynopsisLenny Delligatti holds the OMG Certified Systems Modeling Professional (OCSMP): Model Builder Advanced certification. As a senior systems engineer with Lockheed Martin, he created SysML models for NASA's Mission Control Center: 21st Century (MCC-21) project at Johnson Space Center. Lenny is a member of the Object Management Group (OMG) SysML Revision Task Force (RTF). He has delivered hundreds of hours of training to hundreds of systems and software engineers, enabling many to earn certifications and lead MBSE projects.Trade Review"In keeping with the outstanding tradition of Addison-Wesley's technical publications, Lenny Delligatti's SysML Distilled does not disappoint. Lenny has done a masterful job of capturing the spirit of OMG SysML as a practical, standards-based modeling language to help systems engineers address growing system complexity. This book is loaded with matter-of-fact insights, starting with basic MBSE concepts to distinguishing the subtle differences between use cases and scenarios to illumination on namespaces and SysML packages, and even speaks to some of the more esoteric SysML semantics such as token flows." -Jeff Estefan, Principal Engineer, NASA's Jet Propulsion Laboratory "The power of a modeling language, such as SysML, is that it facilitates communication not only within systems engineering but across disciplines and across the development life cycle. Many languages have the potential to increase communication, but without an effective guide, they can fall short of that objective. In SysML Distilled, Lenny Delligatti combines just the right amount of technology with a common-sense approach to utilizing SysML toward achieving that communication. Having worked in systems and software engineering across many domains for the last 30 years, and having taught computer languages, UML, and SysML to many organizations and within the college setting, I find Lenny's book an invaluable resource. He presents the concepts clearly and provides useful and pragmatic examples to get you off the ground quickly and enables you to be an effective modeler." -Thomas W. Fargnoli, Lead Member of the Engineering Staff, Lockheed Martin "This book provides an excellent introduction to SysML. Lenny Delligatti's explanations are concise and easy to understand; the examples well thought out and interesting." -Susanne Sherba, Senior Lecturer, Department of Computer Science, University of Denver "Lenny hits the thin line between a reference book for SysML to look up elements and an entertaining book that could be read in its entirety to learn the language. A great book in the tradition of the famous UML Distilled." -Tim Weilkiens, CEO, oose "More informative than a PowerPoint, less pedantic than an OMG Profile Specification, SysML Distilled offers practicing systems engineers just the right level of the motivation, concepts, and notation of pure OMG SysML for them to attain fluency with this graphical language for the specification and analysis of their practical and complex systems." -Lonnie VanZandt, chief architect, No Magic, Inc. "Delligatti's SysML Distilled is a most aptly named book; it represents the distillation of years of experience in teaching and using SysML in industrial settings. The author presents a very clear and highly readable view of this powerful but complex modeling language, illustrating its use via easy-to-follow practical examples. Although intended primarily as an introduction to SysML, I have no doubt that it will also serve as a handy reference for experienced practitioners." -Bran Selic, president, Malina Software Corp. "SysML is a rather intimidating modeling language, but in this book Lenny makes it really easy to understand, and the advice throughout the book will help practitioners avoid numerous pitfalls and help them grasp and apply the core elements and the spirit of SysML. If you are planning on applying SysML, this is the book for you!" -Celso Gonzalez, senior developer, IBM Rational "SysML Distilled is a great book for engineers who are starting to delve into model-based systems engineering. The space system examples capture the imagination and express the concepts in a simple but effective way." -Matthew C. Hause, chief consulting engineer, Atego and chair, OMG UPDM Group "I've been deeply involved with OMG since the 1990s, but my professional needs have not often taken me into the SysML realm. So I thought I'd be a good beta tester for Lenny's book. To my delight, I learned a great deal reading through it, and I know you will too." -Doug Tolbert, distinguished engineer, Unisys, and member, OMG Board of Directors and Architecture Board "SysML Distilled provides a clear and comprehensive description of the language component of model-based systems engineering, while offering suggestions for where to find information about the tool and methodology components. There is evidence throughout the book that the author has a deep understanding of SysML and its application in a system development process. I will definitely be using this as a textbook in the MBSE courses I teach." -J. D. Baker, OCUP, OCSMP, member of the OMG Architecture Board "SysML Distilled is the desktop companion that many SysML modelers have needed for their bookshelves. Lenny has the experience and certifications to help you through your day-to-day modeling questions. This book is not a tutorial, nor is it the encyclopedic compendium of all things SysML. If you model using SysML, this will become your daily companion, as it is meant to be used regularly. I believe your copy will soon be dog-eared, with sticky notes throughout." -Dr. Robert Cloutier, Stevens Institute of Technology "SysML is utilized today in a wide range of applications, including deep space robotic spacecraft and down-to-earth agricultural equipment. This book concisely presents SysML in a manner that is both refreshingly accessible for new learners and quite handy for seasoned practitioners." -Russell Peak, MBSE branch chief, Aerospace Systems Design Lab, Georgia Tech "SysML Distilled is a wonderfully written, knowledgeable, and concise addition to systems modeling literature. The lucid explanations lead a newcomer by the hand into modeling reasonably complex systems, and the wealth and depth of the coverage of the most-used aspects of the SysML modeling language stretch to even enabling advanced intermediate depictions of most systems. It also serves as a handy reference. Kudos to Mr. Delligatti for gifting the world with this very approachable view of systems modeling." -Bobbin Teegarden, CTO/chief architect, OntoAge and Board Member, No Magic, Inc.Table of ContentsForeword by Rick Steiner xvii Foreword by Richard Soley xix Preface xxv Acknowledgments xxxi About the Author xxxiii Chapter 1: Overview of Model-Based Systems Engineering 1 1.1 What Is MBSE? 2 1.2 The Three Pillars of MBSE 4 1.3 The Myth of MBSE 9 Chapter 2: Overview of the Systems Modeling Language 11 2.1 What SysML Is–and Isn’t 11 2.2 Yes, SysML Is Based on UML–but You Can Start with SysML 13 2.3 SysML Diagram Overview 14 2.4 General Diagram Concepts 17 Chapter 3: Block Definition Diagrams 23 3.1 Purpose 23 3.2 When Should You Create a BDD? 24 3.3 The BDD Frame 24 3.4 Blocks 26 3.5 Associations: Another Notation for a Property 44 3.6 Generalizations 49 3.7 Dependencies 52 3.8 Actors 53 3.9 Value Types 55 3.10 Constraint Blocks 57 3.11 Comments 59 Chapter 4: Internal Block Diagrams 63 4.1 Purpose 63 4.2 When Should You Create an IBD? 64 4.3 Blocks, Revisited 64 4.4 The IBD Frame 65 4.5 BDDs and IBDs: Complementary Views of a Block 66 4.6 Part Properties 67 4.7 Reference Properties 67 4.8 Connectors 68 4.9 Item Flows 71 4.10 Nested Parts and References 72 Chapter 5: Use Case Diagrams 77 5.1 Purpose 77 5.2 When Should You Create a Use Case Diagram? 77 5.3 Wait! What’s a Use Case? 78 5.4 The Use Case Diagram Frame 81 5.5 Use Cases 82 5.6 System Boundary 83 5.7 Actors 83 5.8 Associating Actors with Use Cases 84 5.9 Base Use Cases 85 5.10 Included Use Cases 85 5.11 Extending Use Cases 87 Chapter 6: Activity Diagrams 89 6.1 Purpose 89 6.2 When Should You Create an Activity Diagram? 90 6.3 The Activity Diagram Frame 90 6.4 A Word about Token Flow 92 6.5 Actions: The Basics 93 6.6 Object Nodes 95 6.7 Edges 99 6.8 Actions, Revisited 102 6.9 Control Nodes 112 6.10 Activity Partitions: Allocating Behaviors to Structures 119 Chapter 7: Sequence Diagrams 123 7.1 Purpose 123 7.2 When Should You Create a Sequence Diagram? 124 7.3 The Sequence Diagram Frame 125 7.4 Lifelines 125 7.5 Messages 129 7.6 Destruction Occurrences 138 7.7 Execution Specifications 139 7.8 Constraints 141 7.9 Combined Fragments 144 7.10 Interaction Uses 151 Chapter 8: State Machine Diagrams 155 8.1 Purpose 155 8.2 When Should You Create a State Machine Diagram? 156 8.3 The State Machine Diagram Frame 156 8.4 States 158 8.5 Transitions 162 8.6 Pseudostates 171 8.7 Regions 173 Chapter 9: Parametric Diagrams 177 9.1 Purpose 177 9.2 When Should You Create a Parametric Diagram? 178 9.3 Blocks, Revisited 179 9.4 The Parametric Diagram Frame 182 9.5 Constraint Properties 184 9.6 Constraint Parameters 185 9.7 Value Properties 185 9.8 Binding Connectors 187 Chapter 10: Package Diagrams 189 10.1 Purpose 189 10.2 When Should You Create a Package Diagram? 190 10.3 The Package Diagram Frame 190 10.4 Notations for Namespace Containment 191 10.5 Dependencies between Packages 193 10.6 Importing Packages 193 10.7 Specialized Packages 194 10.8 Shades of Gray: Are You Looking at a Package Diagram or a Block Definition Diagram? 198 Chapter 11: Requirements Diagrams 201 11.1 Purpose 201 11.2 When Should You Create a Requirements Diagram? 202 11.3 The Requirements Diagram Frame 202 11.4 Requirements 204 11.5 Requirements Relationships 205 11.6 Notations for Requirements Relationships 209 11.7 Rationale 213 Chapter 12: Allocations: Cross-Cutting Relationships 215 12.1 Purpose 215 12.2 There’s No Such Thing as an Allocation Diagram 216 12.3 Uses for Allocation Relationships 216 12.4 Notations for Allocation Relationships 219 12.5 Rationale 224 Appendix A: SysML Notation Desk Reference 227 Appendix B: Changes between SysML Versions 245 Bibliography 253 Index 255
£25.59
Pearson Education (US) ObjectOriented Thought Process The
Book SynopsisMatt Weisfeld is a college professor, software developer, and author based in Cleveland, Ohio. Prior to teaching college full time, he spent 20 years in the information technology industry as a software developer, entrepreneur, and adjunct professor. Weisfeld holds an MS in computer science and an MBA. Besides several editions of The Object-Oriented Thought Process, Matt has authored two other software development books and published many articles in magazines and journals, such as informit.com, developer.com, Dr. Dobb's Journal, The C/C++ Users Journal, Software Development Magazine, Java Report, and the international journal Project Management.Table of Contents 1. Introduction to Object-Oriented Concepts 2. How to Think in Terms of Objects 3. Advanced Object-Oriented Concepts 4. The Anatomy of a Class 5. Mastering Inheritance and Composition 6. Frameworks and Reuse: Designing with Interfaces and Abstract Classes 7. Building Objects & Object-Oriented Design 8. Object-Oriented and Object Based Languages 9. Objects and Portable Data: XML, SOAP, and JSON 10. Persistent Objects: Serialization, Marshalling and Relational Databases 11. Objects in Web Services and Mobile Apps 12. Design Patterns Appendix A Code Examples
£27.19
O'Reilly Media C Software Design
Book SynopsisWith this book, experienced C++ developers will get a thorough, practical, and unparalleled overview of software design with this modern language.
£47.99
ESRI Press Python Scripting for ArcGIS Pro
Book SynopsisUnlock the power of Python in ArcGIS Pro with this definitive, easy-to-follow guide designed for users with limited programming or scripting experience.Get started learning to write Python scripts to automate tasks in ArcGIS Pro with Python Scripting for ArcGIS Pro. This book begins with the fundamentals of Python programming and then dives into how to write useful Python scripts that work with spatial data in ArcGIS Pro. You'll learn how to use geoprocessing tools; describe, create, and update data; and execute specialized tasks. With step-by-step instructions, practical examples, and insightful guidance, you'll be able to write scripts that will automate and improve your ArcGIS Pro workflows.This third edition has been revised for ArcGIS Pro 3.2 and Python 3.9.18 and includes updated images; a fully updated chapter 2; and expanded chapters 4, 8, 9, and 10.The key topics you will learn include: Python fundamentals Setting up a Python editor Automating geoprocessing tasks using ArcPy Exploring and manipulating spatial and tabular data Working with geometries using cursors Working with rasters and map algebra Map scripting Debugging and error handling Helpful points to remember, key terms, and review questions are included at the end of each chapter to reinforce your understanding of Python. Corresponding data and tutorials are available online.Whether you're new to Python or already have some experience, Python Scripting for ArcGIS Pro is the go-to resource for learning the versatility of Python coding to solve problems and enhance productivity and efficiency in ArcGIS Pro.
£67.44
John Wiley & Sons Inc Beginning Java Programming
Book SynopsisA comprehensive Java guide, with samples, exercises, case studies, and step-by-step instruction Beginning Java Programming: The Object Oriented Approach is a straightforward resource for getting started with one of the world''s most enduringly popular programming languages. Based on classes taught by the authors, the book starts with the basics and gradually builds into more advanced concepts. The approach utilizes an integrated development environment that allows readers to immediately apply what they learn, and includes step-by-step instruction with plenty of sample programs. Each chapter contains exercises based on real-world business and educational scenarios, and the final chapter uses case studies to combine several concepts and put readers'' new skills to the test. Beginning Java Programming: The Object Oriented Approach provides both the information and the tools beginners need to develop Java skills, from the general concepts of object-oriented Trade Review"Learning Java is a big subject, and this is a big book to match. I would recommend this book top anyone who is serioys in learning to program in Java." (BCS - The Chartered Institute for IT, February 2017)Table of ContentsIntroduction xxii Chapter 1: A General Introduction To Programming 1 The Programming Process 2 Object-Oriented Programming: A Sneak Preview 5 Programming Errors 6 Syntax/Compilation Errors 6 Runtime Errors 6 Logic/Semantic Errors 7 Principles of Software Testing 7 Software Maintenance 8 Adaptive Maintenance 8 Perfective Maintenance 8 Corrective Maintenance 8 Preventive Maintenance 9 Principles of Structured Programming 9 Chapter 2: Getting To Know Java 11 A Short Java History 12 Features of Java 13 Looking Under the Hood 13 Bytecode 14 Java Runtime Environment (JRE) 15 Java Application Programming Interface (API) 16 Class Loader 17 Bytecode Verifier 18 Java Virtual Machine (JVM) 18 Java Platforms 19 Java Applications 19 Standalone Applications 19 Java Applets 20 Java Servlets 20 Java Beans 21 Java Language Structure 21 Classes 22 Identifiers 22 Java Keywords 22 Variables 23 Methods 23 Comments 24 Naming Conventions 26 Java Data Types 27 Primitive Data Types 27 Literals 28 Operators 29 Arithmetic Operators 29 Assignment Operators 30 Bitwise Operators 31 Logical Operators 32 Relational Operators 34 Arrays 34 Type Casting 37 Summary 40 Chapter 3: Setting Up Your Development Environment 41 Integrated Development Environments 42 Coding in Text Editors 42 Choosing an IDE 46 Eclipse 47 NetBeans 47 IntelliJ IDEA 47 Continuing with One IDE 47 Installing Eclipse on Your Computer 48 Downloading and Installing Eclipse 48 Using Eclipse 50 Chapter 4: Moving Toward Object‐Oriented Programming 61 Basic Concepts of Object‐Oriented Programming 62 Classes and Objects in Java 63 Defining Classes in Java 63 Creating Objects 71 Storing Data: Variables 76 Instance Variables 76 Class Variables 80 Final Variables 82 Variable Scope 87 Defining Behavior: Methods 91 Instance Methods 91 Class Methods 94 Constructors 95 The Main Method 100 Method Argument Passing 109 Java SE Built‐in Classes 115 Classes in the java.lang Package 115 Classes in the java.io and java.nio Packages 117 Classes in the java.math Package 118 Classes in the java.net, java.rmi, javax.rmi, and org.omg.CORBA Packages 118 Classes in the java.awt and javax.swing Packages 118 Classes in the java.util Package 118 Collections 119 Other Utility Classes 126 Other Classes and Custom Libraries 127 Chapter 5: Controlling the Flow of Your Program 129 Comparisons Using Operators and Methods 130 Comparing Primitive Data Types with Comparison Operators 130 Comparing Composite Data Types with Comparison Methods 132 Understanding Language Control 135 Creating if-then Statements 135 Nesting if-then Statements 137 Creating for Loops 138 What is an Enhanced for Loop? 143 Nesting for Loops 146 Creating while Loops 148 What is a do while Loop? 152 Comparing for and while Loops 156 Creating Switches 156 Comparing Switches and if-then Statements 161 Reviewing Keywords for Control 162 Controlling with the return Keyword 162 Controlling with the break Keyword 163 Controlling with the continue Keyword 164 Specifying a Label for break or continue Control 164 Reviewing Control Structures 168 Chapter 6: Handling Exceptions and Debugging 171 Recognizing Error Types 172 Identifying Syntax Errors 172 Identifying Runtime Errors 175 Identifying Logical Errors 176 Exceptions 180 Common Exceptions 181 Catching Exceptions 187 Debugging Your Applications 195 Using a Debugger Tool 195 Using a Logging API 200 Testing Your Applications 210 Summary 219 Chapter 7: Delving Further Into Object‐Oriented Concepts 221 Annotations 222 Overloading Methods 222 The this KeyWord 224 Information Hiding 229 Access Modifiers 230 Getters 231 Setters 232 Class Inheritance 240 The Keyword super 241 Method Overriding 243 Polymorphism 243 Static Binding 244 Dynamic Binding 244 The Superclass Object 245 Abstract Classes and Methods 246 Packages 251 Interfaces 252 Garbage Collection 259 Chapter 8: Handling Input and Output 261 General Input and Output 262 Input and Output in Java 266 Streams 268 Byte Streams 269 Character Streams 275 Buffered Streams 276 Data and Object Streams 278 Other Streams 281 Scanners 281 Input and Output from the Command-Line 283 Input and Output from Files 290 Java NIO2 File Input and Output 291 The Path Interface 291 The Files Class 293 Checking Existence 293 Legacy File Input and Output 304 A Word on FileUtils 305 Conclusion 305 Chapter 9: Working With Databases in Java 307 Covering the Basics of Relational Databases 308 Accessing Relational Databases from Java 315 Java Database Connectivity (JDBC) 315 SQLJ 321 Ensuring Object Persistence 324 Hibernate 325 Object-Oriented Database Access from Java 341 Comparing Java Database Access Technologies 343 What’s Ahead 344 Chapter 10: Accessing Web Sources 347 A Brief Introduction to Networking 348 Web Services 360 RPC and RMI 360 SOAP 364 REST 366 Accessing Web Services and Sources with Java 368 Accessing SOAP Services 368 Installing JAX‐WS 368 Accessing SOAP Services with JAX‐WS Without WSDL 369 Accessing SOAP Services with JAX‐WS with WSDL 395 Accessing REST Services 406 Accessing REST Services Without Authentication 408 Accessing REST Services with Authentication 421 Screen Scraping 449 Screen Scraping Without Cookies 451 Screen Scraping with Cookies 453 Creating Your Own Web Services with Java 457 Setting Up an HTTP Server 457 Providing REST Services 461 Chapter 11: Designing Graphical Interfaces 463 Covering the Basics of GUIs in Java 464 Highlighting the Built‐In GUI Libraries 464 Abstract Window Toolkit (AWT) 464 Swing 464 Standard Widget Toolkit (SWT) 465 JavaFX 465 Other Toolkits and Libraries 466 Choosing a GUI Library 466 Building with Containers and Components 467 Looking at the Full Picture 472 Comparing Layout Managers 473 FlowLayout 474 BorderLayout 476 GridLayout 478 GridBagLayout 482 CardLayout 486 BoxLayout 489 GroupLayout and SpringLayout 493 Absolute Positioning (No Layout Manager) 494 Understanding Events 496 Introduction to Events 496 Event Listeners 497 On Threading and Swing 514 Closing Topics 524 Best Practices: Keeping Looks and Logic Separated 524 Let’s Draw: Defining Custom Draw Behavior 525 Visual GUI Designers: Making Life Easy? 540 JavaFX: The Road Ahead? 545 Chapter 12: Using Object‐Oriented Patterns 557 Introduction to Patterns 558 Object‐Oriented Patterns 558 Creational Patterns 559 Singleton Pattern and Static Utility Class 559 Service Provider Pattern and Null Object Pattern 565 (Abstract) Factory Pattern 566 Structural Patterns 568 Adapter Pattern 568 Bridge Pattern 570 Decorator Pattern 571 Facade Pattern 574 Composite Pattern 575 Type Pattern and Role Pattern 583 Behavioral Patterns 591 Chain‐of‐Responsibility Pattern 591 Observer Pattern and Model‐View‐Controller Pattern 592 Iterator Pattern 605 Visitor Pattern 607 Template Method Pattern 610 Strategy Pattern 612 Helpful Libraries 614 Apache Commons 614 Google Guava 615 Trove 615 Colt 615 Lombok 616 OpenCSV 616 HTML and JSON Libraries 616 Hibernate and Other JPA‐Compliant Libraries 617 Joda‐Time 617 Charting Libraries 617 3D Graphics Libraries 617 Financial Libraries 618 Index 619
£28.80
John Wiley & Sons Inc Patterns Principles and Practices of DomainDriven
Book SynopsisMethods for managing complex software construction following the practices, principles and patterns of Domain-Driven Design with code examples in C# This book presents the philosophy of Domain-Driven Design (DDD) in a down-to-earth and practical manner for experienced developers building applications for complex domains.Table of ContentsINTRODUCTION xxxv PART I: THE PRINCIPLES AND PRACTICES OF DOMAIN‐DRIVEN DESIGN CHAPTER 1: WHAT IS DOMAIN‐DRIVEN DESIGN? 3 The Challenges of Creating Software for Complex Problem Domains 4 Code Created Without a Common Language 4 A Lack of Organization 5 The Ball of Mud Pattern Stifles Development 5 A Lack of Focus on the Problem Domain 6 How the Patterns of Domain‐Driven Design Manage Complexity 6 The Strategic Patterns of DDD 6 Distilling the Problem Domain to Reveal What Is Important 7 Creating a Model to Solve Domain Problems 7 Using a Shared Language to Enable Modeling Collaboration 7 Isolate Models from Ambiguity and Corruption 8 Understanding the Relationships between Contexts 9 The Tactical Patterns of DDD 9 The Problem Space and the Solution Space 9 The Practices and Principles of Domain‐Driven Design 11 Focusing on the Core Domain 11 Learning through Collaboration 11 Creating Models through Exploration and Experimentation 11 Communication 11 Understanding the Applicability of a Model 12 Constantly Evolving the Model 12 Popular Misconceptions of Domain‐Driven Design 12 Tactical Patterns Are Key to DDD 12 DDD Is a Framework 13 DDD Is a Silver Bullet 13 The Salient Points 13 CHAPTER 2: DISTILLING THE PROBLEM DOMAIN 15 Knowledge Crunching and Collaboration 15 Reaching a Shared Understanding through a Shared Language 16 The Importance of Domain Knowledge 17 The Role of Business Analysts 17 An Ongoing Process 17 Gaining Domain Insight with Domain Experts 18 Domain Experts vs Stakeholders 18 Deeper Understanding for the Business 19 Engaging with Your Domain Experts 19 Patterns for Effective Knowledge Crunching 19 Focus on the Most Interesting Conversations 19 Start from the Use Cases 20 Ask Powerful Questions 20 Sketching 20 Class Responsibility Collaboration Cards 21 Defer the Naming of Concepts in Your Model 21 Behavior‐Driven Development 22 Rapid Prototyping 23 Look at Paper‐Based Systems 24 Look For Existing Models 24 Understanding Intent 24 Event Storming 25 Impact Mapping 25 Understanding the Business Model 27 Deliberate Discovery 28 Model Exploration Whirlpool 29 The Salient Points 29 CHAPTER 3: FOCUSING ON THE CORE DOMAIN 31 Why Decompose a Problem Domain? 31 How to Capture the Essence of the Problem 32 Look Beyond Requirements 32 Capture the Domain Vision for a Shared Understanding of What Is Core 32 How to Focus on the Core Problem 33 Distilling a Problem Domain 34 Core Domains 35 Treat Your Core Domain as a Product Rather than a Project 36 Generic Domains 37 Supporting Domains 37 How Subdomains Shape a Solution 37 Not All Parts of a System will be Well Designed 37 Focus on Clean Boundaries over Perfect Models 38 The Core Domain Doesn’t Always Have to Be Perfect the First Time 39 Build Subdomains for Replacement Rather than Reuse 39 What if You Have no Core Domain? 39 The Salient Points 40 CHAPTER 4: MODEL‐DRIVEN DESIGN 41 What Is a Domain Model? 42 The Domain versus the Domain Model 42 The Analysis Model 43 The Code Model 43 The Code Model Is the Primary Expression of the Domain Model 44 Model‐Driven Design 44 The Challenges with Upfront Design 44 Team Modeling 45 Using a Ubiquitous Language to Bind the Analysis to the Code Model 47 A Language Will Outlive Your Software 47 The Language of the Business 48 Translation between the Developers and the Business 48 Collaborating on a Ubiquitous Language 48 Carving Out a Language by Working with Concrete Examples 49 Teach Your Domain Experts to Focus on the Problem and Not Jump to a Solution 50 Best Practices for Shaping the Language 51 How to Create Effective Domain Models 52 Don’t Let the Truth Get in the Way of a Good Model 52 Model Only What Is Relevant 54 Domain Models Are Temporarily Useful 54 Be Explicit with Terminology 54 Limit Your Abstractions 54 Focus Your Code at the Right Level of Abstraction 55 Abstract Behavior Not Implementations 55 Implement the Model in Code Early and Often 56 Don’t Stop at the First Good Idea 56 When to Apply Model‐Driven Design 56 If It’s Not Worth the Effort Don’t Try and Model It 56 Focus on the Core Domain 57 The Salient Points 57 CHAPTER 5: DOMAIN MODEL IMPLEMENTATION PATTERNS 59 The Domain Layer 60 Domain Model Implementation Patterns 60 Domain Model 62 Transaction Script 65 Table Module 67 Active Record 67 Anemic Domain Model 67 Anemic Domain Model and Functional Programming 68 The Salient Points 71 CHAPTER 6: MAINTAINING THE INTEGRITY OF DOMAIN MODELS WITH BOUNDED CONTEXTS 73 The Challenges of a Single Model 74 A Model Can Grow in Complexity 74 Multiple Teams Working on a Single Model 74 Ambiguity in the Language of the Model 75 The Applicability of a Domain Concept 76 Integration with Legacy Code or Third Party Code 78 Your Domain Model Is not Your Enterprise Model 79 Use Bounded Contexts to Divide and Conquer a Large Model 79 Defining a Model’s Boundary 82 Define Boundaries around Language 82 Align to Business Capabilities 83 Create Contexts around Teams 83 Try to Retain Some Communication between Teams 84 Context Game 85 The Difference between a Subdomain and a Bounded Context 85 Implementing Bounded Contexts 85 The Salient Points 89 CHAPTER 7: CONTEXT MAPPING 91 A Reality Map 92 The Technical Reality 92 The Organizational Reality 93 Mapping a Relevant Reality 94 X Marks the Spot of the Core Domain 94 Recognising the Relationships between Bounded Contexts 95 Anticorruption Layer 95 Shared Kernel 96 Open Host Service 97 Separate Ways 97 Partnership 98 An Upstream/Downstream Relationship 98 Customer‐Supplier 99 Conformist 100 Communicating the Context Map 100 The Strategic Importance of Context Maps 101 Retaining Integrity 101 The Basis for a Plan of Attack 101 Understanding Ownership and Responsibility 101 Revealing Areas of Confusion in Business Work Flow 102 Identifying Nontechnical Obstacles 102 Encourages Good Communication 102 Helps On‐Board New Starters 102 The Salient Points 103 CHAPTER 8: APPLICATION ARCHITECTURE 105 Application Architecture 105 Separating the Concerns of Your Application 106 Abstraction from the Complexities of the Domain 106 A Layered Architecture 106 Dependency Inversion 107 The Domain Layer 107 The Application Service Layer 108 The Infrastructural Layers 108 Communication Across Layers 108 Testing in Isolation 109 Don t Share Data Schema between Bounded Contexts 109 Application Architectures versus Architectures for Bounded Contexts 111 Application Services 112 Application Logic versus Domain Logic 114 Defining and Exposing Capabilities 114 Business Use Case Coordination 115 Application Services Represent Use Cases, Not Create, Read, Update, and Delete 115 Domain Layer As an Implementation Detail 115 Domain Reporting 116 Read Models versus Transactional Models 116 Application Clients 117 The Salient Points 120 CHAPTER 9: COMMON PROBLEMS FOR TEAMS STARTING OUT WITH DOMAIN‐DRIVEN DESIGN 121 Overemphasizing the Importance of Tactical Patterns 122 Using the Same Architecture for All Bounded Contexts 122 Striving for Tactical Pattern Perfection 122 Mistaking the Building Blocks for the Value of DDD 123 Focusing on Code Rather Than the Principles of DDD 123 Missing the Real Value of DDD: Collaboration, Communication, and Context 124 Producing a Big Ball of Mud Due to Underestimating the Importance of Context 124 Causing Ambiguity and Misinterpretations by Failing to Create a UL 125 Designing Technical‐Focused Solutions Due to a Lack of Collaboration 125 Spending Too Much Time on What’s Not Important 126 Making Simple Problems Complex 126 Applying DDD Principles to a Trivial Domain with Little Business Expectation 126 Disregarding CRUD as an Antipattern 127 Using the Domain Model Pattern for Every Bounded Context 127 Ask Yourself: Is It Worth This Extra Complexity? 127 Underestimating the Cost of Applying DDD 127 Trying to Succeed Without a Motivated and Focused Team 128 Attempting Collaboration When a Domain Expert Is Not Behind the Project 128 Learning in a Noniterative Development Methodology 128 Applying DDD to Every Problem 129 Sacrificing Pragmatism for Needless Purity 129 Wasted Effort by Seeking Validation 129 Always Striving for Beautiful Code 130 DDD Is About Providing Value 130 The Salient Points 130 CHAPTER 10: APPLYING THE PRINCIPLES, PRACTICES, AND PATTERNS OF DDD 131 Selling DDD 132 Educating Your Team 132 Speaking to Your Business 132 Applying the Principles of DDD 133 Understand the Vision 133 Capture the Required Behaviors 134 Distilling the Problem Space 134 Focus on What Is Important 134 Understand the Reality of the Landscape 135 Modeling a Solution 135 All Problems Are Not Created Equal 136 Engaging with an Expert 136 Select a Behavior and Model Around a Concrete Scenario 137 Collaborate with the Domain Expert on the Most Interesting Parts 137 Evolve UL to Remove Ambiguity 138 Throw Away Your First Model, and Your Second 138 Implement the Model in Code 139 Creating a Domain Model 139 Keep the Solution Simple and Your Code Boring 139 Carve Out an Area of Safety 140 Integrate the Model Early and Often 140 Nontechnical Refactoring 140 Decompose Your Solution Space 140 Rinse and Repeat 141 Exploration and Experimentation 142 Challenge Your Assumptions 142 Modeling Is a Continuous Activity 142 There Are No Wrong Models 142 Supple Code Aids Discovery 143 Making the Implicit Explicit 143 Tackling Ambiguity 144 Give Things a Name 145 A Problem Solver First, A Technologist Second 146 Don’t Solve All the Problems 146 How Do I Know That I Am Doing It Right? 146 Good Is Good Enough 147 Practice, Practice, Practice 147 The Salient Points 147 PART II: STRATEGIC PATTERNS: COMMUNICATING BETWEEN BOUNDED CONTEXTS CHAPTER 11: INTRODUCTION TO BOUNDED CONTEXT INTEGRATION 151 How to Integrate Bounded Contexts 152 Bounded Contexts Are Autonomous 153 The Challenges of Integrating Bounded Contexts at the Code Level 153 Multiple Bounded Contexts Exist within a Solution 153 Namespaces or Projects to Keep Bounded Contexts Separate 154 Integrating via the Database 155 Multiple Teams Working in a Single Codebase 156 Models Blur 156 Use Physical Boundaries to Enforce Clean Models 157 Integrating with Legacy Systems 158 Bubble Context 158 Autonomous Bubble Context 158 Exposing Legacy Systems as Services 160 Integrating Distributed Bounded Contexts 161 Integration Strategies for Distributed Bounded Contexts 161 Database Integration 162 Flat File Integration 163 RPC 164 Messaging 165 REST 165 The Challenges of DDD with Distributed Systems 165 The Problem with RPC 166 RPC Is Harder to Make Resilient 167 RPC Costs More to Scale 167 RPC Involves Tight Coupling 168 Distributed Transactions Hurt Scalability and Reliability 169 Bounded Contexts Don’t Have to Be Consistent with Each Other 169 Eventual Consistency 169 Event‐Driven Reactive DDD 170 Demonstrating the Resilience and Scalability of Reactive Solutions 171 Challenges and Trade‐Offs of Asynchronous Messaging 173 Is RPC Still Relevant? 173 SOA and Reactive DDD 174 View Your Bounded Contexts as SOA Services 175 Decompose Bounded Contexts into Business Components 175 Decompose Business Components into Components 176 Going Even Further with Micro Service Architecture 178 The Salient Points 180 CHAPTER 12: INTEGRATING VIA MESSAGING 181 Messaging Fundamentals 182 Message Bus 182 Reliable Messaging 184 Store‐and‐Forward 184 Commands and Events 185 Eventual Consistency 186 Building an E‐Commerce Application with NServiceBus 186 Designing the System 187 Domain‐Driven Design 187 Containers Diagrams 188 Evolutionary Architecture 191 Sending Commands from a Web Application 192 Creating a Web Application to Send Messages with NServiceBus 192 Sending Commands 197 Handling Commands and Publishing Events 200 Creating an NServiceBus Server to Handle Commands 200 Configuring the Solution for Testing and Debugging 201 Publishing Events 204 Subscribing to Events 206 Making External HTTP Calls Reliable with Messaging Gateways 208 Messaging Gateways Improve Fault Tolerance 208 Implementing a Messaging Gateway 209 Controlling Message Retries 212 Eventual Consistency in Practice 215 Dealing with Inconsistency 215 Rolling Forward into New States 215 Bounded Contexts Store All the Data They Need Locally 216 Storage Is Cheap—Keep a Local Copy 217 Common Data Duplication Concerns 223 Pulling It All Together in the UI 224 Business Components Need Their Own APIs 225 Be Wary of Server‐Side Orchestration 226 UI Composition with AJAX Data 226 UI Composition with AJAX HTML 226 Sharing Your APIs with the Outside World 227 Maintaining a Messaging Application 227 Message Versioning 228 Backward‐Compatible Message Versioning 228 Handling Versioning with NServiceBus’s Polymorphic Handlers 229 Monitoring and Scaling 233 Monitoring Errors 233 Monitoring SLAs 234 Scaling Out 235 Integrating a Bounded Context with Mass Transit 235 Messaging Bridge 236 Mass Transit 236 Installing and Configuring Mass Transit 236 Declaring Messages for Use by Mass Transit 238 Creating a Message Handler 239 Subscribing to Events 239 Linking the Systems with a Messaging Bridge 240 Publishing Events 242 Testing It Out 243 Where to Learn More about Mass Transit 243 The Salient Points 243 CHAPTER 13: INTEGRATING VIA HTTP WITH RPC AND REST 245 Why Prefer HTTP? 247 No Platform Coupling 247 Everyone Understands HTTP 247 Lots of Mature Tooling and Libraries 247 Dogfooding Your APIs 247 RPC 248 Implementing RPC over HTTP 248 SOAP 249 Plain XML or JSON: The Modern Approach to RPC 259 Choosing a Flavor of RPC 263 REST 264 Demystifying REST 264 Resources 264 Hypermedia 265 Statelessness 265 REST Fully Embraces HTTP 266 What REST Is Not 267 REST for Bounded Context Integration 268 Designing for REST 268 Building Event‐Driven REST Systems with ASP.NET Web API 273 Maintaining REST Applications 303 Versioning 303 Monitoring and Metrics 303 Drawbacks with REST for Bounded Context Integration 304 Less Fault Tolerance Out of the Box 304 Eventual Consistency 304 The Salient Points 305 PART III: TACTICAL PATTERNS: CREATING EFFECTIVE DOMAIN MODELS CHAPTER 14: INTRODUCING THE DOMAIN MODELING BUILDING BLOCKS 309 Tactical Patterns 310 Patterns to Model Your Domain 310 Entities 310 Value Objects 314 Domain Services 317 Modules 318 Lifecycle Patterns 318 Aggregates 318 Factories 322 Repositories 323 Emerging Patterns 324 Domain Events 324 Event Sourcing 326 The Salient Points 327 CHAPTER 15: VALUE OBJECTS 329 When to Use a Value Object 330 Representing a Descriptive, Identity‐Less Concept 330 Enhancing Explicitness 331 Defining Characteristics 333 Identity‐Less 333 Attribute‐Based Equality 333 Behavior‐Rich 337 Cohesive 337 Immutable 337 Combinable 339 Self‐Validating 341 Testable 344 Common Modeling Patterns 345 Static Factory Methods 345 Micro Types (Also Known as Tiny Types) 347 Collection Aversion 349 Persistence 35 NoSQL 352 SQL 353 Flat Denormalization 353 Normalizing into Separate Tables 357 The Salient Points 359 CHAPTER 16: ENTITIES 36 Understanding Entities 362 Domain Concepts with Identity and Continuity 362 Context‐Dependent 363 Implementing Entities 363 Assigning Identifiers 363 Natural Keys 363 Arbitrarily Generated IDs 364 Datastore‐Generated IDs 368 Pushing Behavior into Value Objects and Domain Services 369 Validating and Enforcing Invariants 371 Focusing on Behavior, Not Data 374 Avoiding the “Model the Real‐World” Fallacy 377 Designing for Distribution 378 Common Entity Modeling Principles and Patterns 380 Implementing Validation and Invariants with Specifications 380 Avoid the State Pattern; Use Explicit Modeling 382 Avoiding Getters and Setters with the Memento Pattern 385 Favor Hidden‐Side‐Effect‐Free Functions 386 The Salient Points 388 CHAPTER 17: DOMAIN SERVICES 389 Understanding Domain Services 390 When to Use a Domain Service 390 Encapsulating Business Policies and Processes 390 Representing Contracts 394 Anatomy of a Domain Service 395 Avoiding Anemic Domain Models 395 Contrasting with Application Services 396 Utilizing Domain Services 397 In the Service Layer 397 In the Domain 398 Manually Wiring Up 399 Using Dependency Injection 400 Using a Service Locator 400 Applying Double Dispatch 401 Decoupling with Domain Events 402 Should Entities Even Know About Domain Services? 403 The Salient Points 403 CHAPTER 18: DOMAIN EVENTS 405 Essence of the Domain Events Pattern 406 Important Domain Occurrences That Have Already Happened 406 Reacting to Events 407 Optional Asynchrony 407 Internal vs External Events 408 Event Handling Actions 409 Invoke Domain Logic 409 Invoke Application Logic 410 Domain Events’ Implementation Patterns 410 Use the .Net Framework’s Events Model 410 Use an In‐Memory Bus 412 Udi Dahan’s Static DomainEvents Class 415 Handling Threading Issues 417 Avoid a Static Class by Using Method Injection 418 Return Domain Events 419 Use an IoC Container as an Event Dispatcher 421 Testing Domain Events 422 Unit Testing 422 Application Service Layer Testing 424 The Salient Points 425 CHAPTER 19: AGGREGATES 427 Managing Complex Object Graphs 428 Favoring a Single Traversal Direction 428 Qualifying Associations 430 Preferring IDs Over Object References 431 Aggregates 434 Design Around Domain Invariants 435 Higher Level of Domain Abstraction 435 Consistency Boundaries 435 Transactional Consistency Internally 436 Eventual Consistency Externally 439 Special Cases 440 Favor Smaller Aggregates 441 Large Aggregates Can Degrade Performance 441 Large Aggregates Are More Susceptible to Concurrency Conflicts 442 Large Aggregates May Not Scale Well 442 Defining Aggregate Boundaries 442 eBidder: The Online Auction Case Study 443 Aligning with Invariants 444 Aligning with Transactions and Consistency 446 Ignoring User Interface Influences 448 Avoiding Dumb Collections and Containers 448 Don’t Focus on HAS‐A Relationships 449 Refactoring to Aggregates 449 Satisfying Business Use Cases—Not Real Life 449 Implementing Aggregates 450 Selecting an Aggregate Root 450 Exposing Behavioral Interfaces 452 Protecting Internal State 453 Allowing Only Roots to Have Global Identity 454 Referencing Other Aggregates 454 Nothing Outside An Aggregate’s Boundary May Hold a Reference to Anything Inside 455 The Aggregate Root Can Hand Out Transient References to the Internal Domain Objects 456 Objects within the Aggregate Can Hold References to Other Aggregate Roots 456 Implementing Persistence 458 Access to Domain Objects for Reading Can Be at the Database Level 460 A Delete Operation Must Remove Everything within the Aggregate Boundary at Once 461 Avoiding Lazy Loading 461 Implementing Transactional Consistency 462 Implementing Eventual Consistency 463 Rules That Span Multiple Aggregates 463 Asynchronous Eventual Consistency 464 Implementing Concurrency 465 The Salient Points 468 CHAPTER 20: FACTORIES 469 The Role of a Factory 469 Separating Use from Construction 470 Encapsulating Internals 470 Hiding Decisions on Creation Type 472 Factory Methods on Aggregates 474 Factories for Reconstitution 475 Use Factories Pragmatically 477 The Salient Points 477 CHAPTER 21: REPOSITORIES 479 Repositories 479 A Misunderstood Pattern 481 Is the Repository an Antipattern? 481 The Difference between a Domain Model and a Persistence Model 482 The Generic Repository 483 Aggregate Persistence Strategies 486 Using a Persistence Framework That Can Map the Domain Model to the Data Model without Compromise 486 Using a Persistence Framework That Cannot Map the Domain Model Directly without Compromise 487 Public Getters and Setters 487 Using the Memento Pattern 488 Event Streams 49 Be Pragmatic 491 A Repository Is an Explicit Contract 492 Transaction Management and Units of Work 493 To Save or Not To Save 497 Persistence Frameworks That Track Domain Object Changes 497 Having to Explicitly Save Changes to Aggregates 498 The Repository as an Anticorruption Layer 499 Other Responsibilities of a Repository 500 Entity ID Generation 500 Collection Summaries 502 Concurrency 503 Audit Trails 506 Repository Antipatterns 506 Antipatterns: Don’t Support Ad Hoc Queries 506 Antipatterns: Lazy Loading Is Design Smell 507 Antipatterns: Don’t Use Repositories for Reporting Needs 507 Repository Implementations 508 Persistence Framework Can Map Domain Model to Data Model without Compromise 509 NHibernate Example 509 RavenDB Example 543 Persistence Framework Cannot Map Domain Model Directly without Compromise 557 Entity Framework Example 558 Micro ORM Example 577 The Salient Points 593 CHAPTER 22: EVENT SOURCING 595 The Limitations of Storing State as a Snapshot 596 Gaining Competitive Advantage by Storing State as a Stream of Events 597 Temporal Queries 597 Projections 599 Snapshots 599 Event‐Sourced Aggregates 600 Structuring 600 Adding Event‐Sourcing Capabilities 601 Exposing Expressive Domain‐Focused APIs 602 Adding Snapshot Support 604 Persisting and Rehydrating 605 Creating an Event-Sourcing Repository 605 Adding Snapshot Persistence and Reloading 607 Handling Concurrency 609 Testing 610 Building an Event Store 611 Designing a Storage Format 612 Creating Event Streams 614 Appending to Event Streams 614 Querying Event Streams 615 Adding Snapshot Support 616 Managing Concurrency 618 A SQL Server‐Based Event Store 621 Choosing a Schema 621 Creating a Stream 622 Saving Events 623 Loading Events from a Stream 624 Snapshots 625 Is Building Your Own Event Store a Good Idea? 627 Using the Purpose‐Built Event Store 627 Installing Greg Young’s Event Store 628 Using the C# Client Library 627 Running Temporal Queries 632 Querying a Single Stream 632 Querying Multiple Streams 634 Creating Projections 635 CQRS with Event Sourcing 637 Using Projections to Create View Caches 638 CQRS and Event Sourcing Synergy 638 Event Streams as Queues 639 No Two‐Phase Commits 639 Recapping the Benefits of Event Sourcing 639 Competitive Business Advantage 639 Expressive Behavior‐Focused Aggregates 639 Simplified Persistence 640 Superior Debugging 640 Weighing the Costs of Event Sourcing 640 Versioning 640 New Concepts to Learn and Skills to Hone 640 New Technologies to Learn and Master 641 Greater Data Storage Requirements 641 Additional Learning Resources 641 The Salient Points 641 PART IV: DESIGN PATTERNS FOR EFFECTIVE APPLICATIONS CHAPTER 23: ARCHITECTING APPLICATION USER INTERFACES 645 Design Considerations 646 Owned UIs versus Composed UIs 646 Autonomous 646 Authoritative 647 Some Help Deciding 648 HTML APIs versus Data APIs 649 Client versus Server‐Side Aggregation/Coordination 649 Example 1: An HTML API‐Based, Server‐Side UI for Nondistributed Bounded Contexts 651 Example 2: A Data API‐Based, Client‐Side UI for Distributed Bounded Contexts 658 The Salient Points 667 CHAPTER 24: CQRS: AN ARCHITECTURE OF A BOUNDED CONTEXT 669 The Challenges of Maintaining a Single Model for Two Contexts 670 A Better Architecture for Complex Bounded Contexts 670 The Command Side: Business Tasks 672 Explicitly Modeling Intent 672 A Model Free from Presentational Distractions 674 Handling a Business Request 675 The Query Side: Domain Reporting 676 Reports Mapped Directly to the Data Model 676 Materialized Views Built from Domain Events 678 The Misconceptions of CQRS 679 CQRS Is Hard 679 CQRS Is Eventually Consistent 679 Your Models Need to Be Event Sourced 680 Commands Should Be Asynchronous 680 CQRS Only Works with Messaging Systems 680 You Need to Use Domain Events with CQRS 680 Patterns to Enable Your Application to Scale 680 Scaling the Read Side: An Eventually Consistent Read Model 681 The Impact to the User Experience 682 Use the Read Model to Consolidate Many Bounded Contexts 682 Using a Reporting Database or a Caching Layer 682 Scaling the Write Side: Using Asynchronous Commands 683 Command Validation 683 Impact to the User Experience 684 Scaling It All 684 The Salient Points 685 CHAPTER 25: COMMANDS: APPLICATION SERVICE PATTERNS FOR PROCESSING BUSINESS USE CASES 687 Differentiating Application Logic and Domain Logic 689 Application Logic 689 Infrastructural Concerns 690 Coordinating Full Business Use Cases 698 Application Services and Framework Integration 698 Domain Logic from an Application Service’s Perspective 700 Application Service Patterns 700 Command Processor 701 Publish/Subscribe 704 Request/Reply Pattern 706 async/await 708 Testing Application Services 709 Use Domain Terminology 709 Test as Much Functionality as Possible 710 The Salient Points 712 CHAPTER 26: QUERIES: DOMAIN REPORTING 713 Domain Reporting within a Bounded Context 714 Deriving Reports from Domain Objects 714 Using Simple Mappings 714 Using the Mediator Pattern 718 Going Directly to the Datastore 720 Querying a Datastore 721 Reading Denormalized View Caches 724 Building Projections from Event Streams 726 Setting Up ES for Projections 727 Creating Reporting Projections 728 Counting the Number of Events in a Stream 729 Creating As Many Streams As Required 729 Building a Report from Streams and Projections 730 Domain Reporting Across Bounded Contexts 733 Composed UI 733 Separate Reporting Context 734 The Salient Points 736 INDEX 737
£37.50
John Wiley & Sons Inc Data Structures and Algorithms in Java
Book SynopsisThe design and analysis of efficient data structures has long been recognized as a key component of the Computer Science curriculum. Goodrich and Tomassia's approach to this classic topic is based on the object-oriented paradigm as the framework of choice for the design of data structures.Table of Contents1 Java Primer 2 Object-Oriented Design 3 Fundamental Data Structures 4 Algorithm Analysis 5 Recursion 6 Stacks, Queues, and Deques 7 List and Iterator ADTs 8 Trees 9 Priority Queues 10 Maps, Hash Tables, and Skip Lists 11 Search Trees 12 Text Processing13 Sorting and Selection 14 Graph Algorithms 15 Memory Management and B-Trees
£45.59
Dover Publications Inc. An Introduction to Functional Programming Through
Book Synopsis
£23.59
Mike Murach & Associates Inc. Murach's Java Programming (6th Edition)
Book Synopsis
£45.74
The Pragmatic Programmers Learn to Program
Book SynopsisIt's easier to learn how to program a computer than it has ever been before. Now everyone can learn to write programs for themselves - no previous experience is necessary. Chris Pine takes a thorough, but lighthearted approach that teaches you the fundamentals of computer programming, with a minimum of fuss or bother. Whether you are interested in a new hobby or a new career, this book is your doorway into the world of programming. Computers are everywhere, and being able to program them is more important than it has ever been. But since most books on programming are written for other programmers, it can be hard to break in. At least it used to be. Chris Pine will teach you how to program. You'll learn to use your computer better, to get it to do what you want it to do. Starting with small, simple one-line programs to calculate your age in seconds, you'll see how to write interactive programs, to use APIs to fetch live data from the internet, to rename your photos from your digital camera, and more. You'll learn the same technology used to drive modern dynamic websites and large, professional applications. Whether you are looking for a fun new hobby or are interested in entering the tech world as a professional, this book gives you a solid foundation in programming. Chris teaches the basics, but also shows you how to think like a programmer. You'll learn through tons of examples, and through programming challenges throughout the book. When you finish, you'll know how and where to learn more - you'll be on your way. What You Need: All you need to learn how to program is a computer (Windows, macOS, or Linux) and an internet connection. Chris Pine will lead you through setting set up with the software you will need to start writing programs of your own.
£35.14
O'Reilly Media Concurrency in C Cookbook
Book SynopsisIf you're one of the many developers uncertain about concurrent and multithreaded development, this practical cookbook will change your mind. With more than 75 code-rich recipes, author Stephen Cleary demonstrates parallel processing and asynchronous programming techniques, using libraries and language features in .NET and C#.
£33.74
Manning Publications Get Programming with Haskell
Book SynopsisUnlike any other programming language, Haskell is purely functionalwith a strong type system and lazy evaluation. It is arguable the mostinteresting language but also has the reputation of being one of themost challenging to learn. Learning Haskell doesn't have to bedifficult, and this book can help! Get Programming with Haskell introduces you to the Haskell languagewithout drowning you in academic jargon and heavy functionalprogramming theory. By working through 43 easy-to-follow lessons,you'll learn Haskell by doing Haskell. This book starts with firstconcepts, building your knowledge with concrete examples andexercises. You'll learn to think the Haskell way, as you start tounderstand the language and how to use it effectively. And you'll reallyappreciate the crystal-clear illustrations, quick-checks, and open-endedtasks that make sure you're solid on each new concept before you movealong! KEY FEATURES• Full of interesting examples• Easy approach to functional programming basics• Write safe, predictable code with fewer bugs• Lots of illustrations and exercises Readers should have some experience with JavaScript, Python orRuby. No functional programming or math skills required. ABOUT THE TECHNOLOGYHaskell is a purely functional programming language. It treats programs asmuch like math as you can, requires you to think more than you type, andcan express the idea of infinite lists in code! These are just the more obviousfeatures that make Haskell unlike any other programming language AUTHOR BIOWill Kurt currently works as a Data Scientist at Quick Sprout. With aformal background in both Computer Science (MS) and English Literature(BA) he is fascinated with explaining complex technical topics as clearlyand generally as possible. He has taught a course section on Haskell at theUniversity of Nevada, Reno and given workshops on FunctionalProgramming. He also blogs about probability at CountBayesie.com.
£32.39
The Pragmatic Programmers From Objects to Functions: Build Your Software
Book SynopsisBuild applications quicker and with less effort using functional programming and Kotlin. Learn by building a complete application, from gathering requirements to delivering a microservice architecture following functional programming principles. Learn how to implement CQRS and EventSourcing in a functional way to map the domain into code better and to keep the cost of change low for the whole application life cycle. If you're curious about functional programming or you are struggling with how to put it into practice, this guide will help you increase your productivity composing small functions together instead of creating fat objects. Switching to the functional paradigm isn't easy when you're used to object-oriented programming. You need more than just lambdas and mapping over collections to get a declarative style and disentangle the state from the computations. Use transformations and compositions to help you write less code with better results. Boost your productivity and harness the power of functional programming by creating real-world applications rather than focusing on theoretical concepts. Work through a series of short exercises to find and compose pure functions, and create data structures that work like algebra. Get rid of mutable state in your software to eliminate the main source of bugs. Apply CQRS and EventSourcing patterns to translate stakeholder requirements into functional design and then into code. See how Kotlin's easy-to-learn syntax and functional-friendly approach make it a great option for a pragmatic language that integrates well with existing Java code and libraries. Leverage functional programming to build and deliver robust applications in less time and with fewer defects. What You Need: The code in this book is designed to allow you to build your application from scratch on Windows, Mac and Linux. You will need a recent IDE, we recommend IntelliJ Community Edition, and Kotlin 1.3.x or later.
£36.57
ESRI Press Advanced Python Scripting for ArcGIS Pro
Book SynopsisTackle complex spatial data tasks effortlessly with this easy-to-follow guide to writing specialized Python scripts and developing tools for spatial data?in ArcGIS Pro.Advanced Python Scripting for ArcGIS Pro?follows up on the topics explained in?Python Scripting for ArcGIS Pro?(Esri Press, 2024) and is now updated for ArcGIS Pro 3.2.Intended for users who have a good foundation in Python, this book explores how to develop scripts into tools and notebooks to share with others, use third-party packages, and learn other more specialized tasks. By the end of this book, you'll be confident in writing more advanced scripts, developing them into tools and notebooks, and sharing them with others.The key topics you will learn include: Creating custom functions and classes Writing specialized scripts using?ArcPy Creating Python script tools and Python toolboxes Sharing scripts and tools Managing Python packages and environments Migrating scripts from Python 2 to 3 NumPy, Pandas, and Matplotlib Creating and using notebooks ArcGIS API for Python and?Jupyter?Notebook Helpful points to remember, key terms, and review questions are included at the end of each chapter to reinforce your understanding of Python. Companion data and tutorials are available online.Packed with advanced techniques and practical examples, Advanced Python Scripting for ArcGIS Pro?is perfect for more experienced ArcGIS Pro users who are looking to upgrade their Python skills and enhance their workflows.
£60.79
In Easy Steps Limited C++ Programming in easy steps
Book SynopsisC++ Programming in easy steps, 6th edition shows you how to program in the powerful C++ native system language. Now, in its sixth edition, this guide gives complete examples that illustrate each aspect with colorized source code. Updated for the latest GNU C Compiler and Visual Studio 2022.C++ Programming in easy steps, 6th edition begins by explaining how to install a free C++ compiler so you can quickly begin to create your own executable programs by copying the book's examples. It demonstrates all the C++ language basics before moving on to provide examples of Object Oriented Programming (OOP). C++ is not platform-dependent, so programs can be created on any operating system. Most illustrations in this book depict output on the Windows operating system (purely because it is the most widely-used desktop platform) but the examples can also be created on other platforms such as Linux or macOS. The book concludes by demonstrating how you can use your acquired knowledge to create programs graphically using a modern C++ Integrated Development Environment (IDE), such as Microsoft's Visual Studio 2022. C++ Programming in easy steps, 6th edition has an easy-to-follow style that will appeal to: Anyone who wants to begin programming in C++.Programmers looking to advance from an interpreted programming language, such as Python, who want to harness the superior speed of C++.Students who are studying C++ Programming at school or college. Those seeking a career in computing who need a fundamental understanding of Object Oriented Programming. This book makes no assumption that you have previous knowledge of any programming language, so it is suitable for the beginner to programming in C++, whether you know C or not.
£11.99
Manning Publications Unity in Action
Book SynopsisCreate your first 2D, 3D, and AR/VR games with the awesome Unity game platform. With this hands-on beginner's guide, you'll start building games fast! In Unity in Action, Third Edition, you will learn how to: Create characters that run, jump, and bump into things Build 3D first-person shooters and third-person action games Construct 2D card games and side-scrolling platformers Script enemies with AI Improve game graphics by importing models and images Design an intuitive user interface for your games Play music and spatially-aware sound effects Connect your games to the internet for online play Deploy your games to desktop, mobile, and the web Thousands of new game developers have chosen Joe Hocking's Unity in Action as their first step toward Unity mastery. This fully updated third edition comes packed with fully refreshed graphics, Unity's latest features, and coverage of the augmented and virtual reality toolkits. Using your existing coding skills, you'll write custom code instead of just clicking together premade scripts. You'll master the Unity toolset from the ground up, adding the skills you need to go from application coder to game developer. Build your next game without sweating the low-level details. The Unity game engine handles the heavy lifting, so you can focus on game play, graphics, and user experience. With support for C#, a huge ecosystem of production-quality prebuilt assets, and a strong dev community, Unity will get your game idea off the drawing board and onto the screen! You can even use Unity for more than game development, with new tools for VR and augmented reality that are perfect for developing useful apps.Trade ReviewThis is the best resource, bar none, for an introduction to Unity and fundamental game programming concepts. Erik Hansson This book is a wonderful introduction to Unity. I believe this book will be very useful to readers from a wide range of backgrounds. Everything is explained very well and is easy to read and understand. Kent R. Spillner This is a great introduction to Unity. I think it could even be used as the foundation for a high school or college course. Robert Walsh If you want to start building games as a hobby or a profession, this is a good place to start! Bradley Irby A great introduction to learning Game development with Unity and C#. The author steps you through all the elements of Unity so if you've never used Unity before, don't worry about it. Owain Williams If you already have some programming experience, this book on Unity can really help you connect into a new platform and enable you to create a game! James Matlock
£36.09
In Easy Steps Limited C Programming in easy steps
Book SynopsisC++ Programming in easy steps, 7th edition shows you how to program in the powerful C++ native system language. Now, in its seventh edition, this guide gives complete examples that illustrate each aspect with colorized source code.C++ Programming in easy steps, 7th edition begins by explaining how to install a free C++ compiler so that you can quickly begin to create your own executable programs by copying the book’s examples. It demonstrates all the C++ language basics before moving on to provide examples of Object Oriented Programming (OOP). C++ is not platform-dependent, so programs can be created on any operating system. Most illustrations in this book depict output on the Windows operating system (purely because it is the most widely-used desktop platform) but the examples can also be created on other platforms such as Linux or macOS. The book concludes by demonstrating how you can use your acquired knowledge to create programs graphically using a modern C++ Integrated Development Environment (IDE), such as Microsoft’s Visual Studio. C++ Programming in easy steps, 7th edition has an easy-to-follow style that will appeal to: Anyone who wants to begin programming in C++.Programmers looking to advance from an interpreted programming language, such as Python, who want to harness the superior speed of C++.Students who are studying C++ Programming at school or college. Those seeking a career in computing who need a fundamental understanding of Object Oriented Programming. This book makes no assumption that you have previous knowledge of any programming language, so it is suitable for the beginner to programming in C++, whether you know C or not.
£15.99
Elsevier Science API Design for C
Book SynopsisThe design of application programming interfaces can affect the behavior, capabilities, stability, and ease of use of end-user applications. This book helps you learn how to design a good API for large-scale long-term projects. With C++ code to illustrate each concept, it covers the various strategies of API development.Trade Review"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 & ResearchTable of ContentsIntroduction 1. Qualities 2. Patterns 3. Design 4. Styles 5. C++ Usage 6. Performance 7. Versioning 8. Documentation 9. Testing 10. Scripting 11. Extensibility Appendix A: Libraries Bibliography Index
£47.49
Pearson Education Learning to Program with Alice w CD ROM
Book SynopsisWanda Dann is the Director of the Alice Project and Associate Teaching Professor of Computer Science at Carnegie Mellon University. Her research has encompassed program visualization and object-oriented and event-driven programming. She has published papers on the use of program visualization in computer science education for SIGCSE, the Computer Science Education Journal, and related publications. She has been co-PI for three NSF-funded projects. She is an active member of the ITiCSE Visualization Working Group, studying the effectiveness of visualization in computer science education. She has taken on a major leadership role in the international computer science education community, serving as SIGCSE 2004 Program co-Chair and SIGCSE 2005 Symposium co-Chair.Stephen Cooper is an Associate Professor of Computer Science and the Director for the Center for Visualization at Saint Joseph's University.He taught previously at Rivier College, serving as
£130.94
Pearson Education (US) Data Structures and Algorithm Analysis in Java
Book SynopsisMark Allen Weiss is Professor and Associate Director for the School of Computing and Information Sciences at Florida International University. He is also currently serving as both Director of Undergraduate Studies and Director of Graduate Studies. He received his Bachelor's Degree in Electrical Engineering from the Cooper Union in 1983, and his Ph.D. in Computer Science from Princeton University in 1987, working under Bob Sedgewick. He has been at FIU since 1987 and was promoted to Professor in 1996. His interests include data structures, algorithms, and education. He is most well-known for his highly-acclaimed Data Structures textbooks, which have been used for a generation by roughly a million students. Professor Weiss is the author of numerous publications in top-rated journals and was recipient of the University's Excellence in Research Award in 1994. In 1996 at FIU he was the first in the world to teach Data Structures using the Java programming language, which isTable of ContentsTable of Contents Chapter 1 Introduction 1.1 What’s the Book About? 1.2 Mathematics Review 1.2.1 Exponents 1.2.2 Logarithms 1.2.3 Series 1.2.4 Modular Arithmetic 1.2.5 The P Word 1.3 A Brief Introduction to Recursion 1.4 Implementing Generic Components Pre-Java 5 1.4.1 Using Object for Genericity 1.4.2 Wrappers for Primitive Types 1.4.3 Using Interface Types for Genericity 1.4.4 Compatibility of Array Types 1.5 Implementing Generic Components Using Java 5 Generics 1.5.1 Simple Generic Classes and Interfaces 1.5.2 Autoboxing/Unboxing 1.5.3 The Diamond Operator 1.5.4 Wildcards with Bounds 1.5.5 Generic Static Methods 1.5.6 Type Bounds 1.5.7 Type Erasure 1.5.8 Restrictions on Generics 1.6 Function Objects Summary Exercises References Chapter 2 Algorithm Analysis 2.1 Mathematical Background 2.2 Model 2.3 What to Analyze 2.4 Running Time Calculations 2.4.1 A Simple Example 2.4.2 General Rules 2.4.3 Solutions for the Maximum Subsequence Sum Problem 2.4.4 Logarithms in the Running Time 2.4.5 A Grain of Salt Summary Exercises References Chapter 3 Lists, Stacks, and Queues 3.1 Abstract Data Types (ADTs) 3.2 The List ADT 3.2.1 Simple Array Implementation of Lists 3.2.2 Simple Linked Lists 3.3 Lists in the Java Collections API 3.3.1 Collection Interface 3.3.2 Iterators 3.3.3 The List Interface, ArrayList, and LinkedList 3.3.4 Example: Using remove on a LinkedList 3.3.5 ListIterators 3.4 Implementation of ArrayList 3.4.1 The Basic Class 3.4.2 The Iterator and Java Nested and Inner Classes 3.5 Implementation of LinkedList 3.6 The Stack ADT 3.6.1 Stack Model 3.6.2 Implementation of Stacks 3.6.3 Applications 3.7 The Queue ADT 3.7.1 Queue Model 3.7.2 Array Implementation of Queues 3.7.3 Applications of Queues Summary Exercises Chapter 4 Trees 4.1 Preliminaries 4.1.1 Implementation of Trees 4.1.2 Tree Traversals with an Application 4.2 Binary Trees 4.2.1 Implementation 4.2.2 An Example: Expression Trees 4.3 The Search Tree ADT–Binary Search Trees 4.3.1 contains 4.3.2 findMin and findMax 4.3.3 insert 4.3.4 remove 4.3.5 Average-Case Analysis 4.4 AVL Trees 4.4.1 Single Rotation 4.4.2 Double Rotation 4.5 Splay Trees 4.5.1 A Simple Idea (That Does Not Work) 4.5.2 Splaying 4.6 Tree Traversals (Revisited) 4.7 B-Trees 4.8 Sets and Maps in the Standard Library 4.8.1 Sets 4.8.2 Maps 4.8.3 Implementation of TreeSet and TreeMap 4.8.4 An Example That Uses Several Maps Summary Exercises References Chapter 5 Hashing 5.1 General Idea 5.2 Hash Function 5.3 Separate Chaining 5.4 Hash Tables Without Linked Lists 5.4.1 Linear Probing 5.4.2 Quadratic Probing 5.4.3 Double Hashing 5.5 Rehashing 5.6 Hash Tables in the Standard Library 5.7 Hash Tables with Worst-Case O(1) Access 5.7.1 Perfect Hashing 5.7.2 Cuckoo Hashing 5.7.3 Hopscotch Hashing 5.8 Universal Hashing 5.9 Extendible Hashing Summary Exercises References Chapter 6 Priority Queues (Heaps) 6.1 Model 6.2 Simple Implementations 6.3 Binary Heap 6.3.1 Structure Property 6.3.2 Heap-Order Property 6.3.3 Basic Heap Operations 6.3.4 Other Heap Operations 6.4 Applications of Priority Queues 6.4.1 The Selection Problem 6.4.2 Event Simulation 6.5 d-Heaps 6.6 Leftist Heaps 6.6.1 Leftist Heap Property 6.6.2 Leftist Heap Operations 6.7 Skew Heaps 6.8 Binomial Queues 6.8.1 Binomial Queue Structure 6.8.2 Binomial Queue Operations 6.8.3 Implementation of Binomial Queues 6.9 Priority Queues in the Standard Library Summary Exercises References Chapter 7 Sorting 7.1 Preliminaries 7.2 Insertion Sort 7.2.1 The Algorithm 7.2.2 Analysis of Insertion Sort 7.3 A Lower Bound for Simple Sorting Algorithms 7.4 Shellsort 7.4.1 Worst-Case Analysis of Shellsort 7.5 Heapsort 7.5.1 Analysis of Heapsort 7.6 Mergesort 7.6.1 Analysis of Mergesort 7.7 Quicksort 7.7.1 Picking the Pivot 7.7.2 Partitioning Strategy 7.7.3 Small Arrays 7.7.4 Actual Quicksort Routines 7.7.5 Analysis of Quicksort 7.7.6 A Linear-Expected-Time Algorithm for Selection 7.8 A General Lower Bound for Sorting 7.8.1 Decision Trees 7.9 Decision-Tree Lower Bounds for Selection Problems 7.10 Adversary Lower Bounds 7.11 Linear-Time Sorts: Bucket Sort and Radix Sort 7.12 External Sorting 7.12.1 Why We Need New Algorithms 7.12.2 Model for External Sorting 7.12.3 The Simple Algorithm 7.12.4 Multiway Merge 7.12.5 Polyphase Merge 7.12.6 Replacement Selection Summary Exercises References Chapter 8 The Disjoint Set Class 8.1 Equivalence Relations 8.2 The Dynamic Equivalence Problem 8.3 Basic Data Structure 8.4 Smart Union Algorithms 8.5 Path Compression 8.6 Worst Case for Union-by-Rank and Path Compression 8.6.1 Slowly Growing Functions 8.6.2 An Analysis By Recursive Decomposition 8.6.3 An O(M log * N) Bound 8.6.4 An O( M α (M, N) ) Bound 8.7 An Application Summary Exercises References Chapter 9 Graph Algorithms 9.1 Definitions 9.1.1 Representation of Graphs 9.2 Topological Sort 9.3 Shortest-Path Algorithms 9.3.1 Unweighted Shortest Paths 9.3.2 Dijkstra’s Algorithm 9.3.3 Graphs with Negative Edge Costs 9.3.4 Acyclic Graphs 9.3.5 All-Pairs Shortest Path 9.3.6 Shortest-Path Example 9.4 Network Flow Problems 9.4.1 A Simple Maximum-Flow Algorithm 9.5 Minimum Spanning Tree 9.5.1 Prim’s Algorithm 9.5.2 Kruskal’s Algorithm 9.6 Applications of Depth-First Search 9.6.1 Undirected Graphs 9.6.2 Biconnectivity 9.6.3 Euler Circuits 9.6.4 Directed Graphs 9.6.5 Finding Strong Components 9.7 Introduction to NP-Completeness 9.7.1 Easy vs. Hard 9.7.2 The Class NP 9.7.3 NP-Complete Problems Summary Exercises References Chapter 10 Algorithm Design Techniques 10.1 Greedy Algorithms 10.1.1 A Simple Scheduling Problem 10.1.2 Huffman Codes 10.1.3 Approximate Bin Packing 10.2 Divide and Conquer 10.2.1 Running Time of Divide-and-Conquer Algorithms 10.2.2 Closest-Points Problem 10.2.3 The Selection Problem 10.2.4 Theoretical Improvements for Arithmetic Problems 10.3 Dynamic Programming 10.3.1 Using a Table Instead of Recursion 10.3.2 Ordering Matrix Multiplications 10.3.3 Optimal Binary Search Tree 10.3.4 All-Pairs Shortest Path 10.4 Randomized Algorithms 10.4.1 Random Number Generators 10.4.2 Skip Lists 10.4.3 Primality Testing 10.5 Backtracking Algorithms 10.5.1 The Turnpike Reconstruction Problem 10.5.2 Games Summary Exercises References Chapter 11 Amortized Analysis 11.1 An Unrelated Puzzle 11.2 Binomial Queues 11.3 Skew Heaps 11.4 Fibonacci Heaps 11.4.1 Cutting Nodes in Leftist Heaps 11.4.2 Lazy Merging for Binomial Queues 11.4.3 The Fibonacci Heap Operations 11.4.4 Proof of the Time Bound 11.5 Splay Trees Summary Exercises References Chapter 12 Advanced Data Structures and Implementation 12.1 Top-Down Splay Trees 12.2 Red-Black Trees 12.2.1 Bottom-Up Insertion 12.2.2 Top-Down Red-Black Trees 12.2.3 Top-Down Deletion 12.3 Treaps 12.4 Suffix Arrays and Suffix Trees 12.4.1 Suffix Arrays 12.4.2 Suffix Trees 12.4.3 Linear-Time Construction of Suffix Arrays and Suffix Trees 12.5 k-d Trees 12.6 Pairing Heaps Summary Exercises References Index
£158.01
SIGS ObjectOriented COBOL
Book SynopsisThis is the only book that walks COBOL users through the next phase of COBOL: Object-Oriented COBOL (OOCOBOL). Written by experts in COBOL programming, Object-Oriented COBOL teaches you how to integrate COBOL with object-oriented methodologies. It provides explanations and roadmaps that will help you understand, navigate, and successfully integrate analysis and design concepts with enabling OOCOBOL constructs. Designed for current COBOL users and based on the authors' experience teaching Object-Oriented COBOL, experienced COBOL programmers can use Object-Oriented COBOL to begin programming effectively with objects in as little as twelve weeks, significantly less than the steep learning curve of twelve to twenty-four months for Smalltalk and C++. Object-Oriented COBOL also includes extensive examples and experiences, written in OOCOBOL, that explain the defining traits of an object-oriented language, such as encapsulation, inheritance, and polymorphism.Trade Review"I would recommend this book for those interested in seeing how an object-oriented structure can be imposed on a flat language like COBOL." Computing ReviewsTable of ContentsPart I. Concepts: 1. COBOL and objects; 2. An object-oriented COBOL model; Part II. Constructs: 3. Classes - a matter of structure; 4. Objects; 5. Inheritance; Part III. Objects in Action: 6. Messages; 7. Creating and destroying objects; 8. Working with objects; 9. Collections; Part IV. Putting Objects to Work: 10. Object-oriented analysis and design; 11. Migrating Legacy Systems; Appendix A. Object-oriented COBOL vendors: Hitachi, IBM, and Micro Focus; Appendix B. The Library Application; Appendix C. COBOL reserved words; Appendix D. New COBOL reserved words; Appendix E. Intrinsic functions; Appendix F. COBOL 85/89 features.
£67.99
Pearson Education Java Software Structures
Book Synopsis
£168.88
Pearson Education Programming Abstractions in C
Book SynopsisAfter receiving his Ph.D. in Applied Mathematics from Harvard University in 1980, Eric Roberts taught at Wellesley College from 1980-85, where he chaired the Computer Science Department. From 1985-90, he was a member of the research staff at Digital Equipment Corporation's Systems Research Center in Palo Alto, California, where he conducted computer science research, focusing on programming tools for multiprocessor architectures. In September 1990, Roberts joined the Stanford faculty, where he is now Professor of Computer Science and the John A. and Cynthia Fry Gunn University Fellow in Undergraduate Education. From 1990 to 2002, Professor Roberts was Associate Chair and Director of Undergraduate Studies for Computer Science. In that capacity, he was the principal architect of Stanford's introductory programming sequence, which for many years held the distinction of being the largest course at Stanford. He has also written four computer science textbooks that are used at many
£177.77
Pearson Education (US) Agile Software Development Principles Patterns
Book Synopsis ROBERT C. MARTIN is President of Object Mentor Inc. Martin and his team of software consultants use Object-Oriented Design, Patterns, UML, Agile Methodologies, and eXtreme Programming with worldwide clients. He is the author of the best-selling book Designing Object-Oriented C++ Applications Using the Booch Method (Prentice Hall, 1995), Chief Editor of, Pattern Languages of Program Design 3 (Addison Wesley, 1997), Editor of, More C++ Gems (Cambridge, 1999), and co-author of XP in Practice, with James Newkirk (Addison-Wesley, 2001). He was Editor in Chief of the C++ Report from 1996 to 1999. He is a featured speaker at international conferences and trade shows. Table of Contents I. AGILE DEVELOPMENT. 1. Agile Practices. 2. Overview of Extreme Programming. 3. Planning. 4. Testing. 5. Refactoring. 6. A Programming Episode. II. AGILE DESIGN. 7. What Is Agile Design? 8. SRP: The Single-Responsibility Principle. 9. OCP: The Open-Closed Principle. 10. LSP: The Liskov Substitution Principle. 11. DIP: The Dependency-Inversion Principle. 12. ISP: The Interface-Segregation Principle. III. THE PAYROLL CASE STUDY. 13. Command and Active Object. 14. Template Method & Strategy: Inheritance vs. Delegation. 15. Facade and Mediator. 16. Singleton and Monostate. 17. Null Object. 18. The Payroll Case Study: Iteration One Begins. 19. The Payroll Case Study: Implementation. IV. PACKAGING THE PAYROLL SYSTEM. 20. Principles of Package Design. 21. Factory. 22. The Payroll Case Study (Part 2). V. THE WEATHER STATION CASE STUDY. 23. Composite. 24. Observer—Backing into a Pattern. 25. Abstract Server, Adapter, and Bridge. 26. Proxy and Stairway to Heaven: Managing Third Party APIs. 27. Case Study: Weather Station. VI. THE ETS CASE STUDY. 28. Visitor. 29. State. 30. The ETS Framework. Appendix A. UML Notation I: The CGI Example. Appendix B. UML Notation II: The Statmux. Appendix C. A Satire of Two Companies. Appendix D. The Source Code Is the Design. Index.
£73.88
Pearson Education (US) Python Programming with Design Patterns
Book SynopsisJames W. Cooper holds a PhD in chemistry and worked in academia, for the scientific instrument industry, and for IBM for 25 years, primarily as a computer scientist at IBM's Thomas J. Watson Research Center. Now retired, he is the author of 20 books, including 3 on design patterns in various languages. His most recent books are Flameout: The Rise and Fall of IBM Instruments (2019) and Food Myths Debunked (2014). James holds 11 patents and has written 60 columns for JavaPro Magazine. He has also written nearly 1,000 columns for the now vanished Examiner.com on foods and chemistry, and he currently writes his own blog: FoodScienceInstitute.com. Recently, he has written columns on Python for Medium.com and Substack. He is also involved in local theater groups and is the treasurer for Troupers Light Opera, where he performs regularly.Table of ContentsPreface xxi PART I: INTRODUCTION 1 The tkinter Library 2 GitHub 2 Chapter 1 Introduction to Objects 5 The Class __init__ Method 6 Variables Inside a Class 6 Collections of Classes 7 Inheritance 8 Derived Classes Created with Revised Methods 8 Multiple Inheritance 8 Drawing a Rectangle and a Square 10 Visibility of Variables 12 Properties 13 Local Variables 13 Types in Python 13 Summary 14 Programs on GitHub 15 Chapter 2 Visual Programming in Python 17 Importing Fewer Names 19 Creating an Object-Oriented Version 19 Using Message Boxes 21 Using File Dialogs 22 Understanding Options for the Pack Layout Manager 23 Using the ttk Libraries 24 Responding to User Input 25 Adding Two Numbers 26 Catching the Error 26 Applying Colors in tkinter 27 Creating Radio Buttons 27 Using a Class-Level Variable 30 Communicating Between Classes 30 Using the Grid Layout 30 Creating Checkbuttons 32 Disabling Check Boxes 32 Adding Menus to Windows 35 Using the LabelFrame 39 Moving On 40 Examples on GitHub 40 Chapter 3 Visual Programming of Tables of Data 41 Creating a Listbox 42 Displaying the State Data 44 Using a Combobox 46 The Treeview Widget 47 Inserting Tree Nodes 50 Moving On 51 Example Code on GitHub 51 Chapter 4 What Are Design Patterns? 53 Defining Design Patterns 54 The Learning Process 55 Notes on Object-Oriented Approaches 56 Python Design Patterns 57 References 57 PART II: CREATIONAL PATTERNS 59 Chapter 5 The Factory Pattern 61 How a Factory Works 61 Sample Code 62 The Two Subclasses 62 Building the Simple Factory 63 Using the Factory 63 A Simple GUI 64 Factory Patterns in Math Computation 65 Programs on GitHub 65 Thought Questions 66 Chapter 6 The Factory Method Pattern 67 The Swimmer Class 68 The Event Classes 69 Straight Seeding 70 Circle Seeding 71 Our Seeding Program 72 Other Factories 74 When to Use a Factory Method 74 Programs on GitHub 74 Chapter 7 The Abstract Factory Pattern 75 A GardenMaker Factory 75 How the User Interface Works 77 Consequences of the Abstract Factory Pattern 77 Thought Questions 78 Code on GitHub 78 Chapter 8 The Singleton Pattern 79 Throwing the Exception 80 Creating an Instance of the Class 80 Static Classes As Singleton Patterns 81 Finding the Singletons in a Large Program 81 Other Consequences of the Singleton Pattern 82 Sample Code on GitHub 82 Chapter 9 The Builder Pattern 83 An Investment Tracker 84 Calling the Builders 86 The List Box Builder 87 The Checkbox Builder 88 Displaying the Selected Securities 89 Consequences of the Builder Pattern 89 Thought Questions 89 Sample Code on GitHub 89 Chapter 10 The Prototype Pattern 91 Cloning in Python 91 Using the Prototype 92 Consequences of the Prototype Pattern 94 Sample Code on GitHub 94 Chapter 11 Summary of Creational Patterns 95 PART III: STRUCTURAL PATTERNS 97 Chapter 12 The Adapter Pattern 99 Moving Data Between Lists 99 Making an Adapter 101 The Class Adapter 103 Two-Way Adapters 103 Pluggable Adapters 103 Programs on GitHub 103 Chapter 13 The Bridge Pattern 105 Creating the User Interface 107 Extending the Bridge 108 Consequences of the Bridge Pattern 109 Programs on GitHub 110 Chapter 14 The Composite Pattern 111 An Implementation of a Composite 112 Salary Computation 112 The Employee Classes 112 The Boss Class 113 Building the Employee Tree 114 Printing the Employee Tree 114 Creating a Treeview of the Composite 116 Using Doubly Linked Lists 117 Consequences of the Composite Pattern 118 A Simple Composite 119 Other Implementation Issues 119 Dealing with Recursive Calls 119 Ordering Components 120 Caching Results 120 Programs on GitHub 120 Chapter 15 The Decorator Pattern 121 Decorating a Button 121 Using a Decorator 122 Using Nonvisual Decorators 123 Decorated Code 124 The dataclass Decorator 125 Using dataclass with Default Values 126 Decorators, Adapters, and Composites 126 Consequences of the Decorator Pattern 126 Programs on GitHub 127 Chapter 16 The Facade Pattern 129 Building the Façade Classes 131 Creating Databases and Tables 135 Using the SQLite Version 136 Consequences of the Façade 137 Programs on GitHub 137 Notes on MySQL 137 Using SQLite 138 References 138 Chapter 17 The Flyweight Pattern 139 What Are Flyweights? 139 Example Code 140 Selecting a Folder 142 Copy-on-Write Objects 143 Program on GitHub 143 Chapter 18 The Proxy Pattern 145 Using the Pillow Image Library 145 Displaying an Image Using PIL 146 Using Threads to Handle Image Loading 146 Logging from Threads 149 Copy-on-Write 149 Comparing Related Patterns 149 Programs on GitHub 150 Chapter 19 Summary of Structural Patterns 151 PART IV: BEHAVIORAL PATTERNS 153 Chapter 20 Chain of Responsibility Pattern 155 When to Use the Chain 156 Sample Code 156 The Listboxes 159 Programming a Help System 160 Receiving the Help Command 161 The First Case 162 A Chain or a Tree? 163 Kinds of Requests 164 Consequences of the Chain of Responsibility 164 Programs on GitHub 165 Chapter 21 The Command Pattern 167 When to Use the Command Pattern 167 Command Objects 168 A Keyboard Example 168 Calling the Command Objects 170 Building Command Objects 171 The Command Pattern 172 Consequences of the Command Pattern 172 Providing the Undo Function 172 Creating the Red and Blue Buttons 175 Undoing the Lines 175 Summary 176 References 176 Programs on GitHub 176 Chapter 22 The Interpreter Pattern 177 When to Use an Interpreter 177 Where the Pattern Can Be Helpful 177 A Simple Report Example 178 Interpreting the Language 179 How Parsing Works 180 Sorting Using attrgetter() 181 The Print Verb 182 The Console Interface 182 The User Interface 183 Consequences of the Interpreter Pattern 184 Programs on GitHub 185 Chapter 23 The Iterator Pattern 187 Why We Use Iterators 187 Iterators in Python 187 A Fibonacci Iterator 188 Getting the Iterator 189 Filtered Iterators 189 The Iterator Generator 191 A Fibonacci Iterator 191 Generators in Classes 192 Consequences of the Iterator Pattern 192 Programs on GitHub 193 Chapter 24 The Mediator Pattern 195 An Example System 195 Interactions Between Controls 197 Sample Code 198 Mediators and Command Objects 199 Consequences of the Mediator Pattern 200 Single Interface Mediators 200 Programs on GitHub 201 Chapter 25 The Memento Pattern 203 When to Use a Memento 203 Sample Code 204 Consequences of the Memento Pattern 209 Programs on GitHub 209 Chapter 26 The Observer Pattern 211 Example Program for Watching Colors Change 212 The Message to the Media 215 Consequences of the Observer Pattern 215 Programs on GitHub 215 Chapter 27 The State Pattern 217 Sample Code 217 Switching Between States 221 How the Mediator Interacts with the State State Transitions 224 Programs on GitHub 224 Chapter 28 The Strategy Pattern 225 Why We Use the Strategy Pattern 225 Sample Code 226 The Context 227 The Program Commands 227 The Line and Bar Graph Strategies 228 Consequences of the Strategy Pattern 230 Programs on GitHub 231 Chapter 29 The Template Pattern 233 Why We Use Template Patterns 233 Kinds of Methods in a Template Class 234 Sample Code 234 Drawing a Standard Triangle 235 Drawing an Isosceles Triangle 236 The Triangle Drawing Program 237 Templates and Callbacks 238 Summary and Consequences 238 Example Code on GitHub 238 Chapter 30 The Visitor Pattern 239 When to Use the Visitor Pattern 239 Working with the Visitor Pattern 241 Sample Code 241 Visiting Each Class 242 Visiting Several Classes 242 Bosses Are Employees, Too 243 Double Dispatching 245 Traversing a Series of Classes 245 Consequences of the Visitor Pattern 245 Example Code on GitHub 245 PART V: A BRIEF INTRODUCTION TO PYTHON 247 Chapter 31 Variables and Syntax in Python 249 Data Types 250 Numeric Constants 250 Strings 250 Character Constants 251 Variables 252 Complex Numbers 253 Integer Division 253 Multiple Equal Signs for Initialization 254 A Simple Python Program 254 Compiling and Running This Program 255 Arithmetic Operators 255 Bitwise Operators 255 Combined Arithmetic and Assignment Statements 256 Comparison Operators 256 The input Statement 257 PEP 8 Standards 258 Variable and Function Names 258 Constants 258 Class Names 258 Indentation and Spacing 259 Comments 259 Docstrings 259 String Methods 260 Examples on GitHub 261 Chapter 32 Making Decisions in Python 263 elif is “else if” 263 Combining Conditions 264 The Most Common Mistake 264 Looping Statements in Python 265 The for Loop and Lists 265 Using range in if Statements 266 Using break and continue 266 The continue Statement 267 Python Line Length 267 The print Function 267 Formatting Numbers 268 C and Java Style Formatting 269 The format string Function 269 f-string Formatting 269 Comma-Separated Numbers 270 Strings 270 Formatting Dates 271 Using the Python match Function 271 Pattern Matching 272 Reference 273 Moving On 273 Sample Code on GitHub 273 Chapter 33 Development Environments 275 IDLE 275 Thonny 275 PyCharm 276 Visual Studio 276 Other Development Environments 276 LiClipse 276 Jupyter Notebook 277 Google Colaboratory 277 Anaconda 277 Wing 278 Command-Line Execution 278 CPython, IPython, and Jython 278 Chapter 34 Python Collections and Files 279 Slicing 279 Slicing Strings 280 Negative Indexes 281 String Prefix and Suffix Removal 281 Changing List Contents 281 Copying a List 282 Reading Files 282 Using the with Loop 283 Handling Exceptions 284 Using Dictionaries 284 Combining Dictionaries 286 Using Tuples 286 Using Sets 287 Using the map Function 287 Writing a Complete Program 288 Impenetrable Coding 288 Using List Comprehension 289 Sample Programs on GitHub 290 Chapter 35 Functions 291 Returning a Tuple 292 Where Does the Program Start? 292 Summary 293 Programs on GitHub 293 Appendix A Running Python Programs 295 If You Have Python Installed 295 Shortcuts 295 Creating an Executable Python Program 296 Command-Line Arguments 297 Index 299
£34.19
Pearson Education (US) ObjectOriented Analysis and Design with
Book SynopsisGrady Booch is an IBM fellow and author of six best-selling books on object-oriented programming. He is world-reknowned as an originator of OO and founder of UML. Robert A. Maksimchuk, as Research Director in the Unisys CTO Office, focuses on emerging modeling technologies to advance the strategic direction of the Unisys 3D-Visual Enterprise modeling framework. Bob brings an abundance of systems engineering, modeling, and object-oriented analysis and design expertise, in numerous industries, to this mission. He is the coauthor of the books UML for Mere Mortals and UML for Database Design, has written various articles, has traveled worldwide as a featured speaker in numerous technology forums, and led workshops and seminars on UML and object-oriented development. Michael W. Engle is a principal member of the engineering staff with the Lockheed Martin Corporation. He has extensive technical and management experience across theTable of ContentsSidebars xiPreface xiiiAcknowledgments xixAbout the Authors xxi Section I: Concepts 1 Chapter 1: Complexity 3 1.1 The Structure of Complex Systems 41.2 The Inherent Complexity of Software 71.3 The Five Attributes of a Complex System 121.4 Organized and Disorganized Complexity 141.5 Bringing Order to Chaos 181.6 On Designing Complex Systems 24 Chapter 2: The Object Model 29 2.1 The Evolution of the Object Model 292.2 Foundations of the Object Model 372.3 Elements of the Object Model 432.4 Applying the Object Model 71 Chapter 3: Classes and Objects 75 3.1 The Nature of an Object 753.2 Relationships among Objects 883.3 The Nature of a Class 923.4 Relationships among Classes 963.5 The Interplay of Classes and Objects 1113.6 On Building Quality Classes and Objects 112 Chapter 4: Classification 121 4.1 The Importance of Proper Classification 1214.2 Identifying Classes and Objects 1264.3 Key Abstractions and Mechanisms 138 Section II: Method 145 Chapter 5: Notation 147 5.1 The Unified Modeling Language 1475.2 Package Diagrams 1555.3 Component Diagrams 1635.4 Deployment Diagrams 1715.5 Use Case Diagrams 1755.6 Activity Diagrams 1855.7 Class Diagrams 1925.8 Sequence Diagrams 2065.9 Interaction Overview Diagrams 2135.10 Composite Structure Diagrams 2155.11 State Machine Diagrams 2185.12 Timing Diagrams 2315.13 Object Diagrams 2355.14 Communication Diagrams 238 Chapter 6: Process 247 6.1 First Principles 2486.2 The Macro Process: The Software Development Lifecycle 2566.3 The Micro Process: The Analysis and Design Process 272 Chapter 7: Pragmatics 303 7.1 Management and Planning 3047.2 Staffing 3087.3 Release Management 3127.4 Reuse 3147.5 Quality Assurance and Metrics 3167.6 Documentation 3207.7 Tools 3227.8 Special Topics 3247.9 The Benefits and Risks of Object-Oriented Development 326 Section III: Applications 331 Chapter 8: System Architecture: Satellite-Based Navigation 333 8.1 Inception 3348.2 Elaboration 3478.3 Construction 3708.4 Post-Transition 371 Chapter 9: Control System: Traffic Management 375 9.1 Inception 3769.2 Elaboration 3859.3 Construction 3969.4 Post-Transition 411 Chapter 10: Artificial Intelligence: Cryptanalysis 413 10.1 Inception 41410.2 Elaboration 42110.3 Construction 42710.4 Post-Transition 446 Chapter 11: Data Acquisition: Weather Monitoring Station 449 11.1 Inception 45011.2 Elaboration 46311.3 Construction 47411.4 Post-Transition 487 Chapter 12: Web Application: Vacation Tracking System 489 12.1 Inception 49012.2 Elaboration 49412.3 Construction 50612.4 Transition and Post-Transition 534 Appendix A: Object-Oriented Programming Languages 537 A.1 Language Evolution 537A.2 Smalltalk 541A.3 C++ 546A.4 Java 551 Appendix B: Further Reading 557 Notes 567Glossary 591Classified Bibliography 603Index 677
£56.69
MIT Press Ltd Java Precisely The MIT Press
Book SynopsisAn updated, concise reference for the Java programming language, version 8.0, and essential parts of its class languages, offering more detail than a standard textbook. The third edition of Java Precisely provides a concise description of the Java programming language, version 8.0. It offers a quick reference for the reader who has already learned (or is learning) Java from a standard textbook and who wants to know the language in more detail. The book presents the entire Java programming language and essential parts of the class libraries: the collection classes, the input-output classes, the stream libraries and Java 8's facilities for parallel programming, and the functional interfaces used for that.Though written informally, the book describes the language in detail and offers many examples. For clarity, most of the general rules appear on left-hand pages with the relevant examples directly opposite on the right-hand pages. All examples are fragments of lega
£31.35
Pearson Education (US) Design Patterns Explained
Book SynopsisAlan Shalloway is founder, CEO, and principal consultant of Net Objectives, an object-oriented consulting and training organization. An object-oriented consultant and software developer for over 20 years, he is a frequent speaker at leading development conferences, including SD Expo, Java One, OOP, and OOPSLA. He is a certified Scrum master. He is co-author of An Introduction to XML and its Family of Technologies. Shalloway holds a master's degree in computer science from MIT. James R. Trott currently works as a senior consultant for a large financial institution in the Pacific Northwest. He has used object-oriented and pattern-based analysis techniques throughout his 20-year career in knowledge management and knowledge engineering. He holds a master of science in applied mathematics, an MBA, and a master of arts in intercultural studies. Copyright Pearson Education. All rights reserved.Table of ContentsI. AN INTRODUCTION TO OBJECT-ORIENTED SOFTWARE DEVELOPMENT. 1. The Object-Oriented Paradigm. Overview. Before the Object-Oriented Paradigm: Functional Decomposition. The Problem of Requirements. Dealing with Changes: Using Functional Decomposition. Dealing with Changing Requirements. The Object-Oriented Paradigm. Object-Oriented Programming in Action. Special Object Methods. Summary. Review Questions. 2. The UML-The Unified Modeling Language. Overview. What Is the UML? Why Use the UML? The Class Diagram. Interaction Diagrams. Summary. Review Questions. II. THE LIMITATIONS OF TRADITIONAL OBJECT-ORIENTED DESIGN. 3. A Problem That Cries Out for Flexible Code. Overview. Extracting Information from a CAD/CAM System. Understand the Vocabulary. Describe the Problem. The Essential Challenges and Approaches. Summary. Review Questions. 4. A Standard Object-Oriented Solution. Overview. Solving with Special Cases. Summary. Review Questions. III. DESIGN PATTERNS. 5. An Introduction to Design Patterns. Overview. Design Patterns Arose from Architecture and Anthropology. Moving from Architectural to Software Design Patterns. Why Study Design Patterns? Other Advantages of Studying Design Patterns. Summary. Review Questions. 6. The Facade Pattern. Overview. Introducing the Facade Pattern. Learning the Facade Pattern. Field Notes: The Facade Pattern. Relating the Facade Pattern to the CAD/CAM Problem. Summary. Review Questions. 7. The Adapter Pattern. Overview. Introducing the Adapter Pattern. Learning the Adapter Pattern. Field Notes: The Adapter Pattern. Relating the Adapter Pattern to the CAD/CAM Problem. Summary. Review Questions. 8. Expanding Our Horizons. Overview. Objects: The Traditional View and the New View. Encapsulation: The Traditional View and the New View. Find What Is Varying and Encapsulate It. Commonality and Variability Analysis and Abstract Classes. The Qualities of Agile Coding. Summary. Review Questions. 9. The Strategy Pattern. Overview. An Approach to Handling New Requirements. The International E-Commerce System Case Study: Initial Requirements. Handling New Requirements. The Strategy Pattern. Field Notes: Using the Strategy Pattern. Summary. Review Questions. 10. The Bridge Pattern. Overview. Introducing the Bridge Pattern. Learning the Bridge Pattern: An Example. An Observation About Using Design Patterns. Learning the Bridge Pattern: Deriving It. The Bridge Pattern in Retrospect. Field Notes: Using the Bridge Pattern. Summary. Review Questions. 11. The Abstract Factory Pattern. Overview. Introducing the Abstract Factory Pattern. Learning the Abstract Factory Pattern: An Example. Learning the Abstract Factory Pattern: Implementing It. Field Notes: The Abstract Factory Pattern. Relating the Abstract Factory Pattern to the CAD/CAM Problem. Summary. Review Questions. IV. PUTTING IT ALL TOGETHER: THINKING IN PATTERNS. 12. How Do Experts Design? Overview. Building by Adding Distinctions. Summary. Review Questions. 13. Solving the CAD/CAM Problem with Patterns. Overview. Review of the CAD/CAM Problem. Thinking in Patterns. Thinking in Patterns: Step 1. Thinking in Patterns: Step 2a. Thinking in Patterns: Step 2b. Thinking in Patterns: Step 2c. Thinking in Patterns: Steps 2a and 2b Repeated (Facade). Thinking in Patterns: Steps 2a and 2b Repeated (Adapter). Thinking in Patterns: Steps 2a and 2b Repeated (Abstract Factory). Thinking in Patterns: Step 3. Comparison with the Previous Solution. Summary. Review Questions. V. TOWARD A NEW PARADIGM OF DESIGN. 14. The Principles and Strategies of Design Patterns. Overview. The Open-Closed Principle. The Principle of Designing from Context. The Principle of Encapsulating Variation. Abstract Classes vs. Interfaces. The Principle of Healthy Skepticism. Summary. Review Questions. 15. Commonality and Variability Analysis. Overview. Commonality and Variability Analysis and Application Design. Solving the CAD/CAM Problem with CVA. Summary. Review Questions. 16. The Analysis Matrix. Overview. In the Real World: Variations. The International E-Commerce System Case Study: Handling Variation. Field Notes. Summary. Review Questions. 17. The Decorator Pattern. Overview. A Little More Detail. The Decorator Pattern. Applying the Decorator Pattern to the Case Study. Another Example: Input/Output. Field Notes: Using the Decorator Pattern. The Essence of the Decorator Pattern. Summary. Review Questions. VI. OTHER VALUES OF PATTERNS. 18. The Observer Pattern. Overview. Categories of Patterns. More Requirements for the International E-Commerce Case Study. The Observer Pattern. Applying the Observer to the Case Study. Field Notes: Using the Observer Pattern. Summary. Review Questions. 19. The Template Method Pattern. Overview. More Requirements for the International E-Commerce Case Study. The Template Method Pattern. Applying the Template Method to the International E-Commerce Case Study. Using the Template Method Pattern to Reduce Redundancy. Field Notes: Using the Template Method Pattern. Summary. Review Questions. VII. FACTORIES. 20. Lessons from Design Patterns: Factories. Overview. Factories. The Universal Context Revisited. Factories Follow Our Guidelines. Limiting the Vectors of Change. Another Way to Think About It. Different Roles of Factories. Field Notes. Summary. Review Questions. Overview. 21. The Singleton Pattern and the Double-Checked Locking Pattern. Introducing the Singleton Pattern. Applying the Singleton Pattern to the Case Study. A Variant: The Double-Checked Locking Pattern. Reflections. Field Notes: Using the Singleton and Double-Checked Locking Patterns. Summary. Review Questions. 22. The Object Pool Pattern. Overview. A Problem Requiring the Management of Objects. The Object Pool Pattern. Observation: Factories Can Do Much More Than Instantiation. Summary. Review Questions. 23. The Factory Method Pattern. Overview. More Requirements for the Case Study. The Factory Method Pattern. Factory Method Pattern and Object-Oriented Languages. Field Notes: Using the Factory Method Pattern. Summary. Review Questions. 24. Summary of Factories. Overview. Steps in the Software Process. Parallels in Factories and XP Practices. Scaling Systems. VIII. ENDINGS AND BEGINNINGS. 25. Design Patterns Reviewed: A Summation and a Beginning. Overview. A Summary of Object-Oriented Principles. How Design Patterns Encapsulate Implementations. Commonality and Variability Analysis and Design Patterns. Decomposing a Problem Domain into Responsibilities. Patterns and Contextual Design. Relationships Within a Pattern. Design Patterns and Agile Coding Practices. Field Notes. Summary. Review Questions. 26. Bibliography. Design Patterns Explained: The Web Site Companion. Recommended Reading. Recommended Reading for Java Programmers. Recommended Reading for C++ Programmers. Recommended Reading for COBOL Programmers. Recommended Reading on eXtreme Programming. Recommended Reading on General Programming. Personal Favorites. Index.
£40.04
Pearson Education (US) Agile Software Development
Book SynopsisDr. Alistair Cockburn is an internationally renowned expert on all aspects of software development, from object-oriented modeling and architecture, to methodology design, to project management and organizational alignment. One of the pioneers who coined the term agile software development, he co-authored the 2001 Agile Software Development Manifesto and the 2005 Declaration of Interdependence. Since 1975, he has led projects and taught in places from Oslo to Cape Town, from Vancouver to Beijing. His work has covered topics from design to management to testing, in research, in government, and in industry. His most recent book is Crystal Clear: A Human-Powered Methodology for Small Teams. His books Writing Effective Use Cases and Agile Software Development won back-to-back Jolt Productivity Awards in 2001 and 2002.Table of ContentsList of Figures xi List of Stories xvii Preface xxi Preface to Second Edition xxxi 0 Unknowable and Incommunicable 1 0.1 Unknowable and Incommunicable: Evolution 21 Chapter 1 A Cooperative Game of Invention and Communication 27 Chapter 1.1 A Cooperative Game of Invention and Communication: Evolution 47 Chapter 2 Individuals 65 Chapter 2.1 Individuals: Evolution 99 Chapter 3 Communication, Cooperating Teams 105 Chapter 3.1 Teams: Evolution 143 Chapter 4 Methodologies 147 Chapter 4.1 Methodologies: Evolution 207 Chapter 5 Agile and Self-Adapting 217 Chapter 5.1 Agile and Self-Adapting: Evolution 241 Chapter 6 The Crystal Methodologies 335 Chapter 6.1 The Crystal Methodologies: Evolution 351 Appendix A The Agile Software Development Manifesto 367 Appendix A.1 The Agile Software Development Manifesto and the Declaration of Interdependence 379 Appendix B Naur, Ehn, Musashi 391 Appendix B.1 Naur, Ehn, Musashi: Evolution 427 Appendix C Afterword 431 Appendix D Books and References 437 Index 453
£42.27
Pearson Education (US) Growing ObjectOriented Software Guided by Tests
Book SynopsisTable of ContentsForeword xv Preface xvii Acknowledgments xxi About the Authors xxiii PART I: INTRODUCTION 1 Chapter 1: What Is the Point of Test-Driven Development? 3 Software Development as a Learning Process 3 Feedback Is the Fundamental Tool 4 Practices That Support Change 5 Test-Driven Development in a Nutshell 6 The Bigger Picture 7 Testing End-to-End 8 Levels of Testing 9 External and Internal Quality 10 Chapter 2: Test-Driven Development with Objects 13 A Web of Objects 13 Values and Objects 13 Follow the Messages 14 Tell, Don’t Ask 17 But Sometimes Ask 17 Unit-Testing the Collaborating Objects 18 Support for TDD with Mock 19 Chapter 3: An Introduction to the Tools 21 Stop Me If You’ve Heard This One Before 21 A Minimal Introduction to JUnit 4 21 Hamcrest Matchers and assertThat() 24 jMock2: Mock Objects 25 PART II: THE PROCESS OF TEST-DRIVEN DEVELOPMENT 29 Chapter 4: Kick-Starting the Test-Driven Cycle 31 Introduction 31 First, Test a Walking Skeleton 32 Deciding the Shape of the Walking Skeleton 33 Build Sources of Feedback 35 Expose Uncertainty Early 36 Chapter 5: Maintaining the Test-Driven Cycle 39 Introduction 39 Start Each Feature with an Acceptance Test 39 Separate Tests That Measure Progress from Those That Catch Regressions 40 Start Testing with the Simplest Success Case 41 Write the Test That You’d Want to Read 42 Watch the Test Fail 42 Develop from the Inputs to the Outputs 43 Unit-Test Behavior, Not Methods 43 Listen to the Tests 44 Tuning the Cycle 45 Chapter 6: Object-Oriented Style 47 Introduction 47 Designing for Maintainability 47 Internals vs. Peers 50 No And’s, Or’s, or But’s 51 Object Peer Stereotypes 52 Composite Simpler Than the Sum of Its Parts 53 Context Independence 54 Hiding the Right Information 55 An Opinionated View 56 Chapter 7: Achieving Object-Oriented Design 57 How Writing a Test First Helps the Design 57 Communication over Classification 58 Value Types 59 Where Do Objects Come From? 60 Identify Relationships with Interfaces 63 Refactor Interfaces Too 63 Compose Objects to Describe System Behavior 64 Building Up to Higher-Level Programming 65 And What about Classes? 67 Chapter 8: Building on Third-Party Code 69 Introduction 69 Only Mock Types That You Own 69 Mock Application Objects in Integration Tests 71 PART III: A WORKED EXAMPLE 73 Chapter 9: Commissioning an Auction Sniper 75 To Begin at the Beginning 75 Communicating with an Auction 78 Getting There Safely 79 This Isn’t Real 81 Chapter 10: The Walking Skeleton 83 Get the Skeleton out of the Closet 83 Our Very First Test 84 Some Initial Choices 86 Chapter 11: Passing the First Test 89 Building the Test Rig 89 Failing and Passing the Test 95 The Necessary Minimum 102 Chapter 12: Getting Ready to Bid 105 An Introduction to the Market 105 A Test for Bidding 106 The AuctionMessageTranslator 112 Unpacking a Price Message 118 Finish the Job 121 Chapter 13: The Sniper Makes a Bid 123 Introducing AuctionSniper 123 Sending a Bid 126 Tidying Up the Implementation 131 Defer Decisions 136 Emergent Design 137 Chapter 14: The Sniper Wins the Auction 139 First, a Failing Test 139 Who Knows about Bidders? 140 The Sniper Has More to Say 143 The Sniper Acquires Some State 144 The Sniper Wins 146 Making Steady Progress 148 Chapter 15: Towards a Real User Interface 149 A More Realistic Implementation 149 Displaying Price Details 152 Simplifying Sniper Events 159 Follow Through 164 Final Polish 168 Observations 171 Chapter 16: Sniping for Multiple Items 175 Testing for Multiple Items 175 Adding Items through the User Interface 183 Observations 189 Chapter 17: Teasing Apart Main 191 Finding a Role 191 Extracting the Chat 192 Extracting the Connection 195 Extracting the SnipersTableModel 197 Observations 201 Chapter 18: Filling In the Details 205 A More Useful Application 205 Stop When We’ve Had Enough 205 Observations 212 Chapter 19: Handling Failure 215 What If It Doesn’t Work? 215 Detecting the Failure 217 Displaying the Failure 218 Disconnecting the Sniper 219 Recording the Failure 221 Observations 225 PART IV: SUSTAINABLE TEST-DRIVEN DEVELOPMENT 227 Chapter 20: Listening to the Tests 229 Introduction 229 I Need to Mock an Object I Can’t Replace (without Magic) 230 Logging Is a Feature 233 Mocking Concrete Classes 235 Don’t Mock Values 237 Bloated Constructor 238 Confused Object 240 Too Many Dependencies 241 Too Many Expectations 242 What the Tests Will Tell Us (If We’re Listening) 244 Chapter 21: Test Readability 247 Introduction 247 Test Names Describe Features 248 Canonical Test Structure 251 Streamline the Test Code 252 Assertions and Expectations 254 Literals and Variables 255 Chapter 22: Constructing Complex Test Data 257 Introduction 257 Test Data Builders 258 Creating Similar Objects 259 Combining Builders 261 Emphasizing the Domain Model with Factory Methods 261 Removing Duplication at the Point of Use 262 Communication First 264 Chapter 23: Test Diagnostics 267 Design to Fail 267 Small, Focused, Well-Named Tests 268 Explanatory Assertion Messages 268 Highlight Detail with Matchers 268 Self-Describing Value 269 Obviously Canned Value 270 Tracer Object 270 Explicitly Assert That Expectations Were Satisfied 271 Diagnostics Are a First-Class Feature 271 Chapter 24: Test Flexibility 273 Introduction 273 Test for Information, Not Representation 274 Precise Assertions 275 Precise Expectations 277 “Guinea Pig” Objects 284 PART V: ADVANCED TOPICS 287 Chapter 25: Testing Persistence 289 Introduction 289 Isolate Tests That Affect Persistent State 290 Make Tests Transaction Boundaries Explicit 292 Testing an Object That Performs Persistence Operations 294 Testing That Objects Can Be Persisted 297 But Database Tests Are S-l-o-w! 300 Chapter 26: Unit Testing and Threads 301 Introduction 301 Separating Functionality and Concurrency Policy 302 Unit-Testing Synchronization 306 Stress-Testing Passive Objects 311 Synchronizing the Test Thread with Background Threads 312 The Limitations of Unit Stress Tests 313 Chapter 27: Testing Asynchronous Code 315 Introduction 315 Sampling or Listening 316 Two Implementations 318 Runaway Tests 322 Lost Updates 323 Testing That an Action Has No Effect 325 Distinguish Synchronizations and Assertions 326 Externalize Event Sources 326 Afterword: A Brief History of Mock Objects 329 Appendix A: jMock2 Cheat Sheet 335 Appendix B: Writing a Hamcrest Matcher 343 Bibliography 347 Index 349
£40.04
Pearson Education (US) ObjectiveC Programming The Big Nerd Ranch Guide
Book SynopsisWant to write iOS apps or desktop Mac applications? This introduction to programming and the Objective-C language is your first step on the journey from someone who uses apps to someone who writes them. Based on Big Nerd Ranch's popular Objective-C Bootcamp, Objective-C Programming: The Big Nerd Ranch Guide covers C, Objective-C, and the common programming idioms that enable developers to make the most of Apple technologies. Compatible with Xcode 5, iOS 7, and OS X Mavericks (10.9), this guide features short chapters and an engaging style to keep you motivated and moving forward. At the same time, it encourages you to think critically as a programmer. Here are some of the topics covered: Using Xcode, Apple's documentation, and other toolsProgramming basics: variables, loops, functions, etc. Objects, classes, methods, and messagesPointers, addresses, and memory management with ARCProperties and Key-Value Coding (KVC)Class extensionsCategoriesClasses from the Foundation framewoTable of Contents Part I: Getting Started1. You and This Book2. Your First Program Part II: How Programming Works3. Variables and Types4. if/else5. Functions6. Numbers7. Loops8. Addresses and Pointers9. Pass By Reference10. Structs11. The Heap Part III: Objective-C and Foundation12. Objects13. More Messages14. NSString15. NSArray16. Developer Documentation17. Your First Class18. Inheritance19. Object Instance Variables20. Preventing Memory Leaks21. Collection Classes22. Constants23. Writing Files with NSString and NSData24. Callbacks25. Protocols26. Property Lists Part IV: Event-Driven Applications27. Your First iOS Application28. Your First Cocoa Application Part V: Advanced Objective-C29. init30. Properties31. Categories32. Blocks Part VI: Advanced C33. Bitwise Operations34. C Strings35. C Arrays36. Command-Line Arguments37. Switch Statements Part VII: Objective-C Runtime38. How Messaging Works39. How Classes Work40. Runtime Attributes41. Method Swizzling42. Associated Objects
£28.02
John Wiley & Sons Inc Data Structures and Algorithms in C
Book SynopsisThis second edition of Data Structures and Algorithms in C++ is designed to provide an introduction to data structures and algorithms, including their design, analysis, and implementation. The authors offer an introduction to object-oriented design with C++ and design patterns, including the use of class inheritance and generic programming through class and function templates, and retain a consistent object-oriented viewpoint throughout the book. This is a sister book to Goodrich & Tamassia's Data Structures and Algorithms in Java, but uses C++ as the basis language instead of Java. This C++ version retains the same pedagogical approach and general structure as the Java version so schools that teach data structures in both C++ and Java can share the same core syllabus. In terms of curricula based on the IEEE/ACM 2001 Computing Curriculum, this book is appropriate for use in the courses CS102 (I/O/B versions), CS103 (I/O/B versions), CS111 (A version), and CS112 (A/I/O/F/H veTable of Contents1 A C++ Primer 1 1.1 Basic C++ Programming Elements 2 1.1.1 A Simple C++ Program 2 1.1.2 Fundamental Types 4 1.1.3 Pointers, Arrays, and Structures 7 1.1.4 Named Constants, Scope, and Namespaces 13 1.2 Expressions 16 1.2.1 Changing Types through Casting 20 1.3 Control Flow 23 1.4 Functions 26 1.4.1 Argument Passing 28 1.4.2 Overloading and Inlining 30 1.5 Classes 32 1.5.1 Class Structure 33 1.5.2 Constructors and Destructors 37 1.5.3 Classes and Memory Allocation 40 1.5.4 Class Friends and Class Members 43 1.5.5 The Standard Template Library 45 1.6 C++ Program and File Organization 47 1.6.1 An Example Program 48 1.7 Writing a C++ Program53 1.7.1 Design 54 1.7.2 Pseudo-Code 54 1.7.3 Coding 55 1.7.4 Testing and Debugging 57 1.8 Exercises 60 2 Object-Oriented Design 65 2.1 Goals, Principles, and Patterns 66 2.1.1 Object-Oriented Design Goals 66 2.1.2 Object-Oriented Design Principles 67 2.1.3 Design Patterns 70 2.2 Inheritance and Polymorphism 71 2.2.1 Inheritance in C++ 71 2.2.2 Polymorphism 78 2.2.3 Examples of Inheritance in C++ 79 2.2.4 Multiple Inheritance and Class Casting 84 2.2.5 Interfaces and Abstract Classes 87 2.3 Templates 90 2.3.1 Function Templates 90 2.3.2 Class Templates 91 2.4 Exceptions 93 2.4.1 Exception Objects 93 2.4.2 Throwing and Catching Exceptions 94 2.4.3 Exception Specification 96 2.5 Exercises 98 3 Arrays, Linked Lists, and Recursion 103 3.1 Using Arrays 104 3.1.1 Storing Game Entries in an Array 104 3.1.2 Sorting an Array 109 3.1.3 Two-Dimensional Arrays and Positional Games 111 3.2 Singly Linked Lists 117 3.2.1 Implementing a Singly Linked List 117 3.2.2 Insertion to the Front of a Singly Linked List 119 3.2.3 Removal from the Front of a Singly Linked List 119 3.2.4 Implementing a Generic Singly Linked List 121 3.3 Doubly Linked Lists 123 3.3.1 Insertion into a Doubly Linked List 123 3.3.2 Removal from a Doubly Linked List 124 3.3.3 A C++ Implementation 125 3.4 Circularly Linked Lists and List Reversal 129 3.4.1 Circularly Linked Lists 129 3.4.2 Reversing a Linked List 133 3.5 Recursion 134 3.5.1 Linear Recursion 140 3.5.2 Binary Recursion 144 3.5.3 Multiple Recursion 147 3.6 Exercises 149 4 Analysis Tools 153 4.1 The Seven Functions Used in This Book 154 4.1.1 The Constant Function 154 4.1.2 The Logarithm Function 154 4.1.3 The Linear Function 156 4.1.4 The N-Log-N Function 156 4.1.5 The Quadratic Function 156 4.1.6 The Cubic Function and Other Polynomials 158 4.1.7 The Exponential Function 159 4.1.8 Comparing Growth Rates 161 4.2 Analysis of Algorithms 162 4.2.1 Experimental Studies 163 4.2.2 Primitive Operations 164 4.2.3 Asymptotic Notation 166 4.2.4 Asymptotic Analysis 170 4.2.5 Using the Big-Oh Notation 172 4.2.6 A Recursive Algorithm for Computing Powers 176 4.2.7 Some More Examples of Algorithm Analysis 177 4.3 Simple Justification Techniques 181 4.3.1 By Example 181 4.3.2 The “Contra” Attack 181 4.3.3 Induction and Loop Invariants 182 4.4 Exercises 185 5 Stacks, Queues, and Deques 193 5.1 Stacks 194 5.1.1 The Stack Abstract Data Type 195 5.1.2 The STL Stack 196 5.1.3 A C++ Stack Interface 196 5.1.4 A Simple Array-Based Stack Implementation 198 5.1.5 Implementing a Stack with a Generic Linked List 202 5.1.6 Reversing a Vector Using a Stack 203 5.1.7 Matching Parentheses and HTML Tags 204 5.2 Queues 208 5.2.1 The Queue Abstract Data Type 208 5.2.2 The STL Queue 209 5.2.3 A C++ Queue Interface 210 5.2.4 A Simple Array-Based Implementation 211 5.2.5 Implementing a Queue with a Circularly Linked List 213 5.3 Double-Ended Queues 217 5.3.1 The Deque Abstract Data Type 217 5.3.2 The STL Deque 218 5.3.3 Implementing a Deque with a Doubly Linked List 218 5.3.4 Adapters and the Adapter Design Pattern 220 5.4 Exercises 223 6 List and Iterator ADTs 227 6.1 Vectors 228 6.1.1 The Vector Abstract Data Type 228 6.1.2 A Simple Array-Based Implementation 229 6.1.3 An Extendable Array Implementation 231 6.1.4 STL Vectors 236 6.2 Lists 238 6.2.1 Node-Based Operations and Iterators 238 6.2.2 The List Abstract Data Type 240 6.2.3 Doubly Linked List Implementation 242 6.2.4 STL Lists 247 6.2.5 STL Containers and Iterators 248 6.3 Sequences 255 6.3.1 The Sequence Abstract Data Type 255 6.3.2 Implementing a Sequence with a Doubly Linked List .255 6.3.3 Implementing a Sequence with an Array 257 6.4 Case Study: Bubble-Sort on a Sequence 259 6.4.1 The Bubble-Sort Algorithm 259 6.4.2 A Sequence-Based Analysis of Bubble-Sort 260 6.5 Exercises 262 7 Trees 267 7.1 General Trees 268 7.1.1 Tree Definitions and Properties 269 7.1.2 Tree Functions 272 7.1.3 A C++ Tree Interface 273 7.1.4 A Linked Structure for General Trees 274 7.2 Tree Traversal Algorithms 275 7.2.1 Depth and Height 275 7.2.2 Preorder Traversal 278 7.2.3 Postorder Traversal 281 7.3 Binary Trees 284 7.3.1 The Binary Tree ADT 285 7.3.2 A C++ Binary Tree Interface 286 7.3.3 Properties of Binary Trees 287 7.3.4 A Linked Structure for Binary Trees 289 7.3.5 A Vector-Based Structure for Binary Trees 295 7.3.6 Traversals of a Binary Tree 297 7.3.7 The Template Function Pattern 303 7.3.8 Representing General Trees with Binary Trees 309 7.4 Exercises 310 8 Heaps and Priority Queues 321 8.1 The Priority Queue Abstract Data Type 322 8.1.1 Keys, Priorities, and Total Order Relations 322 8.1.2 Comparators 324 8.1.3 The Priority Queue ADT 327 8.1.4 A C++ Priority Queue Interface 328 8.1.5 Sorting with a Priority Queue 329 8.1.6 The STL priority queue Class 330 8.2 Implementing a Priority Queue with a List 331 8.2.1 A C++ Priority Queue Implementation using a List 333 8.2.2 Selection-Sort and Insertion-Sort 335 8.3 Heaps 337 8.3.1 The Heap Data Structure 337 8.3.2 Complete Binary Trees and Their Representation 340 8.3.3 Implementing a Priority Queue with a Heap 344 8.3.4 C++ Implementation 349 8.3.5 Heap-Sort 351 8.3.6 Bottom-Up Heap Construction ⋆ 353 8.4 Adaptable Priority Queues 357 8.4.1 A List-Based Implementation 358 8.4.2 Location-Aware Entries 360 8.5 Exercises 361 9 Hash Tables, Maps, and Skip Lists 367 9.1 Maps 368 9.1.1 The Map ADT 369 9.1.2 A C++ Map Interface 371 9.1.3 The STL map Class 372 9.1.4 A Simple List-Based Map Implementation 374 9.2 Hash Tables 375 9.2.1 Bucket Arrays 375 9.2.2 Hash Functions 376 9.2.3 Hash Codes 376 9.2.4 Compression Functions 380 9.2.5 Collision-Handling Schemes 382 9.2.6 Load Factors and Rehashing 386 9.2.7 A C++ Hash Table Implementation 387 9.3 Ordered Maps 394 9.3.1 Ordered Search Tables and Binary Search 395 9.3.2 Two Applications of Ordered Maps 399 9.4 Skip Lists 402 9.4.1 Search and Update Operations in a Skip List 404 9.4.2 A Probabilistic Analysis of Skip Lists ⋆ 408 9.5 Dictionaries 411 9.5.1 The Dictionary ADT 411 9.5.2 A C++ Dictionary Implementation 413 9.5.3 Implementations with Location-Aware Entries 415 9.6 Exercises 417 10 Search Trees 423 10.1 Binary Search Trees 424 10.1.1 Searching 426 10.1.2 Update Operations 428 10.1.3 C++ Implementation of a Binary Search Tree 432 10.2 AVL Trees438 10.2.1 Update Operations 440 10.2.2 C++ Implementation of an AVL Tree 446 10.3 Splay Trees 450 10.3.1 Splaying 450 10.3.2 When to Splay 454 10.3.3 Amortized Analysis of Splaying ⋆456 10.4 (2,4) Trees 461 10.4.1 Multi-Way Search Trees 461 10.4.2 Update Operations for (2,4) Trees 467 10.5 Red-Black Trees473 10.5.1 Update Operations 475 10.5.2 C++ Implementation of a Red-Black Tree 488 10.6 Exercises 492 11 Sorting, Sets, and Selection 499 11.1 Merge-Sort500 11.1.1 Divide-and-Conquer 500 11.1.2 Merging Arrays and Lists 505 11.1.3 The Running Time of Merge-Sort 508 11.1.4 C++ Implementations of Merge-Sort 509 11.1.5 Merge-Sort and Recurrence Equations ⋆ 511 11.2 Quick-Sort 513 11.2.1 Randomized Quick-Sort 521 11.2.2 C++ Implementations and Optimizations 523 11.3 Studying Sorting through an Algorithmic Lens 526 11.3.1 A Lower Bound for Sorting 526 11.3.2 Linear-Time Sorting: Bucket-Sort and Radix-Sort 528 11.3.3 Comparing Sorting Algorithms 531 11.4 Sets and Union/Find Structures 533 11.4.1 The Set ADT 533 11.4.2 Mergable Sets and the Template Method Pattern 534 11.4.3 Partitions with Union-Find Operations 538 11.5 Selection 542 11.5.1 Prune-and-Search 542 11.5.2 Randomized Quick-Select 543 11.5.3 Analyzing Randomized Quick-Select 544 11.6 Exercises 545 12 Strings and Dynamic Programming 553 12.1 String Operations 554 12.1.1 The STL String Class 555 12.2 Dynamic Programming 557 12.2.1 Matrix Chain-Product 557 12.2.2 DNA and Text Sequence Alignment 560 12.3 Pattern Matching Algorithms 564 12.3.1 Brute Force 564 12.3.2 The Boyer-Moore Algorithm 566 12.3.3 The Knuth-Morris-Pratt Algorithm 570 12.4 Text Compression and the Greedy Method 575 12.4.1 The Huffman-Coding Algorithm 576 12.4.2 The Greedy Method 577 12.5 Tries 578 12.5.1 Standard Tries 578 12.5.2 Compressed Tries 582 12.5.3 Suffix Tries 584 12.5.4 Search Engines 586 12.6 Exercises 587 13 Graph Algorithms 593 13.1 Graphs 594 13.1.1 The Graph ADT 599 13.2 Data Structures for Graphs 600 13.2.1 The Edge List Structure 600 13.2.2 The Adjacency List Structure 603 13.2.3 The Adjacency Matrix Structure 605 13.3 Graph Traversals 607 13.3.1 Depth-First Search 607 13.3.2 Implementing Depth-First Search 611 13.3.3 A Generic DFS Implementation in C++ 613 13.3.4 Polymorphic Objects and Decorator Values ⋆ 621 13.3.5 Breadth-First Search 623 13.4 Directed Graphs 626 13.4.1 Traversing a Digraph 628 13.4.2 Transitive Closure 630 13.4.3 Directed Acyclic Graphs 633 13.5 Shortest Paths 637 13.5.1 Weighted Graphs 637 13.5.2 Dijkstra’s Algorithm 639 13.6 Minimum Spanning Trees 645 13.6.1 Kruskal’s Algorithm 647 13.6.2 The Prim-Jarn´ık Algorithm 651 13.7 Exercises 654 14 Memory Management and B-Trees 665 14.1 Memory Management 666 14.1.1 Memory Allocation in C++ 669 14.1.2 Garbage Collection 671 14.2 External Memory and Caching 673 14.2.1 The Memory Hierarchy 673 14.2.2 Caching Strategies 674 14.3 External Searching and B-Trees679 14.3.1 (a,b) Trees 680 14.3.2 B-Trees 682 14.4 External-Memory Sorting 683 14.4.1 Multi-Way Merging 684 14.5 Exercises 685 A Useful Mathematical Facts 689 Bibliography 697 Index 702 1 A C++ Primer 1 1.1 Basic C++ Programming Elements 2 1.1.1 A Simple C++ Program 2 1.1.2 Fundamental Types 4 1.1.3 Pointers, Arrays, and Structures 7 1.1.4 Named Constants, Scope, and Namespaces 13 1.2 Expressions 16 1.2.1 Changing Types through Casting 20 1.3 Control Flow 23 1.4 Functions 26 1.4.1 Argument Passing 28 1.4.2 Overloading and Inlining 30 1.5 Classes 32 1.5.1 Class Structure 33 1.5.2 Constructors and Destructors 37 1.5.3 Classes and Memory Allocation 40 1.5.4 Class Friends and Class Members 43 1.5.5 The Standard Template Library 45 1.6 C++ Program and File Organization 47 1.6.1 An Example Program 48 1.7 Writing a C++ Program53 1.7.1 Design 54 1.7.2 Pseudo-Code 54 1.7.3 Coding 55 1.7.4 Testing and Debugging 57 1.8 Exercises 60 2 Object-Oriented Design 65 2.1 Goals, Principles, and Patterns 66 2.1.1 Object-Oriented Design Goals 66 2.1.2 Object-Oriented Design Principles 67 2.1.3 Design Patterns 70 2.2 Inheritance and Polymorphism 71 2.2.1 Inheritance in C++ 71 2.2.2 Polymorphism 78 2.2.3 Examples of Inheritance in C++ 79 2.2.4 Multiple Inheritance and Class Casting 84 2.2.5 Interfaces and Abstract Classes 87 2.3 Templates 90 2.3.1 Function Templates 90 2.3.2 Class Templates 91 2.4 Exceptions 93 2.4.1 Exception Objects 93 2.4.2 Throwing and Catching Exceptions 94 2.4.3 Exception Specification 96 2.5 Exercises 98 3 Arrays, Linked Lists, and Recursion 103 3.1 Using Arrays 104 3.1.1 Storing Game Entries in an Array 104 3.1.2 Sorting an Array 109 3.1.3 Two-Dimensional Arrays and Positional Games 111 3.2 Singly Linked Lists 117 3.2.1 Implementing a Singly Linked List 117 3.2.2 Insertion to the Front of a Singly Linked List 119 3.2.3 Removal from the Front of a Singly Linked List 119 3.2.4 Implementing a Generic Singly Linked List 121 3.3 Doubly Linked Lists 123 3.3.1 Insertion into a Doubly Linked List 123 3.3.2 Removal from a Doubly Linked List 124 3.3.3 A C++ Implementation 125 3.4 Circularly Linked Lists and List Reversal 129 3.4.1 Circularly Linked Lists 129 3.4.2 Reversing a Linked List 133 3.5 Recursion 134 3.5.1 Linear Recursion 140 3.5.2 Binary Recursion 144 3.5.3 Multiple Recursion 147 3.6 Exercises 149 4 Analysis Tools 153 4.1 The Seven Functions Used in This Book 154 4.1.1 The Constant Function 154 4.1.2 The Logarithm Function 154 4.1.3 The Linear Function 156 4.1.4 The N-Log-N Function 156 4.1.5 The Quadratic Function 156 4.1.6 The Cubic Function and Other Polynomials 158 4.1.7 The Exponential Function 159 4.1.8 Comparing Growth Rates 161 4.2 Analysis of Algorithms 162 4.2.1 Experimental Studies 163 4.2.2 Primitive Operations 164 4.2.3 Asymptotic Notation 166 4.2.4 Asymptotic Analysis 170 4.2.5 Using the Big-Oh Notation 172 4.2.6 A Recursive Algorithm for Computing Powers 176 4.2.7 Some More Examples of Algorithm Analysis 177 4.3 Simple Justification Techniques 181 4.3.1 By Example 181 4.3.2 The “Contra” Attack 181 4.3.3 Induction and Loop Invariants 182 4.4 Exercises 185 5 Stacks, Queues, and Deques 193 5.1 Stacks 194 5.1.1 The Stack Abstract Data Type 195 5.1.2 The STL Stack 196 5.1.3 A C++ Stack Interface 196 5.1.4 A Simple Array-Based Stack Implementation 198 5.1.5 Implementing a Stack with a Generic Linked List 202 5.1.6 Reversing a Vector Using a Stack 203 5.1.7 Matching Parentheses and HTML Tags 204 5.2 Queues 208 5.2.1 The Queue Abstract Data Type 208 5.2.2 The STL Queue 209 5.2.3 A C++ Queue Interface 210 5.2.4 A Simple Array-Based Implementation 211 5.2.5 Implementing a Queue with a Circularly Linked List 213 5.3 Double-Ended Queues 217 5.3.1 The Deque Abstract Data Type 217 5.3.2 The STL Deque 218 5.3.3 Implementing a Deque with a Doubly Linked List 218 5.3.4 Adapters and the Adapter Design Pattern 220 5.4 Exercises 223 6 List and Iterator ADTs 227 6.1 Vectors 228 6.1.1 The Vector Abstract Data Type 228 6.1.2 A Simple Array-Based Implementation 229 6.1.3 An Extendable Array Implementation 231 6.1.4 STL Vectors 236 6.2 Lists 238 6.2.1 Node-Based Operations and Iterators 238 6.2.2 The List Abstract Data Type 240 6.2.3 Doubly Linked List Implementation 242 6.2.4 STL Lists 247 6.2.5 STL Containers and Iterators 248 6.3 Sequences255 6.3.1 The Sequence Abstract Data Type 255 6.3.2 Implementing a Sequence with a Doubly Linked List .255 6.3.3 Implementing a Sequence with an Array 257 6.4 Case Study: Bubble-Sort on a Sequence 259 6.4.1 The Bubble-Sort Algorithm 259 6.4.2 A Sequence-Based Analysis of Bubble-Sort 260 6.5 Exercises 262 7 Trees 267 7.1 General Trees 268 7.1.1 Tree Definitions and Properties 269 7.1.2 Tree Functions 272 7.1.3 A C++ Tree Interface 273 7.1.4 A Linked Structure for General Trees 274 7.2 Tree Traversal Algorithms 275 7.2.1 Depth and Height 275 7.2.2 Preorder Traversal 278 7.2.3 Postorder Traversal 281 7.3 Binary Trees 284 7.3.1 The Binary Tree ADT 285 7.3.2 A C++ Binary Tree Interface 286 7.3.3 Properties of Binary Trees 287 7.3.4 A Linked Structure for Binary Trees 289 7.3.5 A Vector-Based Structure for Binary Trees 295 7.3.6 Traversals of a Binary Tree 297 7.3.7 The Template Function Pattern 303 7.3.8 Representing General Trees with Binary Trees 309 7.4 Exercises 310 8 Heaps and Priority Queues 321 8.1 The Priority Queue Abstract Data Type 322 8.1.1 Keys, Priorities, and Total Order Relations 322 8.1.2 Comparators 324 8.1.3 The Priority Queue ADT 327 8.1.4 A C++ Priority Queue Interface 328 8.1.5 Sorting with a Priority Queue 329 8.1.6 The STL priority queue Class 330 8.2 Implementing a Priority Queue with a List 331 8.2.1 A C++ Priority Queue Implementation using a List 333 8.2.2 Selection-Sort and Insertion-Sort 335 8.3 Heaps 337 8.3.1 The Heap Data Structure 337 8.3.2 Complete Binary Trees and Their Representation 340 8.3.3 Implementing a Priority Queue with a Heap 344 8.3.4 C++ Implementation 349 8.3.5 Heap-Sort 351 8.3.6 Bottom-Up Heap Construction ⋆353 8.4 Adaptable Priority Queues 357 8.4.1 A List-Based Implementation 358 8.4.2 Location-Aware Entries 360 8.5 Exercises 361 9 Hash Tables, Maps, and Skip Lists 367 9.1 Maps 368 9.1.1 The Map ADT 369 9.1.2 A C++ Map Interface 371 9.1.3 The STL map Class 372 9.1.4 A Simple List-Based Map Implementation 374 9.2 Hash Tables 375 9.2.1 Bucket Arrays 375 9.2.2 Hash Functions 376 9.2.3 Hash Codes 376 9.2.4 Compression Functions 380 9.2.5 Collision-Handling Schemes 382 9.2.6 Load Factors and Rehashing 386 9.2.7 A C++ Hash Table Implementation 387 9.3 Ordered Maps 394 9.3.1 Ordered Search Tables and Binary Search 395 9.3.2 Two Applications of Ordered Maps 399 9.4 Skip Lists 402 9.4.1 Search and Update Operations in a Skip List 404 9.4.2 A Probabilistic Analysis of Skip Lists ⋆408 9.5 Dictionaries 411 9.5.1 The Dictionary ADT 411 9.5.2 A C++ Dictionary Implementation 413 9.5.3 Implementations with Location-Aware Entries 415 9.6 Exercises 417 10 Search Trees 423 10.1 Binary Search Trees 424 10.1.1 Searching 426 10.1.2 Update Operations 428 10.1.3 C++ Implementation of a Binary Search Tree 432 10.2 AVL Trees438 10.2.1 Update Operations 440 10.2.2 C++ Implementation of an AVL Tree 446 10.3 Splay Trees 450 10.3.1 Splaying 450 10.3.2 When to Splay 454 10.3.3 Amortized Analysis of Splaying ⋆456 10.4 (2,4) Trees 461 10.4.1 Multi-Way Search Trees 461 10.4.2 Update Operations for (2,4) Trees 467 10.5 Red-Black Trees473 10.5.1 Update Operations 475 10.5.2 C++ Implementation of a Red-Black Tree 488 10.6 Exercises 492 11 Sorting, Sets, and Selection 499 11.1 Merge-Sort500 11.1.1 Divide-and-Conquer 500 11.1.2 Merging Arrays and Lists 505 11.1.3 The Running Time of Merge-Sort 508 11.1.4 C++ Implementations of Merge-Sort 509 11.1.5 Merge-Sort and Recurrence Equations ⋆511 11.2 Quick-Sort 513 11.2.1 Randomized Quick-Sort 521 11.2.2 C++ Implementations and Optimizations 523 11.3 Studying Sorting through an Algorithmic Lens 526 11.3.1 A Lower Bound for Sorting 526 11.3.2 Linear-Time Sorting: Bucket-Sort and Radix-Sort 528 11.3.3 Comparing Sorting Algorithms 531 11.4 Sets and Union/Find Structures 533 11.4.1 The Set ADT 533 11.4.2 Mergable Sets and the Template Method Pattern 534 11.4.3 Partitions with Union-Find Operations 538 11.5 Selection 542 11.5.1 Prune-and-Search 542 11.5.2 Randomized Quick-Select 543 11.5.3 Analyzing Randomized Quick-Select 544 11.6 Exercises 545 12 Strings and Dynamic Programming 553 12.1 String Operations 554 12.1.1 The STL String Class 555 12.2 Dynamic Programming 557 12.2.1 Matrix Chain-Product 557 12.2.2 DNA and Text Sequence Alignment 560 12.3 Pattern Matching Algorithms 564 12.3.1 Brute Force 564 12.3.2 The Boyer-Moore Algorithm 566 12.3.3 The Knuth-Morris-Pratt Algorithm 570 12.4 Text Compression and the Greedy Method 575 12.4.1 The Huffman-Coding Algorithm 576 12.4.2 The Greedy Method 577 12.5 Tries 578 12.5.1 Standard Tries 578 12.5.2 Compressed Tries 582 12.5.3 Suffix Tries 584 12.5.4 Search Engines 586 12.6 Exercises 587 13 Graph Algorithms 593 13.1 Graphs 594 13.1.1 The Graph ADT 599 13.2 Data Structures for Graphs 600 13.2.1 The Edge List Structure 600 13.2.2 The Adjacency List Structure 603 13.2.3 The Adjacency Matrix Structure 605 13.3 Graph Traversals 607 13.3.1 Depth-First Search 607 13.3.2 Implementing Depth-First Search 611 13.3.3 A Generic DFS Implementation in C++ 613 13.3.4 Polymorphic Objects and Decorator Values ⋆621 13.3.5 Breadth-First Search 623 13.4 Directed Graphs 626 13.4.1 Traversing a Digraph 628 13.4.2 Transitive Closure 630 13.4.3 Directed Acyclic Graphs 633 13.5 Shortest Paths 637 13.5.1 Weighted Graphs 637 13.5.2 Dijkstra’s Algorithm 639 13.6 Minimum Spanning Trees 645 13.6.1 Kruskal’s Algorithm 647 13.6.2 The Prim-Jarn´ık Algorithm 651 13.7 Exercises 654 14 Memory Management and B-Trees 665 14.1 Memory Management 666 14.1.1 Memory Allocation in C++ 669 14.1.2 Garbage Collection 671 14.2 External Memory and Caching 673 14.2.1 The Memory Hierarchy 673 14.2.2 Caching Strategies 674 14.3 External Searching and B-Trees679 14.3.1 (a,b) Trees 680 14.3.2 B-Trees 682 14.4 External-Memory Sorting 683 14.4.1 Multi-Way Merging 684 14.5 Exercises 685 A Useful Mathematical Facts 689 Bibliography 697 Index 702
£151.16
John Wiley & Sons Inc UML in Practice
Book SynopsisUML is the de facto industry standard modeling language for specifying, visualizing, constructing, and documenting aspects of the design of software systems. UML in Practice offers practical, clear guidance on the real--life usage of UML, mentoring software developers through every aspect of the modeling process.Table of ContentsForeword ix Introduction xi Acknowledgements xv PART 1 FUNCTIONAL VIEW 1 1 Case study: automatic teller machine 3 1.1 Step 1 – Identifying the actors of the ATM 5 1.2 Step 2 – Identifying use cases 8 1.3 Step 3 – Creating use case diagrams 10 1.4 Step 4 – Textual description of use cases 14 1.5 Step 5 – Graphical description of use cases 20 1.6 Step 6 – Organising the use cases 26 2 Complementary exercises 37 2.1 Step 1 – Business modelling 53 2.2 Step 2 – Defining system requirements 57 Appendix A: Glossary & tips 65 PART 2 STATIC VIEW 71 3 Case study: flight booking system 73 3.1 75 3.2 Step 2 – Modelling sentences 6, 7 and 10 77 3.3 Step 3 – Modelling sentences 8 and 9 82 3.4 Step 4 – Modelling sentences 3, 4 and 5 86 3.5 Step 5 – Adding attributes, constraints and qualifiers 89 3.6 Step 6 – Using analysis patterns 94 3.7 Step 7 – Structuring into packages 98 3.8 Step 8 – Generalisation and re-use 105 4 Complementary exercises 113 Appendix B: Glossary & tips 149 Step 1– Modelling sentences 1 and 2 PART 3 DYNAMIC VIEW 157 5 Case study: coin-operated pay phone 159 5.1 Step 1 – Identifying the actors and use cases 161 5.2 Step 2 – Realising the system sequence diagram 164 5.3 Step 3 – Representing the dynamic context 166 5.4 Step 4 – In-depth description using a state diagram 168 6 Complementary exercises 185 Apendix C: Glossary & tips 207 PART 4 DESIGN 213 7 Case study: training request 215 7.1 Step 1 – Defining iterations 217 7.2 Step 2 – Defining the system architecture 219 7.3 Step 3 – Defining system operations (iteration 1) 224 7.4 Step 4 – Operation contracts (iteration 1) 225 7.5 Step 5 – Interaction diagrams (iteration 1) 228 7.6 Step 6 – Design class diagrams (iteration 1) 237 7.7 Step 7 – Defining the system operations (iteration 2) 245 7.8 Step 8 – Operation contracts (iteration 2) 247 7.9 Step 9 – Interaction diagrams (iteration 2) 250 7.10 Step 10 – Design class diagrams (iteration 2) 252 7.11 Step 11 – Back to architecture 253 7.12 Step 12 – Transition to Java code 254 7.13 Step 13 – Putting the application into action 262 8 Complementary exercises 267 Appendix D: Glossary & tips 283 Index 293
£27.20
John Wiley & Sons Inc Practical Database Programming with Java
Book SynopsisThis important resource offers a detailed description about the practical considerations and applications in database programming using Java NetBeans 6. 8 with authentic examples and detailed explanations. This book provides readers with a clear picture as to how to handle the database programming issues in the Java NetBeans environment.Table of ContentsPreface xxiii Acknowledgments xxv Chapter 1 Introduction 1 What This Book Covers 2 How This Book Is Organized and How to Use This Book 3 How to Use the Source Code and Sample Databases 5 Instructor and Customer Support 6 Homework Solutions 7 Chapter 2 Introduction to Databases 9 2.1 What Are Databases and Database Programs? 10 2.2 Develop a Database 12 2.3 Sample Database 13 2.4 Identifying Keys 17 2.5 Define Relationships 18 2.6 ER Notation 21 2.7 Data Normalization 21 2.8 Database Components in Some Popular Databases 26 2.9 Create Microsoft Access Sample Database 34 2.10 Create Microsoft SQL Server 2008 2.11 Create Oracle 10g XE Sample Database 61 2.12 Chapter Summary 85 Chapter 3 JDBC API and JDBC Drivers 89 3.1 What Are JDBC and JDBC API? 89 3.2 JDBC Components and Architecture 90 3.3 How Does JDBC Work? 92 3.4 JDBC Driver and Driver Types 95 3.5 JDBC Standard Extension API 99 3.6 Chapter Summary 108 Chapter 4 JDBC Application Design Considerations 113 4.1 JDBC Application Models 113 4.2 JDBC Applications Fundamentals 115 4.3 Chapter Summary 151 Chapter 5 Introduction to NetBeans IDE 155 5.1 Overview of the NetBeans IDE 6.8 156 5.2 Installing and Confi guring the NetBeans IDE 6.8 161 5.3 Exploring NetBeans IDE 6.8 164 5.4 Chapter Summary 312 PART I Building Two-Tier Client–Server Applications 317 Chapter 6 Query Data from Databases 319 Section I Query Data Using Java Persistence API Wizards 319 6.1 Java Persistence APIs 319 6.2 Query Data Using Java Persistence API Wizards (JPA) 321 Section II Query Data Using Java Runtime Objects Method 383 6.3 Introduction to Runtime Object Method 383 6.4 Create a Java Application Project to Access the SQL Server Database 384 6.5 Create a Java Application Project to Access the Oracle Database 441 6.6 Chapter Summary 455 Chapter 7 Insert, Update, and Delete Data from Databases 463 Section I Insert, Update and Delete Data Using Java Persistence API Wizards 463 7.1 Perform Data Manipulations to SQL Server Database Using JPA Wizards 464 7.2 Perform Data Manipulations to Oracle Database Using JPA Wizards 482 Section II Insert, Update and Delete Data Using Java Runtime Objects Method 488 7.3 Perform Data Manipulations to SQL Server Database Using Java Runtime Object 488 7.4 Perform Data Manipulations to Oracle Database Using Java Runtime Object 502 7.5 Perform Data Manipulations Using Updatable ResultSet 510 7.6 Perform Data Manipulations Using Callable Statements 522 7.7 Chapter Summary 550 PART II Building Three-Tier Client–Server Applications 555 Chapter 8 Developing Java Web Applications to Access Databases 557 8.1 A Historical Review about Java Web Application Development 557 8.2 Java EE Web Application Model 597 8.3 The Architecture and Components of Java Web Applications 599 8.4 Getting Started with Java Web Applications Using NetBeans IDE 611 8.5 Build Java Web Project to Access SQL Server Database 625 8.6 Build Java Web Project to Access and Manipulate Oracle Database 690 8.7 Chapter Summary 764 Chapter 9 Developing Java Web Services to Access Databases 769 9.1 Introduction to Java Web Services 770 9.2 The Structure and Components of SOAP-Based Web Services 772 9.3 The Procedure of Building a Typical SOAP-Based Web Service Project 774 9.4 Getting Started with Java Web Services Using NetBeans IDE 786 9.5 Build Java Web Service Projects to Access SQL Server Database 787 9.6 Build a Windows-Based Web Client Project to Consume the Web Service 795 9.7 Build a Web-Based Client Project to Consume the Web Service 801 9.8 Build Java Web Service to Insert Data into the SQL Server Database 808 9.9 Build a Windows-Based Web Client Project to Consume the Web Service 811 9.10 Build a Web-Based Client Project to Consume the Web Service 815 9.11 Build Java Web Service to Update and Delete Data from the SQL Server Database 819 9.12 Build a Windows-Based Web Client Project to Consume the Web Service 827 9.13 Build a Web-Based Client Project to Consume the Web Service 834 9.14 Build Java Web Service Projects to Access Oracle Databases 840 9.15 Build a Windows-Based Web Client Project to Consume the Web Service 873 9.16 Build a Web-Based Web Client Project to Consume the Web Service 890 9.17 Chapter Summary 904 Homework 905 Index 909 About the Author 919
£86.36
John Wiley & Sons Inc Karel the Robot A Gentle Introduction to the Art
Book SynopsisUses a creative approach to teach the basic skills and concepts of programming quickly. This edition offers excellent insights into problem solving and program design processes. It will also improve comprehension of such computer science considerations as loop invariants and recursion. Includes 60 color line drawings.Table of ContentsThe Robot World. Primitive Instructions and Simple Programs. Extending Karel's Vocabulary. Conditionally Executing Instructions. Instructions That Repeat. Advanced Techniques for Karel. Appendix. Indexes.
£26.52
John Wiley & Sons Inc Introductory Programming with ObjectOriented C
Book SynopsisA gentle introductory programming book written specifically to teach readers to use objects for the very beginning, rather than starting with structured programming. Perfect for structure programmers that need to learn the object-oriented perspective. Covers the fundamentals of C++ and gives a firm grounding in the object-oriented paradigm. Begins with the systems development life cycle and demonstrates where the software development cycle fits within it.Table of ContentsSoftware Development: The Organizational Process. Software Development: The Programming Process. The Role of Binary. Introducing the Object-Oriented Paradigm. Anatomy of a C++ Program. Variables. Declaring Member Functions. Writing and Using Member Functions. Stream I/O. File I/O. Doing Arithmetic. Making Decisions. Repeating Actions. Introducing Arrays. Arrays of Objects. Strings. Pointers. Inheritance. Linked Lists. Overloading. Templates. Summing Up. Glossary. Index.
£158.60
John Wiley & Sons Inc An Introduction to Object COBOL
Book SynopsisAre You Ready to Meet the Demand for Object COBOL Programming? Now you can keep up-to-date with the newest standards in COBOL. With its use of straightforward language and real-world examples, An Introduction To Object COBOL is a concise and accessible introduction to using Object COBOL.Table of ContentsWhy Study Object-Oriented Technology? Object-Oriented Concepts. Why Study Object COBOL? The Evolution of the COBOL Language. Fundamentals of Object COBOL. Working With Superclasses and Subclasses. Data Management. User Interface. Object COBOL and Beyond. Index.
£77.36
John Wiley & Sons Inc Java Programming
Book SynopsisThis introduction to Java programming features a business focus. It discusses what it means to be object oriented, how to structure classes, and how to write methods using Java''s structured programming elements. After outlining the elements of a complete Java program, the book moves on to advanced topics such as writing event-driven GUI programs, preparing applets for the Web, one- and two-dimensional arrays, animation, and more. Files from the book will be available on the Web.Table of ContentsIntroducing Java and the Object-Oriented Paradigm. Running Java. Variables and Data Types. Writing and Using Methods (Part I). Writing Methods (Part II). Inheritance. Event-Driven Programming and the Graphic User Interface. Arrays and Vectors. Containers. Applets. Enhancing the GUI. File I/O and Exception Handling. Images, Animation, and Threads. Glossary. Index.
£144.00
John Wiley & Sons Inc Data Structures and Algorithms with
Book SynopsisAn object-oriented learning framework for creating good software design. Bruno Preiss presents readers with a modern, object-oriented perspective for looking at data structures and algorithms, clearly showing how to use polymorphism and inheritance, and including fragments from working and tested programs.Table of ContentsAlgorithm Analysis. Asymptotic Notation. Foundational Data Structures. Data Types and Abstraction. Stacks, Queues and Deques. Ordered Lists and Sorted Lists. Hashing, Hash Tables and Scatter Tables. Trees. Search Trees. Heaps and Priority Queues. Sets, Multisets and Partitions. Dynamic Storage Allocation. Algorithmic Patterns and Problem Solvers. Sorting Algorithms and Sorters. Graphs and Graph Algorithms. Appendices. Index.
£180.86
John Wiley & Sons Inc A Practical Introduction to ObjectOriented Design
Book SynopsisThis text details the use of inheritance, object libraries, design patterns and notations, and library class creation. It discusses language and programming features like exception handling, and interprocess communication. It also contains material from software engineering and object-orientation.Table of ContentsWhat Is Object-Oriented Design? A Simple Example of Object-Oriented Design. Implementing an Object-Oriented Design. How to Use C++ Effectively. Designing with Inheritance. Design Notations. Using Object-Oriented Libraries. Debugging and Testing. Graphical Application Concepts. Designing Graphical Applications. User-Interface Design. Creating Object Libraries. Design Patterns. Multiple-Processs Programming. Software Engineering. Writing Larger Systems. Appendices. Index.
£164.30
John Wiley & Sons Inc Programming with Objects
Book SynopsisPROGRAMMING WITH OBJECTS Your essential comparative approach to learning C++ and Java Programming with Objects: A Comparative Presentation of Object-Oriented Programming with C++ and Java, a comparative presentation of object-oriented programming with two of the most popular programming languages of today, teaches vital skills and techniques for the Internet age. Based on highly successful courses taught by the author, this book answers the need for a comprehensive educational program on the subject of object-oriented programming. In a clear and accessible format, the author compares and contrasts both languages, from basic language constructs to how both languages are used in application-level programming, such as graphics programming, network programming, and database programming. Since both C++ and Java were born out of the same language, C, learning these two languages together has several distinct advantages: Because they have much in common aTrade Review"...a wonderful volume...a very worthwhile read...essential..." (Choice, September 2003)Table of ContentsWhy OO Programming - Some Parallels with Things at Large. Baby Steps. The Notion of a Class and Some Other Key Ideas. Strings. Using the Container Classes. The Primitive Types and Their Input/Output. Declarations, Definitions, and Initializations. Object Reference and Memory Allocation. Functions and Methods. Handling Exceptions. Classes, The Rest of the Story. Overloading Operators in C++. Generics and Templates. Modeling Diagrams for OO Programs. Extending Classes. Multiple Inheritance in C++. OO for Graphical User Interfaces, A Tour of Three Toolkits. Multithreaded Object-Oriented Programming. Network Programming. Database Programming.
£99.86
John Wiley & Sons Inc The Common LISP Companion
Book SynopsisA self-contained, intermediate-level introduction to the structure and syntax of Common Lisp, this text is the first based on the draft ANSI standard for Common Lisp. Presents the concepts of object-oriented programming and incorporates the Common Lisp Object-Oriented Systems (CLOS) of the new ANSI standard. Includes end-of-section exercises.Table of ContentsIntroduction--Wherefore Lisp?. The Rule of Three--The Three Rules of Evaluation. Forms and Functions--Defining Common Lisp Functions. Inquisitor of Structures--Common Lisp Symbols. Objects all Sublime--Common Lisp Structures. Methods--Generic Functions. Gently Down the Stream--Lisp I/O. Functions Revisited--Advanced Features of Functions. Program Structure--Structuring Code. Programmation Etlogique--Logic Programming. Epilogue--Common Lisp: A Reappraisal for Further Reading. Appendices. References. Index.
£129.56