ApplicationManifest class

Microsoft Office Live Communications Server 2005 with SP1


The ApplicationManifest class defines the application manifest for a SIP application.

An application manifest is required for all Live Communications Server 1.0 applications, and provides the SIP message processing rules needed to correctly handle only those SIP messages of interest to the application. An application uses the ApplicationManifest object to register the application with the Live Communications Server through the ServerAgent object. Most applications will use only one manifest, but multiple manifests are supported.

The application manifest is represented as an XML document available to the application, either within the source or as a separate file. The document structure of the application manifest is as follows:

<?xml version="1.0" ?>
   --application attributes here--

      --message filter script here--


The application attributes must precede the message filter script. The lc:appUri attribute is a unique string containing the name of the running application, and is used to identify the application manifest to the server. An HTTP-style URI that contains the domain and the application name is required because it guarantees uniqueness. This URI must be registered upon installation with WMI using the MSFT_SIPApplicationSetting WMI class.

The message filter script must be written in the Microsoft SIP Processing Language (MSPL).

For more information on creating and implementing an application manifest, as well as a complete list of application attributes and MSPL instructions, see Application Manifests.

The ApplicationManifest class is derived from the System.Object class.

Public Methods

The ApplicationManifest class has the following public methods.

Method Description

Parses the application manifest specified with the CreateFromFile or CreateFromString method and compiles the content.


Static (Shared). Creates an instance of an ApplicationManifest object from a specified application manifest file.


Static (Shared). Creates an instance of an ApplicationManifest object from a specified string containing an application manifest.


Inherited from System.Object. Determines whether the specified System.Object is equal to the current System.Object.


Inherited from System.Object. Serves as a hash function for a particular type, suitable for use in hashing algorithms and data structures like a hash table.


Inherited from System.Object. Gets the System.Type of the current instance.


Indicates whether the compiled application should be displayed when Compile is called.


Inherited from System.Object. Returns a System.String that represents the current System.Object.

Public Properties

The ApplicationManifest class has the following public property.

Property Description
ApplicationUri Data type: String
Access type: Read-only

Contains the application URI as defined in the application manifest.

Example Code

The following code sample demonstrates the dynamic creation and compilation of an application manifest.

ServerAgent mySA;
string manifest = @"<?xml version=""1.0""?><lc:applicationManifest appUri=""" + 
    appURI + @""" xmlns:lc="""">" +
    "\n" + @"<lc:requestFilter methodNames=""ALL"" strictRoute=""true""/>" +
    "\n" + @"<lc:responseFilter reasonCodes=""ALL"" />" +
    "\n" + @"<lc:proxyByDefault action=""true"" />" +
    "\n" + @"<lc:splScript><![CDATA[" +
    "\n" + @"   if (sipRequest)  {  Dispatch (""OnRequest"");  return; }" +             
    "\n" + @"   if (sipResponse)  {  Dispatch (""OnResponse"");  return; }" +               
    "\n" + @" ]]></lc:splScript>" +
    "\n" + @"</lc:applicationManifest>";

ApplicationManifest myAppManifest = ApplicationManifest.CreateFromString(manifest);
bool success = true;    

    Console.WriteLine("The application manifest was compiled successfully.");
catch(CompilerErrorException e)
    Console.WriteLine("The application manifest could not be compiled successfully:" + e.Message);
    success = false;

if (success)
    // Create a new ServerAgent, taking the object instance (presuming it has the dispatch handlers 
    // OnRequest and OnResponse implemented on it) and the application manifest as parameters.
    mySA = new ServerAgent(this, myAppManifest);


Redistributable: Requires Microsoft Office Live Communications Server 2005 with SP1.
Namespace: Microsoft.Rtc.Sip
Assembly: ServerAgent (in ServerAgent.dll)

See Also

Creating an Application Manifest, Application Manifests

What did you think of this topic?
© 2008 Microsoft Corporation. All rights reserved.