From 01c956d68a0d9d3d2c6bf882959ba1f8e9099719 Mon Sep 17 00:00:00 2001 From: Andrew Frost Date: Tue, 9 Jul 2024 05:21:50 +0100 Subject: [PATCH] Documentation updates for AIR SDK 51.0.1.4 Adding BitmapData.convertColorProfile() Updating ELS documentation Correcting ScriptTimeoutError and StackOverflowError Updating new AS3 operators to AS '3.1' Updating NativeWindow documentation for mobile OS --- .../actionscript/3.0/all-index-C.html | 16 +- .../actionscript/3.0/all-index-I.html | 20 +- .../actionscript/3.0/all-index-S.html | 33 +- .../actionscript/3.0/class-summary.html | 50 ++- .../3.0/flash/data/EncryptedLocalStore.html | 290 ++++++++++++++++-- .../3.0/flash/display/BitmapData.html | 90 +++++- .../3.0/flash/display/NativeWindow.html | 65 ++-- .../3.0/flash/errors/InvalidSWFError.html | 72 ++++- .../3.0/flash/errors/ScriptTimeoutError.html | 143 ++++++++- .../3.0/flash/errors/StackOverflowError.html | 130 +++++++- .../3.0/flash/errors/package-detail.html | 17 +- .../reference/actionscript/3.0/operators.html | 10 +- .../reference/actionscript/3.0/whatsnew.html | 24 +- 13 files changed, 845 insertions(+), 115 deletions(-) diff --git a/static/reference/actionscript/3.0/all-index-C.html b/static/reference/actionscript/3.0/all-index-C.html index 1005619bf..33de1929c 100644 --- a/static/reference/actionscript/3.0/all-index-C.html +++ b/static/reference/actionscript/3.0/all-index-C.html @@ -3745,6 +3745,16 @@ The conversion mode of the current IME. +convertColorProfile(source:flash.display:Screen, destination:flash.display:Screen) — Method in class flash.display.BitmapData + + + + + Create a copy of the image data, converting between color profiles based on the provided + + Screen objects. + + converted — Property in class flash.text.ime.CompositionAttributeRange @@ -4734,11 +4744,11 @@

- + - + diff --git a/static/reference/actionscript/3.0/all-index-I.html b/static/reference/actionscript/3.0/all-index-I.html index 91b1ffe70..8d20edd63 100644 --- a/static/reference/actionscript/3.0/all-index-I.html +++ b/static/reference/actionscript/3.0/all-index-I.html @@ -1222,7 +1222,16 @@ - Flash Player throws this exception when it encounters a corrupted SWF file. + + The Flash runtimes throw this exception when they encounter a corrupted SWF file. + + +InvalidSWFError(message:String, id:int) — Constructor in class flash.errors.InvalidSWFError + + + + + Creates a new InvalidSWFError object. invert() — Method in class flash.geom.Matrix @@ -1932,8 +1941,11 @@ + The isSupported property is set to true if the + EncryptedLocalStore class is supported on the current platform, otherwise it is + set to false. @@ -2323,11 +2335,11 @@

- + - + diff --git a/static/reference/actionscript/3.0/all-index-S.html b/static/reference/actionscript/3.0/all-index-S.html index f008796fc..f2716ddd3 100644 --- a/static/reference/actionscript/3.0/all-index-S.html +++ b/static/reference/actionscript/3.0/all-index-S.html @@ -378,7 +378,17 @@ ScriptTimeoutError — Dynamic class in package flash.errors - + + + The ScriptTimeoutError exception is thrown when the script timeout interval is reached. + + +ScriptTimeoutError(message:String) — Constructor in class flash.errors.ScriptTimeoutError + + + + + Creates a new ScriptTimeoutError object. scroll(x:int, y:int) — Method in class flash.display.BitmapData @@ -1446,6 +1456,7 @@ + Stores a ByteArray object under the specified name. @@ -3576,7 +3587,19 @@ StackOverflowError — Dynamic class in package flash.errors - + + + ActionScript throws a StackOverflowError exception when the stack available to the script + + is exhausted. + + +StackOverflowError(message:String) — Constructor in class flash.errors.StackOverflowError + + + + + Creates a new StackOverflowError object. stackTrace — Property in class flash.events.HTMLUncaughtScriptExceptionEvent @@ -6228,11 +6251,11 @@

