Accessor​Extensions Accessor​Extensions Class

Definition

Extension methods for IInfrastructure<T>.

These methods are typically used by database providers (and other extensions). They are generally not used in application code.

IInfrastructure<T> is used to hide properties that are not intended to be used in application code but can be used in extension methods written by database providers etc.

public static class AccessorExtensionsPublic Module AccessorExtensions
Inheritance
System.ObjectSystem.Object
AccessorExtensionsAccessorExtensions

Inherited Members

System.Object

System.Object.ToString()System.Object.ToString()
System.Object.Equals(System.Object)System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)System.Object.Equals(System.Object, System.Object)
System.Object.ReferenceEquals(System.Object, System.Object)System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.GetHashCode()System.Object.GetHashCode()
System.Object.GetType()System.Object.GetType()
System.Object.MemberwiseClone()System.Object.MemberwiseClone()

Methods

GetInfrastructure<T>(IInfrastructure<T>) GetInfrastructure(Of T)(IInfrastructure(Of T))

Gets the value from a property that is being hidden using IInfrastructure<T>.

This method is typically used by database providers (and other extensions). It is generally not used in application code.

IInfrastructure<T> is used to hide properties that are not intended to be used in application code but can be used in extension methods written by database providers etc.

public static T GetInfrastructure<T>(this IInfrastructure<T> accessor)<ExtensionAttribute>
Public Shared Function GetInfrastructure(Of T)(accessor As IInfrastructure(Of T)) As T
Type Parameters
T

The type of the property being hidden by IInfrastructure<T>.

Parameters
accessor
IInfrastructure<T> IInfrastructure(Of T)

The object that exposes the property.

Returns
T T

The object assigned to the property.

GetService<TService>(IInfrastructure<IServiceProvider>) GetService(Of TService)(IInfrastructure(Of IServiceProvider))

Resolves a service from the System.IServiceProvider exposed from a type that implements IInfrastructure<T>.

This method is typically used by database providers (and other extensions). It is generally not used in application code.

IInfrastructure<T> is used to hide properties that are not intended to be used in application code but can be used in extension methods written by database providers etc.

public static TService GetService<TService>(this IInfrastructure<IServiceProvider> accessor)<ExtensionAttribute>
Public Shared Function GetService(Of TService)(accessor As IInfrastructure(Of IServiceProvider)) As TService
Type Parameters
TService

The type of service to be resolved.

Parameters
accessor
IInfrastructure<System.IServiceProvider> IInfrastructure(Of System.IServiceProvider)

The object exposing the service provider.

Returns
TService TService

The requested service.