Browse code

- doxygen comment moved to the header file

Jan Janak authored on 02/02/2008 12:26:59
Showing 2 changed files
... ...
@@ -140,7 +140,7 @@ int set_to_uid(str* uid)
140 140
 }
141 141
 
142 142
 
143
-/* Retrieves the UID of the callee. This function retrieves the UID (unique
143
+/** Retrieves the UID of the callee. This function retrieves the UID (unique
144 144
  * identifier) of the party being called. The function first searches the list
145 145
  * of available attributes and if it finds an attribute with name "uid" then
146 146
  * the value of the attribute is returned.  If no such attribute can be found
... ...
@@ -57,8 +57,26 @@ int set_to_uid(str* uid);
57 57
 int get_to_uid(str* uid, struct sip_msg* msg);
58 58
 
59 59
 
60
-/*
61
- * Return current To domain id
60
+/** Retrieves the UID of the callee. This function retrieves the UID (unique
61
+ * identifier) of the party being called. The function first searches the list
62
+ * of available attributes and if it finds an attribute with name "uid" then
63
+ * the value of the attribute is returned.  If no such attribute can be found
64
+ * then the function retrieves the username from To header field of REGISTER
65
+ * requests (because that is the party being registered), or the username from
66
+ * the Reqeuest-URI of other requests. The username is then used as the UID
67
+ * string identifying the callee. If no attribute with the UID was found and
68
+ * the function successfully retrieved the UID from the SIP message then, in
69
+ * addition to storing the result in the first parameter, the function will
70
+ * also create the attribute named "uid" which will contain the UID. The
71
+ * function is not reentrant because it uses an internal static buffer to
72
+ * store the result.
73
+ * @param uid A pointer to ::str variable where the result will be stored, the
74
+ *            pointer in the variable will be updated to point to a static
75
+ *            buffer in the function.  
76
+ * @param msg The SIP message being processed.  
77
+ * @return 1 is returned when the attribute with UID exists and it is used, 0
78
+ *         is returned when the function retrieved the UID from the SIP
79
+ *         message and created the attribute, -1 is returned on error.
62 80
  */
63 81
 int get_to_did(str* did, struct sip_msg* msg);
64 82