- + - + diff --git a/static/reference/actionscript/3.0/class-summary.html b/static/reference/actionscript/3.0/class-summary.html index 915b56ee3..de881df17 100644 --- a/static/reference/actionscript/3.0/class-summary.html +++ b/static/reference/actionscript/3.0/class-summary.html @@ -462,6 +462,7 @@  Context3D
flash.display3D + The Context3D class provides a context for rendering geometrically defined graphics. @@ -629,13 +630,16 @@  DataEvent
flash.events + An object dispatches a DataEvent object when raw data has completed loading.  DatagramSocket
flash.net + The DatagramSocket class enables code to send and receive + Universal Datagram Protocol (UDP) packets. @@ -714,6 +718,7 @@  Digest
air.security + The Digest class is used to generate a digest, or hash, of some data. @@ -910,14 +915,18 @@  EncryptedLocalStore
flash.data + The EncryptedLocalStore class (ELS) provides an encrypted local storage mechanism + that can be used as a small cache for an application's private data.  Encryption
air.security + The Encryption class is used to encrypt and decrypt ByteArray objects + using industry-standard AES-CBC algorithms. @@ -998,6 +1007,7 @@  File
flash.filesystem + A File object represents a path to a file or directory. @@ -1069,12 +1079,14 @@  Font
flash.text + The Font class is used to manage embedded fonts in SWF files.  FontDescription
flash.text.engine + The FontDescription class represents the information necessary to describe a font. @@ -1550,7 +1562,9 @@  InteractiveObject
flash.display + The InteractiveObject class is the abstract base class for all display objects with which the user can + interact, using the mouse, keyboard, or other user input device. @@ -1571,7 +1585,8 @@  InvalidSWFError
flash.errors - Flash Player throws this exception when it encounters a corrupted SWF file. + + The Flash runtimes throw this exception when they encounter a corrupted SWF file.  InvokeEvent @@ -1704,7 +1719,9 @@  License
air.system + The License class is used to provide information about the AIR SDK license, + for a running application. @@ -1881,6 +1898,7 @@  MouseEvent
flash.events + A MouseEvent object is dispatched into the event flow whenever mouse events occur. @@ -2175,7 +2193,9 @@  NetworkInfo
flash.net + The NetworkInfo class provides information about the network + interfaces on a computer. @@ -2527,7 +2547,9 @@  ScriptTimeoutError
-flash.errors  +flash.errors + + The ScriptTimeoutError exception is thrown when the script timeout interval is reached.  SecureSocket @@ -2562,7 +2584,9 @@  SecurityErrorEvent
flash.events + An object dispatches a SecurityErrorEvent object to report the occurrence of a + security error. @@ -2692,7 +2716,9 @@  Socket
flash.net + The Socket class enables code to establish Transport Control Protocol (TCP) socket + connections for sending and receiving binary data. @@ -2916,7 +2942,11 @@  StackOverflowError
-flash.errors  +flash.errors + + ActionScript throws a StackOverflowError exception when the stack available to the script + + is exhausted.  Stage @@ -3041,6 +3071,7 @@  StageWebView
flash.media + The StageWebView class displays HTML content in a stage view port. @@ -3221,6 +3252,7 @@  TextField
flash.text + The TextField class is used to create display objects for text display and input. @@ -3459,7 +3491,9 @@  URLLoader
flash.net + The URLLoader class downloads data from a URL + as text, binary data, or URL-encoded variables. @@ -3499,7 +3533,9 @@  URLStream
flash.net + The URLStream class provides low-level access to + downloading URLs. @@ -3544,6 +3580,7 @@  VertexBuffer3D
flash.display3D + The VertexBuffer3D class represents a set of vertex data uploaded to a rendering context. @@ -3610,13 +3647,16 @@  WebSocket
air.net + The WebSocket class is a utility that encapsulates a normal Socket object + and implements the WebSocket protocol (RFC 6455).  WebSocketEvent
flash.events + An event that contains data received from a WebSocket object. @@ -3727,8 +3767,8 @@

