115 lines
3.8 KiB
XML
Executable file
115 lines
3.8 KiB
XML
Executable file
<?xml version="1.0" encoding="utf-8" ?>
|
|
<!-- DOCTYPE application PUBLIC "-//CYGNETS//DTD ADL 0.1//EN" "http://www.cygnets.co.uk/schemas/adl-0.1.1.dtd" -->
|
|
<!-- DOCTYPE application SYSTEM "file:/C:/Projects/ADL/schemas/adl-0.dtd" -->
|
|
|
|
<!--
|
|
Application Description Language framework
|
|
testapp.adl.xml
|
|
|
|
the object of this file is to exercise as many aspects of ADL as possible;
|
|
it isn't expected to describe an application which does anything useful
|
|
|
|
Copyright (c) 2008 Cygnet Solutions Ltd
|
|
|
|
$Author: sb $
|
|
$Revision: 1.2 $
|
|
$Date: 2008-07-01 16:08:17 $
|
|
-->
|
|
|
|
<application name="ADLTestApp" xmlns="http://cygnets.co.uk/schemas/adl-1.2">
|
|
<content>
|
|
<head>
|
|
|
|
</head>
|
|
<top>
|
|
|
|
</top>
|
|
<foot>
|
|
|
|
</foot>
|
|
</content>
|
|
<typedef name="postcode" type="string" size="10"
|
|
pattern="^([A-PR-UWYZ0-9][A-HK-Y0-9][AEHMNPRTVXY0-9]?[ABEHMNPRVWXY0-9]? {1,2}[0-9][ABD-HJLN-UW-Z]{2}|GIR 0AA)$">
|
|
<documentation>
|
|
a postcode follows arcane rules; this specification from
|
|
http://regexlib.com/REDetails.aspx?regexp_id=260.
|
|
</documentation>
|
|
</typedef>
|
|
<typedef name="age" type="integer" minimum="0" maximum="120">
|
|
<documentation>
|
|
We don't believe people who claim to be over 120.
|
|
</documentation>
|
|
</typedef>
|
|
<group name="public"/>
|
|
<group name="admin" parent="public"/>
|
|
<entity name="Person">
|
|
<property name="LastName" type="string" required="true" size="100" distinct="user">
|
|
<prompt locale="en-UK" prompt="Surname"/>
|
|
</property>
|
|
<property name="ForeNames" type="string" required="true" size="100" distinct="user">
|
|
<prompt locale="en-UK" prompt="Fore names"/>
|
|
</property>
|
|
<property name="Partner" type="entity" entity="Person"/>
|
|
<property name="Gender" type="string" size="1" required="true">
|
|
<option value="M">
|
|
<prompt locale="en-GB" prompt="Male"/>
|
|
</option>
|
|
<option value="F">
|
|
<prompt locale="en-GB" prompt="Female"/>
|
|
</option>
|
|
</property>
|
|
<property name="age" type="defined" typedef="age"/>
|
|
<property name="Address" type="entity" entity="Address" distinct="user"/>
|
|
<property name="Friends" type="link" entity="Person"/>
|
|
<form name="edit" properties="listed">
|
|
<fieldgroup name="Personal Data">
|
|
<documentation>
|
|
Basic data about the person
|
|
</documentation>
|
|
<field property="ForeNames">
|
|
<prompt locale="en-GB" prompt="Fore names"/>
|
|
</field>
|
|
<field property="LastName">
|
|
<prompt locale="en-GB" prompt="Surname"/>
|
|
<help locale="en-GB">
|
|
Family name of this person, conventionally their last name
|
|
</help>
|
|
</field>
|
|
<field property="Partner"/>
|
|
<field property="Gender"/>
|
|
<field property="Address"/>
|
|
</fieldgroup>
|
|
<fieldgroup name="Community">
|
|
<field property="Friends"/>
|
|
</fieldgroup>
|
|
</form>
|
|
</entity>
|
|
<entity name="Address">
|
|
<key>
|
|
<property name="Number" type="string" size="8" distinct="all">
|
|
<prompt locale="en-GB" prompt="House number"/>
|
|
<help locale="en-GB">
|
|
House or building number
|
|
</help>
|
|
</property>
|
|
<property name="Postcode" type="defined" typedef="postcode" required="false" distinct="all">
|
|
<prompt locale="en-UK" prompt="Post code"/>
|
|
</property>
|
|
</key>
|
|
<property name="Address1" type="string" required="true" size="255">
|
|
<prompt locale="en-UK" prompt="Address"/>
|
|
</property>
|
|
<property name="Address2" type="string" required="false" size="255">
|
|
<prompt locale="en-UK" prompt="Line 2"/>
|
|
</property>
|
|
<property name="Address3" type="string" required="false" size="255">
|
|
<prompt locale="en-UK" prompt="Line 3"/>
|
|
</property>
|
|
<property name="City" type="string" required="false" size="255">
|
|
<prompt locale="en-UK" prompt="Post town"/>
|
|
</property>
|
|
<property name="County" type="string" required="false" size="255" />
|
|
<form name="edit" properties="all"/>
|
|
<list name="list" properties="user-distinct"/>
|
|
</entity>
|
|
</application> |