O'Reilly logo

Professional ASP.NET MVC 4 by Scott Hanselman, K. Scott Allen, Brad Wilson, Phil Haack, Jon Galloway

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

Modeling the Music Store

Imagine you are building the ASP.NET MVC Music Store from scratch. You start, as with all great applications, by using the File &cmdarr, New Project menu command in Visual Studio. Once you give the project a name, Visual Studio will open the dialog you see in Figure 4.1, and you can tell Visual Studio you want to work with the Internet Application project template.

The Internet Application project template gives you everything you need to get started (see Figure 4.2): a basic layout view, a default homepage with a link for a customer to log in, an initial style sheet, and a relatively empty Models folder. All you find inside the Models folder is an AccountModels.cs file with some view-specific model classes for account management (the classes are specific to the views for registering, logging in, and changing a password).

The Models folder is nearly empty because the project template doesn't know what domain you are working in and it doesn't know what problem you are trying to solve.

At this point, you might not know what problem you are trying to solve, either! You might need to talk to customers and business owners, and do some initial prototyping or test-drivendevelopment to start fleshing out a design. The ASP.NET MVC framework doesn't dictate your process or methodologies.

Eventually, you might decide the first step in building a music ...

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