型名とアセンブリ名で指定したオブジェクトが、リモート アクティブ化クライアント型として登録されているかどうかを確認します。
Overloads Public Shared Function IsRemotelyActivatedClientType( _
ByVal typeName As String, _ ByVal assemblyName As String _) As ActivatedClientTypeEntry
[C#]
public static ActivatedClientTypeEntry IsRemotelyActivatedClientType(stringtypeName,stringassemblyName);
[C++]
public: static ActivatedClientTypeEntry* IsRemotelyActivatedClientType(String* typeName,String* assemblyName);
[JScript]
public static function IsRemotelyActivatedClientType(
typeName : String,assemblyName : String) : ActivatedClientTypeEntry;
パラメータ
- typeName
確認する対象のオブジェクトの型名。 - assemblyName
確認する対象のオブジェクトのアセンブリ名。
戻り値
指定したオブジェクト型に対応している ActivatedClientTypeEntry 。
例外
| 例外の種類 | 条件 |
|---|---|
| SecurityException | コールスタックの上位にある 1 つ以上の呼び出し元に、リモート処理の型とチャネルを構成するためのアクセス許可がありません。 |
使用例
Dim myAssembly As [Assembly] = [Assembly].GetAssembly(GetType(MyServerImpl))
Dim myName As AssemblyName = myAssembly.GetName()
' Check whether the 'MyServerImpl' type is registered as
' a remotely activated client type.
Dim myActivatedClientEntry As ActivatedClientTypeEntry = _
RemotingConfiguration.IsRemotelyActivatedClientType(GetType(MyServerImpl).FullName, _
myName.Name)
Console.WriteLine("The Object type : " + myActivatedClientEntry.ObjectType.ToString())
Console.WriteLine("The Application Url : " + myActivatedClientEntry.ApplicationUrl)
[C#]
Assembly myAssembly = Assembly.GetAssembly(typeof(MyServerImpl));
AssemblyName myName = myAssembly.GetName();
// Check whether the 'MyServerImpl' type is registered as
// a remotely activated client type.
ActivatedClientTypeEntry myActivatedClientEntry =
RemotingConfiguration.IsRemotelyActivatedClientType(
(typeof(MyServerImpl)).FullName,myName.Name);
Console.WriteLine("The Object type : "
+myActivatedClientEntry.ObjectType);
Console.WriteLine("The Application Url : "
+myActivatedClientEntry.ApplicationUrl);
[C++]
Assembly* myAssembly = Assembly::GetAssembly(__typeof(MyServerImpl));
AssemblyName* myName = myAssembly->GetName();
// Check whether the 'MyServerImpl' type is registered as
// a remotely activated client type.
ActivatedClientTypeEntry* myActivatedClientEntry =
RemotingConfiguration::IsRemotelyActivatedClientType((__typeof(MyServerImpl))->FullName, myName->Name);
Console::WriteLine(S"The Object type : {0}", myActivatedClientEntry->ObjectType);
Console::WriteLine(S"The Application Url : {0}", myActivatedClientEntry->ApplicationUrl);
[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 セキュリティ:
- SecurityPermission (リモート処理インフラストラクチャを構成するために必要なアクセス許可)要求値: SecurityAction.Demand; アクセス許可値: SecurityPermissionFlag.RemotingConfiguration
参照
RemotingConfiguration クラス | RemotingConfiguration メンバ | System.Runtime.Remoting 名前空間 | RemotingConfiguration.IsRemotelyActivatedClientType オーバーロードの一覧 | クライアント アクティベーション