Share via


LinqToEntitiesDomainService<TContext>.CreateObjectContext Method

[WCF RIA Services Version 1 Service Pack 2 is compatible with either .NET framework 4 or .NET Framework 4.5, and with either Silverlight 4 or Silverlight 5.]

Creates and returns the ObjectContext instance that will be used by this provider.

Namespace:  System.ServiceModel.DomainServices.EntityFramework
Assembly:  System.ServiceModel.DomainServices.EntityFramework (in System.ServiceModel.DomainServices.EntityFramework.dll)

Syntax

'Declaration
Protected Overridable Function CreateObjectContext As TContext
'Usage
Dim returnValue As TContext

returnValue = Me.CreateObjectContext()
protected virtual TContext CreateObjectContext()
protected:
virtual TContext CreateObjectContext()
abstract CreateObjectContext : unit -> 'TContext 
override CreateObjectContext : unit -> 'TContext 
protected function CreateObjectContext() : TContext

Return Value

Type: TContext
A new ObjectContext instance.

See Also

Reference

LinqToEntitiesDomainService<TContext> Class

System.ServiceModel.DomainServices.EntityFramework Namespace