O'Reilly logo

Visual Basic 2010 Unleashed by Alessandro Del Sole

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

Adding the Domain Service Class

To make the data model consumable from clients, you need to implement your business logic. In WCF RIA Services-based applications, this is accomplished by implementing a Domain Service Class. Such kinds of classes inherit from LinqToEntitiesDomainService(Of T) and expose queries and methods for performing CRUD (Create/Read/Update/Delete) operations and can contain other custom logic. To add one, right-click the Services folder and select Add New Item. In the Add New Item dialog, select the Domain Service Class template and name it OrdersDomainService.vb. The goal is to provide logic for accessing the Orders entity set (see Figure 39.11).

Figure 39.11 The item template for adding a domain service class.

At this ...

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