Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/openzoom/zoomit-as3-sdk
Zoom.it ActionScript 3 SDK
https://github.com/openzoom/zoomit-as3-sdk
Last synced: 2 months ago
JSON representation
Zoom.it ActionScript 3 SDK
- Host: GitHub
- URL: https://github.com/openzoom/zoomit-as3-sdk
- Owner: openzoom
- Created: 2010-08-06T23:03:16.000Z (over 14 years ago)
- Default Branch: master
- Last Pushed: 2011-06-13T06:44:59.000Z (over 13 years ago)
- Last Synced: 2024-08-04T05:05:01.568Z (6 months ago)
- Language: ActionScript
- Homepage: http://api.zoom.it
- Size: 314 KB
- Stars: 13
- Watchers: 2
- Forks: 4
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG
Awesome Lists containing this project
- awesome-actionscript-sorted - zoomit-as3-sdk - Zoom.it ActionScript 3 SDK (API / Other API)
README
Zoom.it ActionScript 3 SDK
==========================Zoom.it is a free service for viewing and sharing high-resolution imagery.
The Zoom.it API provides you with programmatic access to the Zoom.it service.
This library lets you access this API with Adobe Flash, Flex and AIR
using ActionScript 3.
You can display the Deep Zoom images hosted on the Zoom.it using the free and
open source OpenZoom SDK available at [openzoom.org](http://openzoom.org)Documentation
-------------
Documentation about the Zoom.it service and API are available at [zoom.it](http://zoom.it)License
-------The Zoom.it API ActionScript 3 library was created by Daniel Gasienica
and is licensed under the [Apache License, Version 2.0](http://www.apache.org/licenses/LICENSE-2.0.html)Example
-------```actionscript
////////////////////////////////////////////////////////////////////////////////
//
// Copyright 2010 Daniel Gasienica
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
//
////////////////////////////////////////////////////////////////////////////////
package
{import flash.display.Sprite;
import it.zoom.api.AsyncRequest;
import it.zoom.api.ContentInfo;
import it.zoom.api.ZoomItService;
import it.zoom.api.events.FaultEvent;
import it.zoom.api.events.ResultEvent;public class ZoomItServiceExample extends Sprite
{
public function ZoomItServiceExample()
{
service = new ZoomItService()var request:AsyncRequest = service.getContentInfoById("h")
request.context = "I'm the successful request:"
request.addEventListener(ResultEvent.RESULT,
request_resultHandler, false, 0, true)
request.addEventListener(FaultEvent.FAULT,
request_faultHandler, false, 0, true)
var faultyRequest:AsyncRequest = service.getContentInfoById("101010")
faultyRequest.context = "I'm the faulty request:"
faultyRequest.addEventListener(ResultEvent.RESULT,
request_resultHandler, false, 0, true)
faultyRequest.addEventListener(FaultEvent.FAULT,
request_faultHandler, false, 0, true)
}
private var service:ZoomItService
private function request_resultHandler(event:ResultEvent):void
{
var content:ContentInfo = event.result as ContentInfoif (content)
trace(event.request.context, content)
}
private function request_faultHandler(event:FaultEvent):void
{
trace(event.request.context, event.text)
}
}}
```