C++ TargetRTS
Loading...
Searching...
No Matches
RTJsonDecoding.h
1/*
2 * Licensed Materials - Property of HCL and/or IBM
3 * Copyright HCL Technologies Ltd. 2016, 2023. All Rights Reserved.
4 * Copyright IBM Corporation 1999, 2016. All Rights Reserved.
5 *
6 * U.S. Government Users Restricted Rights - Use, duplication or
7 * disclosure restricted by GSA ADP Schedule.
8 */
9
10#ifndef __RTJsonDecoding_h__
11#define __RTJsonDecoding_h__ included
12
13#ifdef PRAGMA
14#pragma interface
15#endif
16
17#include <RTAsciiDecoding.h>
18
19#if OBJECT_DECODE
20
22{
23
24public:
25
26 explicit RTJsonDecoding(RTIBuffer *);
27 virtual ~RTJsonDecoding(void);
28
29 virtual int get( void **, const RTObject_class ** ) override;
30
31 // basic data types
32 virtual int get_address ( void * & ) override;
33
34 // an array of characters
35 virtual int get_opaque( int &, char * & ) override;
36
37 // an enumerated value
38 virtual int get_enum( int &, int, const RTFieldDescriptor * ) override;
39
40 // a homogeneous array of objects
41 virtual int get_array( void *, int, const RTObject_class * ) override;
42
43 // an indirect object
44 virtual int get_indirect( void *, const RTObject_class * ) override;
45
46 // a structure
47 virtual int get_struct( void *, const RTObject_class * ) override;
48
49protected:
50 virtual char getCharQuote() override;
51 int getArrayStart( void );
52 int getArrayFinish( void );
53 int getColonSeparator( void );
54 int getFieldName( char *, int );
55
56private:
57 enum { UngetMax = 3 };
58
59 int unget_size;
60 char unget_buffer[ UngetMax ];
61
62 // unavailable methods
64 RTJsonDecoding & operator=( const RTJsonDecoding & );
65
66}; //lint !e1712
67
68#endif // OBJECT_DECODE
69
70#endif // __RTJsonDecoding_h__
The default decoding implementation that is used for all default type descriptors.
Definition: RTAsciiDecoding.h:32
Definition: RTIBuffer.h:22
Definition: RTJsonDecoding.h:22
Definition: RTFieldDescriptor.h:40
A type descriptor providing information about a type.
Definition: RTObject_class.h:64