Debian Codegraph @

src/scene/x3d/auto_generated_node_helpers/x3dnodes_logger.inc

raw
1 { -*- buffer-read-only: t -*-
2
3 Copyright 2015-2024 Michalis Kamburelis.
4
5 This file is part of "Castle Game Engine".
6
7 "Castle Game Engine" is free software; see the file COPYING.txt,
8 included in this distribution, for details about the copyright.
9
10 "Castle Game Engine" is distributed in the hope that it will be useful,
11 but WITHOUT ANY WARRANTY; without even the implied warranty of
12 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
13
14 ----------------------------------------------------------------------------
15 }
16
17 { Automatically generated node properties.
18
19 Do not edit this file manually!
20 To add new properties:
21 - add them to the text files in tools/internal/x3d-nodes-to-pascal/nodes-specification/ ,
22 - and regenerate include files by running x3d-nodes-to-pascal }
23
24 {$ifdef read_interface}
25
26 strict private
27 function GetLevel: Integer;
28 procedure SetLevel(const Value: Integer);
29 function GetLogFile: String;
30 procedure SetLogFile(const Value: String);
31 function GetEnabled: Boolean;
32 procedure SetEnabled(const Value: Boolean);
33 public
34 { Create node fields and events. }
35 procedure CreateNode; override;
36 class function ClassX3DType: String; override;
37
38 strict private FFdLevel: TSFInt32;
39 { Internal wrapper for property @code(Level). This wrapper API may change, we advise to access simpler @code(Level) instead, if it is defined (TODO: for now, some field types do not have a simpler counterpart). }
40 public property FdLevel: TSFInt32 read FFdLevel;
41 { }
42 property Level: Integer read GetLevel write SetLevel;
43
44 strict private FFdLogFile: TSFString;
45 { Internal wrapper for property @code(LogFile). This wrapper API may change, we advise to access simpler @code(LogFile) instead, if it is defined (TODO: for now, some field types do not have a simpler counterpart). }
46 public property FdLogFile: TSFString read FFdLogFile;
47 { }
48 property LogFile: String read GetLogFile write SetLogFile;
49
50 strict private FFdEnabled: TSFBool;
51 { Internal wrapper for property @code(Enabled). This wrapper API may change, we advise to access simpler @code(Enabled) instead, if it is defined (TODO: for now, some field types do not have a simpler counterpart). }
52 public property FdEnabled: TSFBool read FFdEnabled;
53 { }
54 property Enabled: Boolean read GetEnabled write SetEnabled;
55
56 strict private FEventWrite: TXFAnyEvent;
57 { }
58 public property EventWrite: TXFAnyEvent read FEventWrite;
59
60 {$endif read_interface}
61
62 {$ifdef read_implementation}
63
64 { TLoggerNode ----------------------------------------------- }
65
66 function TLoggerNode.GetLevel: Integer;
67 begin
68 Result := FdLevel.Value;
69 end;
70
71 procedure TLoggerNode.SetLevel(const Value: Integer);
72 begin
73 FdLevel.Send(Value);
74 end;
75
76 function TLoggerNode.GetLogFile: String;
77 begin
78 Result := FdLogFile.Value;
79 end;
80
81 procedure TLoggerNode.SetLogFile(const Value: String);
82 begin
83 FdLogFile.Send(Value);
84 end;
85
86 function TLoggerNode.GetEnabled: Boolean;
87 begin
88 Result := FdEnabled.Value;
89 end;
90
91 procedure TLoggerNode.SetEnabled(const Value: Boolean);
92 begin
93 FdEnabled.Send(Value);
94 end;
95
96 class function TLoggerNode.ClassX3DType: String;
97 begin
98 Result := 'Logger';
99 end;
100
101 procedure TLoggerNode.CreateNode;
102 begin
103 inherited;
104
105 FFdLevel := TSFInt32.Create(Self, True, 'level', 1);
106 FdLevel.ChangeAlways := chVisibleNonGeometry;
107 AddField(FFdLevel);
108
109 FFdLogFile := TSFString.Create(Self, False, 'logFile', '');
110 FdLogFile.ChangeAlways := chVisibleNonGeometry;
111 AddField(FFdLogFile);
112
113 FFdEnabled := TSFBool.Create(Self, True, 'enabled', true);
114 FdEnabled.ChangeAlways := chVisibleNonGeometry;
115 AddField(FFdEnabled);
116
117 FEventWrite := TXFAnyEvent.Create(Self, 'write', true);
118 AddEvent(FEventWrite);
119 end;
120
121 {$endif read_implementation}