Writing a Standard Registration Resource File

For Symbian OS V9.1 and onwards, the name of the standard registration resource file must be the same as that of the executable with .rss extension. All the registration resource structure types are defined in RegistryInfo.rh. This file has to be included in the registration resource file.

Steps

  1. Define a single REGISTRY_INFO resource.

  2. Set the dll_uid to the DLL's UID.

  3. Set interfaces member to be an array of INTERFACE_INFO resources.

    Each INTERFACE_INFO resource defines registration information for implementations of the interface identified by interface_uid member. The information takes the form of an array of IMPLEMENTATION_INFO resources.

  4. Each IMPLEMENTATION_INFO resource declares the properties of a single implementation. It has five members:

    1. implementation_uid: An unique identifier for the implementation.

      For this value, use a new UID allocated by Symbian Signed. The allocated value can be from the protected or non-protected range of UIDs.

    2. version_no: The version of the interface implementation.

    3. display_name: The external name of the implementation.

    4. default_data: The data identifier field used by the resolver to determine if the implementation matches a client request.

    5. opaque_data: A binary data field that can contain additional data. This additional data can be used by the custom resolvers.

Example

The following example depicts a resource registration file for an implementation collection with two implementations.

// 10009DB1.RSS
//
#include "RegistryInfo.rh"

RESOURCE REGISTRY_INFO theInfo
{
dll_uid = 0x10009DB1;
interfaces = 
	{
	INTERFACE_INFO
		{
		interface_uid = 0x10009DC0;
		implementations = 
			{
			IMPLEMENTATION_INFO
				{
				implementation_uid = 0x10009DC3;
				version_no = 1;
				display_name = "Implementation name 1";
				default_data = "text/wml";
				opaque_data = "some extra data";
				},
			IMPLEMENTATION_INFO
				{
				implementation_uid = 0x10009DC4;
				version_no = 1;
				display_name = "Implementation name 1";
				default_data = "text/xml||Type of data handled";
				opaque_data = "";
				}
			};
		}
	};
}

Related tasks