Code Only Mapping - Overview
This article is relevant to entity models that utilize the deprecated Visual Studio integration of Telerik Data Access. The current documentation of the Data Access framework is available here.
The Telerik Data Access Visual Designer is designed to help you build Telerik Data Access applications. With the Visual Designer you can create a domain model from an existing database and then graphically visualize and edit your domain model. Or, you can graphically create a domain model first, and then generate a database that supports your model. In either case, you can automatically update your model when the underlying database changes and automatically generate object-layer code for your application.
However, many developers view their code as their model. Ideally these developers just want to write some class and without ever touching a designer or a piece of XML to be able to use those classes with Telerik Data Access. Basically they want to write "Code Only". Fortunately, Telerik Data Access provides a Fluent Mapping API, which is perfect for these scenarios.
This section contains the following topics that discuss the Fluent Mapping API:
- Getting Started - demonstrates how to create a Fluent Mapping project by using Telerik Data Access, and then how to map the model using the default mapping functionality of the Fluent Mapping API. Also shows how to create a custom context class that provides strongly typed IQueryable end points and how to write sample code that uses the context.
- Mapping CLR Types, Properties and Associations - demonstrates how to map CLR types, properties and associations.
- Default Mapping - demonstrates how to use the default mapping functionality.
- Modeling Inheritance - demonstrates how to model inheritance by using the Telerik Data Access Fluent Mapping API.
- Artificial Types - demonstrates the Artificial Types/Properties feature of the Telerik Data Access Fluent Mapping API.
- Extending Domain Models Using Fluent Mapping - demonstrates how to extend existing domain models with new CLR classes or artificial types.
- Merging MetadataSources - demonstrates how to merge multiple metadata sources and how to control reference resolutions.