projects
/
yaz-moved-to-github.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
SRU GET/Solr base URLs may hold additional ?args YAZ-729
[yaz-moved-to-github.git]
/
include
/
yaz
/
marcdisp.h
diff --git
a/include/yaz/marcdisp.h
b/include/yaz/marcdisp.h
index
f1eaae8
..
d7bbaa0
100644
(file)
--- a/
include/yaz/marcdisp.h
+++ b/
include/yaz/marcdisp.h
@@
-1,5
+1,5
@@
/* This file is part of the YAZ toolkit.
/* This file is part of the YAZ toolkit.
- * Copyright (C) 1995-2013 Index Data.
+ * Copyright (C) Index Data.
* All rights reserved.
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
* All rights reserved.
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
@@
-76,6
+76,8
@@
YAZ_EXPORT void yaz_marc_xml(yaz_marc_t mt, int xmlmode);
#define YAZ_MARC_CHECK 6
/** \brief Output format: Turbo MARC Index Data format (XML based) */
#define YAZ_MARC_TURBOMARC 7
#define YAZ_MARC_CHECK 6
/** \brief Output format: Turbo MARC Index Data format (XML based) */
#define YAZ_MARC_TURBOMARC 7
+/** \brief Output format: JSON */
+#define YAZ_MARC_JSON 8
/** \brief set iconv handle for character set conversion */
YAZ_EXPORT void yaz_marc_iconv(yaz_marc_t mt, yaz_iconv_t cd);
/** \brief set iconv handle for character set conversion */
YAZ_EXPORT void yaz_marc_iconv(yaz_marc_t mt, yaz_iconv_t cd);
@@
-260,6
+262,15
@@
int yaz_marc_write_xml(yaz_marc_t mt, xmlNode **root_ptr,
const char *type);
#endif
const char *type);
#endif
+/** \brief writes MARC record in JSON represenation
+ \param mt handle
+ \param w WRBUF for output
+ \retval 0 Creation successful
+ \retval -1 ERROR
+*/
+YAZ_EXPORT
+int yaz_marc_write_json(yaz_marc_t mt, WRBUF w);
+
/** \brief sets leader spec (for modifying bytes in 24 byte leader)
\param mt handle
\param leader_spec
/** \brief sets leader spec (for modifying bytes in 24 byte leader)
\param mt handle
\param leader_spec
@@
-469,6
+480,10
@@
YAZ_EXPORT int yaz_marc_write_trailer(yaz_marc_t mt, WRBUF wr);
*/
YAZ_EXPORT void yaz_marc_enable_collection(yaz_marc_t mt);
*/
YAZ_EXPORT void yaz_marc_enable_collection(yaz_marc_t mt);
+struct json_node;
+
+YAZ_EXPORT int yaz_marc_read_json_node(yaz_marc_t mt, struct json_node *n);
+
YAZ_END_CDECL
#endif
YAZ_END_CDECL
#endif