دسترسی نامحدود
برای کاربرانی که ثبت نام کرده اند
برای ارتباط با ما می توانید از طریق شماره موبایل زیر از طریق تماس و پیامک با ما در ارتباط باشید
در صورت عدم پاسخ گویی از طریق پیامک با پشتیبان در ارتباط باشید
برای کاربرانی که ثبت نام کرده اند
درصورت عدم همخوانی توضیحات با کتاب
از ساعت 7 صبح تا 10 شب
دسته بندی: برنامه نویسی: زبان های برنامه نویسی ویرایش: نویسندگان: Nick Hodges سری: ناشر: Lean Publishing سال نشر: 0 تعداد صفحات: 118 زبان: English فرمت فایل : PDF (درصورت درخواست کاربر به PDF، EPUB یا AZW3 تبدیل می شود) حجم فایل: 2 مگابایت
در صورت تبدیل فایل کتاب Dependency Injection In Delphi به فرمت های PDF، EPUB، AZW3، MOBI و یا DJVU می توانید به پشتیبان اطلاع دهید تا فایل مورد نظر را تبدیل نمایند.
توجه داشته باشید کتاب تزریق وابستگی در دلفی نسخه زبان اصلی می باشد و کتاب ترجمه شده به فارسی نمی باشد. وبسایت اینترنشنال لایبرری ارائه دهنده کتاب های زبان اصلی می باشد و هیچ گونه کتاب ترجمه شده یا نوشته شده به فارسی را ارائه نمی دهد.
این کتاب Dependency Injection از A تا Z را پوشش میدهد. در آن با Constructor Injection، Property Injection و Method Injection آشنا خواهید شد. با روش درست و غلط استفاده از ظرف تزریق وابستگی آشنا خواهید شد
This book covers Dependency Injection from A to Z. In it you'll learn about Constructor Injection, Property Injection, and Method Injection. You'll learn about the right and wrong way to use the Dependency Injection Container
Preface . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . i Acknowledgements . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . iii What is Dependency Injection? . . . . . . . . . . . . . . . . . . . . . . . . 1 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1 So What Exactly is Dependency Injection? . . . . . . . . . . . . . . . . . 3 What to Do? . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5 Basic Principles to Follow . . . . . . . . . . . . . . . . . . . . . . . . . . 6 Conclusion . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8 Benefits of Dependency Injection . . . . . . . . . . . . . . . . . . . . . . . 10 A Closer Look at Coupling: Connascence . . . . . . . . . . . . . . . . . . . 12 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12 Connascence . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12 Qualities of Connascence . . . . . . . . . . . . . . . . . . . . . . . . . . 13 Levels of Connascence . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14 What to Do About Connascence? . . . . . . . . . . . . . . . . . . . . . . 23 Conclusion . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 24 Constructor Injection . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25 Constructor Injection . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25 Never Accept nil . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26 When to Use Constructor Injection . . . . . . . . . . . . . . . . . . . . . 28 Property Injection . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 29 Method Injection . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 33 The Dependency Injection Container . . . . . . . . . . . . . . . . . . . . . 38 What is a Dependency Injection Container? . . . . . . . . . . . . . . . . 38 What is the Container? . . . . . . . . . . . . . . . . . . . . . . . . . . . 39 Why is a Container Needed? . . . . . . . . . . . . . . . . . . . . . . . . 40 Where to Use the Container . . . . . . . . . . . . . . . . . . . . . . . . . 40 When to Use the Container . . . . . . . . . . . . . . . . . . . . . . . . . 41 Capabilities and Functionality . . . . . . . . . . . . . . . . . . . . . . . 42 Conclusion . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 48 A Step-by-Step Example . . . . . . . . . . . . . . . . . . . . . . . . . . . . 49 The Beginning . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 49 Introducing Constructor Injection . . . . . . . . . . . . . . . . . . . . . 51 Coding to an Interface . . . . . . . . . . . . . . . . . . . . . . . . . . . . 52 Enter the Container . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 56 Conclusion . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 60 Advanced Container Use . . . . . . . . . . . . . . . . . . . . . . . . . . . . 61 Multiple Implementations at Runtime . . . . . . . . . . . . . . . . . . . 61 Lazy Initialization . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 64 Registering Factories . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 69 Registering Primitive Parameters . . . . . . . . . . . . . . . . . . . . . . 73 Attributes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 75 Conclusion . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 79 Dependency Injection Anti-Patterns . . . . . . . . . . . . . . . . . . . . . 80 Service Locator . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 80 Field Injection . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 82 Constructor Over-Injection . . . . . . . . . . . . . . . . . . . . . . . . . 85 VCL Components in the Container . . . . . . . . . . . . . . . . . . . . . 88 Multiple Constructors . . . . . . . . . . . . . . . . . . . . . . . . . . . . 89 Mixing the Container in with Your Code . . . . . . . . . . . . . . . . . . 89 Conclusion . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 90 A Simple, Useful, and Complete Example . . . . . . . . . . . . . . . . . . . 91 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 91 Interfaces . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 91 The File Displayer . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 93 Building Displayers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 96 Tying It All Together . . . . . . . . . . . . . . . . . . . . . . . . . . . . 98 Connecting to the User Interface . . . . . . . . . . . . . . . . . . . . . . 103 Ways to Improve This Application . . . . . . . . . . . . . . . . . . . . . 106 Conclusions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 107 Final Thoughts . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 109