Pascal Doc
Source: test1.pas
Search
Unit Dependencies
Interface Uses
Source Code
1
(**!2
* @mainpage Mein Projekt3
*4
* Willkommen in der Dokumentation.5
*6
* @section Übersicht7
* Diese Engine erzeugt Pascal-Dokumentation.8
*9
* @subsection Features10
* Klassen, Interfaces, Records und Typverlinkungen.11
*12
* @subsubsection Details13
* Später kommen Graphviz, Call-Graphs und Unit-Dependencies dazu.14
*)15
16
(**!17
* @defgroup IntVariables Das sind die Integer Variablen18
* @{19
*)20
21
(**!22
* Text innerhalb der Gruppe.23
*)24
25
(**!26
* @class VirtualClass27
* @brief eine virtuelle Klasse28
*)29
30
(**!31
* @defgroup IntS Das sind die Integer Variable S32
* @{33
*)34
35
(**!36
* Text der Untergruppe.37
*)38
39
(**!40
* @}41
*)42
43
(**!44
* @}45
*)46
unit TestUnit;47
48
interface49
50
uses51
Objects (**! @brief Base classes of all others *),52
SysUtils (**! @brief System Utils function's *),53
Classes (**! @brief Pascal Class'es *),54
Dialogs;55
56
const57
(**!58
* @brief Maximale Anzahl.59
*60
* Dieser Wert begrenzt die Verarbeitung.61
*)62
MAX_COUNT = 100;63
64
const65
PI_VALUE = 3.1415 ; (**! @brief This is the documentation for the PI const *)66
APP_NAME = 'MyApp'; (**! @brief This is the application name *)67
APP_VERSION = $1001 ; (**! @brief This is the Version *)68
69
var70
(**! @brief Player values *)71
score_board : Integer; (**! @brief point score board *)72
score_text : string; (**! @brief player name text *)73
74
(**! @brief Window values *)75
main_width : Integer;76
main_height : Integer;77
78
type79
(**!80
* @brief Beispiel-Record.81
* @details Dieser Record speichert X- und Y-Werte.82
*)83
TPoint = record84
X: Integer;85
(**!86
* @brief give the X position87
* @details blah blah about X pos field88
*)89
Y: Integer; (**! @brief give the Y position *)90
end;91
92
TIntArray = array[0..10] of Integer; (**! @brief this is a integer array 0 .. 10 *)93
TCharSet = set of Char; (**! @brief a char set *)94
95
type96
TCard = (One, Two, Three); (**! @brief available cards *)97
98
type99
TColor = (100
Red, (**! @brief red color *)101
Green, (**! @brief green color *)102
Blue (**! @brief blue color *)103
); (**! @brief available colors *)104
105
type106
(**!107
* @brief Basisklasse.108
*109
* Dies ist die ausführliche Beschreibung der Basisklasse.110
*)111
TBaseClass = class112
public113
procedure BaseMethod;114
end;115
116
(**! @brief Abgeleitete Klasse *)117
TChildClass = class(TBaseClass)118
public119
procedure ChildMethod;120
end;121
122
type123
(**!124
* @brief Beispiel-Interface.125
* @details Dies ist eine längere Beschreibung126
* für das Interface.127
*)128
IExample = interface129
procedure Execute;130
end;131
132
(**!133
* @brief Beispielklasse.134
*135
* Diese Klasse zeigt @brief und automatische Details.136
*)137
TExampleClass = class(TBaseClass, IExample)138
public139
(**!140
* @brief Führt die Aktion aus.141
*142
* Diese Methode implementiert die Interface-Methode.143
*)144
procedure Execute;145
end;146
147
type148
(**! @brief Basis-Interface für zeichnbare Objekte *)149
IDrawable = interface150
(**! @brief Zeichnet das Objekt *)151
procedure Draw;152
153
(**! @brief Sichtbarkeit des Objekts *)154
property Visible: Boolean155
read FVisible (**! @brief Liefert den Sichtbarkeitsstatus *)156
write FVisible (**! @brief Setzt den Sichtbarkeitsstatus *);157
end;158
159
(**! @brief Interface für geometrische Formen *)161
(**! @brief Berechnet die Fläche *)162
function Area: Double;163
164
(**! @brief Name der Form *)165
property Name: string166
read FName (**! @brief Liefert den Namen *)167
write FName (**! @brief Setzt den Namen *);168
end;169
170
(**! @brief Generisches Listen-Interface *)171
IList<T> = interface172
(**! @brief Fügt ein Element hinzu *)173
procedure Add(Item: T);174
175
(**! @brief Liefert ein Element anhand des Index *)176
function GetItem(Index: Integer): T;177
178
(**! @brief Anzahl der Elemente *)179
property Count: Integer read FCount (**! @brief Liefert die Anzahl *);180
end;181
182
type183
(**! @brief Sprite class implementing IDrawable *)185
public186
procedure Draw;187
end;188
189
type190
TWeapon = class191
end;192
193
TInventory = class194
end;195
196
IRenderable = interface197
procedure Render;198
end;199
200
TPlayer = class(TObject, IRenderable)201
private203
FInventory: TInventory;204
public206
procedure Render;207
end;208
209
type210
(**!211
* @brief This is the TPerson class212
*)214
private215
FName: string;216
FAge: Integer;217
protected218
procedure Paint;219
public220
(**!221
* @brief Erzeugt ein neues Objekt222
* @details This is the default constructor.223
*)224
constructor Create; overload;225
(**!226
* @brief Erzeugt ein neues Objekt mit einen string.227
* @details This is the constructor with a string.228
*)229
constructor Create(S1: String); overload;231
destructor Destroy; override;232
(**!233
* @brief Speichert die aktuellen Daten234
*235
* @param S1 string 1236
* @param S2 string 2237
*238
* @note Wird intern gecached.239
* @info Diese Methode ist thread-safe.240
* @warn X und Y dürfen nicht negativ sein.241
*)242
procedure Save(S1: string; S2: string); virtual;244
(**!245
* @brief Get the name of the class246
* @return string - Ein String als Rückgabe247
*)248
function GetName: string;249
property Name: string (**! @brief Datentyp *)250
read FName (**! @brief getter of Name *)251
write FName (**! @brief setter of Name *);252
end;253
254
type255
(**! @brief Generic list interface *)256
IList<T> = interface257
(**! @brief Add one item to the list *)258
procedure Add(Item: T);259
260
(**! @brief Get item by index *)261
function GetItem(Index: Integer): T;262
263
property Count: Integer (**! @brief number datatype *)264
read GetCount (**! @brief returns item count *);265
end;266
267
(**! @brief Generic key value pair record *)268
TPair<TKey, TValue> = record269
Key : TKey; (**! @brief key value *)270
Value : TValue; (**! @brief stored value *)271
end;272
273
(**! @brief Generic repository class *)274
TRepository<T> = class275
private277
278
public279
(**! @brief Add entity *)280
procedure Add(Entity: T);281
282
(**! @brief Find entity by id *)283
function FindById(Id: Integer): T;284
286
read FItems (**! @brief returns internal list *);287
end;288
289
(**!290
* @class TVirtualClass291
* @brief Virtuelle Klasse292
* @details Diese Klasse existiert nur in der Dokumentation.293
*294
* A list of events:295
* - mouse events296
* -# mouse move event297
* -# mouse click event\n298
* More info about the click event.299
* -# mouse double click event300
* - keyboard events301
* 1. key down event302
* 2. key up event303
* - checkbox list304
* - [ ] unchecked305
* - [x] checked306
*307
* More text here.308
*309
*310
* | Name | Type | Description |311
* |------|------|-------------|312
* | X | Integer | Position X |313
* | Y | Integer | Position Y |314
*315
* @code316
* procedure Test;317
* begin318
* WriteLn('Hallo');319
* end;320
* @endcode321
*)322
323
(**!324
* @interface IVirtualInterface325
* @brief Virtuelles Interface326
*)327
328
(**!329
* @record TVirtualRecord330
* @brief Virtueller Record331
*)332
333
(**!334
* @enum TVirtualEnum335
* @brief Virtuelles Enum336
* @details337
*338
* :icon-info: Das ist eine Information.339
* :icon-alert: Das ist eine Warnung.340
*341
* @icon check Erfolgreich abgeschlossen.342
* @icon bug Bekannter Fehler.343
*)344
345
implementation346
347
uses348
Windows (**! @brief Windows XP System stuff *),349
VCL (**! @brief Visual Control Library *),350
Forms (**! @brief Window Forms stuff *);351
352
procedure TExampleClass.Execute;353
begin354
end;355
356
end.