Chapter 3. Component Programming Overview


Components are the building blocks of software applications. A component encapsulates state and execution logic and can be reused in different applications. Components make applications modular, easier to develop, and easier to maintain. The .NET Framework class library contains a large number of components that you can readily use in your applications. In addition, the .NET Framework enables you to write components that can interact seamlessly with other .NET components. In this book, we will develop several kinds of .NET components , including ASP.NET server controls, XML Web services, and HTTP handlers.

In this chapter, we will discuss the main characteristics of .NET components and describe the common constructs that you will encounter when developing your own components: properties, methods , events, and metadata attributes. Unless you are already proficient in using these constructs in managed code, we encourage you to read this chapter to familiarize yourself with the design patterns for these constructs. However, if this chapter feels as though it contains a lot of terminology and guidelines, you can browse through it and return to this chapter for a more detailed look at these programming constructs after you start using them.

The components that you develop should be consistent with the components in the .NET Framework, especially if you plan to distribute them in the form of a class library. The white paper on MSDN entitled ".NET Framework Design Guidelines ”Writing Class Libraries for the .NET Framework," contains the recommendations of the .NET Framework team. You can also use a tool named FxCop to check your components for compliance with the .NET Framework design guidelines. The Introduction of this book contains a brief description of FxCop and provides the location from which you can download this tool.



Developing Microsoft ASP. NET Server Controls and Components
Developing Microsoft ASP.NET Server Controls and Components (Pro-Developer)
ISBN: 0735615829
EAN: 2147483647
Year: 2005
Pages: 183

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net