C# Class ReflectionMagic.PrivateReflectionUsingDynamicExtensions

Afficher le fichier Open project: davidebbo/ReflectionMagic

Méthodes publiques

Méthode Description
AsDynamic ( this o ) : dynamic

Wraps the specified object in a dynamic object that allows access to private members.

Does not wrap null, string, primitive types, and already wrapped objects.

AsDynamicType ( this type ) : dynamic

Wraps the specified type in a dynamic object which allows easy instantion through the PrivateReflectionDynamicObjectStatic.New method.

CreateDynamicInstance ( this assembly, string typeName ) : dynamic

Tries to instantiate the type with the specified type name from the specified assembly instance using the specified constructor arguments.

GetDynamicType ( this assembly, string typeName ) : dynamic

Gets the type with the specified name from the specified assembly instance, and returns it as a dynamic object. See also AsDynamicType.

Method Details

AsDynamic() public static méthode

Wraps the specified object in a dynamic object that allows access to private members.
Does not wrap null, string, primitive types, and already wrapped objects.
public static AsDynamic ( this o ) : dynamic
o this The object to wrap
Résultat dynamic

AsDynamicType() public static méthode

Wraps the specified type in a dynamic object which allows easy instantion through the PrivateReflectionDynamicObjectStatic.New method.
public static AsDynamicType ( this type ) : dynamic
type this The type to wrap.
Résultat dynamic

CreateDynamicInstance() public static méthode

Tries to instantiate the type with the specified type name from the specified assembly instance using the specified constructor arguments.
Thrown when no suitable constructor can be found.
public static CreateDynamicInstance ( this assembly, string typeName ) : dynamic
assembly this The assembly instance to search.
typeName string The full type name.
Résultat dynamic

GetDynamicType() public static méthode

Gets the type with the specified name from the specified assembly instance, and returns it as a dynamic object. See also AsDynamicType.
public static GetDynamicType ( this assembly, string typeName ) : dynamic
assembly this The assembly instance to search for the type.
typeName string The type name.
Résultat dynamic