1mms_rsp_type(3MMS) Media Management System Library Functionsmms_rsp_type(3MMS)
2
3
4
6 mms_rsp_type, mms_get_tree, mms_get_str, mms_get_attribute, mms_han‐
7 dle_err_rsp - MMS client functions for handling responses
8
10 cc [ flag...] file... -lmms [ library...]
11 #include <mms_api.h>
12
13 int mms_rsp_type(void *response);
14
15
16 mms_par_node_t *mms_get_tree(void *response);
17
18
19 char *mms_get_str(void *response);
20
21
22 char *mms_get_attribute(void *response, char *name, void **prev);
23
24
25 int mms_handle_err_response(void *response, int * class, int * code,
26 char **message);
27
28
30 For these functions, response is the MMS response to an MMP command
31 sent by the client.
32
33
34 The mms_rsp_type() macro returns the type of the response. The follow‐
35 ing is a list of responses:
36
37 MMS_API_RSP_UNACC unacceptable response
38
39
40 MMS_API_RSP_FINAL success response
41
42
43 MMS_API_RSP_FINAL_INTR intermediate response
44
45
46 MMS_API_RSP_FINAL_ERR error response
47
48
49 MMS_API_RSP_FINAL_CANC cancelled response
50
51
52
53 The mms_get_tree() macro returns the parse tree of the response.
54
55
56 The mms_get_str() macro returns the response string.
57
58
59 The mms_get_attribute() function takes a response with name values
60 looking for name, and returning the value associated with it. A client
61 can call this function multiple times if the response contains multiple
62 instances of name. When all occurrences of name have been found, NULL
63 is returned.
64
65
66 The mms_handle_err_rsp() function processes an error response on behalf
67 of the client. It returns the error class, error code, and the interna‐
68 tionalized error message if one was included.
69
71 Upon successful completion, mms_handle_err_rsp() returns MMS_API_OK. If
72 it encounters a processing error, it returns an error code indicating
73 the type of error.
74
76 These functions will fail if:
77
78 MMS_API_ERROR Unable to obtain error class or code.
79
80
81 MMS_API_NOT_ERR_RSP Response is not an error response.
82
83
85 See attributes(5) for descriptions of the following attributes:
86
87
88
89
90 ┌─────────────────────────────┬─────────────────────────────┐
91 │ ATTRIBUTE TYPE │ ATTRIBUTE VALUE │
92 ├─────────────────────────────┼─────────────────────────────┤
93 │Interface Stability │Uncommitted │
94 ├─────────────────────────────┼─────────────────────────────┤
95 │MT-Level │MT-Safe │
96 └─────────────────────────────┴─────────────────────────────┘
97
99 libmms(3LIB), mms_init(3MMS), mms_send_cmd(3MMS), attributes(5)
100
101
102
103SunOS 5.11 28 Oct 2008 mms_rsp_type(3MMS)