nostrdb/content_parser: add initial db decoders

We need to pull the data out as well! Let's add some initial decoders.
We still need tests to make sure it's working.

Signed-off-by: William Casarin <jb55@jb55.com>
This commit is contained in:
William Casarin
2023-12-27 14:55:17 -08:00
committed by Daniel D’Aquino
parent c3b06d281e
commit d73422db38
5 changed files with 169 additions and 38 deletions

View File

@@ -198,6 +198,12 @@ struct ndb_builder {
struct ndb_tag *current_tag;
};
/*
struct ndb_block_iterator {
struct note_block block;
};
*/
struct ndb_iterator {
struct ndb_note *note;
struct ndb_tag *tag;
@@ -390,4 +396,6 @@ int ndb_parse_content(unsigned char *buf, int buf_size,
const char *content, int content_len,
struct ndb_note_blocks **blocks_p);
//int ndb_blocks_iterate_next(struct ndb_block_iterator *iter);
#endif