O'Reilly logo

Metaprogramming in .NET by Kevin Hazzard and Jason Bock

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Chapter 4. Generating code with the CodeDOM

This chapter covers

  • Understanding the CodeDOM
  • The code providers classes
  • Adding objects to a code graph
  • Metaprogramming with the CodeDOM

Web browsers have a Document Object Model (DOM) for creating windows and managing the navigation between pages. HTML has a DOM for describing the content and structure of those pages. JavaScript has a DOM for automating the others. These models are appropriately called DOMs because they’re technologies for the World Wide Web, which is a largely document-oriented system.

Given the range of roles that a DOM can fill, what do you think Microsoft’s CodeDOM does? It could be used to describe code. As you learned in chapters 1 and 2, .NET provides a rich metadata ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required