- + - + diff --git a/static/reference/actionscript/3.0/flash/data/EncryptedLocalStore.html b/static/reference/actionscript/3.0/flash/data/EncryptedLocalStore.html index f821d8fb1..6b57603a5 100644 --- a/static/reference/actionscript/3.0/flash/data/EncryptedLocalStore.html +++ b/static/reference/actionscript/3.0/flash/data/EncryptedLocalStore.html @@ -46,136 +46,271 @@

- +
Language version: ActionScript 3.0 Language version: ActionScript 3.0 +
Runtime version: AIR 1.0 +

+ The EncryptedLocalStore class (ELS) provides an encrypted local storage mechanism + that can be used as a small cache for an application's private data. + +

ELS data cannot be shared between applications. The intent of ELS is to allow an + application to store easily recreated items such as login credentials and other private information. + ELS data should not be considered as permanent; + see "Limitations of the encrypted local store" and "Best practices for using ELS." below. +

-

AIR profile support: This feature is not supported on AIR for TV devices. You can test + + +

AIR profile support: This feature is not supported on AIR for TV devices. You can test + for support at run time using the EncryptedLocalStore.isSupported property. See + + AIR Profile Support for more information regarding API support across multiple profiles.

+ +

AIR provides an encrypted local store (ELS) for each AIR application installed on + a user's computer or device. This lets you save and retrieve data that is - stored on the user’s local hard drive in an encrypted format that + + stored on the user's local hard drive in an encrypted format that + cannot easily be deciphered by other users. A separate encrypted + local store is used for each AIR application, and each AIR application + uses a separate encrypted local store for each user account on the computer.

+ +

Use the encrypted local store to cache information + that must be secured, such as login credentials for web services. + The ELS is appropriate for storing information that must be kept + private from other users. It does not, however, protect the data + from other processes run under the same user account. It is thus + not appropriate for protecting secret application data, such as DRM + or encryption keys.

+ -

AIR uses - DPAPI on Windows, KeyChain on Mac OS and iOS, and KeyRing or KWallet on Linux to associate - the encrypted local store to each application and user. - The encrypted local store uses AES-CBC 128-bit encryption.

+ +

AIR uses platform-specific storage mechanisms in order to secure the key to the ELS file. + + Internally it then uses AES-CBC 256- bit encryption to secure the data. This same approach + + is now used across all platforms/operating systems.

+ -

On Android, the data stored by the EncryptedLocalStorage class are not encrypted. - Instead the data is protected by the user-level security provided by the operating system. - The Android operating system assigns every application a separate user ID. - Applications can only access their own files and files created in public locations - (such as the removable storage card). Note that on rooted Android devices, applications - running with root privileges can access the files of other applications. - Thus on a rooted device, the encrypted local store does not provide as high a level of - data protection as it does on on a non-rooted device. -

+ +

With AIR 51.0, a new mechanism is being used, but if a getItem call fails to + + find the item in the new store, the older mechanism will be queried instead. When setItem + + is called, the item will be set in the new store, and removed from the old. In a future update + + of AIR, this fallback mechanism will be removed, so it would be necessary for applications to update + + through a 51.x version if they want to migrate the data.

+ +

Information in the encrypted local store is only available to + AIR application content in the application security sandbox.

+ +

If you update an AIR application, the updated version retains + access to any existing data in the encrypted local store unless:

+ + + +

Limitations of the encrypted local store

+

The - data in the encrypted local store is protected by the user’s operating + + data in the encrypted local store is protected by the user's operating + system account credentials. Other entities cannot access the data + in the store unless they can login as that user. However, the data + is not secure against access by other applications run by an authenticated + user. Thus, data that your application + may want to keep secret from users, such as keys used for licensing + or digital rights management, is not secure. The ELS is not + an appropriate location for storing such information. It is only - an appropriate place for storing a user’s private data, such as - passwords.

+ + an appropriate place for storing a user's private data, such as + + passwords. Note that the relevant user will normally have the access + + rights to be able to view the key that AIR uses to secure their ELS files.

