Adobe® Flash® Platform 用 ActionScript® 3.0 リファレンスガイド
ホーム  |  パッケージおよびクラスリストの非表示 |  パッケージ  |  クラス  |  新機能  |  索引  |  付録  |  英語で表示される理由
フィルター: サーバーからデータを取得しています...
サーバーからデータを取得しています...
com.adobe.icomm.assetplacement.controller 

XMLDataLoader  - AS3 Asset Placement

パッケージcom.adobe.icomm.assetplacement.controller
クラスpublic class XMLDataLoader
継承XMLDataLoader Inheritance EventDispatcher Inheritance Object
実装 IMXMLObject, IPackageObject

言語バージョン: ActionScript 3.0
製品バージョン: Asset Placement Building Block 9.5
ランタイムバージョン: AIR 1.0, Flash Player 9, Flash Player 10

XMLDataLoader is used to load a resource from the package definition that points to an XML data file. The XMLDataLoader is linked to an asset in the package definition through its id.

If autoLoad is true, then whenever the id property is changed, the data linked to the new id will be loaded. If autoLoad is false, then an explicit call to loadData() must be made to load the package XML resource. Once the XML data is loaded and ready to use, an XmlDataReadyEvent is dispatched.

例を表示



パブリックプロパティ
 プロパティ定義元
  autoLoad : Boolean
A flag that indictes whether content starts loading automatically when the id is set or waits for a call to the loadData() method.
XMLDataLoader
 Inheritedconstructor : Object
指定されたオブジェクトインスタンスのクラスオブジェクトまたはコンストラクター関数への参照です。
Object
  id : String
The id of this object, which is used to link up to the controller attribute in the assets section of the package definition file.
XMLDataLoader
  packageAttachments : IList
[読み取り専用] A list of Attachment objects who's controller id attribute matches the id of this object.
XMLDataLoader
  packageController : Controller
[読み取り専用] The controller object who's id matches the id of this object.
XMLDataLoader
  packageResource : Resource
[読み取り専用] The current Resource object who's controller id attribute matches the id of this object.
XMLDataLoader
  packageResources : IList
[読み取り専用] A list of Resource objects who's controller id attribute matches the id of this object.
XMLDataLoader
パブリックメソッド
 メソッド定義元
  
Constructor.
XMLDataLoader
 Inherited
addEventListener(type:String, listener:Function, useCapture:Boolean = false, priority:int = 0, useWeakReference:Boolean = false):void
イベントリスナーオブジェクトを EventDispatcher オブジェクトに登録し、リスナーがイベントの通知を受け取るようにします。
EventDispatcher
 Inherited
イベントをイベントフローに送出します。
EventDispatcher
 Inherited
EventDispatcher オブジェクトに、特定のイベントタイプに対して登録されたリスナーがあるかどうかを確認します。
EventDispatcher
 Inherited
オブジェクトに指定されたプロパティが定義されているかどうかを示します。
Object
 Inherited
Object クラスのインスタンスが、パラメーターとして指定されたオブジェクトのプロトタイプチェーン内にあるかどうかを示します。
Object
  
This method loads the XML data associated to the id property in the package definition file.
XMLDataLoader
 Inherited
指定されたプロパティが存在し、列挙できるかどうかを示します。
Object
 Inherited
removeEventListener(type:String, listener:Function, useCapture:Boolean = false):void
EventDispatcher オブジェクトからリスナーを削除します。
EventDispatcher
 Inherited
ループ処理に対するダイナミックプロパティの可用性を設定します。
Object
 Inherited
ロケール固有の規則に従って書式設定された、このオブジェクトのストリング表現を返します。
Object
 Inherited
指定されたオブジェクトのストリング表現を返します。
Object
 Inherited
指定されたオブジェクトのプリミティブな値を返します。
Object
 Inherited
指定されたイベントタイプについて、この EventDispatcher オブジェクトまたはその祖先にイベントリスナーが登録されているかどうかを確認します。
EventDispatcher
イベント
 イベント 概要 定義元
 Inherited[ブロードキャストイベント] Flash Player または AIR アプリケーションがオペレーティングシステムのフォーカスを取得して、アクティブになったときに送出されます。EventDispatcher
 Inherited[ブロードキャストイベント] Flash Player または AIR アプリケーションがオペレーティングシステムのフォーカスを失って、非アクティブになったときに送出されます。EventDispatcher
  Dispatched when new content is loaded after calling loadData() or when changing the id property, if autoLoad is set to true.XMLDataLoader
プロパティの詳細

autoLoad

プロパティ
autoLoad:Boolean

言語バージョン: ActionScript 3.0
製品バージョン: Asset Placement Building Block 9.5
ランタイムバージョン: AIR 1.0, Flash Player 9, Flash Player 10

A flag that indictes whether content starts loading automatically when the id is set or waits for a call to the loadData() method. If true, the content loads automatically. If false, you must call the loadData() method.

デフォルト値: true。



実装
    public function get autoLoad():Boolean
    public function set autoLoad(value:Boolean):void

