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
Added Bib-1 Attribute Set man page.
[yaz-moved-to-github.git]
/
doc
/
odr.xml
diff --git
a/doc/odr.xml
b/doc/odr.xml
index
0633205
..
627f5c9
100644
(file)
--- a/
doc/odr.xml
+++ b/
doc/odr.xml
@@
-1,4
+1,3
@@
-<!-- $Id: odr.xml,v 1.20 2007-02-01 09:56:14 adam Exp $ -->
<chapter id="odr"><title>The ODR Module</title>
<sect1 id="odr.introduction"><title>Introduction</title>
<chapter id="odr"><title>The ODR Module</title>
<sect1 id="odr.introduction"><title>Introduction</title>
@@
-105,7
+104,7
@@
</para>
<synopsis>
</para>
<synopsis>
- void odr_reset(ODR o, int size);
+ void odr_reset(ODR o);
</synopsis>
<para>
</synopsis>
<para>
@@
-322,23
+321,23
@@
void do_nothing_useful(int value)
if (!(decode = odr_createmem(ODR_DECODE)))
return;
if (!(decode = odr_createmem(ODR_DECODE)))
return;
- valp = &value;
- if (odr_integer(encode, &valp, 0, 0) == 0)
+ valp = &value;
+ if (odr_integer(encode, &valp, 0, 0) == 0)
{
printf("encoding went bad\n");
return;
}
{
printf("encoding went bad\n");
return;
}
- bufferp = odr_getbuf(encode, &len);
- printf("length of encoded data is %d\n", len);
+ bufferp = odr_getbuf(encode, &len, 0);
+ printf("length of encoded data is %d\n", len);
/* now let's decode the thing again */
/* now let's decode the thing again */
- odr_setbuf(decode, bufferp, len);
- if (odr_integer(decode, &resvalp, 0, 0) == 0)
+ odr_setbuf(decode, bufferp, len, 0);
+ if (odr_integer(decode, &resvalp, 0, 0) == 0)
{
printf("decoding went bad\n");
return;
}
{
printf("decoding went bad\n");
return;
}
- printf("the value is %d\n", *resvalp);
+ printf("the value is %d\n", *resvalp);
/* clean up */
odr_destroy(encode);
/* clean up */
odr_destroy(encode);
@@
-505,7
+504,7
@@
void do_nothing_useful(int value)
<title>Summary and Synopsis</title>
<synopsis>
<title>Summary and Synopsis</title>
<synopsis>
- #include <odr.h>
+ #include <yaz/odr.h>
ODR odr_createmem(int direction);
ODR odr_createmem(int direction);
@@
-513,19
+512,17
@@
void do_nothing_useful(int value)
void odr_reset(ODR o);
void odr_reset(ODR o);
- char *odr_getbuf(ODR o, int *len);
+ char *odr_getbuf(ODR o, int *len, int *size);
- void odr_setbuf(ODR o, char *buf, int len);
+ void odr_setbuf(ODR o, char *buf, int len, int can_grow);
void *odr_malloc(ODR o, int size);
void *odr_malloc(ODR o, int size);
- ODR_MEM odr_extract_mem(ODR o);
-
- void odr_release_mem(ODR_MEM r);
+ NMEM odr_extract_mem(ODR o);
int odr_geterror(ODR o);
int odr_geterror(ODR o);
- void odr_perror(char *message);
+ void odr_perror(ODR o, const char *message);
extern char *odr_errlist[];
</synopsis>
extern char *odr_errlist[];
</synopsis>
@@
-759,9
+756,9
@@
int odr_oid(ODR o, Odr_oid **p, int optional, const char *name);
<para>
The C OID representation is simply an array of integers, terminated by
the value -1 (the <literal>Odr_oid</literal> type is synonymous with
<para>
The C OID representation is simply an array of integers, terminated by
the value -1 (the <literal>Odr_oid</literal> type is synonymous with
- the <literal>int</literal> type).
+ the <literal>short</literal> type).
We suggest that you use the OID database module (see
We suggest that you use the OID database module (see
- <xref linkend="asn.oid"/>) to handle object identifiers
+ <xref linkend="tools.oid.database"/>) to handle object identifiers
in your application.
</para>
in your application.
</para>