GUPnP Reference Manual | ||||
---|---|---|---|---|
enum GUPnPServiceActionArgDirection; GUPnPServiceActionArgInfo; GUPnPServiceActionInfo; GUPnPServiceStateVariableInfo; GUPnPServiceIntrospection; const GList* gupnp_service_introspection_list_action_names (GUPnPServiceIntrospection *introspection); const GList* gupnp_service_introspection_list_actions (GUPnPServiceIntrospection *introspection); const GUPnPServiceActionInfo* gupnp_service_introspection_get_action (GUPnPServiceIntrospection *introspection, const gchar *action_name); const GList* gupnp_service_introspection_list_state_variable_names (GUPnPServiceIntrospection *introspection); const GList* gupnp_service_introspection_list_state_variables (GUPnPServiceIntrospection *introspection); const GUPnPServiceStateVariableInfo* gupnp_service_introspection_get_state_variable (GUPnPServiceIntrospection *introspection, const gchar *variable_name);
The GUPnPServiceIntrospection class provides methods for service introspection based on information contained in its service description document (SCPD). There is no constructor provided for this class, please use gupnp_service_info_get_introspection or gupnp_service_info_get_introspection_async to create an GUPnPServiceIntrospection object for a specific service.
Note that all the introspection information is retreived from the service description document (SCPD) provided by the service and hence can not be guaranteed to be complete. A UPnP service is required to provide an SCPD but unfortunately, many services either do not provide this document or the document does not provide any or all of the introspection information.
This class exposes internals of the UPnP protocol and should not need to be used for regular device or control point development.
typedef enum { GUPNP_SERVICE_ACTION_ARG_DIRECTION_IN, GUPNP_SERVICE_ACTION_ARG_DIRECTION_OUT } GUPnPServiceActionArgDirection;
Represents the direction of a service state variable.
typedef struct { char *name; GUPnPServiceActionArgDirection direction; char *related_state_variable; gboolean retval; } GUPnPServiceActionArgInfo;
This structure contains information about the argument of service action.
char * |
The name of the action argument. |
GUPnPServiceActionArgDirection |
The direction of the action argument. |
char * |
The name of the state variable associated with this argument. |
gboolean |
Whether this argument is the return value of the action. |
typedef struct { char *name; GList *arguments; /* list of #GUPnPServiceActionArgInfo */ } GUPnPServiceActionInfo;
This structure contains information about a service action.
char * |
The name of the action argument. |
GList * |
A GList of all the arguments (of type GUPnPServiceActionArgInfo) of this action. |
typedef struct { char *name; gboolean send_events; gboolean is_numeric; GType type; GValue default_value; GValue minimum; GValue maximum; GValue step; GList *allowed_values; } GUPnPServiceStateVariableInfo;
This structure contains information about service state variable.
char * |
The name of the state variable. |
gboolean |
Whether this state variable can source events. |
gboolean |
Wether this state variable is a numeric type (integer and float). |
GType |
The GType of this state variable. |
GValue |
The default value of this state variable. |
GValue |
The minimum value of this state variable. Only applies to numeric data types. |
GValue |
The maximum value of this state variable. Only applies to numeric data types. |
GValue |
The step value of this state variable. Only applies to numeric data types. |
GList * |
The allowed values of this state variable. Only applies to string data types. Unlike the other fields in this structure, this field contains a list of (char *) strings rather than GValues. |
typedef struct _GUPnPServiceIntrospection GUPnPServiceIntrospection;
This struct contains private data only, and should be accessed using the functions below.
const GList* gupnp_service_introspection_list_action_names (GUPnPServiceIntrospection *introspection);
Returns a GList of names of all the actions in this service.
|
A GUPnPServiceIntrospection |
Returns : |
A GList of names of all the actions or NULL . Do not modify
or free it or its contents.
|
const GList* gupnp_service_introspection_list_actions (GUPnPServiceIntrospection *introspection);
Returns a GList of all the actions (of type GUPnPServiceActionInfo) in this service.
|
A GUPnPServiceIntrospection |
Returns : |
A GList of all the actions or NULL . Do not modify or free it
or its contents.
|
const GUPnPServiceActionInfo* gupnp_service_introspection_get_action (GUPnPServiceIntrospection *introspection, const gchar *action_name);
Returns the action by the name action_name
in this service.
|
A GUPnPServiceIntrospection |
|
The name of the action to retreive |
Returns : |
the action or NULL . Do not modify or free it.
|
const GList* gupnp_service_introspection_list_state_variable_names (GUPnPServiceIntrospection *introspection);
Returns a GList of names of all the state variables in this service.
|
A GUPnPServiceIntrospection |
Returns : |
A GList of names of all the state variables or NULL . Do not
modify or free it or its contents.
|
const GList* gupnp_service_introspection_list_state_variables (GUPnPServiceIntrospection *introspection);
Returns a GList of all the state variables (of type GUPnPServiceStateVariableInfo) in this service.
|
A GUPnPServiceIntrospection |
Returns : |
A GList of all the state variables or NULL . Do not modify or
free it or its contents.
|
const GUPnPServiceStateVariableInfo* gupnp_service_introspection_get_state_variable (GUPnPServiceIntrospection *introspection, const gchar *variable_name);
Returns the state variable by the name variable_name
in this service.
|
A GUPnPServiceIntrospection |
|
The name of the variable to retreive |
Returns : |
the state variable or NULL . Do not modify or free it.
|
"scpd"
property"scpd" gpointer : Write / Construct Only
The scpd of the device description file.