id

プロパティ 
id:String

言語バージョン: ActionScript 3.0
製品バージョン: Asset Placement Building Block 9.5
ランタイムバージョン: AIR 1.0, Flash Player 9, Flash Player 10

The id of this object, which is used to link up to the controller attribute in the assets section of the package definition file.



実装
    public function get id():String
    public function set id(value:String):void

packageAttachments

プロパティ 
packageAttachments:IList  [読み取り専用]

言語バージョン: ActionScript 3.0
製品バージョン: Asset Placement Building Block 9.5
ランタイムバージョン: AIR 1.0, Flash Player 9, Flash Player 10

A list of Attachment objects who's controller id attribute matches the id of this object.



実装
    public function get packageAttachments():IList

packageController

プロパティ 
packageController:Controller  [読み取り専用]

言語バージョン: ActionScript 3.0
製品バージョン: Asset Placement Building Block 9.5
ランタイムバージョン: AIR 1.0, Flash Player 9, Flash Player 10

The controller object who's id matches the id of this object.



実装
    public function get packageController():Controller

packageResource

プロパティ 
packageResource:Resource  [読み取り専用]

言語バージョン: ActionScript 3.0
製品バージョン: Asset Placement Building Block 9.5
ランタイムバージョン: AIR 1.0, Flash Player 9, Flash Player 10

The current Resource object who's controller id attribute matches the id of this object.



実装
    public function get packageResource():Resource

packageResources

プロパティ 
packageResources:IList  [読み取り専用]

言語バージョン: ActionScript 3.0
製品バージョン: Asset Placement Building Block 9.5
ランタイムバージョン: AIR 1.0, Flash Player 9, Flash Player 10

A list of Resource objects who's controller id attribute matches the id of this object.



実装
    public function get packageResources():IList
コンストラクターの詳細

XMLDataLoader

()コンストラクター
public function XMLDataLoader(id:String = "")

言語バージョン: ActionScript 3.0
製品バージョン: Asset Placement Building Block 9.5
ランタイムバージョン: AIR 1.0, Flash Player 9, Flash Player 10

Constructor.

パラメーター
id:String (default = "") — Set the id property when constructing the object.
メソッドの詳細

loadData

()メソッド
public function loadData():void

言語バージョン: ActionScript 3.0
製品バージョン: Asset Placement Building Block 9.5
ランタイムバージョン: AIR 1.0, Flash Player 9, Flash Player 10

This method loads the XML data associated to the id property in the package definition file. When the data is ready for use, an xmlDataReady event is dispatched. The event contains the data.

関連する API エレメント

イベントの詳細

xmlDataReady

イベント
イベントオブジェクトの型: com.adobe.icomm.assetplacement.controller.XMLDataReadyEvent
プロパティ XMLDataReadyEvent.type = com.adobe.icomm.assetplacement.controller.XMLDataReadyEvent.XML_DATA_READY

言語バージョン: ActionScript 3.0
製品バージョン: Asset Placement Building Block 9.5
ランタイムバージョン: AIR 1.0, Flash Player 9, Flash Player 10

Dispatched when new content is loaded after calling loadData() or when changing the id property, if autoLoad is set to true.

A value that represents the Event name.
This class can be used in ActionScript as follows:
     
     public function foo():void
     {
          var xmlDataLoader:XMLDataLoader = new XMLDataLoader();
          xmlDataLoader.autoLoad = false;
          xmlDataLoader.id = "data";
     
          xmlDataLoader.addEventListener(XMLDataReadyEvent.XML_DATA_READY, xmlDataReadyHandler);
          xmlDataLoader.loadData(); 
     }
     
     private function xmlDataReadyHandler(event:XMLDataReadyEvent):void
     {
          var root:XML = event.data;
     
          // Do stuff with the XML...
     }
     
     

The XMLDataLoader can also be used in MXML:

     
     <mx:Module xmlns:mx="http://www.adobe.com/2006/mxml" 
                xmlns:ap="http://ns.adobe.com/livecycle/icomm/assetplacement">
     
             <mx:Script>
                 <![CDATA[
                     // Called when XMLDataLoader loads data
                     private function onXMLDataReady(event:XMLDataReadyEvent):void
                  {
                      var info:XML = event.data;
                      StatementDataText.data = info.PhoneBill;
                  }    
             ]]>
          </mx:Script>
     
          <ap:XMLDataLoader id="data" xmlDataReady="onXMLDataReady(event)"/>
     
     </mx:Module>
     
     




[ X ]英語で表示される理由
ActionScript 3.0 リファレンスガイドのコンテンツが英語で表示されます。

ActionScript 3.0 リファレンスガイドのすべての部分がすべての言語に翻訳されているわけではありません。言語エレメントが翻訳されていない場合、そのエレメントは英語で表示されます。例えば、ga.controls.HelpBox クラスはどの言語にも訳されていません。このため、リファレンスガイドの日本語バージョンでは、ga.controls.HelpBox クラスは英語で表示されます。