The maximum number of items that can be cached at one time
pendingRequests
property
protected var pendingRequests:Dictionary
Language Version :
ActionScript 3.0
Product Version :
Portfolio 10.0
Runtime Versions :
Flash Player 10.1, AIR 2.0
XXXXX
swfImage
property
protected var swfImage:Class
timeoutTimer
property
protected var timeoutTimer:Timer
Language Version :
ActionScript 3.0
Product Version :
Portfolio 10.0
Runtime Versions :
Flash Player 10.1, AIR 2.0
XXXXX
videoImage
property
protected var videoImage:Class
Constructor Detail
ThumbnailManager
()
Constructor
public function ThumbnailManager(token:Object)
Language Version :
ActionScript 3.0
Product Version :
Portfolio 10.0
Runtime Versions :
Flash Player 10.1, AIR 2.0
Constructor
Parameters
token:Object
Method Detail
addToPending
()
method
protected function addToPending(cacheObject:CacheObject, callback:Function, requests:Dictionary):void
Language Version :
ActionScript 3.0
Product Version :
Portfolio 10.0
Runtime Versions :
Flash Player 10.1, AIR 2.0
XXXXX
Parameters
cacheObject:CacheObject
callback:Function
requests:Dictionary
cacheThumb
()
method
protected function cacheThumb(callback:Function, cacheObject:CacheObject, thumbnail:Bitmap, clearPendingRequests:Boolean = true):void
Language Version :
ActionScript 3.0
Product Version :
Portfolio 10.0
Runtime Versions :
Flash Player 10.1, AIR 2.0
XXXXX
Parameters
callback:Function
cacheObject:CacheObject
thumbnail:Bitmap
clearPendingRequests:Boolean (default = true)
callPendingCallbacks
()
method
protected function callPendingCallbacks(cacheObject:CacheObject, requests:Dictionary, clearPendingRequests:Boolean = true):void
Language Version :
ActionScript 3.0
Product Version :
Portfolio 10.0
Runtime Versions :
Flash Player 10.1, AIR 2.0
XXXXX
Parameters
cacheObject:CacheObject
requests:Dictionary
clearPendingRequests:Boolean (default = true)
getAspectRatio
()
method
public function getAspectRatio(object:Object, mediaValue:Boolean = false, allowNaN:Boolean = false):Number
Language Version :
ActionScript 3.0
Product Version :
Portfolio 10.0
Runtime Versions :
Flash Player 10.1, AIR 2.0
Returns the aspect ratio for the specified object.
If object is null then it returns NaN if allowNaN is true,
or 1 if allowNaN is false
Parameters
object:Object — the thumbnail object for which you are requesting the aspect ratio
mediaValue:Boolean (default = false)
allowNaN:Boolean (default = false) — if true then the defaultApectRatio is allowed to be NaN
Returns
Number
getCachedThumb
()
method
protected function getCachedThumb(thumbKey:String):Bitmap
Language Version :
ActionScript 3.0
Product Version :
Portfolio 10.0
Runtime Versions :
Flash Player 10.1, AIR 2.0
XXXXX
Parameters
thumbKey:String
Returns
Bitmap
getDownsampledThumb
()
method
protected function getDownsampledThumb(c:CacheObject, downSampleOK:Boolean):Bitmap
Language Version :
ActionScript 3.0
Product Version :
Portfolio 10.0
Runtime Versions :
Flash Player 10.1, AIR 2.0
XXXXX
Parameters
c:CacheObject
downSampleOK:Boolean
Returns
Bitmap
getPredefinedThumbnail
()
method
protected function getPredefinedThumbnail(attachment:IAttachment):Bitmap
Language Version :
ActionScript 3.0
Product Version :
Portfolio 10.0
Runtime Versions :
Flash Player 10.1, AIR 2.0
Returns the predefined thumbnail images for the specified attachment,
such as folders, SWF files, video, and audio files. If the there is no
predefined image for the attachment type, it returns null.
protected function logEntry(prefix:String, id:*, attachment:IAttachment, width:Number, height:Number, pageNumber:uint):void
Language Version :
ActionScript 3.0
Product Version :
Portfolio 10.0
Runtime Versions :
Flash Player 10.1, AIR 2.0
Creates a log entry for the specified attachement,
using the specified prefix, id, width, height, and pageNumber
Parameters
prefix:String — A string that is the prefix for the log entry
id:* — An id that the client can use for tracking purposes.
attachment:IAttachment — Specifies the attachment (an IAttachment) for which the thumbnail is generated.
width:Number — The desired width of the thumbnail, in pixels. It must be > 0 and <= 2048.
height:Number — The desired height of the thumbnail, in pixels. It must be > 0 and <= 2048.
pageNumber:uint — The desired page number of the attachment. It must be >= 1.
logInfo
()
method
protected function logInfo(prefix:String, cacheObject:CacheObject):void
Language Version :
ActionScript 3.0
Product Version :
Portfolio 10.0
Runtime Versions :
Flash Player 10.1, AIR 2.0
Creates a log entry using the
Parameters
prefix:String — A string that is the prefix for the log entry
cacheObject:CacheObject
onTimeout
()
method
protected function onTimeout(e:Event):void
Parameters
e:Event
requestThumbnail
()
method
public function requestThumbnail(id:*, attachment:IAttachment, width:Number, height:Number, pageNumber:uint, callback:Function, downSampleOK:Boolean = true, upSampleOK:Boolean = true):void
Language Version :
ActionScript 3.0
Product Version :
Portfolio 10.0
Runtime Versions :
Flash Player 10.1, AIR 2.0
Requests a thumbnail to be generated that will fit into the specified width and height.
Parameters
id:* — An id that the client can use for tracking purposes.
attachment:IAttachment — Specifies the attachment (an IAttachment) for which the thumbnail is generated.
width:Number — The desired width of the thumbnail, in pixels. It must be gt; 0 and <= 2048.
height:Number — The desired height of the thumbnail, in pixels. It must be > 0 and <= 2048.
pageNumber:uint — The desired page number of the attachment. It must be >= 1.
callback:Function — A callback function that will be called when the thumbnail has been generated.
Its parameters are specified below.
Callback function parameters:
callbackFunction(id: width:Number, height:Number, thumbnail:Bitmap)
Parameter:Type
Value
id:String
the value of the id param passed to requestThumbnail
width:Number
the value of the width parameter passed to requestThumbnail
height:Number
The value of the height param to requestThumbnail
pageNumber:uint
the value of the pageNumber param to requestThumbnail
thumbnail:Bitmap
the generated thumbnail
downSampleOK:Boolean (default = true)
upSampleOK:Boolean (default = true)
startTimeOutTimer
()
method
protected function startTimeOutTimer():void
supportsDynamicThumbnails
()
method
public function supportsDynamicThumbnails(attachment:IAttachment):Boolean
Returns true if a dynamic thumbnail request has ever succeeded for this attachment,
or false otherwise.