summaryrefslogtreecommitdiffstats
path: root/doc/src/ecmascript.qdoc
blob: 303b752e7d692480f07080f204e5ad468f4f7d6b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
/****************************************************************************
**
** Copyright (C) 2009 Nokia Corporation and/or its subsidiary(-ies).
** Contact: Qt Software Information (qt-info@nokia.com)
**
** This file is part of the documentation of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** No Commercial Usage
** This file contains pre-release code and may not be distributed.
** You may use this file in accordance with the terms and conditions
** contained in the either Technology Preview License Agreement or the
** Beta Release License Agreement.
**
** GNU Lesser General Public License Usage
** Alternatively, this file may be used under the terms of the GNU Lesser
** General Public License version 2.1 as published by the Free Software
** Foundation and appearing in the file LICENSE.LGPL included in the
** packaging of this file.  Please review the following information to
** ensure the GNU Lesser General Public License version 2.1 requirements
** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
**
** In addition, as a special exception, Nokia gives you certain
** additional rights. These rights are described in the Nokia Qt LGPL
** Exception version 1.0, included in the file LGPL_EXCEPTION.txt in this
** package.
**
** GNU General Public License Usage
** Alternatively, this file may be used under the terms of the GNU
** General Public License version 3.0 as published by the Free Software
** Foundation and appearing in the file LICENSE.GPL included in the
** packaging of this file.  Please review the following information to
** ensure the GNU General Public License version 3.0 requirements will be
** met: http://www.gnu.org/copyleft/gpl.html.
**
** If you are unsure which license is appropriate for your use, please
** contact the sales department at qt-sales@nokia.com.
** $QT_END_LICENSE$
**
****************************************************************************/

/*!
    \page ecmascript.html
    \title ECMAScript Reference
    \ingroup scripting
    \brief A list of objects, functions and properties supported by QtScript.

    This reference contains a list of objects, functions and
    properties supported by QtScript.

    \tableofcontents

    \section1 The Global Object

    \section2 Value Properties

    \list
    \o NaN
    \o Infinity
    \o undefined
    \o Math
    \endlist

    \section2 Function Properties

    \list
    \o eval(x)
    \o parseInt(string, radix)
    \o parseFloat(string)
    \o isNaN(number)
    \o isFinite(number)
    \o decodeURI(encodedURI)
    \o decodeURIComponent(encodedURIComponent)
    \o encodeURI(uri)
    \o encodeURIComponent(uriComponent)
    \endlist

    \section2 Constructor Properties

    \list
    \o Object
    \o Function
    \o Array
    \o String
    \o Boolean
    \o Number
    \o Date
    \o RegExp
    \o Error
    \o EvalError
    \o RangeError
    \o ReferenceError
    \o SyntaxError
    \o TypeError
    \o URIError
    \endlist

    \section1 Object Objects

    \section2 Object Prototype Object

    \list
    \o toString()
    \o toLocaleString()
    \o valueOf()
    \o hasOwnProperty(V)
    \o isPrototypeOf(V)
    \o propertyIsEnumerable(V)
    \endlist

    \section1 Function Objects

    \section2 Function Prototype Object

    \section3 Function Properties

    \list
    \o toString()
    \o apply(thisArg, argArray)
    \o call(thisArg [, arg1 [, arg2, ...]])
    \endlist

    \section1 Array Objects

    \section2 Array Prototype Object

    \section3 Function Properties

    \list
    \o toString()
    \o toLocaleString()
    \o concat([item1 [, item2 [, ...]]])
    \o join(separator)
    \o pop()
    \o push([item1 [, item2 [, ...]]])
    \o reverse()
    \o shift()
    \o slice(start, end)
    \o sort(comparefn)
    \o splice(start, deleteCount[, item1 [, item2 [, ...]]])
    \o unshift([item1 [, item2 [, ...]]])
    \endlist

    \section1 String Objects

    \section2 String Prototype Object

    \section3 Function Properties

    \list
    \o toString()
    \o valueOf()
    \o charAt(pos)
    \o charCodeAt(pos)
    \o concat([string1 [, string2 [, ...]]])
    \o indexOf(searchString ,position)
    \o lastIndexOf(searchString, position)
    \o localeCompare(that)
    \o match(regexp)
    \o replace(searchValue, replaceValue)
    \o search(regexp)
    \o slice(start, end)
    \o split(separator, limit)
    \o substring(start, end)
    \o toLowerCase()
    \o toLocaleLowerCase()
    \o toUpperCase()
    \o toLocaleUpperCase()
    \endlist

    \section1 Boolean Objects

    \section2 Boolean Prototype Object

    \section3 Function Properties

    \list
    \o toString()
    \o valueOf()
    \endlist

    \section1 Number Objects

    \section2 Number Prototype Object

    \section3 Function Properties

    \list
    \o toString(radix)
    \o toLocaleString()
    \o toFixed(fractionDigits)
    \o toExponential(fractionDigits)
    \o toPrecision(precision)
    \endlist

    \section1 The Math Object

    \section2 Value Properties

    \list
    \o E
    \o LN10
    \o LN2
    \o LOG2E
    \o LOG10E
    \o PI
    \o SQRT1_2
    \o SQRT2
    \endlist

    \section2 Function Properties

    \list
    \o abs(x)
    \o acos(x)
    \o asin(x)
    \o atan(x)
    \o atan2(y, x)
    \o ceil(x)
    \o cos(x)
    \o exp(x)
    \o floor(x)
    \o log(x)
    \o max([value1 [, value2 [, ...]]])
    \o min([value1 [, value2 [, ...]]])
    \o pow(x, y)
    \o random()
    \o round(x)
    \o sin(x)
    \o sqrt(x)
    \o tan(x)
    \endlist

    \section1 Date Objects

    \section2 Date Prototype Object

    \section3 Function Properties

    \list
    \o toString()
    \o toDateString()
    \o toTimeString()
    \o toLocaleString()
    \o toLocaleDateString()
    \o toLocaleTimeString()
    \o valueOf()
    \o getTime()
    \o getFullYear()
    \o getUTCFullYear()
    \o getMonth()
    \o getUTCMonth()
    \o getDate()
    \o getUTCDate()
    \o getDay()
    \o getUTCDay()
    \o getHours()
    \o getUTCHours()
    \o getMinutes()
    \o getUTCMinutes()
    \o getSeconds()
    \o getUTCSeconds()
    \o getMilliseconds()
    \o getUTCMilliseconds()
    \o getTimeZoneOffset()
    \o setTime(time)
    \o setMilliseconds(ms)
    \o setUTCMilliseconds(ms)
    \o setSeconds(sec [, ms])
    \o setUTCSeconds(sec [, ms])
    \o setMinutes(min [, sec [, ms]])
    \o setUTCMinutes(min [, sec [, ms]])
    \o setHours(hour [, min [, sec [, ms]]])
    \o setUTCHours(hour [, min [, sec [, ms]]])
    \o setDate(date)
    \o setUTCDate(date)
    \o setMonth(month [, date])
    \o setUTCMonth(month [, date])
    \o setFullYear(year [, month [, date]])
    \o setUTCFullYear(year [, month [, date]])
    \o toUTCString()
    \endlist

    \section1 RegExp Objects

    \section2 RegExp Prototype Object

    \section3 Function Properties

    \list
    \o exec(string)
    \o test(string)
    \o toString()
    \endlist

    \section1 Error Objects

    \section2 Error Prototype Object

    \section3 Value Properties

    \list
    \o name
    \o message
    \endlist

    \section3 Function Properties

    \list
    \o toString()
    \endlist

*/