+ +

Data in the ELS can be lost for a variety of reasons. + For example, the user could uninstall the application and delete + the encrypted file. Or, the publisher ID could be changed as a result + of an update. Thus the ELS should be treated as a private cache, + not permanent data storage.

+ +

The stronglyBound parameter + is deprecated and should not be set to true. Setting + the parameter to true does not provide any additional + protection for data. At the same time, access to the data is lost - whenever the application is updated — even if the publisher ID stays + + whenever the application is updated - even if the publisher ID stays + the same.

+ +

The encrypted local store may perform more slowly + if the stored data exceeds 10MB.

+ +

When you uninstall an AIR + application, the uninstaller does not delete data stored in the + encrypted local store.

+ +

Best practices for using ELS

+

The best practices for using the ELS + include:

+ + + +

Items in the encrypted local store are identified with a string. All items are + stored as byte array data.

+ + + +

Note that any internal failure within the ELS code may result in + + an error being thrown, by any of the functions, via an internal method called + + processErrorCode(). There are different types of errors, + + with different descriptions, based on the underlying failure. These details are not + + fully documented but indicate an unrecoverable error within the ELS handlers. The most + + appropriate behaviour would be to enclose any ELS function calls within a try/catch + + block and then call EncryptedLocalStore.reset() within the error handler. This + + would remove the ELS file and should allow information to then be successfully stored + + and retrieved again.

+

@@ -209,8 +344,11 @@   isSupported : Boolean

[static][read-only] + The isSupported property is set to true if the + EncryptedLocalStore class is supported on the current platform, otherwise it is + set to false.
EncryptedLocalStore @@ -244,6 +382,7 @@ getItem(name:String):ByteArray
[static] + The data corresponding to the specified name.
EncryptedLocalStore @@ -285,6 +424,7 @@ removeItem(name:String):void
[static] + Removes the item with the given name from the encrypted local store.
EncryptedLocalStore @@ -294,6 +434,7 @@ reset():void
[static] + Clears the entire encrypted local store, deleting all data.
EncryptedLocalStore @@ -303,6 +444,7 @@ setItem(name:String, data:ByteArray, stronglyBound:Boolean = false):void
[static] + Stores a ByteArray object under the specified name.
EncryptedLocalStore @@ -365,20 +507,27 @@ isSupported:Boolean  [read-only]

- +
Language version: ActionScript 3.0 Language version: ActionScript 3.0 +
Runtime version: AIR 2 +

+ The isSupported property is set to true if the + EncryptedLocalStore class is supported on the current platform, otherwise it is + set to false. -

Implementation + + +

Implementation
    public static function get isSupported():Boolean
@@ -396,25 +545,34 @@

- +
Language version: ActionScript 3.0 Language version: ActionScript 3.0 +
Runtime version: AIR 1.0 +

+ The data corresponding to the specified name. + +

If an item does not exist by the specified name, this method returns null.

+ + Parameters
name:String — The name of the item in the encrypted local store. + +
@@ -424,8 +582,11 @@ ByteArray — The ByteArray data. If there is no data for the provided name, + the method returns null. + + @@ -436,7 +597,17 @@ + + + + + +
ArgumentError — The name value is null or an empty string. + +
 
Error — Various internal error situations could result in a generic Error object being thrown. + +
@@ -452,23 +623,30 @@

- +
Language version: ActionScript 3.0 Language version: ActionScript 3.0 +
Runtime version: AIR 1.0 +

+ Removes the item with the given name from the encrypted local store. + +

Parameters
name:String — The name of the item in the encrypted local store. + +
@@ -477,7 +655,17 @@ + + + + + +
ArgumentError — The name value is null or an empty string. + +
 
Error — Various internal error situations could result in a generic Error object being thrown. + +
@@ -493,19 +681,34 @@

- +
Language version: ActionScript 3.0 Language version: ActionScript 3.0 +
Runtime version: AIR 1.0 +

+ Clears the entire encrypted local store, deleting all data. + -

+


+Throws + + + + +
Error — Various internal error situations could result in a generic Error object being thrown. + + + +
+ @@ -517,23 +720,30 @@

