IDataServiceStreamProvider.ResolveType Method

Returns a namespace-qualified type name that represents the type that the data service runtime must create for the media link entry that is associated with the data stream for the media resource that is being inserted.

Namespace:  System.Data.Services.Providers
Assembly:  Microsoft.Data.Services (in Microsoft.Data.Services.dll)

Syntax

'Declaration
Function ResolveType ( _
    entitySetName As String, _
    operationContext As DataServiceOperationContext _
) As String
'Usage
Dim instance As IDataServiceStreamProvider 
Dim entitySetName As String 
Dim operationContext As DataServiceOperationContext 
Dim returnValue As String 

returnValue = instance.ResolveType(entitySetName, _
    operationContext)
string ResolveType(
    string entitySetName,
    DataServiceOperationContext operationContext
)
String^ ResolveType(
    String^ entitySetName, 
    DataServiceOperationContext^ operationContext
)
abstract ResolveType : 
        entitySetName:string * 
        operationContext:DataServiceOperationContext -> string
function ResolveType(
    entitySetName : String, 
    operationContext : DataServiceOperationContext
) : String

Parameters

  • entitySetName
    Type: System.String
    Fully-qualified entity set name.

Return Value

Type: System.String
A namespace-qualified type name.

Remarks

The ResolveType method is called by the data service when a new entity that is a media link entry is being created together with its media resource. An implementer of this method must inspect the request headers in operationContext and return the namespace qualified type name that represents the type that the data service runtime must instantiate to create the media link entry that is associated with the new media resource. The string that represents this type name is passed to the CreateResource method to create the media link entry.

When you implement the GetWriteStream method, you should raise the following exceptions as indicated:

Exception type

Condition

ArgumentNullException

When operationContext is nulla null reference (Nothing in Visual Basic).

DataServiceException

When an entity type name cannot be resolved based on the operationContext.

See Also

Reference

IDataServiceStreamProvider Interface

System.Data.Services.Providers Namespace