RuntimeReflectionExtensions.GetRuntimeField(Type, String) Metodo

Definizione

Recupera un oggetto che rappresenta un campo specificato.

public:
[System::Runtime::CompilerServices::Extension]
 static System::Reflection::FieldInfo ^ GetRuntimeField(Type ^ type, System::String ^ name);
public static System.Reflection.FieldInfo GetRuntimeField (this Type type, string name);
public static System.Reflection.FieldInfo? GetRuntimeField (this Type type, string name);
static member GetRuntimeField : Type * string -> System.Reflection.FieldInfo
<Extension()>
Public Function GetRuntimeField (type As Type, name As String) As FieldInfo

Parametri

type
Type

Tipo contenente il campo.

name
String

Nome del campo.

Restituisce

FieldInfo

Oggetto che rappresenta il campo specificato o null se il campo non viene trovato.

Eccezioni

type è null.

-oppure-

name è null.

Si applica a

Vedi anche