HostProtectionAttribute.ExternalProcessMgmt プロパティとは? わかりやすく解説

Weblio 辞書 > コンピュータ > .NET Framework クラス ライブラリ リファレンス > HostProtectionAttribute.ExternalProcessMgmt プロパティの意味・解説 

HostProtectionAttribute.ExternalProcessMgmt プロパティ

メモ : このプロパティは、.NET Framework version 2.0新しく追加されたものです。

外部プロセス管理公開されているかどうかを示す値を取得または設定します

名前空間: System.Security.Permissions
アセンブリ: mscorlib (mscorlib.dll 内)
構文構文

Public Property ExternalProcessMgmt As
 Boolean
Dim instance As HostProtectionAttribute
Dim value As Boolean

value = instance.ExternalProcessMgmt

instance.ExternalProcessMgmt = value
public bool ExternalProcessMgmt { get;
 set; }
public:
property bool ExternalProcessMgmt {
    bool get ();
    void set (bool 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 );
   }

};


プラットフォームプラットフォーム
バージョン情報バージョン情報
参照参照
関連項目
HostProtectionAttribute クラス
HostProtectionAttribute メンバ
System.Security.Permissions 名前空間
ExternalProcessMgmt



英和和英テキスト翻訳>> Weblio翻訳
英語⇒日本語日本語⇒英語
  

辞書ショートカット

すべての辞書の索引

HostProtectionAttribute.ExternalProcessMgmt プロパティのお隣キーワード
検索ランキング

   

英語⇒日本語
日本語⇒英語
   



HostProtectionAttribute.ExternalProcessMgmt プロパティのページの著作権
Weblio 辞書 情報提供元は 参加元一覧 にて確認できます。

   
日本マイクロソフト株式会社日本マイクロソフト株式会社
© 2024 Microsoft.All rights reserved.

©2024 GRAS Group, Inc.RSS