Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
Skip to content

Commit ca05c71

Browse files
author
Nikita Glukhov
committed
Export CompressedJsonbObject
1 parent 35e6d57 commit ca05c71

File tree

2 files changed

+12
-10
lines changed

2 files changed

+12
-10
lines changed

src/backend/utils/adt/jsonb_util.c

-10
Original file line numberDiff line numberDiff line change
@@ -64,16 +64,6 @@ typedef struct CompressedDatum
6464
int decompressed_len;
6565
} CompressedDatum;
6666

67-
typedef struct CompressedJsonb
68-
{
69-
#ifndef JSONB_DETOAST_ITERATOR
70-
CompressedDatum *datum;
71-
#else
72-
DetoastIterator iter;
73-
#endif
74-
int offset;
75-
} CompressedJsonb;
76-
7767
typedef struct JsonbKVMap
7868
{
7969
union

src/include/utils/jsonb_internals.h

+12
Original file line numberDiff line numberDiff line change
@@ -161,4 +161,16 @@ typedef struct
161161
JsonbContainerHeader root;
162162
} JsonbDatum;
163163

164+
typedef struct CompressedJsonb
165+
{
166+
#ifdef NO_JSONB_DETOAST_ITERATOR
167+
CompressedDatum *datum;
168+
#else
169+
DetoastIterator iter;
170+
#endif
171+
int offset;
172+
} CompressedJsonb;
173+
174+
#define jsonbzGetCompressedJsonb(jc) ((CompressedJsonb *) &(jc)->_data)
175+
164176
#endif /* __JSONB_INTERNALS_H__ */

0 commit comments

Comments
 (0)