HostProtectionAttribute.ExternalProcessMgmt プロパティ
メモ : このプロパティは、.NET Framework version 2.0 で新しく追加されたものです。
外部プロセス管理が公開されているかどうかを示す値を取得または設定します。
名前空間: System.Security.Permissions
アセンブリ: mscorlib (mscorlib.dll 内)
構文
Dim instance As HostProtectionAttribute Dim value As Boolean value = instance.ExternalProcessMgmt instance.ExternalProcessMgmt = value
/** @property */ public boolean get_ExternalProcessMgmt () /** @property */ public void set_ExternalProcessMgmt (boolean value)
public function get ExternalProcessMgmt () : boolean public function set ExternalProcessMgmt (value : boolean)
プロパティ値
外部プロセス管理が公開されている場合は true。それ以外の場合は false。既定値は false です。


ExternalProcessMgmt プロパティを持つ HostProtectionAttribute 属性を使用するコード例を次に示します。このコード例は、HostProtectionAttribute クラスのトピックで取り上げているコード例の一部分です。
' The following class is an example of code that exposes ' external process management. ' Add the LicenseProviderAttribute to the control. <LicenseProvider(GetType(LicFileLicenseProvider))> _ Public Class MyControl Inherits System.Windows.Forms.Control ' Create a new, null license. Private license As License = Nothing <HostProtectionAttribute(ExternalProcessMgmt := True)> _ Public Sub New() ' Determine if a valid license can be granted. Dim isValid As Boolean = LicenseManager.IsValid(GetType(MyControl)) Console.WriteLine(("The result of the IsValid method call is " & _ isValid.ToString())) End Sub 'New Protected Overrides Sub Dispose(ByVal disposing As Boolean) If disposing Then If Not (license Is Nothing) Then license.Dispose() license = Nothing End If End If End Sub 'Dispose End Class 'MyControl
// The following class is an example of code that exposes // external process management. // Add the LicenseProviderAttribute to the control. [LicenseProvider (typeof(LicFileLicenseProvider))] public class MyControl : System.Windows.Forms.Control { // Create a new, null license. private License license = null; [HostProtection (ExternalProcessMgmt = true)] public MyControl () { // Determine if a valid license can be granted. bool isValid = LicenseManager.IsValid (typeof(MyControl)); Console.WriteLine ("The result of the IsValid method call is " + isValid.ToString ()); } protected override void Dispose (bool disposing) { if (disposing) { if (license != null) { license.Dispose (); license = null; } } } }
// The following class is an example of code that exposes external process management. // Add the LicenseProviderAttribute to the control. [assembly:SecurityPermissionAttribute(SecurityAction::RequestMinimum,ControlAppDomain=true)]; [assembly:SecurityPermissionAttribute(SecurityAction::RequestMinimum,Execution=true)]; [LicenseProvider(LicFileLicenseProvider::typeid)] public ref class MyControl: public System::Windows::Forms::Control { private: // Create a new, null license. License^ license; public: [HostProtection(ExternalProcessMgmt=true)] MyControl() { license = nullptr; // Determine if a valid license can be granted. bool isValid = LicenseManager::IsValid( MyControl::typeid ); Console::WriteLine( "The result of the IsValid method call is {0}", isValid ); } };

Windows 98, Windows 2000 SP4, Windows Millennium Edition, Windows Server 2003, Windows XP Media Center Edition, Windows XP Professional x64 Edition, Windows XP SP2, Windows XP Starter Edition
開発プラットフォームの中には、.NET Framework によってサポートされていないバージョンがあります。サポートされているバージョンについては、「システム要件」を参照してください。


Weblioに収録されているすべての辞書からHostProtectionAttribute.ExternalProcessMgmt プロパティを検索する場合は、下記のリンクをクリックしてください。

- HostProtectionAttribute.ExternalProcessMgmt プロパティのページへのリンク