- +
Language version: ActionScript 3.0 Language version: ActionScript 3.0 +
Runtime version: AIR 1.0 +

+ Stores a ByteArray object under the specified name. + +

Parameters @@ -541,7 +751,9 @@ @@ -549,11 +761,17 @@
name:String — The name of the item in the encrypted local store. + +
data:ByteArray — The data. + +
stronglyBound:Boolean (default = false) — (deprecated) The stronglyBound parameter should + be set to false (the default value). If set to true, the stored item + cannot be retrieved if any application files are altered. For example,if a user installs an + update of your application, the updated application cannot read any strongly bound data that + was previously written to the encrypted local store. + +
@@ -562,6 +780,7 @@ @@ -569,8 +788,19 @@ + + + + + +
ArgumentError — The name value is null or an empty string. +
ArgumentError — The data value is null. + +
 
Error — Various internal error situations could result in a generic Error object being thrown. + + +
@@ -599,11 +829,11 @@

- + - + diff --git a/static/reference/actionscript/3.0/flash/display/BitmapData.html b/static/reference/actionscript/3.0/flash/display/BitmapData.html index 0a033d03f..6308d7073 100644 --- a/static/reference/actionscript/3.0/flash/display/BitmapData.html +++ b/static/reference/actionscript/3.0/flash/display/BitmapData.html @@ -5,7 +5,7 @@ - + flash.display.BitmapData (ActionScript 3.0) @@ -334,6 +334,18 @@   
+convertColorProfile(source:Screen, destination:Screen):BitmapData +
+
+ + Create a copy of the image data, converting between color profiles based on the provided + + Screen objects.
+BitmapData + + +   +
copyChannel(sourceBitmapData:BitmapData, sourceRect:Rectangle, destPoint:Point, sourceChannel:uint, destChannel:uint):void
@@ -1646,6 +1658,76 @@

+ + + + + +
convertColorProfile()method 
+
+public function convertColorProfile(source:Screen, destination:Screen):BitmapData +

+ + + + +
Language version: ActionScript 3.0 +
+ + + + +
Runtime version: AIR 51.0 + +
+

+ + Create a copy of the image data, converting between color profiles based on the provided + + Screen objects. + + +

To convert a normal/loaded image (in sRGB color profile) so that it is displayed properly on a + + display, pass in null for the source screen and the application's display + + location as the destination screen. This would be the normal use case for this feature.

+ + + Parameters + + + + + + + + + + +
source:Screen — A Screen object that will be used to obtain the source color profile. If null, + + sRGB will be assumed. + +
 
destination:Screen — A Screen object that will be used to obtain the destination color profile. If null, + + sRGB will be assumed. + +
+

+Returns + + + + +
BitmapData — + A new BitmapData object with the appropriate color transformation. + + + + +
+
@@ -5797,11 +5879,11 @@

- + - + diff --git a/static/reference/actionscript/3.0/flash/display/NativeWindow.html b/static/reference/actionscript/3.0/flash/display/NativeWindow.html index 5048bdb1f..fdab3fa4b 100644 --- a/static/reference/actionscript/3.0/flash/display/NativeWindow.html +++ b/static/reference/actionscript/3.0/flash/display/NativeWindow.html @@ -63,11 +63,13 @@ -

AIR profile support: This feature is supported +

AIR profile support: This feature is supported fully - on all desktop operating systems, but is not supported on mobile devices or AIR for TV devices. You can test + on desktop operating systems, has some limited (single-window) support on mobile devices, - for support at run time on desktop devices using the NativeWindow.isSupported property. See + and is not supported on AIR for TV devices. You can test for support + + at run time on desktop devices using the NativeWindow.isSupported property. See @@ -75,27 +77,32 @@ -

A reference to the NativeWindow instance is returned by the window constructor. +

On desktop operating systems, a reference to a new NativeWindow instance - A reference to a NativeWindow instance can also be accessed using the stage.nativeWindow + is returned by the window constructor. On mobile operating systems, attempting to create a new - property of any display object on that window's stage: + NativeWindow instance will throw an error - the only NativeWindow that exists is the initial application -

