summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRoss Burton <ross@linux.intel.com>2010-08-04 15:46:31 +0100
committerRoss Burton <ross@linux.intel.com>2010-08-04 16:05:35 +0100
commit4270d6a1be09baecc975f06b9d884aaa9019a2f8 (patch)
treed61781b200640dc9e076c83f34c926f23314a756
parent349736bdbb1338001d0a9f46c75b8294f9af6709 (diff)
downloadlibrest-4270d6a1be09baecc975f06b9d884aaa9019a2f8.tar.gz
Minor documentation fixes
-rw-r--r--rest/oauth-proxy.c15
-rw-r--r--rest/oauth-proxy.h10
-rw-r--r--rest/oauth2-proxy.c2
-rw-r--r--rest/rest-params.c2
-rw-r--r--rest/rest-proxy-call.c2
-rw-r--r--rest/rest-proxy-call.h6
-rw-r--r--rest/rest-proxy.c2
-rw-r--r--rest/rest-proxy.h7
8 files changed, 31 insertions, 15 deletions
diff --git a/rest/oauth-proxy.c b/rest/oauth-proxy.c
index 2cc5224..76ebef6 100644
--- a/rest/oauth-proxy.c
+++ b/rest/oauth-proxy.c
@@ -325,6 +325,7 @@ oauth_proxy_auth_step_async (OAuthProxy *proxy,
* oauth_proxy_auth_step:
* @proxy: an #OAuthProxy
* @function: the function to invoke on the proxy
+ * @error: return location for a #GError
*
* Perform an OAuth authorisation step. This calls @function and then updates
* the token and token secret in the proxy.
@@ -484,7 +485,7 @@ oauth_proxy_request_token_async (OAuthProxy *proxy,
* "access_token" if @function is NULL).
*
* @verifier is only used if you are using OAuth 1.0a. This is either the
- * %oauth_verifier parameter that was passed to your callback URI, or a string
+ * "oauth_verifier" parameter that was passed to your callback URI, or a string
* that the user enters in some other manner (for example in a popup dialog) if
* "oob" was passed to oauth_proxy_request_token(). For OAuth 1.0, pass %NULL.
*
@@ -554,7 +555,7 @@ access_token_cb (RestProxyCall *call,
* "access_token" if @function is NULL).
*
* @verifier is only used if you are using OAuth 1.0a. This is either the
- * %oauth_verifier parameter that was passed to your callback URI, or a string
+ * "oauth_verifier" parameter that was passed to your callback URI, or a string
* that the user enters in some other manner (for example in a popup dialog) if
* "oob" was passed to oauth_proxy_request_token(). For OAuth 1.0, pass %NULL.
*
@@ -665,11 +666,13 @@ oauth_proxy_set_token_secret (OAuthProxy *proxy, const char *token_secret)
/**
* oauth_proxy_is_oauth10a:
- * @proxy: an #OAuthProxy
+ * @proxy: a valid #OAuthProxy
+ *
+ * Determines if the server supports OAuth 1.0a with this proxy. This is only
+ * valid after oauth_proxy_request_token() or oauth_proxy_request_token_async()
+ * has been called.
*
- * Returns %TRUE if the server supports OAuth 1.0a with this proxy, %FALSE
- * otherwise. This is only valid after oauth_proxy_request_token() or
- * oauth_proxy_request_token_async() has been called.
+ * Returns: %TRUE if the server supports OAuth 1.0a, %FALSE otherwise.
*/
gboolean
oauth_proxy_is_oauth10a (OAuthProxy *proxy)
diff --git a/rest/oauth-proxy.h b/rest/oauth-proxy.h
index 0e05965..c84a1b0 100644
--- a/rest/oauth-proxy.h
+++ b/rest/oauth-proxy.h
@@ -90,14 +90,18 @@ RestProxy* oauth_proxy_new_with_token (const char *consumer_key,
/**
* OAuthProxyAuthCallback:
+ * @proxy: the #OAuthProxy
+ * @error: a #GError if the authentication failed, otherwise %NULL
+ * @weak_object: the weak object passed to the caller
+ * @userdata: the user data passed to the caller
*
* Callback from oauth_proxy_request_token_async() and
* oauth_proxy_access_token_async().
*/
-typedef void (*OAuthProxyAuthCallback)(OAuthProxy *proxy,
+typedef void (*OAuthProxyAuthCallback)(OAuthProxy *proxy,
const GError *error,
- GObject *weak_object,
- gpointer userdata);
+ GObject *weak_object,
+ gpointer userdata);
G_GNUC_DEPRECATED
gboolean oauth_proxy_auth_step (OAuthProxy *proxy,
diff --git a/rest/oauth2-proxy.c b/rest/oauth2-proxy.c
index 1a15bb6..830df3a 100644
--- a/rest/oauth2-proxy.c
+++ b/rest/oauth2-proxy.c
@@ -354,7 +354,7 @@ oauth2_proxy_get_access_token (OAuth2Proxy *proxy)
/**
* oauth2_proxy_set_access_token:
* @proxy: an #OAuth2Proxy
- * @token: the access token
+ * @access_token: the access token
*
* Set the access token.
*/
diff --git a/rest/rest-params.c b/rest/rest-params.c
index dc48fd8..794a608 100644
--- a/rest/rest-params.c
+++ b/rest/rest-params.c
@@ -196,7 +196,7 @@ rest_params_as_string_hash_table (RestParams *params)
/**
* rest_params_iter_init:
- * @iter: an uninitialized #RestParamIter
+ * @iter: an uninitialized #RestParamsIter
* @params: a valid #RestParams
*
* Initialize a parameter iterator over @params. Modifying @params after calling
diff --git a/rest/rest-proxy-call.c b/rest/rest-proxy-call.c
index b5777b7..6090135 100644
--- a/rest/rest-proxy-call.c
+++ b/rest/rest-proxy-call.c
@@ -949,7 +949,6 @@ rest_proxy_call_sync (RestProxyCall *call,
/**
* rest_proxy_call_lookup_response_header
- *
* @call: The #RestProxyCall
* @header: The name of the header to lookup.
*
@@ -976,7 +975,6 @@ rest_proxy_call_lookup_response_header (RestProxyCall *call,
/**
* rest_proxy_call_get_response_headers
- *
* @call: The #RestProxyCall
*
* Returns: A pointer to a hash table of headers. This hash table must not be
diff --git a/rest/rest-proxy-call.h b/rest/rest-proxy-call.h
index 5c5ac99..c9648b2 100644
--- a/rest/rest-proxy-call.h
+++ b/rest/rest-proxy-call.h
@@ -78,6 +78,12 @@ typedef struct {
#define REST_PROXY_CALL_ERROR rest_proxy_call_error_quark ()
+/**
+ * RestProxyCallError:
+ * @REST_PROXY_CALL_FAILED: the method call failed
+ *
+ * Error domain used when returning errors from #RestProxyCall.
+ */
typedef enum {
REST_PROXY_CALL_FAILED
} RestProxyCallError;
diff --git a/rest/rest-proxy.c b/rest/rest-proxy.c
index 19b41df..fad6393 100644
--- a/rest/rest-proxy.c
+++ b/rest/rest-proxy.c
@@ -239,7 +239,7 @@ rest_proxy_init (RestProxy *self)
* @binding_required: whether the URL needs to be bound before calling
*
* Create a new #RestProxy for the specified endpoint @url_format, using the
- * %GET method.
+ * "GET" method.
*
* Set @binding_required to %TRUE if the URL contains string formatting
* operations (for example "http://foo.com/%<!-- -->s". These must be expanded
diff --git a/rest/rest-proxy.h b/rest/rest-proxy.h
index 223f4ea..ff38a14 100644
--- a/rest/rest-proxy.h
+++ b/rest/rest-proxy.h
@@ -59,7 +59,6 @@ struct _RestProxy {
/**
* RestProxyClass:
- *
* @bind_valist: Virtual function called to bind parameters.
* @new_call: Virtual function called to construct a new #RestProxyCall.
* @simple_run_valist: Virtual function called when making a "simple" call.
@@ -71,6 +70,7 @@ struct _RestProxy {
* #RestProxyCall.
*/
struct _RestProxyClass {
+ /*< private >*/
GObjectClass parent_class;
/*< public >*/
gboolean (*bind_valist)(RestProxy *proxy, va_list params);
@@ -85,6 +85,11 @@ struct _RestProxyClass {
#define REST_PROXY_ERROR rest_proxy_error_quark ()
+/**
+ * RestProxyError:
+ *
+ * Error domain used when returning errors from a #RestProxy.
+ */
typedef enum {
REST_PROXY_ERROR_CANCELLED = 1,
REST_PROXY_ERROR_RESOLUTION,