Files
2026-06-04 11:42:34 +02:00

155 lines
6.2 KiB
C#

using System;
using System.Runtime.InteropServices;
using System.Runtime.Serialization;
namespace System
{
/// <summary>Identifies the activation context for the current application. This class cannot be inherited. </summary>
/// <filterpriority>1</filterpriority>
// Token: 0x0200062D RID: 1581
[ComVisible(false)]
[Serializable]
public sealed class ActivationContext : IDisposable, ISerializable
{
// Token: 0x06003A0F RID: 14863 RVA: 0x000C7360 File Offset: 0x000C5560
private ActivationContext(ApplicationIdentity identity)
{
this._appid = identity;
}
/// <summary>Populates a <see cref="T:System.Runtime.Serialization.SerializationInfo" /> with the data needed to serialize the target object.</summary>
/// <param name="info">The <see cref="T:System.Runtime.Serialization.SerializationInfo" /> to populate with data.</param>
/// <param name="context">The <see cref="T:System.Runtime.Serialization.StreamingContext" /> structure for this serialization.</param>
// Token: 0x06003A10 RID: 14864 RVA: 0x000C7370 File Offset: 0x000C5570
[MonoTODO("Missing serialization support")]
void ISerializable.GetObjectData(SerializationInfo info, StreamingContext context)
{
if (info == null)
{
throw new ArgumentNullException("info");
}
}
// Token: 0x06003A11 RID: 14865 RVA: 0x000C7384 File Offset: 0x000C5584
~ActivationContext()
{
this.Dispose(false);
}
/// <summary>Gets the form, or store context, for the current application. </summary>
/// <returns>One of the <see cref="T:System.ActivationContext.ContextForm" /> values. </returns>
/// <filterpriority>1</filterpriority>
// Token: 0x17000B1F RID: 2847
// (get) Token: 0x06003A12 RID: 14866 RVA: 0x000C73C0 File Offset: 0x000C55C0
public ActivationContext.ContextForm Form
{
get
{
return this._form;
}
}
/// <summary>Gets the application identity for the current application.</summary>
/// <returns>An <see cref="T:System.ApplicationIdentity" /> object that identifies the current application.</returns>
/// <filterpriority>1</filterpriority>
// Token: 0x17000B20 RID: 2848
// (get) Token: 0x06003A13 RID: 14867 RVA: 0x000C73C8 File Offset: 0x000C55C8
public ApplicationIdentity Identity
{
get
{
return this._appid;
}
}
/// <summary>Initializes a new instance of the <see cref="T:System.ActivationContext" /> class using the specified application identity.</summary>
/// <returns>An <see cref="T:System.ActivationContext" /> object.</returns>
/// <param name="identity">An <see cref="T:System.ApplicationIdentity" /> object that identifies an application.</param>
/// <exception cref="T:System.ArgumentNullException">
/// <paramref name="identity" /> is null. </exception>
/// <exception cref="T:System.ArgumentException">No deployment or application identity is specified in <paramref name="identity" />.</exception>
/// <filterpriority>1</filterpriority>
/// <PermissionSet>
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="UnmanagedCode" />
/// </PermissionSet>
// Token: 0x06003A14 RID: 14868 RVA: 0x000C73D0 File Offset: 0x000C55D0
[MonoTODO("Missing validation")]
public static ActivationContext CreatePartialActivationContext(ApplicationIdentity identity)
{
if (identity == null)
{
throw new ArgumentNullException("identity");
}
return new ActivationContext(identity);
}
/// <summary>Initializes a new instance of the <see cref="T:System.ActivationContext" /> class using the specified application identity and array of manifest paths.</summary>
/// <returns>An <see cref="T:System.ActivationContext" /> object.</returns>
/// <param name="identity">An <see cref="T:System.ApplicationIdentity" /> object that identifies an application.</param>
/// <param name="manifestPaths">A string array of manifest paths for the application.</param>
/// <exception cref="T:System.ArgumentNullException">
/// <paramref name="identity" /> is null. -or-<paramref name="manifestPaths" /> is null. </exception>
/// <exception cref="T:System.ArgumentException">No deployment or application identity is specified in <paramref name="identity" />.-or-<paramref name="identity" /> does not match the identity in the manifests.-or-<paramref name="identity" /> does not have the same number of components as the manifest paths.</exception>
/// <filterpriority>1</filterpriority>
/// <PermissionSet>
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="UnmanagedCode" />
/// </PermissionSet>
// Token: 0x06003A15 RID: 14869 RVA: 0x000C73EC File Offset: 0x000C55EC
[MonoTODO("Missing validation")]
public static ActivationContext CreatePartialActivationContext(ApplicationIdentity identity, string[] manifestPaths)
{
if (identity == null)
{
throw new ArgumentNullException("identity");
}
if (manifestPaths == null)
{
throw new ArgumentNullException("manifestPaths");
}
return new ActivationContext(identity);
}
/// <summary>Releases all resources used by the <see cref="T:System.ActivationContext" />. </summary>
/// <filterpriority>1</filterpriority>
// Token: 0x06003A16 RID: 14870 RVA: 0x000C7424 File Offset: 0x000C5624
public void Dispose()
{
this.Dispose(true);
GC.SuppressFinalize(this);
}
// Token: 0x06003A17 RID: 14871 RVA: 0x000C7434 File Offset: 0x000C5634
private void Dispose(bool disposing)
{
if (this._disposed)
{
if (disposing)
{
}
this._disposed = true;
}
}
// Token: 0x04001763 RID: 5987
private ActivationContext.ContextForm _form;
// Token: 0x04001764 RID: 5988
private ApplicationIdentity _appid;
// Token: 0x04001765 RID: 5989
private bool _disposed;
/// <summary>Indicates the context for a manifest-activated application.</summary>
// Token: 0x0200062E RID: 1582
public enum ContextForm
{
/// <summary>The application is not in the ClickOnce store.</summary>
// Token: 0x04001767 RID: 5991
Loose,
/// <summary>The application is contained in the ClickOnce store.</summary>
// Token: 0x04001768 RID: 5992
StoreBounded
}
}
}