次の方法で共有


RemotingConfiguration.IsWellKnownClientType メソッド (Type)

指定したオブジェクト Type が既知のクライアント型として登録されているかどうかを確認します。

Overloads Public Shared Function IsWellKnownClientType( _
   ByVal svrType As Type _) As WellKnownClientTypeEntry
[C#]
public static WellKnownClientTypeEntry IsWellKnownClientType(TypesvrType);
[C++]
public: static WellKnownClientTypeEntry* IsWellKnownClientType(Type* svrType);
[JScript]
public static function IsWellKnownClientType(
   svrType : Type) : WellKnownClientTypeEntry;

パラメータ

  • svrType
    確認する対象のオブジェクト Type

戻り値

指定したオブジェクト型に対応している WellKnownClientTypeEntry

例外

例外の種類 条件
SecurityException コールスタックの上位にある 1 つ以上の呼び出し元に、リモート処理の型とチャネルを構成するためのアクセス許可がありません。

使用例

 
' Check whether the specified object type is registered as 
' well known client type or not.
Dim myWellKnownClientType As WellKnownClientTypeEntry = _ 
                   RemotingConfiguration.IsWellKnownClientType(GetType(MyServerImpl))
Console.WriteLine("The Object type is " + myWellKnownClientType.ObjectType.ToString())
Console.WriteLine("The Object Url is " + myWellKnownClientType.ObjectUrl)

[C#] 
// Check whether the specified object type is registered as 
// well known client type or not.
WellKnownClientTypeEntry myWellKnownClientType =
    RemotingConfiguration.IsWellKnownClientType(typeof(MyServerImpl));
Console.WriteLine("The Object type is "
                  +myWellKnownClientType.ObjectType);
Console.WriteLine("The Object Url is "
                  +myWellKnownClientType.ObjectUrl);

[C++] 
// Check whether the specified object type is registered as 
// well known client type or not.
WellKnownClientTypeEntry* myWellKnownClientType =
   RemotingConfiguration::IsWellKnownClientType(__typeof(MyServerImpl));
Console::WriteLine(S"The Object type is {0}", myWellKnownClientType->ObjectType);
Console::WriteLine(S"The Object Url is {0}", myWellKnownClientType->ObjectUrl);

[JScript] JScript のサンプルはありません。Visual Basic、C#、および C++ のサンプルを表示するには、このページの左上隅にある言語のフィルタ ボタン 言語のフィルタ をクリックします。

必要条件

プラットフォーム: Windows 98, Windows NT 4.0, Windows Millennium Edition, Windows 2000, Windows XP Home Edition, Windows XP Professional, Windows Server 2003 ファミリ

.NET Framework セキュリティ:

参照

RemotingConfiguration クラス | RemotingConfiguration メンバ | System.Runtime.Remoting 名前空間 | RemotingConfiguration.IsWellKnownClientType オーバーロードの一覧 | サーバー アクティベーション