GUPnPDIDLLiteWriter

GUPnPDIDLLiteWriter — DIDL-Lite fragment writer

Properties

gchar * language Read / Write / Construct Only
gpointer xml-node Read

Types and Values

Object Hierarchy

    GObject
    ╰── GUPnPDIDLLiteWriter

Description

GUPnPDIDLLiteWriter is a helper class for writing DIDL-Lite fragments.

Functions

gupnp_didl_lite_writer_new ()

GUPnPDIDLLiteWriter *
gupnp_didl_lite_writer_new (const char *language);

Note: language should always be set to NULL, DLNA does not support the language parameter.

Parameters

language

The language the DIDL-Lite fragment is in, or NULL.

[allow-none]

Returns

A new GUPnPDIDLLiteWriter object.


gupnp_didl_lite_writer_add_item ()

GUPnPDIDLLiteItem *
gupnp_didl_lite_writer_add_item (GUPnPDIDLLiteWriter *writer);

Creates a new item, attaches it to writer and returns it.

Parameters

writer

A GUPnPDIDLLiteWriter

 

Returns

A new GUPnPDIDLLiteItem object. Unref after usage.

[transfer full]


gupnp_didl_lite_writer_add_container ()

GUPnPDIDLLiteContainer *
gupnp_didl_lite_writer_add_container (GUPnPDIDLLiteWriter *writer);

Creates a new container, attaches it to writer and returns it.

Parameters

writer

A GUPnPDIDLLiteWriter

 

Returns

A new GUPnPDIDLLiteContainer object. Unref after usage.

[transfer full]


gupnp_didl_lite_writer_add_descriptor ()

GUPnPDIDLLiteDescriptor *
gupnp_didl_lite_writer_add_descriptor (GUPnPDIDLLiteWriter *writer);

Creates a new descriptor, attaches it to object and returns it.

Parameters

writer

A GUPnPDIDLLiteWriter

 

Returns

A new GUPnPDIDLLiteDescriptor object. Unref after usage.

[transfer full]


gupnp_didl_lite_writer_get_xml_node ()

xmlNode *
gupnp_didl_lite_writer_get_xml_node (GUPnPDIDLLiteWriter *writer);

Get the pointer to root node in XML document.

Parameters

writer

The GUPnPDIDLLiteWriter

 

Returns

The pointer to root node in XML document.

[transfer none]


gupnp_didl_lite_writer_get_string ()

char *
gupnp_didl_lite_writer_get_string (GUPnPDIDLLiteWriter *writer);

Creates a string representation of the DIDL-Lite XML document.

Parameters

writer

A GUPnPDIDLLiteWriter

 

Returns

The DIDL-Lite XML string, or NULL. g_free after usage.


gupnp_didl_lite_writer_get_language ()

const char *
gupnp_didl_lite_writer_get_language (GUPnPDIDLLiteWriter *writer);

Get the language the DIDL-Lite fragment is in.

Parameters

Returns

The language of the writer , or NULL.

[transfer none]


gupnp_didl_lite_writer_filter ()

void
gupnp_didl_lite_writer_filter (GUPnPDIDLLiteWriter *writer,
                               const char *filter);

Clears the DIDL-Lite XML document of the properties not specified in the filter . The passed filter string would typically come from the 'Filter' argument of Browse or Search actions from a ContentDirectory control point. Please refer to Section 2.3.15 of UPnP AV ContentDirectory version 3 specification for details on this string.

Parameters

writer

A GUPnPDIDLLiteWriter

 

filter

A filter string

 

Types and Values

GUPnPDIDLLiteWriter

typedef struct _GUPnPDIDLLiteWriter GUPnPDIDLLiteWriter;

Property Details

The “language” property

  “language”                 gchar *

The language the DIDL-Lite fragment is in.

Flags: Read / Write / Construct Only

Default value: NULL


The “xml-node” property

  “xml-node”                 gpointer

The pointer to root node in XML document.

Flags: Read