套件 | org.osmf.metadata |
類別 | public class Metadata |
繼承 | Metadata EventDispatcher Object |
子類別 | LayoutMetadata, TimelineMetadata |
語言版本: | ActionScript 3.0 |
產品版本: | OSMF 1.0 |
執行階段版本: | Flash Player 10, AIR 1.5 |
Metadata consists of key-value pairs, where keys are Strings and values are arbitrary Objects. The Metadata class provides a strongly-typed API for working with these key-value pairs, as well as events for detecting changes to the metadata.
屬性 | 定義自 | ||
---|---|---|---|
constructor : Object
類別物件的參照或是特定物件實體的建構函數。 | Object | ||
keys : Vector.<String> [唯讀]
The keys stored in this Metadata object. | Metadata |
方法 | 定義自 | ||
---|---|---|---|
Metadata()
Constructor. | Metadata | ||
addEventListener(type:String, listener:Function, useCapture:Boolean = false, priority:int = 0, useWeakReference:Boolean = false):void
會在 EventDispatcher 物件註冊事件偵聽程式,以便讓偵聽程式收到事件的通知。 | EventDispatcher | ||
Stores the specified value in this Metadata object, using the specified
key. | Metadata | ||
會將事件傳送到事件流程。 | EventDispatcher | ||
Returns the value associate with the specified key. | Metadata | ||
會檢查 EventDispatcher 物件是否有對特定的事件類型註冊偵聽程式。 | EventDispatcher | ||
指出物件是否有已定義的指定屬性。 | Object | ||
指出 Object 類別的實體是否位於指定為參數的物件原型鏈中。 | Object | ||
指出指定的屬性是否存在,以及是否可列舉。 | Object | ||
會從 EventDispatcher 物件移除偵聽程式。 | EventDispatcher | ||
Removes the value associated with the specified key from this
Metadata object. | Metadata | ||
為迴圈作業設定動態屬性的可用性。 | Object | ||
傳回代表此物件的字串,根據地區特定慣例進行格式化。 | Object | ||
會傳回指定之物件的字串形式。 | Object | ||
會傳回指定之物件的基本值。 | Object | ||
檢查此 EventDispatcher 物件是否已註冊事件偵聽程式,或者此物件的任何祖系已為特定事件類型註冊事件偵聽程式。 | EventDispatcher |
事件 | 摘要 | 定義自 | ||
---|---|---|---|---|
[廣播事件] 當 Flash Player 或 AIR 應用程式取得作業系統焦點並成為作用中時傳送。 | EventDispatcher | |||
[廣播事件] 當 Flash Player 或 AIR 應用程式失去作業系統焦點並成為非作用中時傳送。 | EventDispatcher | |||
Dispatched when a new value is added to the Metadata object. | Metadata | |||
Dispatched when a value within the Metadata object changes. | Metadata | |||
Dispatched when a value is removed from the Metadata object. | Metadata |
keys | 屬性 |
Metadata | () | 建構函式 |
public function Metadata()
語言版本: | ActionScript 3.0 |
產品版本: | OSMF 1.0 |
執行階段版本: | Flash Player 10, AIR 1.5 |
Constructor.
addValue | () | 方法 |
public function addValue(key:String, value:Object):void
語言版本: | ActionScript 3.0 |
產品版本: | OSMF 1.0 |
執行階段版本: | Flash Player 10, AIR 1.5 |
Stores the specified value in this Metadata object, using the specified key. The key can subsequently be used to retrieve the value. If the key is equal to the key of another object already in the Metadata object this will overwrite the association with the new value.
參數
key:String — The key to associate the value with.
| |
value:Object — The value to add to the Metadata object.
|
擲回值
ArgumentError — If key is null or somehow invalid.
|
getValue | () | 方法 |
public function getValue(key:String):*
語言版本: | ActionScript 3.0 |
產品版本: | OSMF 1.0 |
執行階段版本: | Flash Player 10, AIR 1.5 |
Returns the value associate with the specified key. Returns 'undefined' if the Metadata object fails to resolve the key.
參數
key:String |
* |
擲回值
ArgumentError — If key is null.
|
removeValue | () | 方法 |
public function removeValue(key:String):*
語言版本: | ActionScript 3.0 |
產品版本: | OSMF 1.0 |
執行階段版本: | Flash Player 10, AIR 1.5 |
Removes the value associated with the specified key from this Metadata object. Returns undefined if there is no value associated with the key in this Metadata object.
參數
key:String — The key associated with the value to be removed.
|
* |
擲回值
ArgumentError — If key is null.
|
valueAdd | 事件 |
org.osmf.events.MetadataEvent
屬性 MetadataEvent.type =
org.osmf.events.MetadataEvent.VALUE_ADD
語言版本: | ActionScript 3.0 |
產品版本: | OSMF 1.0 |
執行階段版本: | Flash Player 10, AIR 1.5 |
Dispatched when a new value is added to the Metadata object.
The MetadataEvent.VALUE_ADD constant defines the value of the type property of the event object for a valueAdd event.valueChange | 事件 |
org.osmf.events.MetadataEvent
屬性 MetadataEvent.type =
org.osmf.events.MetadataEvent.VALUE_CHANGE
語言版本: | ActionScript 3.0 |
產品版本: | OSMF 1.0 |
執行階段版本: | Flash Player 10, AIR 1.5 |
Dispatched when a value within the Metadata object changes.
The MetadataEvent.VALUE_CHANGE constant defines the value of the type property of the event object for a valueChange event.valueRemove | 事件 |
org.osmf.events.MetadataEvent
屬性 MetadataEvent.type =
org.osmf.events.MetadataEvent.VALUE_REMOVE
語言版本: | ActionScript 3.0 |
產品版本: | OSMF 1.0 |
執行階段版本: | Flash Player 10, AIR 1.5 |
Dispatched when a value is removed from the Metadata object.
The MetadataEvent.VALUE_REMOVE constant defines the value of the type property of the event object for a valueRemove event.Tue Jun 12 2018, 03:47 PM Z