TypeDescriptor.GetClassName メソッド
定義
重要
一部の情報は、リリース前に大きく変更される可能性があるプレリリースされた製品に関するものです。 Microsoft は、ここに記載されている情報について、明示または黙示を問わず、一切保証しません。
指定したコンポーネントのクラス名を返します。
オーバーロード
| GetClassName(Object) |
既定の型記述子を使用して、指定されたコンポーネントのクラスの名前を返します。 |
| GetClassName(Type) |
指定した型のクラス名を返します。 |
| GetClassName(Object, Boolean) |
カスタムの型記述子を使用して、指定されたコンポーネントのクラスの名前を返します。 |
GetClassName(Object)
既定の型記述子を使用して、指定されたコンポーネントのクラスの名前を返します。
public:
static System::String ^ GetClassName(System::Object ^ component);
public static string GetClassName (object component);
public static string? GetClassName (object component);
static member GetClassName : obj -> string
Public Shared Function GetClassName (component As Object) As String
パラメーター
戻り値
指定したコンポーネントのクラス名を含む String。
例外
component が nullです。
注釈
通常、このメソッドはパラメーター型の完全な Type 名前を component 返します。 たとえば、ボタンのクラス名は "System.Windows" です。Forms。ボタン"。 が を実装しているICustomTypeDescriptor場合componentは、代替名を返すことができます。
このメソッドは、 の 2 番目のパラメーターfalseを持つオーバーロードされたGetClassName(Object, Boolean)メソッドと同じです。
こちらもご覧ください
- GetClassName()
- GetComponentName
- GetFullComponentName(Object)
- CreateInstance(IServiceProvider, Type, Type[], Object[])
- GetReflectionType
適用対象
GetClassName(Type)
指定した型のクラス名を返します。
public:
static System::String ^ GetClassName(Type ^ componentType);
public static string GetClassName (Type componentType);
public static string? GetClassName (Type componentType);
static member GetClassName : Type -> string
Public Shared Function GetClassName (componentType As Type) As String
パラメーター
戻り値
指定したコンポーネント型のクラス名を含む String を返します。
例外
componentType が nullです。
注釈
このメソッドは、指定した型のキャッシュされたカスタム型記述子を使用して、関連付けられているクラス名を検出します。
こちらもご覧ください
- GetClassName()
- GetComponentName
- GetFullComponentName(Object)
- CreateInstance(IServiceProvider, Type, Type[], Object[])
- GetReflectionType
適用対象
GetClassName(Object, Boolean)
カスタムの型記述子を使用して、指定されたコンポーネントのクラスの名前を返します。
public:
static System::String ^ GetClassName(System::Object ^ component, bool noCustomTypeDesc);
public static string GetClassName (object component, bool noCustomTypeDesc);
public static string? GetClassName (object component, bool noCustomTypeDesc);
static member GetClassName : obj * bool -> string
Public Shared Function GetClassName (component As Object, noCustomTypeDesc As Boolean) As String
パラメーター
- noCustomTypeDesc
- Boolean
カスタム型の説明情報を検討しない場合は true。それ以外の場合は false。
戻り値
指定したコンポーネントのクラス名を含む String。
例外
component が nullです。
component はプロセス間リモート オブジェクトです。
注釈
通常、このメソッドはパラメーター型の完全な Type 名前を component 返します。 たとえば、ボタンのクラス名は "System.Windows" です。Forms。ボタン"。 パラメーターが component を実装している ICustomTypeDescriptor場合は、代替名を返すことができます。
こちらもご覧ください
- GetClassName()
- ICustomTypeDescriptor
- GetComponentName
- GetFullComponentName(Object)
- CreateInstance(IServiceProvider, Type, Type[], Object[])
- GetReflectionType