~maphew/mindtouch-deki/dekiwiki

« back to all changes in this revision

Viewing changes to src/services/Scripts/res/isomorphic/8.1/system/schema/builtinTypes.xml

  • Committer: aaronm
  • Date: 2011-09-28 23:16:51 UTC
  • Revision ID: svn-v4:0eb84ffb-6e0e-0410-b475-cc1b69d517b7:public/dekiwiki/trunk:29562
Feature: CS-42 Add Isomorphic SmartClient library to fake cdn to facilitate skinning work

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
<!-- 
 
2
This file defines the special set of built-in types in the DataSource system.  This file is
 
3
processed by schemaless XML transform, and in fact, can't even rely on the existance of the basic
 
4
types (since it defines them!)
 
5
-->
 
6
<simpleTypes>
 
7
    <!-- the most basic type, means either a simple or complete type is allowed -->
 
8
    <any uberType="true"/>
 
9
 
 
10
    <boolean validators="isBoolean"/>
 
11
    <!-- actually creates a Long in Java -->
 
12
    <integer validators="isInteger"/>
 
13
    <!-- actually creates a Double in Java -->
 
14
    <float validators="isFloat"/>
 
15
    <date validators="isDate"/>
 
16
    <time validators="isTime"/>
 
17
 
 
18
    <!-- synonyms of basic types 
 
19
         note: synonyms should inheritFrom the canonical name for the type, even if the base type
 
20
         definition is trivial, so that the equivalent of "instanceof" checks will detect them as
 
21
         being of the same base type
 
22
    -->
 
23
    <text validators="isString"/>
 
24
    <string inheritsFrom="text"/>
 
25
    <int inheritsFrom="integer"/>
 
26
    <long inheritsFrom="integer"/>
 
27
    <number inheritsFrom="integer"/>
 
28
    <decimal inheritsFrom="float"/>
 
29
    <double inheritsFrom="float"/>
 
30
    <dateTime inheritsFrom="date"/>
 
31
    <datetime inheritsFrom="date"/>
 
32
 
 
33
    <!-- Integer variants -->
 
34
    <!--===================================================================================-->
 
35
    <positiveInteger inheritsFrom="integer">
 
36
        <validators>
 
37
            <type>integerRange</type>
 
38
            <min>0</min>
 
39
        </validators>
 
40
    </positiveInteger>
 
41
 
 
42
    <integerPercent inheritsFrom="integer">
 
43
        <validators>
 
44
            <type>integerRange</type>
 
45
            <min>0</min>
 
46
            <max>100</max>
 
47
        </validators>
 
48
    </integerPercent>
 
49
    <!-- synonym -->
 
50
    <percent inheritsFrom="integerPercent"/>
 
51
 
 
52
    <!-- database sequence.  Has special semantics for SQL DataSources. -->
 
53
    <sequence inheritsFrom="integer"/>
 
54
    
 
55
    <!-- Other types -->
 
56
    <!--===================================================================================-->
 
57
    <!--  -->
 
58
    <enum inheritsFrom="any"/>
 
59
    <intEnum inheritsFrom="integer">
 
60
    </intEnum>
 
61
 
 
62
 
 
63
    <char inheritsFrom="text"/>
 
64
 
 
65
    <!-- regexp is a string which must be a valid regular expression -->
 
66
    <regexp inheritsFrom="text" validators="isRegexp"/>
 
67
 
 
68
    <identifier inheritsFrom="text" validators="isIdentifier"/>
 
69
 
 
70
    <!-- We have a URL validator ("isURL"), but it currently accepts only absolute URLs (must have
 
71
         protocol!)  -->
 
72
    <URL inheritsFrom="text"/>
 
73
    <url inheritsFrom="text"/>
 
74
 
 
75
    <!-- XPath is a string.  Note, no actual validator yet -->
 
76
    <XPath inheritsFrom="text"/>
 
77
 
 
78
    <HTMLString inheritsFrom="text"/>
 
79
    <!-- synonyms -->
 
80
    <HTML inheritsFrom="text"/>
 
81
    <html inheritsFrom="HTML"/>
 
82
 
 
83
    <!-- HTML/JS specific -->
 
84
    <!-- These types should really only be present when doing XML -> JS translation.  At the 
 
85
         moment all types are in one flat namespace; these should be global types in a 
 
86
         namespace specific to HTML/JS translation -->
 
87
    <!--===================================================================================-->
 
88
 
 
89
    <!-- an HTML size value: integer, integer percent, integer + "*", or "auto" -->
 
90
    <measure validators="isMeasure"/>
 
91
 
 
92
    <!-- an integer, or the value "auto" -->
 
93
    <integerOrAuto validators="integerOrAuto"/>
 
94
 
 
95
    <!-- at the moment these types are just "markers" for documentation purposes, or to indicate
 
96
         special handling on the client.  No special processing on the server. -->
 
97
    <!-- responds to some event (eg cellOver) -->
 
98
    <handler inheritsFrom="text"/>
 
99
    <!-- override point to provide some customized value (eg getCellValue) -->
 
100
    <callback inheritsFrom="text"/>
 
101
    <!-- sets a property, usually with side effects (eg setFacetTitleAlign) -->
 
102
    <action inheritsFrom="text"/>
 
103
    <!-- sets a property, usually with side effects (eg setFacetTitleAlign) -->
 
104
    <setter inheritsFrom="text"/>
 
105
    <!-- gets state (eg getRowFacetLayout) -->
 
106
    <getter inheritsFrom="text"/>
 
107
    <!-- tests state (eg cellIsSelected) -->
 
108
    <tester inheritsFrom="text"/>
 
109
    <!-- generic term for a method when none of the above apply -->
 
110
    <method inheritsFrom="text"/>
 
111
    <!-- synonym for method -->
 
112
    <function inheritsFrom="text"/>
 
113
    <!-- could indicate a stringMethod when none of the above apply -->
 
114
    <expression inheritsFrom="text"/>
 
115
    <!-- indicates a name of a class -->
 
116
    <className inheritsFrom="text"/>
 
117
 
 
118
    <valignEnum inheritsFrom="enum">
 
119
        <valueMap top="top" center="center" bottom="bottom"/>
 
120
    </valignEnum>
 
121
    <alignEnum inheritsFrom="enum">
 
122
        <valueMap left="left" center="center" right="right"/>
 
123
    </alignEnum>
 
124
    <sideEnum inheritsFrom="enum">
 
125
        <valueMap left="left" right="right" top="top" bottom="bottom"/>
 
126
    </sideEnum>
 
127
 
 
128
    <!-- a CSS color value or color name -->
 
129
    <color inheritsFrom="string">
 
130
        <validators>
 
131
            <type>isColor</type>
 
132
            <clientOnly>true</clientOnly>
 
133
        </validators>
 
134
    </color>
 
135
 
 
136
    <!-- a CSS color value or color name -->
 
137
    <cssClass inheritsFrom="string"/>
 
138
    
 
139
    <modifier inheritsFrom="text" hidden="true" canEdit="false"/>
 
140
    <modifierTimestamp inheritsFrom="datetime" hidden="true" canEdit="false"/>
 
141
    <creator inheritsFrom="text" hidden="true" canEdit="false"/>
 
142
    <creatorTimestamp inheritsFrom="datetime" hidden="true" canEdit="false"/>
 
143
    
 
144
</simpleTypes>