summaryrefslogtreecommitdiff
path: root/pbstream_lowlevel.h
diff options
context:
space:
mode:
authorJoshua Haberman <joshua@reverberate.org>2009-05-25 18:31:27 -0700
committerJoshua Haberman <joshua@reverberate.org>2009-05-25 18:31:27 -0700
commit0c80c384756a48d5f731eeafa62b6cd5f3861749 (patch)
treec723951c40b0dd7aea5ccd24e9b55fb0167ffb48 /pbstream_lowlevel.h
parentfdcefd68b17a62c7129e910351f5b323044f835d (diff)
A flurry of activity. Doesn't compile yet.
- a descriptor.c that describes the data structures in descriptor.proto using the data structures in descriptor.h. - everything renamed pbstream -> upb. - modularization rethought. - Doesn't compile yet, but should once things settle back down.
Diffstat (limited to 'pbstream_lowlevel.h')
-rw-r--r--pbstream_lowlevel.h51
1 files changed, 0 insertions, 51 deletions
diff --git a/pbstream_lowlevel.h b/pbstream_lowlevel.h
deleted file mode 100644
index c25b16d..0000000
--- a/pbstream_lowlevel.h
+++ /dev/null
@@ -1,51 +0,0 @@
-/*
- * pbstream - a stream-oriented implementation of protocol buffers.
- *
- * Copyright (c) 2008 Joshua Haberman. See LICENSE for details.
- *
- * The structures and functions in this file offer more control than what is
- * offered in pbstream.h. These can be used for more specialized/optimized
- * parsing applications. */
-
-#ifndef PBSTREAM_LOWLEVEL_H_
-#define PBSTREAM_LOWLEVEL_H_
-
-#include "pbstream.h"
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-/* A tag occurs before each value on-the-wire. */
-struct pbstream_tag {
- pbstream_field_number_t field_number;
- pbstream_wire_type_t wire_type;
-};
-
-/* Parses a single tag from the character data starting at buf, and updates
- * buf to point one past the bytes that were consumed. buf will be incremented
- * by at most ten bytes. */
-pbstream_status_t parse_tag(uint8_t **buf, struct pbstream_tag *tag);
-
-/* Parses a wire value with the given type (which must have been obtained from
- * a tag that was just parsed) and adds the number of bytes that were consumed
- * to *offset. */
-pbstream_status_t parse_wire_value(uint8_t *buf, size_t *offset,
- pbstream_wire_type_t wt,
- union pbstream_wire_value *wv);
-
-/* Like the above, but discards the wire value instead of saving it. */
-pbstream_status_t skip_wire_value(uint8_t *buf, size_t *offset,
- pbstream_wire_type_t wt);
-
-/* Looks the given field number up in the fieldset, and returns the
- * corresponding pbstream_field definition (or NULL if this field number
- * does not exist in this fieldset). */
-struct pbstream_field *pbstream_find_field(struct pbstream_fieldset *fs,
- pbstream_field_number_t num);
-
-#ifdef __cplusplus
-} /* extern "C" */
-#endif
-
-#endif /* PBSTREAM_LOWLEVEL_H_ */
generated by cgit on debian on lair
contact matthew@masot.net with questions or feedback