﻿<?xml version="1.0" encoding="utf-8"?><Type Name="HostProtectionException" FullName="System.Security.HostProtectionException"><TypeSignature Language="C#" Value="public class HostProtectionException : SystemException" /><TypeSignature Language="ILAsm" Value=".class public auto ansi serializable beforefieldinit HostProtectionException extends System.SystemException" /><AssemblyInfo><AssemblyName>mscorlib</AssemblyName><AssemblyVersion>2.0.0.0</AssemblyVersion><AssemblyVersion>4.0.0.0</AssemblyVersion></AssemblyInfo><Base><BaseTypeName>System.SystemException</BaseTypeName></Base><Interfaces /><Attributes><Attribute><AttributeName>System.Runtime.InteropServices.ComVisible(true)</AttributeName></Attribute></Attributes><Docs><since version=".NET 2.0" /><remarks><attribution license="cc4" from="Microsoft" modified="false" /><para>A <see cref="T:System.Security.Permissions.HostProtectionAttribute" /> attribute is used to determine if a type or member can be loaded, based on the host’s protection preferences established when the common language runtime is started. If a type or member with an active <see cref="T:System.Security.Permissions.HostProtectionAttribute" /> is called, a link demand occurs for that protection attribute. If the caller does not meet the demand for host protection, a <see cref="T:System.Security.HostProtectionException" /> is thrown. </para><block subset="none" type="note"><para>A <see cref="T:System.Security.Permissions.HostProtectionAttribute" /> is not a permission, even though it is the target of a link demand. Because a <see cref="T:System.Security.HostProtectionException" /> is thrown for a link demand, it cannot be handled, and therefore it cannot be trapped and processed in code.</para></block></remarks><summary><attribution license="cc4" from="Microsoft" modified="false" /><para>The exception that is thrown when a denied host resource is detected.</para></summary></Docs><Members><Member MemberName=".ctor"><MemberSignature Language="C#" Value="public HostProtectionException ();" /><MemberSignature Language="ILAsm" Value=".method public hidebysig specialname rtspecialname instance void .ctor() cil managed" /><MemberType>Constructor</MemberType><AssemblyInfo><AssemblyVersion>2.0.0.0</AssemblyVersion><AssemblyVersion>4.0.0.0</AssemblyVersion></AssemblyInfo><Parameters /><Docs><since version=".NET 2.0" /><remarks><attribution license="cc4" from="Microsoft" modified="false" /><para>The following table shows the initial property values for an instance of the <see cref="T:System.Security.HostProtectionException" /> class.</para><list type="table"><listheader><item><term><para>Property </para></term><description><para>Value </para></description></item></listheader><item><term><para><see cref="P:System.Security.HostProtectionException.ProtectedResources" /></para></term><description><para><see cref="F:System.Security.Permissions.HostProtectionResource.None" /></para></description></item><item><term><para><see cref="P:System.Security.HostProtectionException.DemandedResources" /></para></term><description><para><see cref="F:System.Security.Permissions.HostProtectionResource.None" /></para></description></item></list></remarks><summary><attribution license="cc4" from="Microsoft" modified="false" /><para>Initializes a new instance of the <see cref="T:System.Security.HostProtectionException" /> class with default values. </para></summary></Docs></Member><Member MemberName=".ctor"><MemberSignature Language="C#" Value="public HostProtectionException (string message);" /><MemberSignature Language="ILAsm" Value=".method public hidebysig specialname rtspecialname instance void .ctor(string message) cil managed" /><MemberType>Constructor</MemberType><AssemblyInfo><AssemblyVersion>2.0.0.0</AssemblyVersion><AssemblyVersion>4.0.0.0</AssemblyVersion></AssemblyInfo><Parameters><Parameter Name="message" Type="System.String" /></Parameters><Docs><since version=".NET 2.0" /><remarks><attribution license="cc4" from="Microsoft" modified="false" /><para>The content of the <paramref name="message" /> parameter should be understandable to the user. The caller of this constructor is required to ensure that this string has been localized for the current system culture.</para></remarks><summary><attribution license="cc4" from="Microsoft" modified="false" /><para>Initializes a new instance of the <see cref="T:System.Security.HostProtectionException" /> class with a specified error message. </para></summary><param name="message"><attribution license="cc4" from="Microsoft" modified="false" />The message that describes the error.</param></Docs></Member><Member MemberName=".ctor"><MemberSignature Language="C#" Value="protected HostProtectionException (System.Runtime.Serialization.SerializationInfo info, System.Runtime.Serialization.StreamingContext context);" /><MemberSignature Language="ILAsm" Value=".method familyhidebysig specialname rtspecialname instance void .ctor(class System.Runtime.Serialization.SerializationInfo info, valuetype System.Runtime.Serialization.StreamingContext context) cil managed" /><MemberType>Constructor</MemberType><AssemblyInfo><AssemblyVersion>2.0.0.0</AssemblyVersion><AssemblyVersion>4.0.0.0</AssemblyVersion></AssemblyInfo><Parameters><Parameter Name="info" Type="System.Runtime.Serialization.SerializationInfo" /><Parameter Name="context" Type="System.Runtime.Serialization.StreamingContext" /></Parameters><Docs><since version=".NET 2.0" /><remarks><attribution license="cc4" from="Microsoft" modified="false" /><para>This constructor is called during deserialization to reconstruct the exception object transmitted over a stream. </para></remarks><summary><attribution license="cc4" from="Microsoft" modified="false" /><para>Initializes a new instance of the <see cref="T:System.Security.HostProtectionException" /> class using the provided serialization information and streaming context.</para></summary><param name="info"><attribution license="cc4" from="Microsoft" modified="false" />The object that holds the serialized object data.</param><param name="context"><attribution license="cc4" from="Microsoft" modified="false" />Contextual information about the source or destination.</param></Docs></Member><Member MemberName=".ctor"><MemberSignature Language="C#" Value="public HostProtectionException (string message, Exception e);" /><MemberSignature Language="ILAsm" Value=".method public hidebysig specialname rtspecialname instance void .ctor(string message, class System.Exception e) cil managed" /><MemberType>Constructor</MemberType><AssemblyInfo><AssemblyVersion>2.0.0.0</AssemblyVersion><AssemblyVersion>4.0.0.0</AssemblyVersion></AssemblyInfo><Parameters><Parameter Name="message" Type="System.String" /><Parameter Name="e" Type="System.Exception" /></Parameters><Docs><since version=".NET 2.0" /><remarks><attribution license="cc4" from="Microsoft" modified="false" /><para>An exception that is thrown as a direct result of a previous exception can include a reference to the previous exception in the <see cref="P:System.Exception.InnerException" /> property. The <see cref="P:System.Exception.InnerException" /> property returns the same value that is passed into the constructor, or null if the <see cref="P:System.Exception.InnerException" /> property does not supply the inner exception value to the constructor.</para></remarks><summary><attribution license="cc4" from="Microsoft" modified="false" /><para>Initializes a new instance of the <see cref="T:System.Security.HostProtectionException" /> class with a specified error message and a reference to the inner exception that is the cause of this exception. </para></summary><param name="message"><attribution license="cc4" from="Microsoft" modified="false" />The error message that explains the reason for the exception. </param><param name="e"><attribution license="cc4" from="Microsoft" modified="false" />The exception that is the cause of the current exception. If the <paramref name="innerException" /> parameter is not null, the current exception is raised in a catch block that handles the inner exception. </param></Docs></Member><Member MemberName=".ctor"><MemberSignature Language="C#" Value="public HostProtectionException (string message, System.Security.Permissions.HostProtectionResource protectedResources, System.Security.Permissions.HostProtectionResource demandedResources);" /><MemberSignature Language="ILAsm" Value=".method public hidebysig specialname rtspecialname instance void .ctor(string message, valuetype System.Security.Permissions.HostProtectionResource protectedResources, valuetype System.Security.Permissions.HostProtectionResource demandedResources) cil managed" /><MemberType>Constructor</MemberType><AssemblyInfo><AssemblyVersion>2.0.0.0</AssemblyVersion><AssemblyVersion>4.0.0.0</AssemblyVersion></AssemblyInfo><Parameters><Parameter Name="message" Type="System.String" /><Parameter Name="protectedResources" Type="System.Security.Permissions.HostProtectionResource" /><Parameter Name="demandedResources" Type="System.Security.Permissions.HostProtectionResource" /></Parameters><Docs><since version=".NET 2.0" /><remarks><attribution license="cc4" from="Microsoft" modified="false" /><para>The <paramref name="demandedResources" /> parameter specifies the demanded host protection categories that caused the exception to be thrown. For example, suppose that a method has a <see cref="T:System.Security.Permissions.HostProtectionAttribute" /> attribute that indicates that the method exposes shared state. When the method is called, the <see cref="T:System.Security.Permissions.HostProtectionAttribute" /> performs a link demand for shared state. If the host has set shared state as a prohibited category, then a <see cref="T:System.Security.HostProtectionException" /> is raised with a <paramref name="demandedResources" /> property value of <see cref="F:System.Security.Permissions.HostProtectionResource.SharedState" />.</para></remarks><summary><attribution license="cc4" from="Microsoft" modified="false" /><para>Initializes a new instance of the <see cref="T:System.Security.HostProtectionException" /> class with a specified error message, the protected host resources, and the host resources that caused the exception to be thrown.</para></summary><param name="message"><attribution license="cc4" from="Microsoft" modified="false" />The error message that explains the reason for the exception.</param><param name="protectedResources"><attribution license="cc4" from="Microsoft" modified="false" />A bitwise combination of the enumeration values that specify the host resources that are inaccessible to partially trusted code.</param><param name="demandedResources"><attribution license="cc4" from="Microsoft" modified="false" />A bitwise combination of the enumeration values that specify the demanded host resources.</param></Docs></Member><Member MemberName="DemandedResources"><MemberSignature Language="C#" Value="public System.Security.Permissions.HostProtectionResource DemandedResources { get; }" /><MemberSignature Language="ILAsm" Value=".property instance valuetype System.Security.Permissions.HostProtectionResource DemandedResources" /><MemberType>Property</MemberType><AssemblyInfo><AssemblyVersion>2.0.0.0</AssemblyVersion><AssemblyVersion>4.0.0.0</AssemblyVersion></AssemblyInfo><ReturnValue><ReturnType>System.Security.Permissions.HostProtectionResource</ReturnType></ReturnValue><Docs><value>To be added.</value><since version=".NET 2.0" /><remarks><attribution license="cc4" from="Microsoft" modified="false" /><para>This property returns the demanded host protection categories that caused the exception to be thrown. For example, suppose that a method has a <see cref="T:System.Security.Permissions.HostProtectionAttribute" /> attribute that indicates that the method exposes shared state. When the method is called, the <see cref="T:System.Security.Permissions.HostProtectionAttribute" /> performs a link demand for shared state. If the host has set shared state as a prohibited category, then a <see cref="T:System.Security.HostProtectionException" /> is raised, and the value of the <see cref="P:System.Security.HostProtectionException.DemandedResources" /> property is <see cref="F:System.Security.Permissions.HostProtectionResource.SharedState" />.</para></remarks><summary><attribution license="cc4" from="Microsoft" modified="false" /><para>Gets or sets the demanded host protection resources that caused the exception to be thrown.</para></summary></Docs></Member><Member MemberName="GetObjectData"><MemberSignature Language="C#" Value="public override void GetObjectData (System.Runtime.Serialization.SerializationInfo info, System.Runtime.Serialization.StreamingContext context);" /><MemberSignature Language="ILAsm" Value=".method public hidebysig virtual instance void GetObjectData(class System.Runtime.Serialization.SerializationInfo info, valuetype System.Runtime.Serialization.StreamingContext context) cil managed" /><MemberType>Method</MemberType><AssemblyInfo><AssemblyVersion>2.0.0.0</AssemblyVersion><AssemblyVersion>4.0.0.0</AssemblyVersion></AssemblyInfo><ReturnValue><ReturnType>System.Void</ReturnType></ReturnValue><Parameters><Parameter Name="info" Type="System.Runtime.Serialization.SerializationInfo" /><Parameter Name="context" Type="System.Runtime.Serialization.StreamingContext" /></Parameters><Docs><since version=".NET 2.0" /><remarks><attribution license="cc4" from="Microsoft" modified="false" /><para>The <see cref="M:System.Security.HostProtectionException.GetObjectData(System.Runtime.Serialization.SerializationInfo,System.Runtime.Serialization.StreamingContext)" /> method sets a <see cref="T:System.Runtime.Serialization.SerializationInfo" /> object with all the exception object data targeted for serialization. During deserialization, the exception is reconstructed from the <see cref="T:System.Runtime.Serialization.SerializationInfo" /> transmitted over the stream.</para></remarks><summary><attribution license="cc4" from="Microsoft" modified="false" /><para>Sets the specified <see cref="T:System.Runtime.Serialization.SerializationInfo" /> object with information about the host protection exception.</para></summary><param name="info"><attribution license="cc4" from="Microsoft" modified="false" />The serialized object data about the exception being thrown.</param><param name="context"><attribution license="cc4" from="Microsoft" modified="false" />The contextual information about the source or destination.</param></Docs></Member><Member MemberName="ProtectedResources"><MemberSignature Language="C#" Value="public System.Security.Permissions.HostProtectionResource ProtectedResources { get; }" /><MemberSignature Language="ILAsm" Value=".property instance valuetype System.Security.Permissions.HostProtectionResource ProtectedResources" /><MemberType>Property</MemberType><AssemblyInfo><AssemblyVersion>2.0.0.0</AssemblyVersion><AssemblyVersion>4.0.0.0</AssemblyVersion></AssemblyInfo><ReturnValue><ReturnType>System.Security.Permissions.HostProtectionResource</ReturnType></ReturnValue><Docs><value>To be added.</value><since version=".NET 2.0" /><remarks><attribution license="cc4" from="Microsoft" modified="false" /><para>This property identifies the host protection categories that the host has specified as being inaccessible to code that is not fully trusted.</para></remarks><summary><attribution license="cc4" from="Microsoft" modified="false" /><para>Gets or sets the host protection resources that are inaccessible to partially trusted code.</para></summary></Docs></Member><Member MemberName="ToString"><MemberSignature Language="C#" Value="public override string ToString ();" /><MemberSignature Language="ILAsm" Value=".method public hidebysig virtual instance string ToString() cil managed" /><MemberType>Method</MemberType><AssemblyInfo><AssemblyVersion>2.0.0.0</AssemblyVersion><AssemblyVersion>4.0.0.0</AssemblyVersion></AssemblyInfo><ReturnValue><ReturnType>System.String</ReturnType></ReturnValue><Parameters /><Docs><since version=".NET 2.0" /><remarks><attribution license="cc4" from="Microsoft" modified="false" /><para>The returned string is a textual representation of the exception.</para></remarks><summary><attribution license="cc4" from="Microsoft" modified="false" /><para>Returns a string representation of the current host protection exception.</para></summary><returns><attribution license="cc4" from="Microsoft" modified="false" /><para>A string representation of the current <see cref="T:System.Security.HostProtectionException" />.</para></returns></Docs></Member></Members></Type>