用于 Adobe® Flash® Platform 的 ActionScript® 3.0 参考
主页  |  隐藏包列表和类列表 |   |   |  新增内容  |  索引  |  附录  |  为什么显示为英语?
过滤条件: 正在从服务器检索数据...
正在从服务器检索数据...
com.adobe.mosaic.om.events 

Message  - AS3 ADEP Composite Application

com.adobe.mosaic.om.events
public class Message
继承Message Inheritance Event Inheritance Object

语言版本: ActionScript 3.0
产品版本: Adobe Digital Enterprise Platform Experience Services - Composite Application Framework 9.5
运行时版本: AIR 2.6, Flash Player 10.2

The Message class defines a transient notification including a namespace, a name, and a valid payload.

Messages are not retained or stored after all their listeners have been processed, so messages should only be used for communicating information that never needs to be persisted or recalled.



公共属性
 属性由以下参数定义
 Inheritedbubbles : Boolean
[只读] 表示事件是否为冒泡事件。
Event
 Inheritedcancelable : Boolean
[只读] 表示是否可以阻止与事件相关联的行为。
Event
 Inheritedconstructor : Object
对类对象或给定对象实例的构造函数的引用。
Object
 InheritedcurrentTarget : Object
[只读] 当前正在使用某个事件侦听器处理 Event 对象的对象。
Event
 InheritedeventPhase : uint
[只读] 事件流中的当前阶段。
Event
  name : String
[只读] Returns the name of this message.
Message
  nameSpace : String
[只读] Returns the namespace of this message.
Message
  payload : *
[只读] Returns the payload of this message.
Message
 Inheritedtarget : Object
[只读] 事件目标。
Event
 Inheritedtype : String
[只读] 事件的类型。
Event
公共方法
 方法由以下参数定义
  
Message(ns:String, name:String, payload:*)
Constructor.
Message
  
[覆盖] Clones this Message instance.
Message
 Inherited
formatToString(className:String, ... arguments):String
用于在自定义 ActionScript 3.0 Event 类中实现 toString() 方法的实用程序函数。
Event
 Inherited
表示对象是否已经定义了指定的属性。
Object
 Inherited
检查是否已对事件调用 preventDefault() 方法。
Event
 Inherited
表示 Object 类的实例是否在指定为参数的对象的原型链中。
Object
 Inherited
如果可以取消事件的默认行为,则取消该行为。
Event
 Inherited
表示指定的属性是否存在、是否可枚举。
Object
 Inherited
设置循环操作动态属性的可用性。
Object
 Inherited
防止对事件流中当前节点中和所有后续节点中的事件侦听器进行处理。
Event
 Inherited
防止对事件流中当前节点的后续节点中的所有事件侦听器进行处理。
Event
 Inherited
返回此对象的字符串表示形式,其格式设置遵守区域设置特定的约定。
Object
 Inherited
返回一个字符串,其中包含 Event 对象的所有属性。
Event
 Inherited
返回指定对象的原始值。
Object
公共常量
 常量由以下参数定义
属性详细信息

name

属性
name:String  [只读]

语言版本: ActionScript 3.0
产品版本: Adobe Digital Enterprise Platform Experience Services - Composite Application Framework 9.5
运行时版本: AIR 2.6, Flash Player 10.2

Returns the name of this message.



实现
    public function get name():String

nameSpace

属性 
nameSpace:String  [只读]

语言版本: ActionScript 3.0
产品版本: Adobe Digital Enterprise Platform Experience Services - Composite Application Framework 9.5
运行时版本: AIR 2.6, Flash Player 10.2

Returns the namespace of this message.



实现
    public function get nameSpace():String

payload

属性 
payload:*  [只读]

语言版本: ActionScript 3.0
产品版本: Adobe Digital Enterprise Platform Experience Services - Composite Application Framework 9.5
运行时版本: AIR 2.6, Flash Player 10.2

Returns the payload of this message.



实现
    public function get payload():*
构造函数详细信息

Message

()构造函数
public function Message(ns:String, name:String, payload:*)

语言版本: ActionScript 3.0
产品版本: Adobe Digital Enterprise Platform Experience Services - Composite Application Framework 9.5
运行时版本: AIR 2.6, Flash Player 10.2

Constructor.

The constructor builds a Message object containing a namespace, name, and payload to deliver to other tiles using their event listeners.

参数
ns:String — The namespace of the message.
 
name:String — The name of the message.
 
payload:* — Any object that is allowed to be serialized. The object will be sent to every listener.
方法详细信息

clone

()方法
override public function clone():Event

语言版本: ActionScript 3.0
产品版本: Adobe Digital Enterprise Platform Experience Services - Composite Application Framework 9.5
运行时版本: AIR 2.6, Flash Player 10.2

Clones this Message instance. Duplicates an instance of an Event subclass.

Returns a new Event object that is a copy of the original instance of the Event object. You do not normally call clone(); the EventDispatcher class calls it automatically when you redispatch an event—that is, when you call dispatchEvent(event) from a handler that is handling event.

The new Event object includes all the properties of the original.

When creating your own custom Event class, you must override the inherited Event.clone() method in order for it to duplicate the properties of your custom class. If you do not set all the properties that you add in your event subclass, those properties will not have the correct values when listeners handle the redispatched event.

In this example, PingEvent is a subclass of Event and therefore implements its own version of clone().

     class PingEvent extends Event {
         var URL:String;
         
     public override function clone():Event {
              return new PingEvent(type, bubbles, cancelable, URL);
        }
     }
     

返回
Event — cloned Message




[ X ]为什么显示为英语?
《ActionScript 3.0 参考》中的内容以英语显示

《ActionScript 3.0 参考》中的部分内容未翻译成所有语言。当某个语言元素未翻译时,将显示为英语。例如,ga.controls.HelpBox 类未翻译成任何语言。因此在简体中文版的参考中,ga.controls.HelpBox 类显示为英语。