| 200 * |
200 * |
| 201 * You may also provide a read-only @p space, in which case |
201 * You may also provide a read-only @p space, in which case |
| 202 * you will need to cast the pointer, and you should set the |
202 * you will need to cast the pointer, and you should set the |
| 203 * #CX_BUFFER_COPY_ON_WRITE flag. |
203 * #CX_BUFFER_COPY_ON_WRITE flag. |
| 204 * |
204 * |
| 205 * You need to set the size manually after initialization, if |
205 * You need to set the size manually after initialization if |
| 206 * you provide @p space which already contains data. |
206 * you provide @p space which already contains data. |
| 207 * |
207 * |
| 208 * When you specify stack memory as @p space and decide to use |
208 * When you specify stack memory as @p space and decide to use |
| 209 * the auto-extension feature, you @em must use the |
209 * the auto-extension feature, you @em must use the |
| 210 * #CX_BUFFER_COPY_ON_EXTEND flag, instead of the |
210 * #CX_BUFFER_COPY_ON_EXTEND flag, instead of the |
| 211 * #CX_BUFFER_AUTO_EXTEND flag. |
211 * #CX_BUFFER_AUTO_EXTEND flag. |
| 212 * |
212 * |
| 213 * @note You may provide @c NULL as argument for @p space. |
213 * @note You may provide @c NULL as the argument for @p space. |
| 214 * Then this function will allocate the space and enforce |
214 * Then this function will allocate the space and enforce |
| 215 * the #CX_BUFFER_FREE_CONTENTS flag. In that case, specifying |
215 * the #CX_BUFFER_FREE_CONTENTS flag. In that case, specifying |
| 216 * copy-on-write should be avoided, because the allocated |
216 * copy-on-write should be avoided, because the allocated |
| 217 * space will be leaking after the copy-on-write operation. |
217 * space will be leaking after the copy-on-write operation. |
| 218 * |
218 * |
| 225 * (if @c NULL, the cxDefaultAllocator will be used) |
225 * (if @c NULL, the cxDefaultAllocator will be used) |
| 226 * @param flags buffer features (see cx_buffer_s.flags) |
226 * @param flags buffer features (see cx_buffer_s.flags) |
| 227 * @return zero on success, non-zero if a required allocation failed |
227 * @return zero on success, non-zero if a required allocation failed |
| 228 */ |
228 */ |
| 229 cx_attr_nonnull_arg(1) |
229 cx_attr_nonnull_arg(1) |
| 230 cx_attr_export |
230 CX_EXPORT int cxBufferInit(CxBuffer *buffer, void *space, size_t capacity, |
| 231 int cxBufferInit( |
231 const CxAllocator *allocator, int flags); |
| 232 CxBuffer *buffer, |
|
| 233 void *space, |
|
| 234 size_t capacity, |
|
| 235 const CxAllocator *allocator, |
|
| 236 int flags |
|
| 237 ); |
|
| 238 |
232 |
| 239 /** |
233 /** |
| 240 * Configures the buffer for flushing. |
234 * Configures the buffer for flushing. |
| 241 * |
235 * |
| 242 * Flushing can happen automatically when data is written |
236 * Flushing can happen automatically when data is written |
| 265 * |
255 * |
| 266 * @param buffer the buffer which contents shall be destroyed |
256 * @param buffer the buffer which contents shall be destroyed |
| 267 * @see cxBufferInit() |
257 * @see cxBufferInit() |
| 268 */ |
258 */ |
| 269 cx_attr_nonnull |
259 cx_attr_nonnull |
| 270 cx_attr_export |
260 CX_EXPORT void cxBufferDestroy(CxBuffer *buffer); |
| 271 void cxBufferDestroy(CxBuffer *buffer); |
|
| 272 |
261 |
| 273 /** |
262 /** |
| 274 * Deallocates the buffer. |
263 * Deallocates the buffer. |
| 275 * |
264 * |
| 276 * If the #CX_BUFFER_FREE_CONTENTS feature is enabled, this function also destroys |
265 * If the #CX_BUFFER_FREE_CONTENTS feature is enabled, this function also destroys |
| 277 * the contents. If you @em only want to destroy the contents, use cxBufferDestroy(). |
266 * the contents. If you @em only want to destroy the contents, use cxBufferDestroy(). |
| 278 * |
267 * |
| 279 * @remark As with all free() functions, this accepts @c NULL arguments in which |
|
| 280 * case it does nothing. |
|
| 281 * |
|
| 282 * @param buffer the buffer to deallocate |
268 * @param buffer the buffer to deallocate |
| 283 * @see cxBufferCreate() |
269 * @see cxBufferCreate() |
| 284 */ |
270 */ |
| 285 cx_attr_export |
271 CX_EXPORT void cxBufferFree(CxBuffer *buffer); |
| 286 void cxBufferFree(CxBuffer *buffer); |
|
| 287 |
272 |
| 288 /** |
273 /** |
| 289 * Allocates and initializes a fresh buffer. |
274 * Allocates and initializes a fresh buffer. |
| 290 * |
275 * |
| 291 * You may also provide a read-only @p space, in which case |
276 * You may also provide a read-only @p space, in which case |
| 294 * When you specify stack memory as @p space and decide to use |
279 * When you specify stack memory as @p space and decide to use |
| 295 * the auto-extension feature, you @em must use the |
280 * the auto-extension feature, you @em must use the |
| 296 * #CX_BUFFER_COPY_ON_EXTEND flag, instead of the |
281 * #CX_BUFFER_COPY_ON_EXTEND flag, instead of the |
| 297 * #CX_BUFFER_AUTO_EXTEND flag. |
282 * #CX_BUFFER_AUTO_EXTEND flag. |
| 298 * |
283 * |
| 299 * @note You may provide @c NULL as argument for @p space. |
284 * @note You may provide @c NULL as the argument for @p space. |
| 300 * Then this function will allocate the space and enforce |
285 * Then this function will allocate the space and enforce |
| 301 * the #CX_BUFFER_FREE_CONTENTS flag. |
286 * the #CX_BUFFER_FREE_CONTENTS flag. |
| 302 * |
287 * |
| 303 * @param space pointer to the memory area, or @c NULL to allocate |
288 * @param space pointer to the memory area, or @c NULL to allocate |
| 304 * new memory |
289 * new memory |
| 307 * memory management within the buffer |
292 * memory management within the buffer |
| 308 * (if @c NULL, the cxDefaultAllocator will be used) |
293 * (if @c NULL, the cxDefaultAllocator will be used) |
| 309 * @param flags buffer features (see cx_buffer_s.flags) |
294 * @param flags buffer features (see cx_buffer_s.flags) |
| 310 * @return a pointer to the buffer on success, @c NULL if a required allocation failed |
295 * @return a pointer to the buffer on success, @c NULL if a required allocation failed |
| 311 */ |
296 */ |
| 312 cx_attr_malloc |
297 cx_attr_malloc cx_attr_dealloc(cxBufferFree, 1) cx_attr_nodiscard |
| 313 cx_attr_dealloc(cxBufferFree, 1) |
298 CX_EXPORT CxBuffer *cxBufferCreate(void *space, size_t capacity, |
| 314 cx_attr_nodiscard |
299 const CxAllocator *allocator, int flags); |
| 315 cx_attr_export |
|
| 316 CxBuffer *cxBufferCreate( |
|
| 317 void *space, |
|
| 318 size_t capacity, |
|
| 319 const CxAllocator *allocator, |
|
| 320 int flags |
|
| 321 ); |
|
| 322 |
300 |
| 323 /** |
301 /** |
| 324 * Shifts the contents of the buffer by the given offset. |
302 * Shifts the contents of the buffer by the given offset. |
| 325 * |
303 * |
| 326 * If the offset is positive, the contents are shifted to the right. |
304 * If the offset is positive, the contents are shifted to the right. |
| 327 * If auto extension is enabled, the buffer grows, if necessary. |
305 * If auto extension is enabled, the buffer grows, if necessary. |
| 328 * In case the auto extension fails, this function returns a non-zero value and |
306 * In case the auto extension fails, this function returns a non-zero value and |
| 329 * no contents are changed. |
307 * no contents are changed. |
| 330 * If auto extension is disabled, the contents that do not fit into the buffer |
308 * When the auto extension is disabled, the contents that do not fit into the |
| 331 * are discarded. |
309 * buffer are discarded. |
| 332 * |
310 * |
| 333 * If the offset is negative, the contents are shifted to the left where the |
311 * If the offset is negative, the contents are shifted to the left where the |
| 334 * first @p shift bytes are discarded. |
312 * first @p shift bytes are discarded. |
| 335 * The new size of the buffer is the old size minus the absolute shift value. |
313 * The new size of the buffer is the old size minus the absolute shift value. |
| 336 * If this value is larger than the buffer size, the buffer is emptied (but |
314 * If this value is larger than the buffer size, the buffer is emptied (but |
| 337 * not cleared, see the security note below). |
315 * not cleared, see the security note below). |
| 338 * |
316 * |
| 339 * The buffer position gets shifted alongside with the content but is kept |
317 * The buffer position gets shifted alongside the content but is kept |
| 340 * within the boundaries of the buffer. |
318 * within the boundaries of the buffer. |
| 341 * |
319 * |
| 342 * @note For situations where @c off_t is not large enough, there are specialized cxBufferShiftLeft() and |
320 * @note For situations where @c off_t is not large enough, there are specialized cxBufferShiftLeft() and |
| 343 * cxBufferShiftRight() functions using a @c size_t as parameter type. |
321 * cxBufferShiftRight() functions using a @c size_t as the parameter type. |
| 344 * |
322 * |
| 345 * @attention |
323 * @attention |
| 346 * Security Note: The shifting operation does @em not erase the previously occupied memory cells. |
324 * Security Note: The shifting operation does @em not erase the previously occupied memory cells. |
| 347 * But you can easily do that manually, e.g. by calling |
325 * But you can do that manually by calling |
| 348 * <code>memset(buffer->bytes, 0, shift)</code> for a right shift or |
326 * <code>memset(buffer->bytes, 0, shift)</code> for a right shift or |
| 349 * <code>memset(buffer->bytes + buffer->size, 0, buffer->capacity - buffer->size)</code> |
327 * <code>memset(buffer->bytes + buffer->size, 0, buffer->capacity - buffer->size)</code> |
| 350 * for a left shift. |
328 * for a left shift. |
| 351 * |
329 * |
| 352 * @param buffer the buffer |
330 * @param buffer the buffer |
| 450 * |
410 * |
| 451 * @param buffer the buffer to be cleared |
411 * @param buffer the buffer to be cleared |
| 452 * @see cxBufferClear() |
412 * @see cxBufferClear() |
| 453 */ |
413 */ |
| 454 cx_attr_nonnull |
414 cx_attr_nonnull |
| 455 cx_attr_export |
415 CX_EXPORT void cxBufferReset(CxBuffer *buffer); |
| 456 void cxBufferReset(CxBuffer *buffer); |
|
| 457 |
416 |
| 458 /** |
417 /** |
| 459 * Tests, if the buffer position has exceeded the buffer size. |
418 * Tests, if the buffer position has exceeded the buffer size. |
| 460 * |
419 * |
| 461 * @param buffer the buffer to test |
420 * @param buffer the buffer to test |
| 462 * @retval true if the current buffer position has exceeded the last |
421 * @retval true if the current buffer position has exceeded the last |
| 463 * byte of the buffer's contents |
422 * byte of the buffer's contents |
| 464 * @retval false otherwise |
423 * @retval false otherwise |
| 465 */ |
424 */ |
| 466 cx_attr_nonnull |
425 cx_attr_nonnull cx_attr_nodiscard |
| 467 cx_attr_nodiscard |
426 CX_EXPORT bool cxBufferEof(const CxBuffer *buffer); |
| 468 cx_attr_export |
|
| 469 bool cxBufferEof(const CxBuffer *buffer); |
|
| 470 |
427 |
| 471 |
428 |
| 472 /** |
429 /** |
| 473 * Ensures that the buffer has a minimum capacity. |
430 * Ensures that the buffer has a minimum capacity. |
| 474 * |
431 * |
| 505 * @param buffer the buffer |
458 * @param buffer the buffer |
| 506 * @param reserve the number of bytes that shall remain reserved |
459 * @param reserve the number of bytes that shall remain reserved |
| 507 * @see cxBufferMinimumCapacity() |
460 * @see cxBufferMinimumCapacity() |
| 508 */ |
461 */ |
| 509 cx_attr_nonnull |
462 cx_attr_nonnull |
| 510 cx_attr_export |
463 CX_EXPORT void cxBufferShrink(CxBuffer *buffer, size_t reserve); |
| 511 void cxBufferShrink( |
|
| 512 CxBuffer *buffer, |
|
| 513 size_t reserve |
|
| 514 ); |
|
| 515 |
464 |
| 516 /** |
465 /** |
| 517 * Writes data to a CxBuffer. |
466 * Writes data to a CxBuffer. |
| 518 * |
467 * |
| 519 * If automatic flushing is not enabled, the data is simply written into the |
468 * If automatic flushing is not enabled, the data is simply written into the |
| 520 * buffer at the current position and the position of the buffer is increased |
469 * buffer at the current position, and the position of the buffer is increased |
| 521 * by the number of bytes written. |
470 * by the number of bytes written. |
| 522 * |
471 * |
| 523 * If flushing is enabled and the buffer needs to flush, the data is flushed to |
472 * If flushing is enabled and the buffer needs to flush, the data is flushed to |
| 524 * the target until the target signals that it cannot take more data by |
473 * the target until the target signals that it cannot take more data by |
| 525 * returning zero via the respective write function. In that case, the remaining |
474 * returning zero via the respective write function. In that case, the remaining |
| 526 * data in this buffer is shifted to the beginning of this buffer so that the |
475 * data in this buffer is shifted to the beginning of this buffer so that the |
| 527 * newly available space can be used to append as much data as possible. |
476 * newly available space can be used to append as much data as possible. |
| 528 * |
477 * |
| 529 * This function only stops writing more elements, when the flush target and this |
478 * This function only stops writing more elements when the flush target and this |
| 530 * buffer are both incapable of taking more data or all data has been written. |
479 * buffer are both incapable of taking more data or all data has been written. |
| 531 * |
480 * |
| 532 * If, after flushing, the number of items that shall be written still exceeds |
481 * If, after flushing, the number of items that shall be written still exceeds |
| 533 * the capacity or flush threshold, this function tries to write all items directly |
482 * the capacity or flush threshold, this function tries to write all items directly |
| 534 * to the flush target, if possible. |
483 * to the flush target, if possible. |
| 535 * |
484 * |
| 536 * The number returned by this function is the number of elements from |
485 * The number returned by this function is the number of elements from |
| 537 * @c ptr that could be written to either the flush target or the buffer |
486 * @c ptr that could be written to either the flush target or the buffer. |
| 538 * (so it does not include the number of items that had been already in the buffer |
487 * That means it does @em not include the number of items that were already in |
| 539 * in were flushed during the process). |
488 * the buffer and were also flushed during the process. |
| 540 * |
489 * |
| 541 * @attention |
490 * @attention |
| 542 * When @p size is larger than one and the contents of the buffer are not aligned |
491 * When @p size is larger than one and the contents of the buffer are not aligned |
| 543 * with @p size, flushing stops after all complete items have been flushed, leaving |
492 * with @p size, flushing stops after all complete items have been flushed, leaving |
| 544 * the mis-aligned part in the buffer. |
493 * the misaligned part in the buffer. |
| 545 * Afterward, this function only writes as many items as possible to the buffer. |
494 * Afterward, this function only writes as many items as possible to the buffer. |
| 546 * |
495 * |
| 547 * @note The signature is compatible with the fwrite() family of functions. |
496 * @note The signature is compatible with the fwrite() family of functions. |
| 548 * |
497 * |
| 549 * @param ptr a pointer to the memory area containing the bytes to be written |
498 * @param ptr a pointer to the memory area containing the bytes to be written |
| 612 * @par Example 1 |
551 * @par Example 1 |
| 613 * Assume you have a buffer with size 340 and you are |
552 * Assume you have a buffer with size 340 and you are |
| 614 * at position 200. The flush configuration is |
553 * at position 200. The flush configuration is |
| 615 * @c blkmax=4 and @c blksize=64 . |
554 * @c blkmax=4 and @c blksize=64 . |
| 616 * Assume that the entire flush operation is successful. |
555 * Assume that the entire flush operation is successful. |
| 617 * All 200 bytes on the left hand-side from the current |
556 * All 200 bytes on the left-hand-side from the current |
| 618 * position are written. |
557 * position are written. |
| 619 * That means, the size of the buffer is now 140 and the |
558 * That means the size of the buffer is now 140 and the |
| 620 * position is zero. |
559 * position is zero. |
| 621 * |
560 * |
| 622 * @par Example 2 |
561 * @par Example 2 |
| 623 * Same as Example 1, but now the @c blkmax is 1. |
562 * Same as Example 1, but now the @c blkmax is 1. |
| 624 * The size of the buffer is now 276 and the position is 136. |
563 * The size of the buffer is now 276, and the position is 136. |
| 625 * |
564 * |
| 626 * @par Example 3 |
565 * @par Example 3 |
| 627 * Same as Example 1, but now assume the flush target |
566 * Same as Example 1, but now assume the flush target |
| 628 * only accepts 100 bytes before returning zero. |
567 * only accepts 100 bytes before returning zero. |
| 629 * That means, the flush operations manages to flush |
568 * That means the flush operation manages to flush |
| 630 * one complete block and one partial block, ending |
569 * one complete block and one partial block, ending |
| 631 * up with a buffer with size 240 and position 100. |
570 * up with a buffer with size 240 and position 100. |
| 632 * |
571 * |
| 633 * @remark Just returns zero when flushing was not enabled with |
572 * @remark Just returns zero when flushing was not enabled with |
| 634 * cxBufferEnableFlushing(). |
573 * cxBufferEnableFlushing(). |
| 635 * |
574 * |
| 636 * @remark When the buffer uses copy-on-write, the memory |
575 * @remark When the buffer uses copy-on-write, the memory |
| 637 * is copied first, before attempting any flush. |
576 * is copied first, before attempting any flush. |
| 638 * This is, however, considered an erroneous use of the |
577 * This is, however, considered an erroneous use of the |
| 639 * buffer, because it does not make much sense to put |
578 * buffer because it makes little sense to put |
| 640 * readonly data into an UCX buffer for flushing, instead |
579 * readonly data into an UCX buffer for flushing instead |
| 641 * of writing it directly to the target. |
580 * of writing it directly to the target. |
| 642 * |
581 * |
| 643 * @param buffer the buffer |
582 * @param buffer the buffer |
| 644 * @return the number of successfully flushed bytes |
583 * @return the number of successfully flushed bytes |
| 645 * @see cxBufferEnableFlushing() |
584 * @see cxBufferEnableFlushing() |
| 646 */ |
585 */ |
| 647 cx_attr_nonnull |
586 cx_attr_nonnull |
| 648 cx_attr_export |
587 CX_EXPORT size_t cxBufferFlush(CxBuffer *buffer); |
| 649 size_t cxBufferFlush(CxBuffer *buffer); |
|
| 650 |
588 |
| 651 /** |
589 /** |
| 652 * Reads data from a CxBuffer. |
590 * Reads data from a CxBuffer. |
| 653 * |
591 * |
| 654 * The position of the buffer is increased by the number of bytes read. |
592 * The position of the buffer is increased by the number of bytes read. |
| 662 * @return the total number of elements read |
600 * @return the total number of elements read |
| 663 * @see cxBufferWrite() |
601 * @see cxBufferWrite() |
| 664 * @see cxBufferAppend() |
602 * @see cxBufferAppend() |
| 665 */ |
603 */ |
| 666 cx_attr_nonnull |
604 cx_attr_nonnull |
| 667 cx_attr_export |
605 CX_EXPORT size_t cxBufferRead(void *ptr, size_t size, |
| 668 size_t cxBufferRead( |
606 size_t nitems, CxBuffer *buffer); |
| 669 void *ptr, |
|
| 670 size_t size, |
|
| 671 size_t nitems, |
|
| 672 CxBuffer *buffer |
|
| 673 ); |
|
| 674 |
607 |
| 675 /** |
608 /** |
| 676 * Writes a character to a buffer. |
609 * Writes a character to a buffer. |
| 677 * |
610 * |
| 678 * The least significant byte of the argument is written to the buffer. If the |
611 * The least significant byte of the argument is written to the buffer. If the |
| 679 * end of the buffer is reached and #CX_BUFFER_AUTO_EXTEND feature is enabled, |
612 * end of the buffer is reached and #CX_BUFFER_AUTO_EXTEND feature is enabled, |
| 680 * the buffer capacity is extended by cxBufferMinimumCapacity(). If the feature |
613 * the buffer capacity is extended by cxBufferMinimumCapacity(). If the feature |
| 681 * is disabled or buffer extension fails, @c EOF is returned. |
614 * is disabled or the buffer extension fails, @c EOF is returned. |
| 682 * |
615 * |
| 683 * On successful write, the position of the buffer is increased. |
616 * On successful writing, the position of the buffer is increased. |
| 684 * |
617 * |
| 685 * If you just want to write a null-terminator at the current position, you |
618 * If you just want to write a null-terminator at the current position, you |
| 686 * should use cxBufferTerminate() instead. |
619 * should use cxBufferTerminate() instead. |
| 687 * |
620 * |
| 688 * @param buffer the buffer to write to |
621 * @param buffer the buffer to write to |
| 689 * @param c the character to write |
622 * @param c the character to write |
| 690 * @return the byte that has been written or @c EOF when the end of the stream is |
623 * @return the byte that has been written or @c EOF when the end of the stream is |
| 691 * reached and automatic extension is not enabled or not possible |
624 * reached, and automatic extension is not enabled or not possible |
| 692 * @see cxBufferTerminate() |
625 * @see cxBufferTerminate() |
| 693 */ |
626 */ |
| 694 cx_attr_nonnull |
627 cx_attr_nonnull |
| 695 cx_attr_export |
628 CX_EXPORT int cxBufferPut(CxBuffer *buffer, int c); |
| 696 int cxBufferPut( |
|
| 697 CxBuffer *buffer, |
|
| 698 int c |
|
| 699 ); |
|
| 700 |
629 |
| 701 /** |
630 /** |
| 702 * Writes a terminating zero to a buffer at the current position. |
631 * Writes a terminating zero to a buffer at the current position. |
| 703 * |
632 * |
| 704 * If successful, sets the size to the current position and advances the position by one. |
633 * If successful, sets the size to the current position and advances the position by one. |
| 708 * |
637 * |
| 709 * @param buffer the buffer to write to |
638 * @param buffer the buffer to write to |
| 710 * @return zero, if the terminator could be written, non-zero otherwise |
639 * @return zero, if the terminator could be written, non-zero otherwise |
| 711 */ |
640 */ |
| 712 cx_attr_nonnull |
641 cx_attr_nonnull |
| 713 cx_attr_export |
642 CX_EXPORT int cxBufferTerminate(CxBuffer *buffer); |
| 714 int cxBufferTerminate(CxBuffer *buffer); |
|
| 715 |
643 |
| 716 /** |
644 /** |
| 717 * Writes a string to a buffer. |
645 * Writes a string to a buffer. |
| 718 * |
646 * |
| 719 * This is a convenience function for <code>cxBufferWrite(str, 1, strlen(str), buffer)</code>. |
647 * This is a convenience function for <code>cxBufferWrite(str, 1, strlen(str), buffer)</code>. |
| 720 * |
648 * |
| 721 * @param buffer the buffer |
649 * @param buffer the buffer |
| 722 * @param str the zero-terminated string |
650 * @param str the zero-terminated string |
| 723 * @return the number of bytes written |
651 * @return the number of bytes written |
| 724 */ |
652 */ |
| 725 cx_attr_nonnull |
653 cx_attr_nonnull cx_attr_cstr_arg(2) |
| 726 cx_attr_cstr_arg(2) |
654 CX_EXPORT size_t cxBufferPutString(CxBuffer *buffer, const char *str); |
| 727 cx_attr_export |
|
| 728 size_t cxBufferPutString( |
|
| 729 CxBuffer *buffer, |
|
| 730 const char *str |
|
| 731 ); |
|
| 732 |
655 |
| 733 /** |
656 /** |
| 734 * Gets a character from a buffer. |
657 * Gets a character from a buffer. |
| 735 * |
658 * |
| 736 * The current position of the buffer is increased after a successful read. |
659 * The current position of the buffer is increased after a successful read. |
| 737 * |
660 * |
| 738 * @param buffer the buffer to read from |
661 * @param buffer the buffer to read from |
| 739 * @return the character or @c EOF, if the end of the buffer is reached |
662 * @return the character or @c EOF, if the end of the buffer is reached |
| 740 */ |
663 */ |
| 741 cx_attr_nonnull |
664 cx_attr_nonnull |
| 742 cx_attr_export |
665 CX_EXPORT int cxBufferGet(CxBuffer *buffer); |
| 743 int cxBufferGet(CxBuffer *buffer); |
|
| 744 |
666 |
| 745 #ifdef __cplusplus |
667 #ifdef __cplusplus |
| 746 } |
668 } |
| 747 #endif |
669 #endif |
| 748 |
670 |