summaryrefslogtreecommitdiff
path: root/src/backend/taler-mint-httpd_parsing.h
diff options
context:
space:
mode:
authorMarcello Stanisci <marcello.stanisci@inria.fr>2015-11-05 17:56:12 +0100
committerMarcello Stanisci <marcello.stanisci@inria.fr>2015-11-05 17:56:12 +0100
commitc1159ff547afffd135cde78c026dd35817d2f927 (patch)
tree9d0126a494b7018d4ad70e2c7d21de75ca6c3e8f /src/backend/taler-mint-httpd_parsing.h
parent45cd6f3e16d8411add89588673cd58873293c2b0 (diff)
parente55860d9139702f39ce2b61df5bb0e33e1f30a08 (diff)
downloadmerchant-c1159ff547afffd135cde78c026dd35817d2f927.tar.gz
merchant-c1159ff547afffd135cde78c026dd35817d2f927.tar.bz2
merchant-c1159ff547afffd135cde78c026dd35817d2f927.zip
Merge branch 'fix4013'
Conflicts: src/frontend/index.html
Diffstat (limited to 'src/backend/taler-mint-httpd_parsing.h')
-rw-r--r--src/backend/taler-mint-httpd_parsing.h21
1 files changed, 19 insertions, 2 deletions
diff --git a/src/backend/taler-mint-httpd_parsing.h b/src/backend/taler-mint-httpd_parsing.h
index d6a2b4ea..dae65092 100644
--- a/src/backend/taler-mint-httpd_parsing.h
+++ b/src/backend/taler-mint-httpd_parsing.h
@@ -139,7 +139,13 @@ enum TMH_PARSE_JsonNavigationCommand
* encoded as a JSON integer.
* Param: uint64_t *
*/
- TMH_PARSE_JNC_RET_UINT64
+ TMH_PARSE_JNC_RET_UINT64,
+ /**
+ * Return a 'char *' as returned from 'json_string_value ()'.
+ * So it will live as long as the containg JSON is not freed,
+ * and must not be freed by the user
+ */
+ TMH_PARSE_JNC_RET_STRING
};
@@ -265,7 +271,18 @@ TMH_PARSE_member_variable (const char *field,
void **ptr,
size_t *ptr_size);
-
+/**
+ * Generate line in parser specification for string. The returned
+ * string is already nul-terminated internally by JSON, so no length
+ * information is provided. The string will live as long as the containg
+ * JSON will, and must not be freed by the user
+ * @param field name of the field
+ * @param[out] pointer to the string
+ * @return corresponding field spec
+ */
+struct TMH_PARSE_FieldSpecification
+TMH_PARSE_member_string (const char *field,
+ char **out);
/**
* Generate line in parser specification for 64-bit integer
* given as an integer in JSON.