mscorlib(4.0.0.0) API with additions
InternalActivationContextHelper.cs
2 using System.Security;
3 
5 {
7  [ComVisible(false)]
8  public static class InternalActivationContextHelper
9  {
13  [SecuritySafeCritical]
14  public static object GetActivationContextData(ActivationContext appInfo)
15  {
16  return appInfo.ActivationContextData;
17  }
18 
22  [SecuritySafeCritical]
23  public static object GetApplicationComponentManifest(ActivationContext appInfo)
24  {
25  return appInfo.ApplicationComponentManifest;
26  }
27 
31  [SecuritySafeCritical]
32  public static object GetDeploymentComponentManifest(ActivationContext appInfo)
33  {
34  return appInfo.DeploymentComponentManifest;
35  }
36 
39  public static void PrepareForExecution(ActivationContext appInfo)
40  {
41  appInfo.PrepareForExecution();
42  }
43 
48  public static bool IsFirstRun(ActivationContext appInfo)
49  {
50  return appInfo.LastApplicationStateResult == ActivationContext.ApplicationStateDisposition.RunningFirstTime;
51  }
52 
56  public static byte[] GetApplicationManifestBytes(ActivationContext appInfo)
57  {
58  if (appInfo == null)
59  {
60  throw new ArgumentNullException("appInfo");
61  }
62  return appInfo.GetApplicationManifestBytes();
63  }
64 
68  public static byte[] GetDeploymentManifestBytes(ActivationContext appInfo)
69  {
70  if (appInfo == null)
71  {
72  throw new ArgumentNullException("appInfo");
73  }
74  return appInfo.GetDeploymentManifestBytes();
75  }
76  }
77 }
static void PrepareForExecution(ActivationContext appInfo)
Informs an T:System.ActivationContext to get ready to be run.
The exception that is thrown when a null reference (Nothing in Visual Basic) is passed to a method th...
Provides access to data from an T:System.ActivationContext object.
static bool IsFirstRun(ActivationContext appInfo)
Gets a value indicating whether this is the first time this T:System.ActivationContext object has bee...
static object GetActivationContextData(ActivationContext appInfo)
Gets the contents of the application manifest from an T:System.ActivationContext object.
Identifies the activation context for the current application. This class cannot be inherited.
Definition: __Canon.cs:3
static object GetApplicationComponentManifest(ActivationContext appInfo)
Gets the manifest of the last deployment component in an T:System.ActivationContext object.
static object GetDeploymentComponentManifest(ActivationContext appInfo)
Gets the manifest of the first deployment component in an T:System.ActivationContext object.
static byte [] GetApplicationManifestBytes(ActivationContext appInfo)
Gets a byte array containing the raw content of the application manifest..
static byte [] GetDeploymentManifestBytes(ActivationContext appInfo)
Gets a byte array containing the raw content of the deployment manifest.