Beginning C# Objects : From Concepts to Code
Leverbaar
About the Authors xiii Acknowledgments xv Preface xvii Introduction xix Part One: The ABCs of Objects A Little Taste of C# 3(52) Getting ``Hands On'' with C# 4(1) Why C#? 4(3) C# Language Basics 7(1) Anatomy of a Simple C# Program 8(3) Predefined Types 11(1) Variables 12(3) Strings 15(1) Case Sensitivity 16(1) C# Expressions 16(6) Implicit Type Conversions and Explicit Casting 22(2) Loops and Other Flow of Control Structures 24(12) Jump Statements 36(1) Code Blocks and Variable Scope 37(2) Printing to the Screen 39(4) Elements of C# Style 43(8) Summary 51(1) Exercises 52(3) Abstraction and Modeling 55(14) Simplification Through Abstraction 55(1) Generalization Through Abstraction 56(6) Reuse of Abstractions 62(1) Inherent Challenges 63(3) Summary 66(1) Exercises 66(3) Objects and Classes 69(22) What Is an Object? 69(1) State/Attributes/Data 70(2) Behavior/Operations/Methods 72(2) Classes 74(5) User-Defined Types and Reference Variables 79(1) Instantiating Objects: A Closer Look 80(4) Objects As Attributes 84(2) Composition 86(3) Three Distinguishing Features of an Object-Oriented Programming Language 89(1) Summary 89(1) Exercises 90(1) Object Interactions 91(68) Events Drive Object Collaboration 91(2) Declaring Methods 93(9) Method Invocation and Dot Notation 102(16) Information Hiding/Accessibility 118(24) The Power of Encapsulation 142(9) Instance Constructors 151(4) Summary 155(1) Exercises 156(3) Relationships Between Objects 159(42) Associations and Links 160(8) Inheritance 168(28) Three Distinguishing Features of an Object-Oriented Programming Language, Revisited 196(1) Summary 197(1) Exercises 197(4) Collections of Objects 201(36) What Are Collections? 201(4) Arrays As Simple Collections 205(10) More Sophisticated Collection Types 215(5) Referencing the Same Object Simultaneously from Multiple Collections 220(1) Inventing Our Own Collection Types 221(6) Collections As Method Return Types 227(1) Collections of Supertypes 228(2) Composite Classes, Revisited 230(4) Summary 234(1) Exercises 235(2) Some Final Object Concepts 237(1) What Is Polymorphism? 238(9) Three Distinguishing Features of an Object-Oriented Programming Language 247(1) Abstract Classes 248(8) Interfaces 256(15) Static Features 271(12) Utility Classes 283(5) Summary 288(1) Exercises 289 Part Two: Object Modeling 101(670) The Object Modeling Process in a Nutshell 295(12) The ``Big Picture'' Goal of Object Modeling 295(5) Our Object Modeling Process, in a Nutshell 300(4) Summary 304(1) Exercises 305(2) Formalizing Requirements Through Use Cases 307(14) What Are Use Cases? 308(2) Actors 310(5) Specifying Use Cases 315(1) Matching Up Use Cases with Actors 316(1) To Diagram or Not to Diagram? 317(2) Summary 319(1) Exercises 319(2) Modeling the Static/Data Aspects of the System 321(62) Identifying Appropriate Classes 322(14) Producing a Data Dictionary 336(2) Determining Associations Between Classes 338(5) Identifying Attributes 343(1) UML Notation: Modeling the Static Aspects of an Abstraction 343(14) Object Diagrams 357(4) Information ``Flows'' Along the Association ``Pipeline'' 361(5) ``Mixing and Matching'' Relationship Notations 366(3) Association Classes 369(3) Our Completed Student Registration System Class Diagram 372(7) Metadata 379(2) Summary 381(1) Exercises 382(1) Modeling the Dynamic/Behavioral Aspects of the System 383(26) How Behavior Affects State 384(7) Scenarios 391(4) Sequence Diagrams 395(6) Using Sequence Diagrams to Determine Methods 401(3) Collaboration Diagrams 404(1) Revised SRS Class Diagram 405(2) Summary 407(1) Exercises 407(2) Wrapping Up Our Modeling Efforts 409(12) Testing Your Model 409(1) Revisiting Requirements 410(3) Reusing Models: A Word About Design Patterns 413(3) Summary 416(1) Exercises 417(4) Part Three: Translating a UML ``Blueprint'' into C# Code A Deeper Look at C# 421(126) Sorting Out Terminology 422(2) Setting Up a C# Programming Environment 424(1) Compiling and Running C# Programs 424(14) Namespaces 438(7) Strings As Objects 445(7) C# Exception Handling 452(14) The Object Class 466(8) C#'s Collection Classes 474(24) Initialization of Variables, Revisited 498(2) More About the Main Method 500(1) Developing Command-Line Driven Applications 501(7) Object Self-Referencing with ``this'' 508(2) Constructors, Revisited 510(7) More About Inheritance and C# 517(11) More on Methods 528(5) Object Identities 533(6) Object Deletion and Garbage Collection 539(2) The ``Other'' Kind of Attribute 541(1) Summary 542(2) Exercises 544(3) Transforming Our UML Model into C# Code 547(64) Suggestions for Getting the Maximum Value out of This and Subsequent Chapters 548(1) The SRS Class Diagram, Revisited 548(57) Debugging Tip 605(4) Summary 609(1) Exercises 609(2) Rounding Out Our Application, Part 1: Adding File Persistence 611(56) What Is Persistence? 612(13) Collection Wrapper (Encapsulating Collections; Reading from an ASCII File) 625(5) CourseCatalog 630(8) Faculty 638(2) Revamping ScheduleOfClasses 640(3) Course Modifications 643(1) The Student Class (Dynamic Data Retrieval; Persisting Object State) 644(9) Revisiting the SRS Class 653(11) Summary 664(1) Exercises 664(3) Rounding Out Our Application, Part 2: Adding a Graphical User Interface 667(96) C# GUIs: A Primer 668(8) Stage 1: Preparing a Concept of Operations for the SRS GUI 676(9) Stage 2: Creating the Look of Our GUI 685(31) Stage 3: Adding Functionality Through Event Handling 716(44) Summary 760(1) Exercises 761(2) Next Steps 763(8) Our ``Tried and True'' Approach to Learning C# Properly 764(1) Recommended Reading 765(2) Your Comments, Please! 767(4) Appendix A Suggestions for Using This Book As a Textbook 771(4) Recommended Teaching Approaches 771(1) Suitability of C# As a Teaching Language 772(1) Some Final Recommendations 773(2) Appendix B Alternative Case Studies 775(8) Case Study #1: Prescription Tracking System 775(2) Case Study #2: Conference Room Reservation System 777(4) Case Study #3: Blue Skies Airline Reservation System 781(2) Appendix C Setting Up a Basic Object Modeling/C# Environment 783(8) Object Modeling Tools 783(1) The .NET Framework Software Developer's Kit 783(1) ``Odds and Ends'' Tips for Getting C# to Work Properly 784(5) Using the Online .NET Framework Documentation 789(1) Some Final Notes 789(2) Appendix D Downloading and Compiling the SRS Source Code 791(2) Appendix E C# Keywords 793(1) Index 793
Ingenaaid | 819 pagina's | Engels
1e druk | Verschenen in 2004
Rubriek: