C# Class WebStreams.Server.GenericMethodReflectionHelper

Reflection helper for generic methods.
显示文件 Open project: WebStreams/WebStreams.Server

Public Methods

Method Description
GenericMethodParametersMatch ( this method, Type parameters, Type typeParameters ) : bool

Returns if the provided parameters match the parameters for method; otherwise returns .

GetGenericMethod ( this type, string name, Type parameters, Type typeParameters ) : MethodInfo

Returns the generic method on type matching the provided parameters.

IsNumericType ( this type ) : bool

Returns a value indicating whether or not this is a numeric type.

ShouldUseStaticTryParseMthod ( this type ) : bool

Returns a value indicating whether or not deserialization should use a static TryParse method on the provided type.

Method Details

GenericMethodParametersMatch() public static method

Returns if the provided parameters match the parameters for method; otherwise returns .
public static GenericMethodParametersMatch ( this method, Type parameters, Type typeParameters ) : bool
method this /// The method. ///
parameters System.Type /// The parameters. ///
typeParameters System.Type /// The type parameters linking and . ///
return bool

GetGenericMethod() public static method

Returns the generic method on type matching the provided parameters.
public static GetGenericMethod ( this type, string name, Type parameters, Type typeParameters ) : MethodInfo
type this /// The type. ///
name string /// The name of the method. ///
parameters System.Type /// The parameters. ///
typeParameters System.Type /// The type parameters. ///
return System.Reflection.MethodInfo

IsNumericType() public static method

Returns a value indicating whether or not this is a numeric type.
public static IsNumericType ( this type ) : bool
type this /// The type. ///
return bool

ShouldUseStaticTryParseMthod() public static method

Returns a value indicating whether or not deserialization should use a static TryParse method on the provided type.
public static ShouldUseStaticTryParseMthod ( this type ) : bool
type this The type.
return bool