Wgen generates C-Wrapper Objects from an XML input file.
It generates 3 things:
#include "myapp/wrapper/public/Car.h"
...
void test( iONode carnode ) {
...
const char* cartype = wCar.gettype( carnode );
if( StrOp.equals( wCar.TYPE_BEETLE, cartype ) ) {
...
}
...
/* Check the contents of the given node to the wrapper definition. */
Boolean err = wCar.dump( carnode );
...
}
<wrapper modulename="myapp" docname="myapp" title="MyApp Wrappers">
<Car title="Car:" remark="Car wrapper.">
<const name="TYPE_BEETLE" vt="string" val="Beetle"/>
<var name="type" vt="string" defval="Beetle" range="*" remark="Car type."/>
</Ola>
</wrapper>
After running in the directory myapp the command:
The first option must be always the input xml file!
| option | description |
|---|---|
| -all | creates all html documents |
| -lang [en,de,...] | language to use in case of an external description file |
| -desc [descfile] | external description file |
<?xml version="1.0" encoding="ISO-8859-15"?>
<descriptions>
<description id="Car.type">
<de text="Auto Typ"/>
<en text="Car type"/>
</description>
</descriptions>