| パッケージ | net.user1.reactor |
| クラス | public class AccountManagerEvent |
| 継承 | AccountManagerEvent flash.events.Event |
| バージョン : | Reactor 1.0.0 |
// イベント登録コード
reactor.getAccountManager().addEventListener(
AccountManagerEvent.CREATE_ACCOUNT_RESULT,
createAccountResultListener);
// イベントリスナーのコード
protected function createAccountResultListener (e:AccountManagerEvent):void {
if (e.getStatus() == Status.SUCCESS) {
// "アカウント作成完了"メッセージを表示します(displayAccountCreated()関数の
// 定義はここでは示しません)
displayAccountCreated();
}
}関連項目
| メソッド | 定義元 | ||
|---|---|---|---|
AccountManagerEvent(type:String, bubbles:Boolean = false, cancelable:Boolean = false, userID:String = null, account:UserAccount = null, status:String = null) コンストラクタ | AccountManagerEvent | ||
clone():Event [オーバーライド] | AccountManagerEvent | ||
このアカウントマネージャーイベントに関係するUserAccountオブジェクトを返します。 | AccountManagerEvent | ||
getStatus():String このイベントに関係する操作のステータスを返します。 | AccountManagerEvent | ||
getUserID():String このイベントが関係するアカウントのユーザーIDを返します。 | AccountManagerEvent | ||
toString():String [オーバーライド] | AccountManagerEvent | ||
| 定数 | 定義元 | ||
|---|---|---|---|
| ACCOUNT_ADDED : String = ACCOUNT_ADDED [静的] AccountManagerがUnionサーバーからユーザーアカウントの作成を通知されるときに送出されます。 | AccountManagerEvent | ||
| ACCOUNT_REMOVED : String = ACCOUNT_REMOVED [静的] AccountManagerがUnionサーバーからユーザーアカウントの削除を通知されるときに送出されます。 | AccountManagerEvent | ||
| CREATE_ACCOUNT_RESULT : String = CREATE_ACCOUNT_RESULT [静的] 先に行われたAccountManagerのcreateAccount()メソッド呼び出しの結果を受信したときに送出されます。 | AccountManagerEvent | ||
| REMOVE_ACCOUNT_RESULT : String = REMOVE_ACCOUNT_RESULT [静的] 先に行われたAccountManagerのremoveAccount()メソッド呼び出しの結果を受信したときに送出されます。 | AccountManagerEvent | ||
| STOP_WATCHING_FOR_ACCOUNTS_RESULT : String = STOP_WATCHING_FOR_ACCOUNTS_RESULT [静的] AccountManagerが先に行われたstopWatchingForAccounts()要求の結果を受信するときに送出されます。 | AccountManagerEvent | ||
| SYNCHRONIZE : String = SYNCHRONIZE [静的] watchForAccounts()要求の後にAccountManagerのユーザーアカウントリストの同期が完了するときに送出されます。 | AccountManagerEvent | ||
| WATCH_FOR_ACCOUNTS_RESULT : String = WATCH_FOR_ACCOUNTS_RESULT [静的] AccountManagerが先に行われたwatchForAccounts()要求の結果を受信するときに送出されます。 | AccountManagerEvent | ||
| AccountManagerEvent | () | コンストラクタ |
public function AccountManagerEvent(type:String, bubbles:Boolean = false, cancelable:Boolean = false, userID:String = null, account:UserAccount = null, status:String = null)コンストラクタ
パラメータtype:String | |
bubbles:Boolean (default = false) | |
cancelable:Boolean (default = false) | |
userID:String (default = null) | |
account:UserAccount (default = null) | |
status:String (default = null) |
| clone | () | メソッド |
override public function clone():Event 戻り値 Event |
| getAccount | () | メソッド |
public function getAccount():UserAccount| バージョン : | Reactor 1.0.0 |
このアカウントマネージャーイベントに関係するUserAccountオブジェクトを返します。 例えば、AccountManagerEvent.ACCOUNT_REMOVEDイベントにおいては、getAccount()は除去されたアカウントのUserAccountオブジェクトを返します。
戻り値UserAccount |
| getStatus | () | メソッド |
public function getStatus():String| バージョン : | Reactor 1.0.0 |
このイベントに関係する操作のステータスを返します。 getStatus()メソッドの戻り値は常にStatusクラスの定数のどれかです。 例えば、もしAccountManagerEvent.CREATE_ACCOUNT_RESULTイベントがアカウント生成試行が成功した結果として発生すると、getStatus()はStatus.SUCCESS値を返すでしょう。 ステータスに対応するには、getStatus()の値とStatus定数とを比較します。 例えば、
if (e.getStatus() == Status.SUCCESS) {
showAccountCreatedScreen();
}String |
関連項目
| getUserID | () | メソッド |
public function getUserID():String| バージョン : | Reactor 1.0.0 |
このイベントが関係するアカウントのユーザーIDを返します。 例えば、AccountManagerEvent.ACCOUNT_ADDEDイベントにおいては、getUserID()はサーバーに追加されたアカウントのuserIDを返します。
戻り値String |
| toString | () | メソッド |
override public function toString():String 戻り値 String |
| ACCOUNT_ADDED | 定数 |
public static const ACCOUNT_ADDED:String = ACCOUNT_ADDED| バージョン : | Reactor 1.0.0 |
AccountManagerがUnionサーバーからユーザーアカウントの作成を通知されるときに送出されます。 このイベントはAccountManagerがユーザーアカウントを監視しているときにのみ利用可能です(watchForAccounts()を参照してください)。
関連項目
| ACCOUNT_REMOVED | 定数 |
public static const ACCOUNT_REMOVED:String = ACCOUNT_REMOVED| バージョン : | Reactor 1.0.0 |
AccountManagerがUnionサーバーからユーザーアカウントの削除を通知されるときに送出されます。 このイベントはAccountManagerがユーザーアカウントを監視しているときにのみ利用可能です(watchForAccounts()を参照してください)。
関連項目
| CREATE_ACCOUNT_RESULT | 定数 |
public static const CREATE_ACCOUNT_RESULT:String = CREATE_ACCOUNT_RESULT| バージョン : | Reactor 1.0.0 |
先に行われたAccountManagerのcreateAccount()メソッド呼び出しの結果を受信したときに送出されます。 アカウント作成要求の結果を調べるには、getStatus()を使用してください。このメソッドの戻り値は次のどれかになります:
関連項目
| REMOVE_ACCOUNT_RESULT | 定数 |
public static const REMOVE_ACCOUNT_RESULT:String = REMOVE_ACCOUNT_RESULT| バージョン : | Reactor 1.0.0 |
先に行われたAccountManagerのremoveAccount()メソッド呼び出しの結果を受信したときに送出されます。 アカウント除去要求の結果を調べるには、getStatus()を使用してください。このメソッドの戻り値は次のどれかになります:
関連項目
| STOP_WATCHING_FOR_ACCOUNTS_RESULT | 定数 |
public static const STOP_WATCHING_FOR_ACCOUNTS_RESULT:String = STOP_WATCHING_FOR_ACCOUNTS_RESULT| バージョン : | Reactor 1.0.0 |
AccountManagerが先に行われたstopWatchingForAccounts()要求の結果を受信するときに送出されます。 試行結果を診断するには、getStatus()を使用します。これは次の値をとる可能性があります。
関連項目
| SYNCHRONIZE | 定数 |
public static const SYNCHRONIZE:String = SYNCHRONIZE| バージョン : | Reactor 1.0.0 |
watchForAccounts()要求の後にAccountManagerのユーザーアカウントリストの同期が完了するときに送出されます。
関連項目
| WATCH_FOR_ACCOUNTS_RESULT | 定数 |
public static const WATCH_FOR_ACCOUNTS_RESULT:String = WATCH_FOR_ACCOUNTS_RESULT| バージョン : | Reactor 1.0.0 |
AccountManagerが先に行われたwatchForAccounts()要求の結果を受信するときに送出されます。 要求の結果を確認するためには、getStatus()を使用してください。これは次の戻り値のうちどれかになります:
関連項目