### Method

# GUPnP ResourceFactory register_resource_type

#### Declaration [src]

    void
    gupnp_resource_factory_register_resource_type (
      GUPnPResourceFactory* factory,
      const char* upnp_type,
      GType type
    )

#### Description [src]

Registers the GType `type` for the resource of UPnP type `upnp_type`. After this call, the factory `factory` will create object of GType `type` each time it is asked to create a resource object for UPnP type `upnp_type`.

You can either register a type for a concrete version of a device or service such as urn:schemas-upnp-org:service:AVTransport:2 or version-independently, urn:schemas-upnp-org:service:AVTransport. If you register for an explicit version of a service, it will be an exact match.

Note: GType `type` must be a derived type of #GUPNP_TYPE_DEVICE if resource is a device or #GUPNP_TYPE_SERVICE if its a service.

#### Parameters

`upnp_type`

  Type: `const char*`

  The UPnP type name of the resource.

  The data is owned by the caller of the method.
  The value is a NUL terminated UTF-8 string.

`type`

  Type: `GType`

  The requested GType assignment for the resource.