Usage information [+]
How do I configure this thing for my project?
- Simply copy the Connectivity.as file to your project root and you're good to go.
Extra info: If you want to package this utility to your project's setup, simply edit the first line to the appropriate package (you'll know how to do this when you want to do it.)
How do I interact with it?
- This utility will be available to your project statically by calling 'Connectivity' anywhere in your project. For a class reference, see this link.
Extra info: The connectivity class will automatically be instantiated lazily (which basically means it doesn't take up any memory until you need it). The utility operates using a lazily instantiated singleton (slightly modified to work with Actionscript 3.0).
What uses cases could this 'Connectivity' utility be used for?
- Any time your project depends on an internet connection being (constantly) available, this utility could help you out by providing constant status information on the availability of an internet connection.
- The Connectivity utility dispatches events when changes to the connection occur. For example, if for any reason connection with the internet is lost, the CONNECTION_LOST event will be dispatched, informing any interested listener with this occurance, upon which your application could take appropriate measures.
More questions?
Ask me - jorncruijsen@gmail.com