Packagejp.co.fujitsu.reffi.client.flex.model.rpc
Classpublic class RemoteObjectCore
InheritanceRemoteObjectCore Inheritance RPCCore Inheritance BaseModel Inheritance flash.events.EventDispatcher

[概 要]

RemoteObjectによるリモートモジュール呼び出しをサポートする機能モデルクラスです.

[詳 細]

サーバ側remoting-config.xmlで定義されているRPCモジュールにアクセスする為のクラスです。

[備 考]



サーバ定義されているRPCモジュールにリクエストを行う

Copyright (c) 2008-2009 FUJITSU Japan All rights reserved.



Public Properties
 PropertyDefined by
 InheritedasyncToken : Object

[概 要]

非同期通信トークンです.
RPCCore
 Inheritedcache : Dictionary
[static]

[概 要]

static通信オブジェクトキャッシュプロパティです.
RPCCore
 InheritedcacheMode : Boolean

[概 要]

通信先が同じであれば各種通信オブジェクトをキャッシュします.
RPCCore
 Inheritedcontroller : BaseController

[概 要]

このモデルを起動したコントローラインスタンスです.
BaseModel
 InheritedexecuteIndex : int

[概 要]

実行インデックス設定.
BaseModel
  methodName : String

[概 要]

実行するリモートオブジェクトメソッド名です.
RemoteObjectCore
 InheritedparameterMapping : ParameterMapping

[概 要]

MVC各レイヤを伝播するパラメータオブジェクトです.
BaseModel
  remoteDestination : String

[概 要]

RPCリクエスト時のdestinationです.
RemoteObjectCore
  rpcParameter : Array

[概 要]

RPCメソッド引数です.
RemoteObjectCore
 Inheritedservice : IEventDispatcher

[概 要]

継承先で定義される、各種通信オブジェクトのI/Fです.
RPCCore
 Inheritedskip : Boolean

[概 要]

このモデルを実行するか、コントローラが判断する為のフラグです.
BaseModel
 InheritedsuccessCount : int

[概 要]

モデルインスタンス生存中に、何回モデル処理が成功したかを保持します.
BaseModel
Public Methods
 MethodDefined by
  
addRpcParameter(value:Object):Array

[概 要]

RPCメソッド呼び出し時のパラメータに新規パラメータを追加します.
RemoteObjectCore
 Inherited

[概 要]

モデル処理失敗イベントを発行するメソッドです.
BaseModel
 Inherited

[概 要]

モデル処理完了イベントを発行するメソッドです.
BaseModel
 Inherited

[概 要]

モデル処理成功イベントを発行するメソッドです.
BaseModel
 Inherited

[概 要]

ModelProcessEvent.SUCCESS発行回数を1増加させます.
BaseModel
 Inherited
[static]

[概 要]

通信オブジェクトキャッシュを全て削除します.
RPCCore
 Inherited
removeCache(cacheId:String):void
[static]

[概 要]

通信オブジェクトキャッシュを削除します.
RPCCore
 Inherited
run():void

[概 要]

コントローラにコールされるモデルの主幹メソッドです.
BaseModel
Protected Methods
 MethodDefined by
  
cacheId():String

[概 要]

キャッシュモード実行時、通信オブジェクトを識別する為のIDを返却します.
RemoteObjectCore
  
createConcreteService():IEventDispatcher

[概 要]

具象通信オブジェクトを作成します.
RemoteObjectCore
 Inherited
faultHandler(event:FaultEvent):void

[概 要]

受信失敗ハンドラです.
RPCCore
 Inherited
finallyProc():void

[概 要]

run()が終了したタイミングでテンプレートコールされるメソッドです.
BaseModel
  

[概 要]

通信成功、失敗に関わらずコールされます.
RemoteObjectCore
 Inherited
mainProc():void

[概 要]

メイン処理メソッドです.
RPCCore
 Inherited
onFailure(event:FaultEvent, parameterMapping:ParameterMapping):void

[概 要]

受信失敗処理用オーバーライドメソッドです.
RPCCore
 Inherited