+ window with properties set via the application descriptor file, and accessed from the stage. + + The reference to the initial NativeWindow instance for an application can be accessed using the + + stage.nativeWindow property of any display object on that window's stage:

-
var window:NativeWindow = displayObject.stage.nativeWindow;
+
var window:NativeWindow = displayObject.stage.nativeWindow;
+

On mobile operating systems, the window object cannot be modified, but can be used to listen -

A reference to the NativeWindow instance is returned by the window constructor. + for resize events (for example, on screen orientation changes) and for focus (activate/deactive) - JavaScript in an HTML page can reference the NativeWindow instance by using the window.nativeWindow + events. These can be separate from the NativeApplication events that describe the - property. + foreground/background mode of the application itself, and can be used to determine when other -

+ elements are hiding part of the window's display.

@@ -113,7 +120,7 @@ -

You cannot not add Flex components directly to the display list of a +

You cannot not add Flex components directly to the display list of a NativeWindow instance. Instead, use the Flex mx:WindowedApplication @@ -129,20 +136,6 @@ -

To create a root HTML window for displaying HTML content it is typically - - easier to create the window with HTMLLoader.createRootWindow(). - - Windows created in this way will have an HTMLLoader object added automatically. - - (From JavaScript code, you can also use the JavaScript - - window.open() function. However, this method gives you less control - - over the window appearance and behavior.)

- - -

The following operations on NativeWindow objects are asynchronous: close(), @@ -194,8 +187,6 @@ flash.desktop.NativeApplication
flash.system.ApplicationDomain -
-flash.html.HTMLLoader.createRootWindow()


@@ -3399,6 +3390,14 @@ + + + + + + @@ -3409,8 +3408,6 @@

flash.display.NativeWindowInitOptions -
-flash.html.HTMLLoader.createRootWindow()

Example @@ -5575,11 +5572,11 @@

- + - + diff --git a/static/reference/actionscript/3.0/flash/errors/InvalidSWFError.html b/static/reference/actionscript/3.0/flash/errors/InvalidSWFError.html index cda8612fa..50acc9981 100644 --- a/static/reference/actionscript/3.0/flash/errors/InvalidSWFError.html +++ b/static/reference/actionscript/3.0/flash/errors/InvalidSWFError.html @@ -45,7 +45,10 @@

Error — If the initOptions parameter is invalid. +
 
Error — If an attempt is made to create a new NativeWindow on a mobile operating system. +
- +
Language version: ActionScript 3.0 Language version: ActionScript 3.0 + + +
@@ -55,8 +58,10 @@

- Flash Player throws this exception when it encounters a corrupted SWF file. -

+ + The Flash runtimes throw this exception when they encounter a corrupted SWF file. + +



@@ -123,10 +128,19 @@ Show Inherited Public Methods Show Inherited Public Methods - +
+ + +
 MethodDefined by
   +
+InvalidSWFError(message:String = "", id:int = 0)
+
+ + Creates a new InvalidSWFError object.
+
InvalidSWFError
 Inherited
@@ -222,6 +236,50 @@ showHideInherited(); -->
+ +
Constructor detail
+ + + + + +
InvalidSWFError()constructor
+
+public function InvalidSWFError(message:String = "", id:int = 0) +

+ + + + +
Language version: ActionScript 3.0 +
+ + + + +
Runtime version: 
+

+ + Creates a new InvalidSWFError object. + + + +

Parameters + + + + + + + + + + +
message:String (default = "") — A string associated with the error object. + + +
 
id:int (default = 0)
+



@@ -229,11 +287,11 @@

- +
- + diff --git a/static/reference/actionscript/3.0/flash/errors/ScriptTimeoutError.html b/static/reference/actionscript/3.0/flash/errors/ScriptTimeoutError.html index b254ead60..985b8a1ae 100644 --- a/static/reference/actionscript/3.0/flash/errors/ScriptTimeoutError.html +++ b/static/reference/actionscript/3.0/flash/errors/ScriptTimeoutError.html @@ -7,6 +7,7 @@ flash.errors.ScriptTimeoutError (ActionScript 3.0) +
@@ -43,7 +44,48 @@

