Compartir a través de


CompilerServices.ITypeProvider Interface (F#)

Type providers implement this interface in order to be recognized by the compiler as an F# type provider. The implementation of this interface determines the public interface and behavior of the type provider. For more information, see Type Providers.

Namespace/Module Path: Microsoft.FSharp.Core.CompilerServices

Assembly: FSharp.Core (in FSharp.Core.dll)

type ITypeProvider =
 interface
  inherit IDisposable
  abstract this.ApplyStaticArguments : Type * string [] * obj [] -> Type
  abstract this.GetGeneratedAssemblyContents : System.Reflection.Assembly -> byte[] 
  abstract this.GetInvokerExpression : MethodBase * Quotations.Expr [] -> Quotations.Expr
  abstract this.GetNamespaces : unit -> IProvidedNamespace []
  abstract this.GetStaticParameters : Type -> ParameterInfo []
  abstract this.add_Invalidate : EventHandler -> unit
  abstract this.Invalidate : IEvent<EventHandler,EventArgs>
  abstract this.remove_Invalidate : EventHandler -> unit
 end

Instance Members

Member

Description

add_Invalidate : EventHandler -> unit

Add an event handler for the Invalidate event.

ApplyStaticArguments : Type * string [] * obj [] -> Type

Apply static arguments to a provided type that accepts static arguments.

GetInvokerExpression : MethodBase * Quotations.Expr [] -> Quotations.Expr

Called by the compiler to ask for an Expression tree to replace the given MethodBase with.

GetGeneratedAssemblyContents : System.Reflection.Assembly -> byte []

Get the physical contents of the given logical provided assembly.

GetNamespaces : unit -> IProvidedNamespace []

Namespace name that this type provider injects types into.

GetStaticParameters : Type -> ParameterInfo []

Get the static parameters for a provided type.

Invalidate : IEvent<EventHandler, EventArgs>

Triggered when an assumption changes that invalidates the resolutions so far reported by the provider.

remove_Invalidate : EventHandler -> unit

Remove an event handler for the Invalidate event.

Platforms

Windows 8, Windows 7, Windows Server 2012, Windows Server 2008 R2

Version Information

F# Core Library Versions

Supported in: 4.0Supported in: 4.0, Portable

See Also

Reference

Microsoft.FSharp.Core.CompilerServices Namespace (F#)