jp.go.aist.rtm.RTC.executionContext
クラス PeriodicExecutionContext

java.lang.Object
  上位を拡張 org.omg.PortableServer.Servant
      上位を拡張 OpenRTM.ExtTrigExecutionContextServicePOA
          上位を拡張 jp.go.aist.rtm.RTC.executionContext.ExecutionContextBase
              上位を拡張 jp.go.aist.rtm.RTC.executionContext.PeriodicExecutionContext
すべての実装されたインタフェース:
SDOServiceOperations, java.lang.Runnable, ECNewDeleteFunc, ExtTrigExecutionContextServiceOperations, org.omg.CORBA.portable.InvokeHandler, ExecutionContextOperations, ExecutionContextServiceOperations
直系の既知のサブクラス:
ExtTrigExecutionContext, OpenHRPExecutionContext

public class PeriodicExecutionContext
extends ExecutionContextBase
implements java.lang.Runnable

Periodic Sampled Data Processing(周期実行用)ExecutionContextクラスです。


入れ子のクラスの概要
protected  class PeriodicExecutionContext.Comp
          ExecutionContextにattachされたコンポーネントのメソッド呼出用クラスです。
protected  class PeriodicExecutionContext.DFP
          DataFlowComponentのAction定義用抽象クラスです。
protected  class PeriodicExecutionContext.DFPBase
          DataFlowComponentのAction定義用抽象クラスです。
protected  class PeriodicExecutionContext.find_comp
          管理対象コンポーネント検索用ヘルパークラスです。
protected  class PeriodicExecutionContext.Worker
           
 
フィールドの概要
protected  java.util.Vector<PeriodicExecutionContext.Comp> m_comps
          ExecutionContextにatttachされているコンポーネントのリストです。
protected  boolean m_nowait
           
protected  ExecutionContextProfile m_profile
          ExecutionContextProfileです。
protected  ExecutionContextService m_ref
          ExecutionContextServiceとしてのCORBAオブジェクト参照です。
protected  boolean m_running
          ExecutionContextの実行状態です。
protected  java.lang.Thread m_thread
           
protected  long m_usec
          ExecutionContextの動作周期です。
protected  Logbuf rtcout
          Logging用フォーマットオブジェクト
 