+ + + + +
Language version: ActionScript 3.0 +
+ + + + +
Runtime version: 

+

+ + The ScriptTimeoutError exception is thrown when the script timeout interval is reached. + + The script timeout interval is 15 seconds. There are two XML attributes + + that you can add to the mx:Application tag: scriptTimeLimit + + (the number of seconds until script timeout) and scriptRecursionLimit + + (the depth of recursive calls permitted). + + + +

Two ScriptTimeoutError exceptions are thrown. The first exception you can catch and exit + + cleanly. If there is no exception handler, the uncaught exception terminates execution. The + + second exception is thrown but cannot be caught by user code; it goes to the uncaught + + exception handler. It is uncatchable to prevent the player from hanging + + indefinitely.

+ + + +

+

+View the examples. +



@@ -110,10 +152,19 @@ Show Inherited Public Methods Show Inherited Public Methods
- +
+ + + - +
 MethodDefined by
   +
+ScriptTimeoutError(message:String = "")
+
+ + Creates a new ScriptTimeoutError object.
+
ScriptTimeoutError
 Inherited
@@ -209,6 +260,86 @@ showHideInherited(); -->
+ +
Constructor detail
+ + + + + +
ScriptTimeoutError()constructor
+
+public function ScriptTimeoutError(message:String = "") +

+ + + + +
Language version: ActionScript 3.0 +
+ + + + +
Runtime version: 
+

+ + Creates a new ScriptTimeoutError object. + + + +

Parameters + + + + +
message:String (default = "") — A string associated with the error object. + + +
+
+ +
Examples
+
examples\ScriptTimeoutErrorExample
+
The following example uses the sample ScriptTimeoutErrorExample class to show + the error generated in the event of script timeout. This is accomplished with the following + steps: +
    +
  1. A keepLooking Boolean property is declared.
  2. +
  3. The constructor calls the lockMachine() method within an error handling code + segment that catches ScriptTimeoutError objects.
  4. +
  5. The lockMachine() method contains an endless while loop.
  6. +
  7. After awhile, the ScriptTimeoutError is thrown. The constructor catches it, + outputs an error message through the trace statement and resets the keepLooking + Boolean to false, which terminates the while loop in lockMachine().
  8. +
+
+
+package {
+	import flash.display.Sprite;
+	import flash.errors.ScriptTimeoutError;
+
+	public class ScriptTimeoutErrorExample extends Sprite {		
+		private var keepLooping:Boolean = true;
+
+		public function ScriptTimeoutErrorExample() {
+			try {
+				lockMachine();
+			} 
+			catch(e:ScriptTimeoutError) {
+				trace(e);	// ScriptTimeoutError: Error #1502: A script has executed for longer than 15 seconds
+				keepLooping = false;
+			}
+		}
+		
+		private function lockMachine():void {
+			while(keepLooping){		
+			}
+		}
+	}
+}
+
+



@@ -216,11 +347,11 @@

- +
- + diff --git a/static/reference/actionscript/3.0/flash/errors/StackOverflowError.html b/static/reference/actionscript/3.0/flash/errors/StackOverflowError.html index 175ba831a..7f02d02c8 100644 --- a/static/reference/actionscript/3.0/flash/errors/StackOverflowError.html +++ b/static/reference/actionscript/3.0/flash/errors/StackOverflowError.html @@ -7,6 +7,7 @@ flash.errors.StackOverflowError (ActionScript 3.0) +
@@ -43,7 +44,43 @@

+ + + + +
Language version: ActionScript 3.0 +
+ + + + +
Runtime version: 

+

+ + ActionScript throws a StackOverflowError exception when the stack available to the script + + is exhausted. ActionScript uses a stack to store information about each method call made in + + a script, such as the local variables that the method uses. The amount of stack space + + available varies from system to system. + + + +

A StackOverflowError exception might indicate that infinite recursion has occurred, in + + which case a termination case needs to be added to the function. It also might indicate + + that the recursive algorithm has a proper terminating condition but has exhausted the stack + + anyway. In this case, try to express the algorithm iteratively instead.

+ + +