onFinish(parameterMapping:ParameterMapping):void

[概 要]

通信終了処理実装メソッドです.
RPCCore
 Inherited
onSuccess(event:ResultEvent, parameterMapping:ParameterMapping):void

[概 要]

受信成功処理用オーバーライドメソッドです.
RPCCore
 Inherited
postProc():void

[概 要]

後処理テンプレートメソッドです.
BaseModel
 Inherited
preProc():Boolean

[概 要]

前処理テンプレートメソッドです.
BaseModel
 Inherited
resultHandler(event:ResultEvent):void

[概 要]

受信成功ハンドラです.
RPCCore
  
send(dispatcher:IEventDispatcher):Object

[概 要]

RPCリクエストを行います.
RemoteObjectCore
 Inherited
trap(e:Error):Error

[概 要]

非同期通信開始前のエラーをハンドリングします.
RPCCore
Public Constants
 ConstantDefined by
 InheritedE4X : String = "e4x"
[static] レスポンス返却フォーマット「e4x」を示す定数です.
RPCCore
 InheritedOBJECT : String = "object"
[static] レスポンス返却フォーマット「object」を示す定数です.
RPCCore
 InheritedXML : String = "xml"
[static] レスポンス返却フォーマット「xml」を示す定数です.
RPCCore
Property detail
methodNameproperty
methodName:String  [read-write]

[概 要]

実行するリモートオブジェクトメソッド名です.

[詳 細]

destinationで設定されているオブジェクトが持つメソッド名を指定します。

[備 考]

実装
    public function get methodName():String
    public function set methodName(value:String):void
remoteDestinationproperty 
remoteDestination:String  [read-write]

[概 要]

RPCリクエスト時のdestinationです.

[詳 細]

remoting-config.xmlで設定されているRPCモジュールのdestinationを文字列で指定します。

[備 考]

実装
    public function get remoteDestination():String
    public function set remoteDestination(value:String):void
rpcParameterproperty 
rpcParameter:Array  [read-write]

[概 要]

RPCメソッド引数です.

[詳 細]

methodNameプロパティで指定したメソッドが持つ引数を設定します。
第一引数、第二引数・・・と順番に値が入ります。

[備 考]

実装
    public function get rpcParameter():Array
    public function set rpcParameter(value:Array):void
Method detail
addRpcParameter()method
public function addRpcParameter(value:Object):Array

[概 要]

RPCメソッド呼び出し時のパラメータに新規パラメータを追加します.

[詳 細]

methodNameプロパティで指定したRPCメソッドが持つ引数を設定します。
呼び出すRPCメソッドが以下のシグネチャを持っている場合、
boolean commitData(String name, int age);
addRpcParameter("山田太郎");
addRpcParameter(36);

のようにシグネチャ順に設定します。

[備 考]

パラメータ
value:Object

戻り値
Array
cacheId()method 
protected override function cacheId():String

[概 要]

キャッシュモード実行時、通信オブジェクトを識別する為のIDを返却します.

[詳 細]

remoteDestinationプロパティを返却します。
cacheIdはcacheModeプロパティがtrueの場合のみ使用されます。

[備 考]

戻り値
String — 通信オブジェクトを識別する為のキャッシュID
createConcreteService()method 
protected override function createConcreteService():IEventDispatcher

[概 要]

具象通信オブジェクトを作成します.

[詳 細]

RemoteObjectオブジェクトを生成して返却します。

[備 考]

戻り値
IEventDispatcher — RemoteObjectオブジェクト
finishConnect()method 
protected final override function finishConnect():void

[概 要]

通信成功、失敗に関わらずコールされます.

[詳 細]

処理は有りません。

[備 考]

通信終了処理実装はonFinishをオーバーライドしてください。
send()method 
protected override function send(dispatcher:IEventDispatcher):Object

[概 要]

RPCリクエストを行います.

[詳 細]

RemoteObjectに対してdestination、メソッド名、パラメータを指定、 リモートモジュールにリクエストします。

[備 考]

パラメータ
dispatcher:IEventDispatcher

戻り値
Object — AsyncToken