چه کسانی این کتاب را می‌خوانند

دانشجوعلاقه‌مند یادگیری
کتابخوان حرفه‌ایلذت مطالعه
نویسندهالهام‌گیری

Windows System Programming (4th Edition) (Addison-Wesley Microsoft Technology Series)

Johnson M. Hart

قیمت نهایی

۴۰٬۰۰۰ تومان۴۹٬۰۰۰ تومان۱۸٪ تخفیف
  • تخفیف زمان‌دار−۹٬۰۰۰ تومان

۹٬۰۰۰ تومان صرفه‌جویی نسبت به قیمت اصلی

بلافاصله پس از خرید، فایل کتاب روی دستگاه شما آمادهٔ دانلود است.

تحویل فوری
پرداخت امن
ضمانت فایل
پشتیبانی

نسخه اصلی و اورجینال

فایل دیجیتال کامل و بدون دستکاری — همان نسخه‌ای که پس از خرید دریافت می‌کنید.

مشخصات کتاب

نویسنده
Johnson M. Hart
سال انتشار
۲۰۱۰
فرمت
PDF
زبان
انگلیسی
حجم فایل
۱۰٫۹ مگابایت
شابک
9780321657749، 9780321658265، 9780321658272، 0321657748، 0321658264، 0321658272

دربارهٔ کتاب

