万本电子书0元读

万本电子书0元读

顶部广告

Entity Framework Tutorial - Second Edition电子书

售       价:¥

9人正在读 | 0人评论 9.8

作       者:Joydip Kanjilal

出  版  社:Packt Publishing

出版时间:2015-08-24

字       数:184.8万

所属分类: 进口书 > 外文原版书 > 电脑/网络

温馨提示:数字商品不支持退换货,不提供源文件,不支持导出打印

为你推荐

  • 读书简介
  • 目录
  • 累计评论(0条)
  • 读书简介
  • 目录
  • 累计评论(0条)
If you are a C# developer who wants to learn a new way of querying data and utilizing it in applications efficiently for data binding or other operations, then this book is for you. Basic knowledge of ADO.NET is assumed.
目录展开

Entity Framework Tutorial Second Edition

Table of Contents

Entity Framework Tutorial Second Edition

Credits

About the Author

About the Reviewers

www.PacktPub.com

Support files, eBooks, discount offers, and more

Why subscribe?

Free access for Packt account holders

Preface

What this book covers

What you need for this book

Who this book is for

Conventions

Reader feedback

Customer support

Downloading the example code

Errata

Piracy

Questions

1. Introducing the ADO.NET Entity Framework

What you should know

Looking back

What is the ADO.NET Entity Framework?

Is Entity Framework just another ORM?

A comparative analysis of Entity Framework and other ORM tools

LINQ to SQL and .dbml files

Entity Framework architectural components

The Entity Data Model

How is the EDM represented?

The Object Model (O-Space)

LINQ to Entities

Entity Client

Entity SQL

Avoiding complex joins

The Object Services Layer

Features and benefits at a glance

System requirements

Support for persistence ignorance

Support for T4 code generation

Support for lazy loading

Support for POCO change tracking

Better n-tier support with self-tracking entities

Support for code-first, model-first, and database-first approaches

Support for built-in functions and UDF support

Support for model-defined functions

Enum support

Spatial data types support

Other enhancements

Performance improvements in Entity Framework 6

New features in Entity Framework 7

Summary

2. Getting Started

Designing the UserAuthentication database

Creating the EDM

Creating the Entity Data Model using the ADO.NET Entity Data Model Designer

Creating Entity Data Model using the EdmGen tool

The DataSource controls

The ObjectDataSource control

The SqlDataSource control

The SiteMapDataSource control

The XMLDataSource control

The LinqDataSource control

The EntityDataSource control

Implementing our first application using the Entity Framework

Summary

3. Entities, Relationships, and the Entity Data Model

Entities, entity types, and relationships in the EDM

What is an entity?

Defining entity sets in the EDM

Extending the existing entity types to create derived entity types

Association sets, associations, containment, and multiplicity

What are entity containers?

Exploring the Security EDM

The Mapping Details window

The Entity Model browser

The EDM layers

The CSDL schema

The SSDL schema

The MSL schema

Entity classes

Summary

4. Working with Stored Procedures in the Entity Data Model

Creating a database using model-first development

Creating stored procedures

Mapping stored procedures to functions in the EDM

Mapping the create, update, and delete functions to entities in the EDM

Mapping stored procedures with no entity set

Executing stored procedures using the EDM

Mapping stored procedures that return custom entity types

Summary

5. Working with Entity Client and Entity SQL

An overview of the E-SQL language

From T-SQL to E-SQL

Why E-SQL when I already have LINQ to Entities?

Features of E-SQL

Operators in E-SQL

Arithmetic operators

Comparison operators

Logical operators

Reference operators

Type operators

Set operators

Operator precedence

Expressions in E-SQL

Query expressions in E-SQL

Identifiers, variables, parameters, and types in E-SQL

Row

Collections

Reference

Canonical functions in E-SQL

Mathematical functions

Aggregate functions

String functions

Bitwise functions

Date and time functions

Data paging using E-SQL

Working with the ADO.NET Entity Client

Let's get into action

Building the connection string

Creating an entity connection

Opening the connection

Executing queries using the entity command

Closing the connection

Other operations with E-SQL

Inserting a record using E-SQL

Inserting a record with a foreign key constraint

Retrieving native SQL from EntityCommand

Transaction management in E-SQL

Deferred, eager, and lazy loading

Summary

6. Working with LINQ to Entities

Introducing LINQ

Why LINQ?

Understanding the LINQ architecture

LINQ to XML

LINQ to SQL

LINQ to Objects

LINQ to Entities

Querying data using LINQ to Entities

LINQ to Entities and Entity Framework

Differences between LINQ to Entities and LINQ to SQL

Parallel LINQ

Operators in LINQ

Aggregation

Projections

Ordering

Quantifiers

Restriction

Conversion

Element

Set

Querying data using LINQ

Expressions in LINQ to Entities

Constant expressions

Comparison expressions

Initialization expressions

Null comparisons

Navigation properties

Immediate and deferred query execution

Retrieving entity data from the Security database

Summary

7. Working with the Object Services Layer

What are Object Services?

Features at a glance

The SecurityDbEntity's DbContext class

Querying data as in-memory objects

Using Entity Framework 7

Performing CRUD operations on objects

Attaching and detaching objects to and from ObjectContext

Serializing and deserializing entity instances

Change tracking and identity resolution using ObjectContext

Understanding the code-first, model-first, and database-first approaches to domain design

Using the code-first approach

Using the model-first approach

Using the database-first approach

Inheritance in Entity Framework

Table-per-Hierarchy

Table-per-Type

Table-per-Concrete Type

Implementing complex types in the EDM

State management, identity management, and relationship management

Reading objects from the Security database

Inserting objects from the Security database

Editing objects from the Security database

Deleting objects from the Security database

Summary

8. Working with WCF Data Services

Introducing WCF Data Services

How do WCF Data Services and Web Services differ?

What is Representational State Transfer (REST)?

Why use WCF Data Services?

The features at a glance

Exposing data as a service using WCF Data Services

Why do we need REST?

Resources in REST-based architecture

The REST architectural constraints

The client-server model

Stateless

Cacheable

Code on demand

The uniform interface

Resource management

REST attributes

WebServiceHost

WebHttpBinding

WebHttpBehavior

WebOperationContext

WebMessageFormat

The WebGet attribute

The WebInvoke attribute

UriTemplate

REST-based Web Services

What is the OData Protocol?

Working with WCF Data Services and Entity Framework

Working with OData Services using WCF and ASP.NET MVC Framework

Working with Protobuf WCF Services

Protocol Buffers

Creating Protobuf-net objects

Integrating Protobuf.NET with Visual Studio

Implementing the WCF Service

Specifying binding information

Summary

A. Advanced Concepts

REST and REST-based service frameworks

Ruby on Rails

Restlet

Django REST

The Flickr REST API

The Google API

Yahoo Social REST APIs

Exploring OData

HTTP methods, request, and response codes

Abbreviations

New features in Entity Framework 7

Suggested reading

Index

累计评论(0条) 0个书友正在讨论这本书 发表评论

发表评论

发表评论,分享你的想法吧!

买过这本书的人还买过

读了这本书的人还在读

回顶部