コンストラクタの概要
PeriodicExecutionContext()
          デフォルトコンストラクタ {@.ja デフォルトコンストラクタ プロファイルに以下の項目を設定する。
PeriodicExecutionContext(DataFlowComponent owner)
          コンストラクタ 設定された値をプロファイルに設定する。
PeriodicExecutionContext(DataFlowComponent owner, double rate)
          コンストラクタ 設定された値をプロファイルに設定する。
 
メソッドの概要
 ExecutionContextService __this()
           __this()
 ReturnCode_t activate_component(LightweightRTObject comp)
          コンポーネントをアクティブ化します。
 ReturnCode_t add_component(LightweightRTObject comp)
          RTコンポーネントを追加する {@.ja 指定したRTコンポーネントを参加者リストに追加する。
 ReturnCode_t bindComponent(RTObject_impl rtc)
          コンポーネントをバインドする。
 int close(long flags)
          スレッド終了関数です。
 ReturnCode_t deactivate_component(LightweightRTObject comp)
          コンポーネントを非アクティブ化します。
 java.lang.Object ECDeleteFunc(ExecutionContextBase comp)
          ExecutionContextのインスタンスを破棄します。
 ExecutionContextBase ECNewFunc()
          ExecutionContextのインスタンスを取得します。
 boolean finalizeExecutionContext()
          終了処理用関数
 LifeCycleState get_component_state(LightweightRTObject comp)
          コンポーネントの状態を取得します。
 ExecutionKind get_kind()
          ExecutionKindを取得します。
 ExecutionContextProfile get_profile()
          ExecutionContextProfile を取得します。
 double get_rate()
          ExecutionContextの実行周期(Hz)を取得します。
 ExecutionContextService getObjRef()
           getObjRef
 ExecutionContextService getRef()
          本オブジェクトのExecutionContextServiceとしてのCORBAオブジェクト参照を設定します。
 boolean is_running()
          ExecutionContextが実行中かどうかを取得します。
 int open()
          ExecutionContext用のスレッドを生成します。
static void PeriodicExecutionContextInit(Manager manager)
          このExecutionContextを生成するFactoryクラスを ExecutionContext用ObjectManagerに登録します。
 ReturnCode_t remove_component(LightweightRTObject comp)
          RTコンポーネントを参加者リストから削除する {@.ja 指定したRTコンポーネントを参加者リストから削除する。
 ReturnCode_t reset_component(LightweightRTObject comp)
          コンポーネントをリセットします。
 void run()
          スレッド実行関数です。
 ReturnCode_t set_rate(double rate)
          ExecutionContextの実行周期(Hz)を設定します。
 void setObjRef(ExecutionContextService ref)
          本オブジェクトのExecutionContextServiceとしてのCORBAオブジェクト参照を設定します。
 ReturnCode_t start()
          ExecutionContext をスタートします。
 ReturnCode_t stop()
          ExecutionContext をストップします。
 int svc()
          ExecutionContext用のスレッドの実行関数です。
 
クラス jp.go.aist.rtm.RTC.executionContext.ExecutionContextBase から継承されたメソッド
tick
 
クラス OpenRTM.ExtTrigExecutionContextServicePOA から継承されたメソッド
_all_interfaces, _invoke, _this, _this
 
クラス org.omg.PortableServer.Servant から継承されたメソッド
_default_POA, _get_delegate, _get_interface_def, _is_a, _non_existent, _object_id, _orb, _poa, _set_delegate, _this_object, _this_object
 
クラス java.lang.Object から継承されたメソッド
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

フィールドの詳細

m_comps

protected java.util.Vector<PeriodicExecutionContext.Comp> m_comps

ExecutionContextにatttachされているコンポーネントのリストです。


m_running

protected boolean m_running

ExecutionContextの実行状態です。


m_profile

protected ExecutionContextProfile m_profile

ExecutionContextProfileです。


m_usec

protected long m_usec

ExecutionContextの動作周期です。


m_ref

protected ExecutionContextService m_ref

ExecutionContextServiceとしてのCORBAオブジェクト参照です。


m_nowait

protected boolean m_nowait

m_thread

protected java.lang.Thread m_thread

rtcout

protected Logbuf rtcout

Logging用フォーマットオブジェクト

コンストラクタの詳細

PeriodicExecutionContext

public PeriodicExecutionContext()
デフォルトコンストラクタ

デフォルトコンストラクタ プロファイルに以下の項目を設定する。 - kind : PERIODIC - rate : 0.0


PeriodicExecutionContext

public PeriodicExecutionContext(DataFlowComponent owner)
コンストラクタ

設定された値をプロファイルに設定する。

パラメータ:
owner - 当該 Executioncontext の owner

PeriodicExecutionContext

public PeriodicExecutionContext(DataFlowComponent owner,
                                double rate)
コンストラクタ

設定された値をプロファイルに設定する。

パラメータ:
owner - 当該 Executioncontext の owner
rate - 動作周期(Hz)
メソッドの詳細

finalizeExecutionContext

public boolean finalizeExecutionContext()

終了処理用関数

定義:
クラス ExecutionContextBase 内の finalizeExecutionContext

__this

public ExecutionContextService __this()

__this()

戻り値:
ExecutionContextService

setObjRef

public void setObjRef(ExecutionContextService ref)

本オブジェクトのExecutionContextServiceとしてのCORBAオブジェクト参照を設定します。

オーバーライド:
クラス ExecutionContextBase 内の setObjRef
パラメータ:
ref - CORBAオブジェクト参照

getObjRef

public ExecutionContextService getObjRef()

getObjRef

定義:
クラス ExecutionContextBase 内の getObjRef
戻り値:
ExecutionContextService

getRef

public ExecutionContextService getRef()

本オブジェクトのExecutionContextServiceとしてのCORBAオブジェクト参照を設定します。

戻り値:
CORBAオブジェクト参照

open

public int open()

ExecutionContext用のスレッドを生成します。


svc

public int svc()

ExecutionContext用のスレッドの実行関数です。 登録されたコンポーネントの処理を呼び出します。


run

public void run()

スレッド実行関数です。

定義:
インタフェース java.lang.Runnable 内の run

close

public int close(long flags)

スレッド終了関数です。


is_running

public boolean is_running()

ExecutionContextが実行中かどうかを取得します。

定義:
インタフェース ExecutionContextOperations 内の is_running
戻り値:
実行判定結果

start

public ReturnCode_t start()

ExecutionContext をスタートします。

定義:
インタフェース ExecutionContextOperations 内の start
戻り値:
実行結果

stop

public ReturnCode_t stop()

ExecutionContext をストップします。

定義:
インタフェース ExecutionContextOperations 内の stop
戻り値:
実行結果

get_rate

public double get_rate()

ExecutionContextの実行周期(Hz)を取得します。

定義:
インタフェース ExecutionContextOperations 内の get_rate
戻り値:
実行周期(Hz)

set_rate

public ReturnCode_t set_rate(double rate)

ExecutionContextの実行周期(Hz)を設定します。

定義:
インタフェース ExecutionContextOperations 内の set_rate
パラメータ:
rate - 実行周期(Hz)

activate_component

public ReturnCode_t activate_component(LightweightRTObject comp)

コンポーネントをアクティブ化します。

定義:
インタフェース ExecutionContextOperations 内の activate_component
パラメータ:
comp - アクティブ化対象コンポーネント
戻り値:
実行結果

deactivate_component

public ReturnCode_t deactivate_component(LightweightRTObject comp)

コンポーネントを非アクティブ化します。

定義:
インタフェース ExecutionContextOperations 内の deactivate_component
パラメータ:
comp - 非アクティブ化対象コンポーネント
戻り値:
実行結果

reset_component

public ReturnCode_t reset_component(LightweightRTObject comp)

コンポーネントをリセットします。

定義:
インタフェース ExecutionContextOperations 内の reset_component
パラメータ:
comp - リセット対象コンポーネント
戻り値:
実行結果

get_component_state

public LifeCycleState get_component_state(LightweightRTObject comp)

コンポーネントの状態を取得します。

定義:
インタフェース ExecutionContextOperations 内の get_component_state
パラメータ:
comp - 状態取得対象コンポーネント
戻り値:
コンポーネント状態

get_kind

public ExecutionKind get_kind()

ExecutionKindを取得します。

定義:
インタフェース ExecutionContextOperations 内の get_kind
戻り値:
ExecutionKind

add_component

public ReturnCode_t add_component(LightweightRTObject comp)
RTコンポーネントを追加する

指定したRTコンポーネントを参加者リストに追加する。追加されたRTコ ンポーネントは attach_context が呼ばれ、Inactive 状態に遷移する。 指定されたRTコンポーネントがnullの場合は、BAD_PARAMETER が返され る。指定されたRTコンポーネントが DataFlowComponent 以外の場合は、 BAD_PARAMETER が返される。

定義:
インタフェース ExecutionContextOperations 内の add_component
パラメータ:
comp - 追加対象RTコンポーネント
戻り値:
ReturnCode_t 型のリターンコード

bindComponent

public ReturnCode_t bindComponent(RTObject_impl rtc)
コンポーネントをバインドする。

コンポーネントをバインドする。

定義:
クラス ExecutionContextBase 内の bindComponent
パラメータ:
rtc - RTコンポーネント
戻り値:
ReturnCode_t 型のリターンコード

remove_component

public ReturnCode_t remove_component(LightweightRTObject comp)
RTコンポーネントを参加者リストから削除する

指定したRTコンポーネントを参加者リストから削除する。削除された RTコンポーネントは detach_context が呼ばれる。指定されたRTコンポー ネントが参加者リストに登録されていない場合は、BAD_PARAMETER が返 される。

定義:
インタフェース ExecutionContextOperations 内の remove_component
パラメータ:
comp - 削除対象RTコンポーネント
戻り値:
ReturnCode_t 型のリターンコード

get_profile

public ExecutionContextProfile get_profile()

ExecutionContextProfile を取得します。

定義:
インタフェース ExecutionContextServiceOperations 内の get_profile
戻り値:
ExecutionContextProfile

PeriodicExecutionContextInit

public static void PeriodicExecutionContextInit(Manager manager)

このExecutionContextを生成するFactoryクラスを ExecutionContext用ObjectManagerに登録します。

パラメータ:
manager - Managerオブジェクト

ECNewFunc

public ExecutionContextBase ECNewFunc()

ExecutionContextのインスタンスを取得します。

定義:
インタフェース ECNewDeleteFunc 内の ECNewFunc
戻り値:
ExecutionContextインスタンス

ECDeleteFunc

public java.lang.Object ECDeleteFunc(ExecutionContextBase comp)

ExecutionContextのインスタンスを破棄します。

定義:
インタフェース ECNewDeleteFunc 内の ECDeleteFunc
パラメータ:
comp - 破棄対象ExecutionContextインスタンス