C++ TargetRTS
Loading...
Searching...
No Matches
RTFieldDescriptor.h
1/*
2 * Licensed Materials - Property of HCL and/or IBM
3 * Copyright HCL Technologies Ltd. 2016, 2021. 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 __RTFieldDescriptor_h__
11#define __RTFieldDescriptor_h__ included
12
13#ifdef PRAGMA
14#pragma interface
15#endif
16
17#ifndef __RTFieldOffset_h__
18#include <RTFieldOffset.h>
19#endif
20
21class RTDecoding;
22class RTEncoding;
23struct RTObject_class;
24struct RTTypeModifier;
25
26// This structure describes one component of an actor class.
27//
28// Field Meaning
29// ----- -------
30// name The name of the field.
31// offset The byte offset of the field within the containing class,
32// relative to RTActor or RTSequence, as appropriate.
33// type The basic type of the field.
34// modifier Type modifier for common patterns (eg. pointer to type).
35
36// Applied to the first of a group, lookup finds a following
37// descriptor with the given name, or returns nil.
38
40{
41 const char * name;
42 RTFieldOffset offset;
43 const RTObject_class * type;
44 const RTTypeModifier * modifier;
45
46 const RTFieldDescriptor * lookup( int, const char * _name ) const;
47
48 void init( void * record ) const;
49 void copy( void * target_record,
50 const void * source_record ) const;
51#if OBJECT_DECODE
52 int decode( void * record,
53 RTDecoding * ) const;
54#endif
55#if OBJECT_ENCODE
56 int encode( const void * record,
57 RTEncoding * ) const;
58#endif
59 void destroy( void * record ) const;
60};
61
62#endif // __RTFieldDescriptor_h__
Definition: RTDecoding.h:27
Definition: RTEncoding.h:27
Definition: RTFieldDescriptor.h:40
A type descriptor providing information about a type.
Definition: RTObject_class.h:64
Definition: RTTypeModifier.h:33