+

+View the examples. +



@@ -110,10 +147,19 @@ Show Inherited Public Methods Show Inherited Public Methods
- +
+ + + + + The Flash runtimes throw this exception when they encounter a corrupted SWF file. - + - +
 MethodDefined by
   +
+StackOverflowError(message:String = "")
+
+ + Creates a new StackOverflowError object.
+
StackOverflowError
 Inherited
@@ -209,6 +255,78 @@ showHideInherited(); -->
+ +
Constructor detail
+ + + + + +
StackOverflowError()constructor
+
+public function StackOverflowError(message:String = "") +

+ + + + +
Language version: ActionScript 3.0 +
+ + + + +
Runtime version: 
+

+ + Creates a new StackOverflowError object. + +

Parameters + + + + +
message:String (default = "") — A string associated with the error object. + + +
+
+ +
Examples
+
examples\StackOverflowErrorExample
+
The following example uses the sample StackOverflowErrorExample class to show + the error generated in the event of a stack overflow. This is accomplished using the following + steps: +
    +
  1. The constructor calls the method lockMachine() within an error handling code + segment that catches StackOverflowError objects.
  2. +
  3. The lockMachine() method calls itself until the stack overflows.
  4. +
  5. After the StackOverflowError is thrown, the constructor catches it and then outputs an + error message through the trace statement.
  6. +
+
+
+package {
+	import flash.display.Sprite;
+	import flash.errors.StackOverflowError;
+
+	public class StackOverflowErrorExample extends Sprite {		
+		public function StackOverflowErrorExample() {
+			try {
+				lockMachine();
+			} 
+			catch(e:StackOverflowError) {
+				trace(e);	// StackOverflowError: Error #1023: Stack overflow.
+			}
+		}
+		
+		private function lockMachine():void {
+			lockMachine();
+		}
+	}
+}
+
+



@@ -216,11 +334,11 @@

- +
- + diff --git a/static/reference/actionscript/3.0/flash/errors/package-detail.html b/static/reference/actionscript/3.0/flash/errors/package-detail.html index d29e8d62d..00b70c655 100644 --- a/static/reference/actionscript/3.0/flash/errors/package-detail.html +++ b/static/reference/actionscript/3.0/flash/errors/package-detail.html @@ -58,7 +58,8 @@
 InvalidSWFError - Flash Player throws this exception when it encounters a corrupted SWF file.
 PermissionError @@ -66,7 +67,9 @@ without requesting appropriate permissions.
 ScriptTimeoutError  ScriptTimeoutError + + The ScriptTimeoutError exception is thrown when the script timeout interval is reached.
 SQLError @@ -78,15 +81,19 @@ SQLError.operation property.
 StackOverflowError  StackOverflowError + + ActionScript throws a StackOverflowError exception when the stack available to the script + + is exhausted.

- +
- + diff --git a/static/reference/actionscript/3.0/operators.html b/static/reference/actionscript/3.0/operators.html index df643e629..dee5ea151 100644 --- a/static/reference/actionscript/3.0/operators.html +++ b/static/reference/actionscript/3.0/operators.html @@ -4098,7 +4098,7 @@

- +
Language version: ActionScript 3.0Language version: ActionScript 3.1
@@ -4160,7 +4160,7 @@

- +
Language version: ActionScript 3.0Language version: ActionScript 3.1
@@ -5105,11 +5105,11 @@

- + - + diff --git a/static/reference/actionscript/3.0/whatsnew.html b/static/reference/actionscript/3.0/whatsnew.html index 38956722e..1ff533b29 100644 --- a/static/reference/actionscript/3.0/whatsnew.html +++ b/static/reference/actionscript/3.0/whatsnew.html @@ -586,8 +586,30 @@ + + + + + +
 flash.display.BitmapData + + + + +
New Method + + +
 
+
+
+ + +
convertColorProfile
+
+ +
The operators documentation has also been updated, following new features in the AIR AS3 compiler that had been released with the AIR 50 SDK, for nullish coalescing and null condition member access.
@@ -600,7 +622,7 @@
 flash.geom.BitmapData flash.display.BitmapData
New Method