__"If you're writing a native Win32 program or just want to know what the OS is really doing underneath, you need John's book. He covers the stuff that real systems programmers absolutely must know. Recommended."____"This fourth edition does a great job of incorporating new features in the Vista, Windows 2008, and Windows 7 API, but also stays true to teaching the foundational elements of building applications that target the Windows OS."__**The Definitive Guide to Windows API Programming, Fully Updated for Windows 7, Windows Server 2008, and Windows Vista**now contains extensive new coverage of 64-bit programming, parallelism, multicore systems, and many other crucial topics. Johnson Hart's robust code examples have been updated and streamlined throughout. They have been debugged and tested in both 32-bit and 64-bit versions, on single and multiprocessor systems, and under Windows 7, Vista, Server 2008, and Windows XP. To clarify program operation, sample programs are now illustrated with dozens of screenshots. Hart systematically covers Windows externals at the API level, presenting practical coverage of all the services Windows programmers need, and emphasizing how Windows functions actually behave and interact in real-world applications. Hart begins with features used in single-process applications and gradually progresses to more sophisticated functions and multithreaded environments. Topics covered include file systems, memory management, exceptions, processes, threads, synchronization, interprocess communication, Windows services, and security. New coverage in this edition includesLeveraging parallelism and maximizing performance in multicore systems Promoting source code portability and application interoperability across Windows, Linux, and UNIX Using 64-bit address spaces and ensuring 64-bit/32-bit portability Improving performance and scalability using threads, thread pools, and completion ports Techniques to improve program reliability and performance in all systems Windows performance-enhancing API features available starting with Windows Vista, such as slim reader/writer locks and condition variables A companion Web site,, contains all sample code, Visual Studio projects, additional examples, errata, reader comments, and Windows commentary and discussion. Contents 5 Figures 15 Tables 17 Programs 19 Program Runs 23 Preface 25 About the Author 35 CHAPTER 1 Getting Started with Windows 37 Operating System Essentials 37 Windows Evolution 38 Windows Versions 39 The Windows Market Role 41 Windows, Standards, and Open Systems 42 Windows Principles 43 32-bit and 64-bit Source Code Portability 46 The Standard C Library: When to Use It for File Processing 46 What You Need to Use This Book 47 Example: A Simple Sequential File Copy 49 Summary 56 Exercises 58 CHAPTER 2 Using the Windows File System and Character I/O 61 The Windows File Systems 62 File Naming 63 Opening, Reading, Writing, and Closing Files 64 Interlude: Unicode and Generic Characters 70 Unicode Strategies 73 Example: Error Processing 74 Standard Devices 75 Example: Copying Multiple Files to Standard Output 77 Example: Simple File Encryption 79 File and Directory Management 82 Console I/O 87 Example: Printing and Prompting 89 Example: Printing the Current Directory 91 Summary 92 Exercises 93 CHAPTER 3 Advanced File and Directory Processing, and the Registry 95 The 64-Bit File System 95 File Pointers 96 Getting the File Size 100 Example: Random Record Updates 101 File Attributes and Directory Processing 106 Example: Listing File Attributes 111 Example: Setting File Times 114 File Processing Strategies 116 File Locking 117 The Registry 122 Registry Management 124 Example: Listing Registry Keys and Contents 128 Summary 132 Exercises 133 CHAPTER 4 Exception Handling 137 Exceptions and Their Handlers 137 Floating-Point Exceptions 144 Errors and Exceptions 146 Example: Treating Errors as Exceptions 148 Termination Handlers 149 Example: Using Termination Handlers to Improve Program Quality 153 Example: Using a Filter Function 156 Console Control Handlers 160 Example: A Console Control Handler 162 Vectored Exception Handling 164 Summary 165 Exercises 166 CHAPTER 5 Memory Management, Memory-Mapped Files, and DLLs 167 Windows Memory Management Architecture 168 Heaps 170 Managing Heap Memory 173 Example: Sorting Files with a Binary Search Tree 179 Memory-Mapped Files 185 Example: Sequential File Processing with Mapped Files 192 Example: Sorting a Memory-Mapped File 194 Example: Using Based Pointers 198 Dynamic Link Libraries 203 Example: Explicitly Linking a File Conversion Function 208 The DLL Entry Point 210 DLL Version Management 211 Summary 213 Exercises 214 CHAPTER 6 Process Management 217 Windows Processes and Threads 217 Process Creation 219 Process Identities 226 Duplicating Handles 227 Exiting and Terminating a Process 228 Waiting for a Process to Terminate 230 Environment Blocks and Strings 231 Example: Parallel Pattern Searching 233 Processes in a Multiprocessor Environment 237 Process Execution Times 238 Example: Process Execution Times 238 Generating Console Control Events 240 Example: Simple Job Management 241 Example: Using Job Objects 251 Summary 255 Exercises 256 CHAPTER 7 Threads and Scheduling 259 Thread Overview 259 Thread Basics 261 Thread Management 262 Using the C Library in Threads 267 Example: Multithreaded Pattern Searching 268 Performance Impact 271 The Boss/Worker and Other Threading Models 272 Example: Merge-Sort—Exploiting Multiple Processors 273 Introduction to Program Parallelism 280 Thread Local Storage 281 Process and Thread Priority and Scheduling 282 Thread States 285 Pitfalls and Common Mistakes 287 Timed Waits 288 Fibers 289 Summary 292 Exercises 292 CHAPTER 8 Thread Synchronization 295 The Need for Thread Synchronization 295 Thread Synchronization Objects 304 CRITICAL_SECTION Objects 305 A CRITICAL_SECTION for Protecting Shared Variables 307 Example: A Simple Producer/Consumer System 309 Mutexes 315 Semaphores 320 Events 323 Example: A Producer/Consumer System 325 More Mutex and CRITICAL_SECTION Guidelines 330 More Interlocked Functions 332 Memory Management Performance Considerations 333 Summary 334 Exercises 334 CHAPTER 9 Locking, Performance, and NT6 Enhancements 337 Synchronization Performance Impact 338 A Model Program for Performance Experimentation 343 Tuning Multiprocessor Performance with CS Spin Counts 343 NT6 Slim Reader/Writer Locks 345 Thread Pools to Reduce Thread Contention 348 I/O Completion Ports 352 NT6 Thread Pools 352 Summary: Locking Performance 360 Parallelism Revisited 361 Processor Affinity 365 Performance Guidelines and Pitfalls 367 Summary 368 Exercises 369 CHAPTER 10 Advanced Thread Synchronization 371 The Condition Variable Model and Safety Properties 372 Using SignalObjectAndWait 378 Example: A Threshold Barrier Object 380 A Queue Object 384 Example: Using Queues in a Multistage Pipeline 388 Windows NT6 Condition Variables 398 Asynchronous Procedure Calls 402 Queuing Asynchronous Procedure Calls 403 Alertable Wait States 404 Safe Thread Cancellation 407 Pthreads for Application Portability 408 Thread Stacks and the Number of Threads 408 Hints for Designing, Debugging, and Testing 408 Beyond the Windows API 411 Summary 411 Exercises 412 CHAPTER 11 Interprocess Communication 415 Anonymous Pipes 416 Example: I/O Redirection Using an Anonymous Pipe 416 Named Pipes 420 Named Pipe Transaction Functions 426 Example: A Client/Server Command Line Processor 429 Comments on the Client/Server Command Line Processor 435 Mailslots 437 Pipe and Mailslot Creation, Connection, and Naming 441 Example: A Server That Clients Can Locate 442 Summary 444 Exercises 444 CHAPTER 12 Network Programming with Windows Sockets 447 Windows Sockets 448 Socket Server Functions 450 Socket Client Functions 455 Comparing Named Pipes and Sockets 457 Example: A Socket Message Receive Function 458 Example: A Socket-Based Client 459 Example: A Socket-Based Server with New Features 462 In-Process Servers 470 Line-Oriented Messages, DLL Entry Points, and TLS 472 Example: A Thread-Safe DLL for Socket Messages 473 Example: An Alternative Thread-Safe DLL Strategy 478 Datagrams 481 Berkeley Sockets versus Windows Sockets 483 Overlapped I/O with Windows Sockets 483 Windows Sockets Additional Features 484 Summary 484 Exercises 485 CHAPTER 13 Windows Services 489 Writing Windows Services—Overview 490 The main( ) Function 490 ServiceMain( ) Functions 491 The Service Control Handler 496 Event Logging 497 Example: A Service “Wrapper” 497 Managing Windows Services 503 Summary: Service Operation and Management 507 Example: A Service Control Shell 508 Sharing Kernel Objects with a Service 512 Notes on Debugging a Service 513 Summary 514 Exercises 514 CHAPTER 14 Asynchronous Input/Output and Completion Ports 517 Overview of Windows Asynchronous I/O 518 Overlapped I/O 519 Example: Synchronizing on a File Handle 523 Example: File Conversion with Overlapped I/O and Multiple Buffers 523 Extended I/O with Completion Routines 528 Example: File Conversion with Extended I/O 532 Asynchronous I/O with Threads 536 Waitable Timers 537 Example: Using a Waitable Timer 539 I/O Completion Ports 541 Example: A Server Using I/O Completion Ports 545 Summary 552 Exercises 553 CHAPTER 15 Securing Windows Objects 555 Security Attributes 555 Security Overview: The Security Descriptor 556 Security Descriptor Control Flags 559 Security Identifiers 559 Managing ACLs 561 Example: UNIX-Style Permission for NTFS Files 563 Example: Initializing Security Attributes 567 Reading and Changing Security Descriptors 571 Example: Reading File Permissions 573 Example: Changing File Permissions 574 Securing Kernel and Communication Objects 575 Example: Securing a Process and Its Threads 577 Overview of Additional Security Features 578 Summary 580 Exercises 580 APPENDIX A: Using the Sample Programs 583 Examples File Organization 584 APPENDIX B: Source Code Portability: Windows, UNIX, and Linux 585 Source Code Portability Strategies 586 Windows Services for UNIX 586 Source Code Portability for Windows Functionality 587 Chapters 2 and 3: File and Directory Management 592 Chapter 4: Exception Handling 597 Chapter 5: Memory Management, Memory-Mapped Files, and DLLs 598 Chapter 6: Process Management 599 Chapter 7: Threads and Scheduling 601 Chapters 8–10: Thread Synchronization 603 Chapter 11: Interprocess Communication 605 Chapter 14: Asynchronous I/O 607 Chapter 15: Securing Windows Objects 608 APPENDIX C: Performance Results 611 Test Configurations 611 Performance Measurements 613 Running the Tests 627 Bibliography 629 Index 633 A 633 B 633 C 633 D 635 E 635 F 636 G 636 H 637 I 638 J 638 K 638 L 638 M 639 N 639 O 639 P 640 Q 640 R 641 S 641 T 643 U 644 V 644 W 645 The Definitive Guide to Windows API Programming, Fully Updated for Windows 7, Windows Server 2008, and Windows Vista Windows System Programming, Fourth Edition, now contains extensive new coverage of 64-bit programming, parallelism, multicore systems, and many other crucial topics. Johnson Hart's robust code examples have been updated and streamlined throughout. They have been debugged and tested in both 32-bit and 64-bit versions, on single and multiprocessor systems, and under Windows 7, Vista, Server 2008, and Windows XP. To clarify program operation, sample programs are now illustrated with dozens of screenshots. Hart systematically covers Windows externals at the API level, presenting practical coverage of all the services Windows programmers need, and emphasizing how Windows functions actually behave and interact in real-world applications. Hart begins with features used in single-process applications and gradually progresses to more sophisticated functions and multithreaded environments. Topics covered include file systems, memory management, exceptions, processes, threads, synchronization, interprocess communication, Windows services, and security. New coverage in this edition includes Leveraging parallelism and maximizing performance in multicore systems Promoting source code portability and application interoperability across Windows, Linux, and UNIX Using 64-bit address spaces and ensuring 64-bit/32-bit portability Improving performance and scalability using threads, thread pools, and completion ports Techniques to improve program reliability and performance in all systems Windows performance-enhancing API features available starting with Windows Vista, such as slim reader/writer locks and condition variables A companion Web site, jmhartsoftware.com, contains all sample code, Visual Studio projects, additional examples, errata, reader comments, and Windows commentary and discussion. The Definitive Guide To Programming With The Windows Api - Now Updated For Microsoft's Latest Apis And Best Practices • •includes Extensive New Coverage Of Win64, Parallelism, Multicore System Performance, Source Code Portability, .net Coexistence, Security, Benchmarking, And Much More. •updated, Streamlined Code Examples Reflect Today's Most Effective Windows Programming Techniques. •the Perfect Practical Complement To Mark Russinovich's Windows Internals Windows System Programming, 4/e Is The Definitive Developer's Guide To Making The Most Of Of The Core Windows Api, Including Those Introduced With Windows Vista, Windows Server 2008, And Beyond. Thoroughly Updated To Reflect Microsoft's New Apis, This Book Focuses On Essential Core System Services -- File System, Memory, Processes And Threads, Synchronization, Communication, And Security -- Rather Than The More Commonly Featured Graphical User Interface Functions. Beginning With An Examination Of The Features Required In A Single-process Application, The Text Gradually Progresses To Increasingly Sophisticated Functions And Multithreaded Environments. Each Chapter Contains Realistic Examples, And This Edition's Code Samples Have Been Updated And Streamlined To Reflect Today's Best Practices For Windows Development And 64-bit Code Portability. This Edition's Extensive New Coverage Includes: ' An All-new Chapter On Parallelism And Performance In Multicore Systems ' Detailed New Coverage Of Source Code Portability Across Windows, Linux, And Unix ' New Coverage Of .net And Managed Code Impact And Co-existence ' When, Why, And How To Use The Windows Api Vs. .net ' More Coverage Of Security, Benchmarking, And Other Key Topics. Many Readers Have Noted That Hart's Book Perfectly Complements Mark Russinovich's Well-known Windows Internals. Hart Shows Us How To Make The Most Of The Features That Russinovich Describes.

قیمت نهایی

۴۰٬۰۰۰ تومان