[openrtm-commit:02332] r916 - in trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src: RTMExamples/SimpleIO RTMExamples/StaticFsm RTMExamples/TopicTest jp/go/aist/rtm/RTC/port jp/go/aist/rtm/RTC/port/publisher
openrtm @ openrtm.org
openrtm @ openrtm.org
2017年 1月 25日 (水) 16:34:37 JST
Author: win-ei
Date: 2017-01-25 16:34:37 +0900 (Wed, 25 Jan 2017)
New Revision: 916
Added:
trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/port/ConnectorListenerArgument.java
Modified:
trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/RTMExamples/SimpleIO/ConsoleInImpl.java
trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/RTMExamples/SimpleIO/ConsoleOutImpl.java
trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/RTMExamples/StaticFsm/StaticFsmImpl.java
trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/RTMExamples/TopicTest/ConsoleInImpl.java
trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/RTMExamples/TopicTest/ConsoleOutImpl.java
trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/port/ConnectorDataListener.java
trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/port/ConnectorDataListenerArgumentDataRef.java
trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/port/ConnectorDataListenerHolder.java
trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/port/ConnectorDataListenerT.java
trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/port/ConnectorListener.java
trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/port/ConnectorListenerHolder.java
trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/port/InPortConsumer.java
trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/port/InPortCorbaCdrConsumer.java
trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/port/InPortCorbaCdrProvider.java
trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/port/InPortDirectConsumer.java
trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/port/InPortDirectProvider.java
trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/port/OutPortConnector.java
trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/port/OutPortCorbaCdrConsumer.java
trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/port/OutPortCorbaCdrProvider.java
trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/port/OutPortPullConnector.java
trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/port/OutPortPushConnector.java
trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/port/publisher/PublisherBase.java
trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/port/publisher/PublisherFlush.java
trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/port/publisher/PublisherNew.java
trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/port/publisher/PublisherPeriodic.java
Log:
[FSM4RTC,incompat] Connector listeners intarfaces have been changed to modify info and data in the listeners and return its status. refs #3886
Modified: trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/RTMExamples/SimpleIO/ConsoleInImpl.java
===================================================================
--- trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/RTMExamples/SimpleIO/ConsoleInImpl.java 2017-01-25 07:23:25 UTC (rev 915)
+++ trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/RTMExamples/SimpleIO/ConsoleInImpl.java 2017-01-25 07:34:37 UTC (rev 916)
@@ -9,6 +9,7 @@
import jp.go.aist.rtm.RTC.DataFlowComponentBase;
import jp.go.aist.rtm.RTC.Manager;
+import jp.go.aist.rtm.RTC.connectorListener.ReturnCode;
import jp.go.aist.rtm.RTC.port.OutPort;
import jp.go.aist.rtm.RTC.port.ConnectorBase;
import jp.go.aist.rtm.RTC.port.ConnectorListener;
@@ -229,7 +230,7 @@
m_name = name;
}
- public void operator(final ConnectorBase.ConnectorInfo arg,
+ public ReturnCode operator(final ConnectorBase.ConnectorInfo arg,
final TimedLong data) {
ConnectorBase.ConnectorInfo info =(ConnectorBase.ConnectorInfo)arg;
System.out.println("------------------------------");
@@ -240,6 +241,7 @@
// System.out.println(info.properties);
System.out.println("Data: "+data.data);
System.out.println("------------------------------");
+ return ReturnCode.NO_CHANGE;
}
public String m_name;
}
@@ -248,7 +250,7 @@
m_name = name;
}
- public void operator(final ConnectorBase.ConnectorInfo arg){
+ public ReturnCode operator(final ConnectorBase.ConnectorInfo arg){
System.out.println("------------------------------");
System.out.println("Listener: "+m_name);
System.out.println("Profile::name: "+arg.name);
@@ -256,6 +258,7 @@
String str = new String();
System.out.println("Profile::data_type:"+arg.properties.getProperty("data_type"));
System.out.println("------------------------------");
+ return ReturnCode.NO_CHANGE;
}
public String m_name;
}
Modified: trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/RTMExamples/SimpleIO/ConsoleOutImpl.java
===================================================================
--- trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/RTMExamples/SimpleIO/ConsoleOutImpl.java 2017-01-25 07:23:25 UTC (rev 915)
+++ trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/RTMExamples/SimpleIO/ConsoleOutImpl.java 2017-01-25 07:34:37 UTC (rev 916)
@@ -7,6 +7,7 @@
import RTC.TimedLong;
import jp.go.aist.rtm.RTC.DataFlowComponentBase;
import jp.go.aist.rtm.RTC.Manager;
+import jp.go.aist.rtm.RTC.connectorListener.ReturnCode;
import jp.go.aist.rtm.RTC.port.InPort;
import jp.go.aist.rtm.RTC.port.ConnectorBase;
import jp.go.aist.rtm.RTC.port.ConnectorDataListener;
@@ -217,7 +218,7 @@
m_name = name;
}
- public void operator(final ConnectorBase.ConnectorInfo arg,
+ public ReturnCode operator(final ConnectorBase.ConnectorInfo arg,
final TimedLong data) {
ConnectorBase.ConnectorInfo info =(ConnectorBase.ConnectorInfo)arg;
System.out.println("------------------------------");
@@ -228,6 +229,7 @@
// System.out.println(info.properties);
System.out.println("Data: "+data.data);
System.out.println("------------------------------");
+ return ReturnCode.NO_CHANGE;
}
public String m_name;
}
Modified: trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/RTMExamples/StaticFsm/StaticFsmImpl.java
===================================================================
--- trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/RTMExamples/StaticFsm/StaticFsmImpl.java 2017-01-25 07:23:25 UTC (rev 915)
+++ trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/RTMExamples/StaticFsm/StaticFsmImpl.java 2017-01-25 07:34:37 UTC (rev 916)
@@ -15,6 +15,7 @@
import jp.go.aist.rtm.RTC.DataFlowComponentBase;
import jp.go.aist.rtm.RTC.Manager;
+import jp.go.aist.rtm.RTC.connectorListener.ReturnCode;
import jp.go.aist.rtm.RTC.jfsm.Event;
import jp.go.aist.rtm.RTC.jfsm.Machine;
import jp.go.aist.rtm.RTC.jfsm.machine.EventBase;
@@ -457,7 +458,7 @@
m_que = que;
}
- public void operator(final ConnectorBase.ConnectorInfo arg,
+ public ReturnCode operator(final ConnectorBase.ConnectorInfo arg,
final TimedLong data) {
ConnectorBase.ConnectorInfo info =(ConnectorBase.ConnectorInfo)arg;
System.out.println("------------------------------");
@@ -469,6 +470,7 @@
args[0] = data.getClass();
m_que.offer(new Event(m_name,args,(Object)data));
}
+ return ReturnCode.NO_CHANGE;
}
private String m_name;
Modified: trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/RTMExamples/TopicTest/ConsoleInImpl.java
===================================================================
--- trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/RTMExamples/TopicTest/ConsoleInImpl.java 2017-01-25 07:23:25 UTC (rev 915)
+++ trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/RTMExamples/TopicTest/ConsoleInImpl.java 2017-01-25 07:34:37 UTC (rev 916)
@@ -9,6 +9,7 @@
import jp.go.aist.rtm.RTC.DataFlowComponentBase;
import jp.go.aist.rtm.RTC.Manager;
+import jp.go.aist.rtm.RTC.connectorListener.ReturnCode;
import jp.go.aist.rtm.RTC.port.OutPort;
import jp.go.aist.rtm.RTC.port.ConnectorBase;
import jp.go.aist.rtm.RTC.port.ConnectorListener;
@@ -246,7 +247,7 @@
m_name = name;
}
- public void operator(final ConnectorBase.ConnectorInfo arg,
+ public ReturnCode operator(final ConnectorBase.ConnectorInfo arg,
final TimedLong data) {
ConnectorBase.ConnectorInfo info =(ConnectorBase.ConnectorInfo)arg;
System.out.println("------------------------------");
@@ -257,6 +258,7 @@
// System.out.println(info.properties);
System.out.println("Data: "+data.data);
System.out.println("------------------------------");
+ return ReturnCode.NO_CHANGE;
}
public String m_name;
}
@@ -265,7 +267,7 @@
m_name = name;
}
- public void operator(final ConnectorBase.ConnectorInfo arg){
+ public ReturnCode operator(final ConnectorBase.ConnectorInfo arg){
System.out.println("------------------------------");
System.out.println("Listener: "+m_name);
System.out.println("Profile::name: "+arg.name);
@@ -273,6 +275,7 @@
String str = new String();
System.out.println("Profile::data_type:"+arg.properties.getProperty("data_type"));
System.out.println("------------------------------");
+ return ReturnCode.NO_CHANGE;
}
public String m_name;
}
Modified: trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/RTMExamples/TopicTest/ConsoleOutImpl.java
===================================================================
--- trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/RTMExamples/TopicTest/ConsoleOutImpl.java 2017-01-25 07:23:25 UTC (rev 915)
+++ trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/RTMExamples/TopicTest/ConsoleOutImpl.java 2017-01-25 07:34:37 UTC (rev 916)
@@ -7,6 +7,7 @@
import RTC.TimedLong;
import jp.go.aist.rtm.RTC.DataFlowComponentBase;
import jp.go.aist.rtm.RTC.Manager;
+import jp.go.aist.rtm.RTC.connectorListener.ReturnCode;
import jp.go.aist.rtm.RTC.port.InPort;
import jp.go.aist.rtm.RTC.port.ConnectorBase;
import jp.go.aist.rtm.RTC.port.ConnectorDataListener;
@@ -258,7 +259,7 @@
m_name = name;
}
- public void operator(final ConnectorBase.ConnectorInfo arg,
+ public ReturnCode operator(final ConnectorBase.ConnectorInfo arg,
final TimedLong data) {
ConnectorBase.ConnectorInfo info =(ConnectorBase.ConnectorInfo)arg;
System.out.println("------------------------------");
@@ -269,6 +270,7 @@
// System.out.println(info.properties);
System.out.println("Data: "+data.data);
System.out.println("------------------------------");
+ return ReturnCode.NO_CHANGE;
}
public String m_name;
}
Modified: trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/port/ConnectorDataListener.java
===================================================================
--- trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/port/ConnectorDataListener.java 2017-01-25 07:23:25 UTC (rev 915)
+++ trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/port/ConnectorDataListener.java 2017-01-25 07:34:37 UTC (rev 916)
@@ -5,6 +5,7 @@
import org.omg.CORBA.portable.OutputStream;
+import RTC.ReturnCode_t;
/**
* {@.ja ConnectorDataListener クラス}
@@ -12,21 +13,275 @@
*
* <p>
* {@.ja データポートの Connector において発生する各種イベントに対するコー
- * ルバックを実現するリスナクラスの基底クラス。}
+ * ルバックを実現するリスナクラスの基底クラス。
+ *
+ * コアロジックがOutPortに対してデータ書き込み、InPort側でデータが取
+ * 得されるまでの間で発生する各種イベントをフックするコールバックを設
+ * 定することができる。なお、リスナークラスは2種類存在し、バッファフ
+ * ルや送信時のコールバックで、その時点で有効なデータをファンクタの引
+ * 数として受け取る ConnectorDataListener であり、もう一方はデータエ
+ * ンプティやバッファ読み込み時のタイムアウトなどデータが取得できない
+ * 場合などにコールされるファンクタの引数に何もとらならい
+ * ConnecotorListener がある。
+ *
+ * ConnectorDataListener クラスによってデータが関連する動作をフックし
+ * たい場合、以下の例のように、このクラスを継承し、コネクタの情報とデー
+ * タを引数に取る以下のようなコールバックオブジェクトを定義し、データ
+ * ポートの適切なコールバック設定関数からコールバックオブジェクトをセッ
+ * トする必要がある。なお、Data Listener には、データとしてマーシャリ
+ * ング後のデータを引数に取る ConnectorDataListener と、データを特定
+ * の型にアンマーシャルした後の値を引数に取る、
+ * ConnectorDataListenerT がある。以下の例は、ConnectorDataListenerT
+ * の定義例である。
+ *
+ * <pre>{@code
+ * class MyDataListener extends ConnectorDataListenerT<RTC::TimedLong> {
+ * public MyDataListener(final String name){
+ * super(TimedLong.class);
+ * m_name = name;
+ * }
+ * public void operator()(ConnectorInfo& info, TimedLong& data) {
+ * ConnectorBase.ConnectorInfo info =(ConnectorBase.ConnectorInfo)arg;
+ * System.out.println("Listener: "+m_name);
+ * System.out.println("Data: "+data.data);
+ * System.out.println("Profile::name: "+info.name);
+ * System.out.println("Profile::id: "+info.id);
+ * System.out.println("Profile::properties: ");
+ * System.out.println(info.properties);
+ * };
+ * public String m_name;
+ * };
+ * }</pre>
+ *
+ * このようにして定義されたリスナクラスは、以下のようにデータポートに
+ * 対して、以下のようにセットされる。
+ *
+ * <pre>{@code
+ * protected ReturnCode_t onInitialize() {
+ * m_outOut.addConnectorDataListener(
+ * ConnectorDataListenerType.ON_BUFFER_WRITE,
+ * new MyDataListener("ON_BUFFER_WRITE"));
+ * :
+ * }</pre>
+ *
+ * 第1引数の "ON_BUFFER_WRITE" は、コールバックをフックするポイントで
+ * あり、以下に列挙する値を取ることが可能である。データポートには、接
+ * 続時にデータの送受信方法について、インターフェース型、データフロー
+ * 型、サブスクリプション型等を設定することができるが、これらの設定に
+ * よりフックされるポイントは異なる。以下に、インターフェースがCORBA
+ * CDR型の場合のコールバック一覧を示す。
+ *
+ * OutPort:
+ * <ul>
+ * <li>- Push型: Subscription Typeによりさらにイベントの種類が分かれる。
+ * <ul>
+ * <li>- Flush: Flush型にはバッファがないため ON_BUFFER 系のイベントは発生しない
+ * <ul>
+ * <li>- ON_SEND
+ * <li>- ON_RECEIVED
+ * <li>- ON_RECEIVER_FULL
+ * <li>- ON_RECEIVER_TIMEOUT
+ * <li>- ON_RECEIVER_ERROR
+ * <li>.
+ * </ul>
+ * <li>- New型
+ * <ul>
+ * <li>- ON_BUFFER_WRITE
+ * <li>- ON_BUFFER_FULL
+ * <li>- ON_BUFFER_WRITE_TIMEOUT
+ * <li>- ON_BUFFER_OVERWRITE
+ * <li>- ON_BUFFER_READ
+ * <li>- ON_SEND
+ * <li>- ON_RECEIVED
+ * <li>- ON_RECEIVER_FULL
+ * <li>- ON_RECEIVER_TIMEOUT
+ * <li>- ON_RECEIVER_ERROR
+ * <li>.
+ * </ul>
+ * <li>- Periodic型
+ * <ul>
+ * <li>- ON_BUFFER_WRITE
+ * <li>- ON_BUFFER_FULL
+ * <li>- ON_BUFFER_WRITE_TIMEOUT
+ * <li>- ON_BUFFER_READ
+ * <li>- ON_SEND
+ * <li>- ON_RECEIVED
+ * <li>- ON_RECEIVER_FULL
+ * <li>- ON_RECEIVER_TIMEOUT
+ * <li>- ON_RECEIVER_ERROR
+ * <li>.
+ * </ul>
+ * <li>.
+ * </ul>.
+ * <li>- Pull型
+ * <ul>
+ * <li>- ON_BUFFER_WRITE
+ * <li>- ON_BUFFER_FULL
+ * <li>- ON_BUFFER_WRITE_TIMEOUT
+ * <li>- ON_BUFFER_OVERWRITE
+ * <li>- ON_BUFFER_READ
+ * <li>- ON_SEND
+ * <li>.
+ * </ul>.
+ * </ul>
+ * InPort:
+ * <ul>
+ * <li>- Push型:
+ * <ul>
+ * <li> - ON_BUFFER_WRITE
+ * <li> - ON_BUFFER_FULL
+ * <li> - ON_BUFFER_WRITE_TIMEOUT
+ * <li> - ON_BUFFER_WRITE_OVERWRITE
+ * <li> - ON_BUFFER_READ
+ * <li> - ON_BUFFER_READ_TIMEOUT
+ * <li> - ON_RECEIVED
+ * <li> - ON_RECEIVER_FULL
+ * <li> - ON_RECEIVER_TIMEOUT
+ * <li> - ON_RECEIVER_ERROR
+ * <li> .
+ * </ul>
+ * <li>- Pull型
+ * <ul>
+ * <li> - ON_BUFFER_READ
+ * </ul>
+ * </ul>}
* {@.en This class is abstract base class for listener classes that
- * provides callbacks for various events in the data port's
- * connectors.}
- * </p>
+ * realize callbacks for various events in the data port's
+ * connectors.
*
+ * Callbacks can be hooked to the various kind of events which occur
+ * throgh OutPort side data write action to InPort side data-read
+ * action. Two types listener classes exist. One is
+ * ConnectorDataListener which receives valid data-port's data value
+ * at that time such as buffer-full event, data-send event, and so
+ * on. Other is ConnectorListener which does not receive any data
+ * such as buffer-empty event, buffer-read-timeout event and so on.
+ *
+ * If you want to hook actions which related data-port's data by
+ * ConnectorDataListener, a class which inherits this class should
+ * be defined, and the functor should receive a connector
+ * information and a data value as arguments. And then, the defined
+ * class must be set to data-port object through its member
+ * function, as follows. Two types of ConnectorDataListeners are
+ * available. One is "ConnectorDataListener" which receives
+ * marshalled data as data value, the other is
+ * "ConnectorDataListenerT" which receives unmarshalled data as data
+ * value. The following example is the use of ConnectorDataListenerT.
+ *
+ * <pre>{@code
+ * protected ReturnCode_t onInitialize() {
+ * m_outOut.addConnectorDataListener(
+ * ConnectorDataListenerType.ON_BUFFER_WRITE,
+ * new MyDataListener("ON_BUFFER_WRITE"));
+ * :
+ * }</pre>
+ *
+ * The listener class defained as above can be attached to a
+ * data-port as follows.
+ *
+ * <pre>{@code
+ * protected ReturnCode_t onInitialize() {
+ * m_outOut.addConnectorDataListener(
+ * ConnectorDataListenerType.ON_BUFFER_WRITE,
+ * new MyDataListener("ON_BUFFER_WRITE"));
+ * :
+ * }</pre>
+ *
+ * The first argument "ON_BUFFER_WRITE" specifies hook point of
+ * callback, and the following values are available. Data-port can
+ * be specified some properties such as interface-type,
+ * dataflow-type, subscription type and so on. Available hook points
+ * vary by the those settings. The following hook points are
+ * available when interface type is CORBA CDR type.
+ *
+ * OutPort:
+ * <ul>
+ * <li>- Push type: Available hook event varies by subscription type.
+ * <ul>
+ * <li>- Flush: No ON_BUFFER* events since flush-type has no buffer.
+ * <ul>
+ * <li>- ON_SEND
+ * <li>- ON_RECEIVED
+ * <li>- ON_RECEIVER_FULL
+ * <li>- ON_RECEIVER_TIMEOUT
+ * <li>- ON_RECEIVER_ERROR
+ * <li>.
+ * </ul>
+ * <li>- New type:
+ * <ul>
+ * <li>- ON_BUFFER_WRITE
+ * <li>- ON_BUFFER_FULL
+ * <li>- ON_BUFFER_WRITE_TIMEOUT
+ * <li>- ON_BUFFER_OVERWRITE
+ * <li>- ON_BUFFER_READ
+ * <li>- ON_SEND
+ * <li>- ON_RECEIVED
+ * <li>- ON_RECEIVER_FULL
+ * <li>- ON_RECEIVER_TIMEOUT
+ * <li>- ON_RECEIVER_ERROR
+ * <li>.
+ * </ul>
+ * <li>- Periodic type:
+ * <ul>
+ * <li>- ON_BUFFER_WRITE
+ * <li>- ON_BUFFER_FULL
+ * <li>- ON_BUFFER_WRITE_TIMEOUT
+ * <li>- ON_BUFFER_READ
+ * <li>- ON_SEND
+ * <li>- ON_RECEIVED
+ * <li>- ON_RECEIVER_FULL
+ * <li>- ON_RECEIVER_TIMEOUT
+ * <li>- ON_RECEIVER_ERROR
+ * <li>.
+ * </ul>
+ * <li>.
+ * </ul>.
+ * <li>- Pull type:
+ * <ul>
+ * <li>- ON_BUFFER_WRITE
+ * <li>- ON_BUFFER_FULL
+ * <li>- ON_BUFFER_WRITE_TIMEOUT
+ * <li>- ON_BUFFER_OVERWRITE
+ * <li>- ON_BUFFER_READ
+ * <li>- ON_SEND
+ * <li>.
+ * </ul>.
+ * </ul>
+ * InPort:
+ * <ul>
+ * <li>- Push type:
+ * <ul>
+ * <li> - ON_BUFFER_WRITE
+ * <li> - ON_BUFFER_FULL
+ * <li> - ON_BUFFER_WRITE_TIMEOUT
+ * <li> - ON_BUFFER_WRITE_OVERWRITE
+ * <li> - ON_BUFFER_READ
+ * <li> - ON_BUFFER_READ_TIMEOUT
+ * <li> - ON_RECEIVED
+ * <li> - ON_RECEIVER_FULL
+ * <li> - ON_RECEIVER_TIMEOUT
+ * <li> - ON_RECEIVER_ERROR
+ * <li> .
+ * </ul>
+ * <li>- Pull type
+ * <ul>
+ * <li> - ON_BUFFER_READ
+ * </ul>
+ * </ul>}
+ *
*/
-public abstract class ConnectorDataListener implements Observer{
+public abstract class ConnectorDataListener
+// implements Observer, ConnectorListenerStatus{
+ implements Observer{
public void update(Observable o, Object obj) {
- ConnectorDataListenerArgument arg
+ ConnectorDataListenerArgument arg
= (ConnectorDataListenerArgument)obj;
- operator(arg.m_info,arg.m_data);
+ operator(arg.m_info,arg.m_data);
}
- public abstract void operator(final ConnectorBase.ConnectorInfo info,
- final OutputStream data);
+ //public abstract void operator(final ConnectorBase.ConnectorInfo info,
+ // final OutputStream data);
+ public abstract ReturnCode operator(ConnectorBase.ConnectorInfo info,
+ OutputStream data);
}
Modified: trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/port/ConnectorDataListenerArgumentDataRef.java
===================================================================
--- trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/port/ConnectorDataListenerArgumentDataRef.java 2017-01-25 07:23:25 UTC (rev 915)
+++ trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/port/ConnectorDataListenerArgumentDataRef.java 2017-01-25 07:34:37 UTC (rev 916)
@@ -1,5 +1,7 @@
package jp.go.aist.rtm.RTC.port;
+import java.util.EnumSet;
+import jp.go.aist.rtm.RTC.connectorListener.ReturnCode;
/**
* {@.ja ConnectorDataListenerArgumentDataRef クラス}
* {@.en ConnectorDataListenerArgumentDataRef class}
@@ -16,9 +18,24 @@
DataType data){
m_info = info;
m_data = data;
+ m_ret = ReturnCode.NO_CHANGE;
}
+ public ConnectorDataListenerArgumentDataRef(ConnectorBase.ConnectorInfo info,
+ DataType data, ReturnCode ret){
+ m_info = info;
+ m_data = data;
+ m_ret = ret;
+ }
public ConnectorBase.ConnectorInfo m_info;
public DataType m_data;
+ // public EnumSet<ReturnCode> m_ret;
+ public ReturnCode m_ret;
+ public void setReturnCode(ReturnCode ret) {
+ //m_ret.or(ret);
+ }
+ public ReturnCode getReturnCode() {
+ return m_ret;
+ }
}
Modified: trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/port/ConnectorDataListenerHolder.java
===================================================================
--- trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/port/ConnectorDataListenerHolder.java 2017-01-25 07:23:25 UTC (rev 915)
+++ trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/port/ConnectorDataListenerHolder.java 2017-01-25 07:34:37 UTC (rev 916)
@@ -2,6 +2,7 @@
import java.util.Observable;
+import jp.go.aist.rtm.RTC.connectorListener.ReturnCode;
import jp.go.aist.rtm.RTC.util.DataRef;
import jp.go.aist.rtm.RTC.log.Logbuf;
@@ -13,30 +14,39 @@
* <p> This class manages one ore more instances of ConnectorDataListener class. </p>
*
*/
-public class ConnectorDataListenerHolder<DataType> extends Observable{
+public class ConnectorDataListenerHolder<DataType> extends Observable
+// implements ConnectorListenerStatus{
+ {
public ConnectorDataListenerHolder(){
rtcout = new Logbuf("ConnectorDataListenerHolder");
}
- public void notify(final ConnectorBase.ConnectorInfo info,
+ //public void notify(final ConnectorBase.ConnectorInfo info,
+ public ReturnCode notify(final ConnectorBase.ConnectorInfo info,
final OutputStream cdrdata) {
super.setChanged();
+ ReturnCode ret = ReturnCode.NO_CHANGE;
//ConnectorDataListenerArgument arg
// = new ConnectorDataListenerArgument(info,cdrdata);
ConnectorDataListenerArgumentDataRef<OutputStream> arg
= new ConnectorDataListenerArgumentDataRef<OutputStream>(info,cdrdata);
super.notifyObservers((Object)arg);
+ ret = arg.getReturnCode();
+ return ret;
}
//public void notify(final ConnectorBase.ConnectorInfo info, final DataRef<DataType> data) {
- public void notify(final ConnectorBase.ConnectorInfo info,
- final DataType data) {
+ //public void notify(final ConnectorBase.ConnectorInfo info,
+ public ReturnCode notify(ConnectorBase.ConnectorInfo info,
+ DataType data) {
super.setChanged();
+ ReturnCode ret = ReturnCode.NO_CHANGE;
ConnectorDataListenerArgumentDataRef<DataType> arg
= new ConnectorDataListenerArgumentDataRef<DataType>(info,data);
super.notifyObservers((Object)arg);
super.clearChanged();
+ ret = arg.getReturnCode();
+ return ret;
}
protected Logbuf rtcout;
-
}
Modified: trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/port/ConnectorDataListenerT.java
===================================================================
--- trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/port/ConnectorDataListenerT.java 2017-01-25 07:23:25 UTC (rev 915)
+++ trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/port/ConnectorDataListenerT.java 2017-01-25 07:34:37 UTC (rev 916)
@@ -7,7 +7,11 @@
import org.omg.CORBA.portable.Streamable;
import org.omg.CORBA.portable.OutputStream;
+import jp.go.aist.rtm.RTC.connectorListener.ReturnCode;
import jp.go.aist.rtm.RTC.log.Logbuf;
+
+import RTC.ReturnCode_t;
+
/**
* {@.ja ConnectorDataListenerTクラス}
* {@.en ConnectorDataListenerT class}
@@ -102,7 +106,25 @@
e.printStackTrace();
}
}
- operator(arg.m_info,m_datatype);
+ ReturnCode ret = operator(arg.m_info,m_datatype);
+ if (ret == ReturnCode.DATA_CHANGED || ret == ReturnCode.BOTH_CHANGED) {
+ //cdrdata.rewindPtrs();
+ //data >>= cdrdata;
+ try {
+ OutputStream out_data = (OutputStream)arg.m_data;
+ m_field.set(m_streamable,m_datatype);
+ m_streamable._write(out_data);
+ }
+ catch(IllegalAccessException e){
+ //set throws
+ e.printStackTrace();
+ }
+ catch(IllegalArgumentException e){
+ //invoke throws
+ e.printStackTrace();
+ }
+ }
+ arg.setReturnCode(ret);
}
/**
* {@.ja 抽象コールバックメソッド}
@@ -121,8 +143,10 @@
* {@.en Data}
*
*/
- public abstract void operator(final ConnectorBase.ConnectorInfo info,
- final DataType data);
+ //public abstract void operator(final ConnectorBase.ConnectorInfo info,
+ // final DataType data);
+ public abstract ReturnCode operator(ConnectorBase.ConnectorInfo info,
+ DataType data);
private Streamable m_streamable = null;
private Field m_field = null;
private DataType m_datatype = null;
Modified: trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/port/ConnectorListener.java
===================================================================
--- trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/port/ConnectorListener.java 2017-01-25 07:23:25 UTC (rev 915)
+++ trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/port/ConnectorListener.java 2017-01-25 07:34:37 UTC (rev 916)
@@ -3,13 +3,244 @@
import java.util.Observable;
import java.util.Observer;
-public abstract class ConnectorListener implements Observer{
+import RTC.ReturnCode_t;
+
+import jp.go.aist.rtm.RTC.connectorListener.ReturnCode;
+ /**
+ * {@.ja ConnectorListener クラス}
+ * {@.en ConnectorListener class}
+ *
+ * <p>
+ * {@.ja データポートの Connector において発生する各種イベントに対するコー
+ * ルバックを実現するリスナクラスの基底クラス。
+ *
+ * コアロジックがOutPortに対してデータ書き込み、InPort側でデータが取
+ * 得されるまでの間で発生する各種イベントをフックするコールバックを設
+ * 定することができる。なお、リスナークラスは2種類存在し、バッファフ
+ * ルや送信時のコールバックで、その時点で有効なデータをファンクタの引
+ * 数として受け取る ConnectorDataListener であり、もう一方はデータエ
+ * ンプティやバッファ読み込み時のタイムアウトなどデータが取得できない
+ * 場合などにコールされるファンクタの引数に何もとらならい
+ * ConnecotorListener がある。
+ *
+ * ConnectorListener クラスによって関連する動作をフックしたい場合、以
+ * 下の例のように、このクラスを継承し、コネクタの情報を引数に取る以下
+ * のようなコールバックオブジェクトを定義し、データポートの適切なコー
+ * ルバック設定関数からコールバックオブジェクトをセットする必要がある。
+ *
+ * <pre>{@code
+ * class MyListener extends ConnectorListener{
+ * public MyListener(final String name){
+ * m_name = name;
+ * }
+ * public void operator(final ConnectorBase.ConnectorInfo arg){
+ * System.out.println("Listener: "+m_name);
+ * System.out.println("Profile::name: "+arg.name);
+ * System.out.println("Profile::id: "+arg.id);
+ * System.out.println("Profile::properties: ");
+ * System.out.println(info.properties);
+ * }
+ * public String m_name;
+ * }
+ * }</pre>
+ *
+ * このようにして定義されたリスナクラスは、以下のようにデータポートに
+ * 対して、以下のようにセットされる。
+ *
+ * <pre>{@code
+ * protected ReturnCode_t onInitialize() {
+ * m_outOut.addConnectorListener(
+ * ConnectorListenerType.ON_BUFFER_EMPTY,
+ * new MyListener("ON_BUFFER_EMPTY"));
+ * :
+ * }</pre>
+ *
+ * 第1引数の "ON_BUFFER_EMPTY" は、コールバックをフックするポイントで
+ * あり、以下に列挙する値を取ることが可能である。データポートには、接
+ * 続時にデータの送受信方法について、インターフェース型、データフロー
+ * 型、サブスクリプション型等を設定することができるが、これらの設定に
+ * よりフックされるポイントは異なる。以下に、インターフェースがCORBA
+ * CDR型の場合のコールバック一覧を示す。
+ *
+ * OutPort:
+ * <ul>
+ * <li>- Push型: Subscription Typeによりさらにイベントの種類が分かれる。
+ * <ul>
+ * <li>- Flush: Flush型にはバッファがないため ON_BUFFER 系のイベントは発生しない
+ * <ul>
+ * <li>- ON_CONNECT
+ * <li>- ON_DISCONNECT
+ * <li>.
+ * </ul>
+ * <li>- New型
+ * <ul>
+ * <li>- ON_CONNECT
+ * <li>- ON_DISCONNECT
+ * <li>.
+ * </ul>
+ * <li>- Periodic型
+ * <ul>
+ * <li>- ON_BUFFER_EMPTY
+ * <li>- ON_BUFFER_READ_TIMEOUT
+ * <li>- ON_SENDER_EMPTY
+ * <li>- ON_SENDER_ERROR
+ * <li>- ON_CONNECT
+ * <li>- ON_DISCONNECT
+ * <li>.
+ * </ul>
+ * <li>.
+ * </ul>
+ * <li>- Pull型
+ * <ul>
+ * <li>- ON_BUFFER_EMPTY
+ * <li>- ON_BUFFER_READ_TIMEOUT
+ * <li>- ON_SENDER_EMPTY
+ * <li>- ON_SENDER_TIMEOUT
+ * <li>- ON_SENDER_ERROR
+ * <li>- ON_CONNECT
+ * <li>- ON_DISCONNECT
+ * <li>.
+ * </ul>
+ * </ul>
+ * InPort:
+ * <ul>
+ * <li>- Push型:
+ * <ul>
+ * <li>- ON_BUFFER_EMPTY
+ * <li>- ON_BUFFER_READ_TIMEOUT
+ * <li>- ON_CONNECT
+ * <li>- ON_DISCONNECT
+ * <li>.
+ * </ul>
+ * <li>- Pull型
+ * <ul>
+ * <li>- ON_CONNECT
+ * <li>- ON_DISCONNECT
+ * </ul>
+ * </ul>}
+ *
+ * {@.en This class is abstract base class for listener classes that
+ * realize callbacks for various events in the data port's
+ * connectors.
+ *
+ * Callbacks can be hooked to the various kind of events which occur
+ * throgh OutPort side data write action to InPort side data-read
+ * action. Two types listener classes exist. One is
+ * ConnectorDataListener which receives valid data-port's data value
+ * at that time such as buffer-full event, data-send event, and so
+ * on. Other is ConnectorListener which does not receive any data
+ * such as buffer-empty event, buffer-read-timeout event and so on.
+ *
+ * If you want to hook related actions by
+ * ConnectorListener, a class which inherits this class should
+ * be defined, and the functor should receive a connector
+ * information as an argument. And then, the defined
+ * class must be set to data-port object through its member
+ * function, as follows.
+ *
+ * <pre>{@code
+ * class MyListener extends ConnectorListener{
+ * public MyListener(final String name){
+ * m_name = name;
+ * }
+ * public void operator(final ConnectorBase.ConnectorInfo arg){
+ * System.out.println("Listener: "+m_name);
+ * System.out.println("Profile::name: "+arg.name);
+ * System.out.println("Profile::id: "+arg.id);
+ * System.out.println("Profile::properties: ");
+ * System.out.println(info.properties);
+ * }
+ * public String m_name;
+ * }
+ * }</pre>
+ *
+ * The listener class defained as above can be attached to a
+ * data-port as follows.
+ *
+ * <pre>{@code
+ * protected ReturnCode_t onInitialize() {
+ * m_outOut.addConnectorListener(
+ * ConnectorListenerType.ON_BUFFER_EMPTY,
+ * new MyListener("ON_BUFFER_EMPTY"));
+ * :
+ * }</pre>
+ *
+ * The first argument "ON_BUFFER_EMPTY" specifies hook point of
+ * callback, and the following values are available. Data-port can
+ * be specified some properties such as interface-type,
+ * dataflow-type, subscription type and so on. Available hook points
+ * vary by the those settings. The following hook points are
+ * available when interface type is CORBA CDR type.
+ *
+ * OutPort:
+ * <ul>
+ * <li>- Push type: Available hook event varies by subscription type.
+ * <ul>
+ * <li>- Flush: No ON_BUFFER* events since flush-type has no buffer.
+ * <ul>
+ * <li>- ON_CONNECT
+ * <li>- ON_DISCONNECT
+ * <li>.
+ * </ul>
+ * <li> - New type:
+ * <ul>
+ * <li>- ON_CONNECT
+ * <li>- ON_DISCONNECT
+ * <li>.
+ * </ul>
+ * <li> - Periodic type:
+ * <ul>
+ * <li>- ON_BUFFER_EMPTY
+ * <li>- ON_BUFFER_READ_TIMEOUT
+ * <li>- ON_SENDER_EMPTY
+ * <li>- ON_SENDER_ERROR
+ * <li>- ON_CONNECT
+ * <li>- ON_DISCONNECT
+ * <li>.
+ * </ul>
+ * <li>.
+ * </ul>
+ * <li>- Pull type:
+ * <ul>
+ * <li>- ON_BUFFER_EMPTY
+ * <li>- ON_BUFFER_READ_TIMEOUT
+ * <li>- ON_SENDER_EMPTY
+ * <li>- ON_SENDER_TIMEOUT
+ * <li>- ON_SENDER_ERROR
+ * <li>- ON_CONNECT
+ * <li>- ON_DISCONNECT
+ * <li>.
+ * </ul>
+ * </ul>
+ * InPort:
+ * <ul>
+ * <li>- Push type:
+ * <ul>
+ * <li>- ON_BUFFER_EMPTY
+ * <li>- ON_BUFFER_READ_TIMEOUT
+ * <li>- ON_CONNECT
+ * <li>- ON_DISCONNECT
+ * <li>.
+ * </ul>
+ * <li>- Pull type:
+ * <ul>
+ * <li>- ON_CONNECT
+ * <li>- ON_DISCONNECT
+ * </ul>
+ * </ul>}
+ *
+ *
+ */
+public abstract class ConnectorListener
+// implements Observer, ConnectorListenerStatus{
+ implements Observer{
public void update(Observable o, Object obj) {
ConnectorBase.ConnectorInfo arg
= (ConnectorBase.ConnectorInfo)obj;
operator(arg);
}
- public abstract void operator(final ConnectorBase.ConnectorInfo info);
+ //public abstract void operator(final ConnectorBase.ConnectorInfo info);
+ public abstract ReturnCode operator(ConnectorBase.ConnectorInfo info);
}
Added: trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/port/ConnectorListenerArgument.java
===================================================================
--- trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/port/ConnectorListenerArgument.java (rev 0)
+++ trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/port/ConnectorListenerArgument.java 2017-01-25 07:34:37 UTC (rev 916)
@@ -0,0 +1,28 @@
+package jp.go.aist.rtm.RTC.port;
+
+import java.util.EnumSet;
+import jp.go.aist.rtm.RTC.connectorListener.ReturnCode;
+ /**
+ * {@.ja ConnectorListenerArgument クラス}
+ * {@.en ConnectorListenerArgument class}
+ *
+ *
+ */
+public class ConnectorListenerArgument {
+
+ public ConnectorListenerArgument(ConnectorBase.ConnectorInfo info){
+ m_info = info;
+ //m_ret = ReturnCode.NO_CHANGE;
+ m_ret = ReturnCode.NO_CHANGE;
+ }
+ public ConnectorBase.ConnectorInfo m_info;
+ public ReturnCode m_ret;
+// public EnumSet<ReturnCode> m_ret;
+ public void setReturnCode(ReturnCode ret) {
+ m_ret.or(ret.getValue());
+// EnumSet<ReturnCode> m_flag = EnumSet.noneOf(ReturnCode.class);
+ }
+ public ReturnCode getReturnCode() {
+ return m_ret;
+ }
+}
Modified: trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/port/ConnectorListenerHolder.java
===================================================================
--- trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/port/ConnectorListenerHolder.java 2017-01-25 07:23:25 UTC (rev 915)
+++ trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/port/ConnectorListenerHolder.java 2017-01-25 07:34:37 UTC (rev 916)
@@ -1,18 +1,25 @@
package jp.go.aist.rtm.RTC.port;
import java.util.Observable;
-
+import jp.go.aist.rtm.RTC.connectorListener.ReturnCode;
/**
* <p> ConnectorListener holder class </p>
*
* <p> This class manages one ore more instances of ConnectorListener class. </p>
*
*/
-public class ConnectorListenerHolder extends Observable{
- public void notify(final ConnectorBase.ConnectorInfo info) {
+public class ConnectorListenerHolder extends Observable
+// implements ConnectorListenerStatus{
+ {
+ //public void notify(final ConnectorBase.ConnectorInfo info) {
+ public ReturnCode notify(ConnectorBase.ConnectorInfo info) {
super.setChanged();
+ ReturnCode ret = ReturnCode.NO_CHANGE;
+ ConnectorListenerArgument arg = new ConnectorListenerArgument(info);
super.notifyObservers(info);
super.clearChanged();
+ ret = arg.getReturnCode();
+ return ret;
}
}
Modified: trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/port/InPortConsumer.java
===================================================================
--- trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/port/InPortConsumer.java 2017-01-25 07:23:25 UTC (rev 915)
+++ trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/port/InPortConsumer.java 2017-01-25 07:34:37 UTC (rev 916)
@@ -50,7 +50,7 @@
* <p> Pure virtual function to send data to the destination port. <p>
*
*/
- public ReturnCode put(final OutputStream data);
+ public ReturnCode put(OutputStream data);
/**
* <p> publishInterfaceProfile </p>
* <p> Publish interfaceProfile information. </p>
Modified: trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/port/InPortCorbaCdrConsumer.java
===================================================================
--- trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/port/InPortCorbaCdrConsumer.java 2017-01-25 07:23:25 UTC (rev 915)
+++ trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/port/InPortCorbaCdrConsumer.java 2017-01-25 07:34:37 UTC (rev 916)
@@ -103,7 +103,7 @@
* {@.ja リターンコード}
* {@.en ReturnCode}
*/
- public ReturnCode put(final OutputStream data) {
+ public ReturnCode put(OutputStream data) {
rtcout.println(Logbuf.PARANOID, "put");
EncapsOutputStreamExt cdr;
Modified: trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/port/InPortCorbaCdrProvider.java
===================================================================
--- trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/port/InPortCorbaCdrProvider.java 2017-01-25 07:23:25 UTC (rev 915)
+++ trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/port/InPortCorbaCdrProvider.java 2017-01-25 07:34:37 UTC (rev 916)
@@ -202,7 +202,7 @@
*/
protected OpenRTM.PortStatus
convertReturn(jp.go.aist.rtm.RTC.buffer.ReturnCode status,
- final EncapsOutputStreamExt data) {
+ EncapsOutputStreamExt data) {
switch (status) {
case BUFFER_OK:
onBufferWrite(data);
@@ -483,7 +483,7 @@
* {@.ja OutputStream}
* {@.en OutputStream}
*/
- private void onBufferWrite(final OutputStream data) {
+ private void onBufferWrite(OutputStream data) {
m_listeners.connectorData_[ConnectorDataListenerType.ON_BUFFER_WRITE].notify(m_profile, data);
}
@@ -494,7 +494,7 @@
* {@.ja OutputStream}
* {@.en OutputStream}
*/
- private void onBufferFull(final OutputStream data) {
+ private void onBufferFull(OutputStream data) {
m_listeners.connectorData_[ConnectorDataListenerType.ON_BUFFER_FULL].notify(m_profile, data);
}
@@ -505,7 +505,7 @@
* {@.ja OutputStream}
* {@.en OutputStream}
*/
- private void onBufferWriteTimeout(final OutputStream data) {
+ private void onBufferWriteTimeout(OutputStream data) {
m_listeners.connectorData_[ConnectorDataListenerType.ON_BUFFER_WRITE_TIMEOUT].notify(m_profile, data);
}
@@ -516,7 +516,7 @@
* {@.ja OutputStream}
* {@.en OutputStream}
*/
- private void onBufferWriteOverwrite(final OutputStream data) {
+ private void onBufferWriteOverwrite(OutputStream data) {
m_listeners.connectorData_[ConnectorDataListenerType.ON_BUFFER_OVERWRITE].notify(m_profile, data);
}
@@ -535,7 +535,7 @@
* {@.ja OutputStream}
* {@.en OutputStream}
*/
- private void onReceived(final OutputStream data) {
+ private void onReceived(OutputStream data) {
m_listeners.connectorData_[ConnectorDataListenerType.ON_RECEIVED].notify(m_profile, data);
}
@@ -546,7 +546,7 @@
* {@.ja OutputStream}
* {@.en OutputStream}
*/
- private void onReceiverFull(final OutputStream data) {
+ private void onReceiverFull(OutputStream data) {
m_listeners.connectorData_[ConnectorDataListenerType.ON_RECEIVER_FULL].notify(m_profile, data);
}
@@ -557,7 +557,7 @@
* {@.ja OutputStream}
* {@.en OutputStream}
*/
- private void onReceiverTimeout(final OutputStream data) {
+ private void onReceiverTimeout(OutputStream data) {
m_listeners.connectorData_[ConnectorDataListenerType.ON_RECEIVER_TIMEOUT].notify(m_profile, data);
}
@@ -568,7 +568,7 @@
* {@.ja OutputStream}
* {@.en OutputStream}
*/
- private void onReceiverError(final OutputStream data) {
+ private void onReceiverError(OutputStream data) {
m_listeners.connectorData_[ConnectorDataListenerType.ON_RECEIVER_ERROR].notify(m_profile, data);
}
Modified: trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/port/InPortDirectConsumer.java
===================================================================
--- trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/port/InPortDirectConsumer.java 2017-01-25 07:23:25 UTC (rev 915)
+++ trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/port/InPortDirectConsumer.java 2017-01-25 07:34:37 UTC (rev 916)
@@ -100,7 +100,7 @@
* {@.ja リターンコード}
* {@.en ReturnCode}
*/
- public ReturnCode put(final OutputStream data) {
+ public ReturnCode put(OutputStream data) {
rtcout.println(Logbuf.PARANOID, "put(): never called.");
return ReturnCode.UNKNOWN_ERROR;
Modified: trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/port/InPortDirectProvider.java
===================================================================
--- trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/port/InPortDirectProvider.java 2017-01-25 07:23:25 UTC (rev 915)
+++ trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/port/InPortDirectProvider.java 2017-01-25 07:34:37 UTC (rev 916)
@@ -209,7 +209,7 @@
*/
protected OpenRTM.PortStatus
convertReturn(jp.go.aist.rtm.RTC.buffer.ReturnCode status,
- final EncapsOutputStreamExt data) {
+ EncapsOutputStreamExt data) {
switch (status) {
case BUFFER_OK:
onBufferWrite(data);
@@ -497,7 +497,7 @@
* {@.ja OutputStream}
* {@.en OutputStream}
*/
- private void onBufferWrite(final OutputStream data) {
+ private void onBufferWrite(OutputStream data) {
m_listeners.connectorData_[ConnectorDataListenerType.ON_BUFFER_WRITE].notify(m_profile, data);
}
@@ -508,7 +508,7 @@
* {@.ja OutputStream}
* {@.en OutputStream}
*/
- private void onBufferFull(final OutputStream data) {
+ private void onBufferFull(OutputStream data) {
m_listeners.connectorData_[ConnectorDataListenerType.ON_BUFFER_FULL].notify(m_profile, data);
}
@@ -519,7 +519,7 @@
* {@.ja OutputStream}
* {@.en OutputStream}
*/
- private void onBufferWriteTimeout(final OutputStream data) {
+ private void onBufferWriteTimeout(OutputStream data) {
m_listeners.connectorData_[ConnectorDataListenerType.ON_BUFFER_WRITE_TIMEOUT].notify(m_profile, data);
}
@@ -530,7 +530,7 @@
* {@.ja OutputStream}
* {@.en OutputStream}
*/
- private void onBufferWriteOverwrite(final OutputStream data) {
+ private void onBufferWriteOverwrite(OutputStream data) {
m_listeners.connectorData_[ConnectorDataListenerType.ON_BUFFER_OVERWRITE].notify(m_profile, data);
}
@@ -549,7 +549,7 @@
* {@.ja OutputStream}
* {@.en OutputStream}
*/
- private void onReceived(final OutputStream data) {
+ private void onReceived(OutputStream data) {
m_listeners.connectorData_[ConnectorDataListenerType.ON_RECEIVED].notify(m_profile, data);
}
@@ -560,7 +560,7 @@
* {@.ja OutputStream}
* {@.en OutputStream}
*/
- private void onReceiverFull(final OutputStream data) {
+ private void onReceiverFull(OutputStream data) {
m_listeners.connectorData_[ConnectorDataListenerType.ON_RECEIVER_FULL].notify(m_profile, data);
}
@@ -571,7 +571,7 @@
* {@.ja OutputStream}
* {@.en OutputStream}
*/
- private void onReceiverTimeout(final OutputStream data) {
+ private void onReceiverTimeout(OutputStream data) {
m_listeners.connectorData_[ConnectorDataListenerType.ON_RECEIVER_TIMEOUT].notify(m_profile, data);
}
@@ -582,7 +582,7 @@
* {@.ja OutputStream}
* {@.en OutputStream}
*/
- private void onReceiverError(final OutputStream data) {
+ private void onReceiverError(OutputStream data) {
m_listeners.connectorData_[ConnectorDataListenerType.ON_RECEIVER_ERROR].notify(m_profile, data);
}
Modified: trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/port/OutPortConnector.java
===================================================================
--- trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/port/OutPortConnector.java 2017-01-25 07:23:25 UTC (rev 915)
+++ trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/port/OutPortConnector.java 2017-01-25 07:34:37 UTC (rev 916)
@@ -129,7 +129,7 @@
* {@.en The write function to write data from OutPort to Buffer}
*
*/
- public abstract <DataType> ReturnCode write(final DataType data);
+ public abstract <DataType> ReturnCode write(DataType data);
/**
Modified: trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/port/OutPortCorbaCdrConsumer.java
===================================================================
--- trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/port/OutPortCorbaCdrConsumer.java 2017-01-25 07:23:25 UTC (rev 915)
+++ trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/port/OutPortCorbaCdrConsumer.java 2017-01-25 07:34:37 UTC (rev 916)
@@ -425,7 +425,7 @@
* {@.ja OutputStream}
* {@.en OutputStream}
*/
- private void onBufferWrite(final OutputStream data) {
+ private void onBufferWrite(OutputStream data) {
m_listeners.connectorData_[ConnectorDataListenerType.ON_BUFFER_WRITE].notify(m_profile, data);
}
@@ -436,7 +436,7 @@
* {@.ja OutputStream}
* {@.en OutputStream}
*/
- private void onBufferFull(final OutputStream data) {
+ private void onBufferFull(OutputStream data) {
m_listeners.connectorData_[ConnectorDataListenerType.ON_BUFFER_FULL].notify(m_profile, data);
}
@@ -463,7 +463,7 @@
* {@.ja OutputStream}
* {@.en OutputStream}
*/
- private void onReceived(final OutputStream data) {
+ private void onReceived(OutputStream data) {
m_listeners.connectorData_[ConnectorDataListenerType.ON_RECEIVED].notify(m_profile, data);
}
@@ -474,7 +474,7 @@
* {@.ja OutputStream}
* {@.en OutputStream}
*/
- private void onReceiverFull(final OutputStream data) {
+ private void onReceiverFull(OutputStream data) {
m_listeners.connectorData_[ConnectorDataListenerType.ON_RECEIVER_FULL].notify(m_profile, data);
}
Modified: trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/port/OutPortCorbaCdrProvider.java
===================================================================
--- trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/port/OutPortCorbaCdrProvider.java 2017-01-25 07:23:25 UTC (rev 915)
+++ trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/port/OutPortCorbaCdrProvider.java 2017-01-25 07:34:37 UTC (rev 916)
@@ -478,13 +478,13 @@
// connectorData_[ConnectorDataListenerType.ON_BUFFER_OVERWRITE].notify(m_profile, data);
// }
- private void onBufferRead(final OutputStream data)
+ private void onBufferRead(OutputStream data)
{
m_listeners.
connectorData_[ConnectorDataListenerType.ON_BUFFER_READ].notify(m_profile, data);
}
- private void onSend(final OutputStream data)
+ private void onSend(OutputStream data)
{
m_listeners.
connectorData_[ConnectorDataListenerType.ON_SEND].notify(m_profile, data);
Modified: trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/port/OutPortPullConnector.java
===================================================================
--- trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/port/OutPortPullConnector.java 2017-01-25 07:23:25 UTC (rev 915)
+++ trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/port/OutPortPullConnector.java 2017-01-25 07:34:37 UTC (rev 916)
@@ -181,7 +181,7 @@
* will be transferred to correspondent InPort.}
*
*/
- public <DataType> ReturnCode write(final DataType data) {
+ public <DataType> ReturnCode write(DataType data) {
rtcout.println(Logbuf.TRACE, "write()");
if (m_directInPort != null) {
@@ -197,7 +197,7 @@
m_inPortListeners.
connectorData_[ConnectorDataListenerType.ON_RECEIVER_FULL].notify(m_profile, data);
rtcout.println(Logbuf.PARANOID,
- "ONBUFFER_OVERWRITE(InPort,OutPort), "
+ "ON_BUFFER_OVERWRITE(InPort,OutPort), "
+ "ON_RECEIVER_FULL(InPort,OutPort) "
+ "callback called in direct mode.");
Modified: trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/port/OutPortPushConnector.java
===================================================================
--- trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/port/OutPortPushConnector.java 2017-01-25 07:23:25 UTC (rev 915)
+++ trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/port/OutPortPushConnector.java 2017-01-25 07:34:37 UTC (rev 916)
@@ -197,7 +197,7 @@
* PORT_ERROR Other error}
*
*/
- public <DataType> ReturnCode write(final DataType data) {
+ public <DataType> ReturnCode write(DataType data) {
rtcout.println(Logbuf.TRACE, "write()");
if (m_directInPort != null) {
@@ -213,7 +213,7 @@
m_inPortListeners.
connectorData_[ConnectorDataListenerType.ON_RECEIVER_FULL].notify(m_profile, data);
rtcout.println(Logbuf.PARANOID,
- "ONBUFFER_OVERWRITE(InPort,OutPort), "
+ "ON_BUFFER_OVERWRITE(InPort,OutPort), "
+ "ON_RECEIVER_FULL(InPort,OutPort) "
+ "callback called in direct mode.");
Modified: trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/port/publisher/PublisherBase.java
===================================================================
--- trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/port/publisher/PublisherBase.java 2017-01-25 07:23:25 UTC (rev 915)
+++ trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/port/publisher/PublisherBase.java 2017-01-25 07:34:37 UTC (rev 916)
@@ -49,8 +49,8 @@
* @param usec
* @return ReturnCode
*/
- public abstract ReturnCode write(final OutputStream data, int sec, int usec);
- public abstract ReturnCode write(final OutputStream data);
+ public abstract ReturnCode write(OutputStream data, int sec, int usec);
+ public abstract ReturnCode write(OutputStream data);
/**
* <p> isActive </p>
*
Modified: trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/port/publisher/PublisherFlush.java
===================================================================
--- trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/port/publisher/PublisherFlush.java 2017-01-25 07:23:25 UTC (rev 915)
+++ trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/port/publisher/PublisherFlush.java 2017-01-25 07:34:37 UTC (rev 916)
@@ -166,7 +166,7 @@
* CONNECTION_LOST detected that the connection has been lost}
*
*/
- public ReturnCode write(final OutputStream data, int sec, int usec) {
+ public ReturnCode write(OutputStream data, int sec, int usec) {
if (m_consumer == null ) {
return ReturnCode.PRECONDITION_NOT_MET;
}
@@ -206,7 +206,7 @@
}
}
- public ReturnCode write(final OutputStream data) {
+ public ReturnCode write(OutputStream data) {
return this.write(data, -1, 0);
}
/**
@@ -309,23 +309,23 @@
// m_listeners.connectorData_[ConnectorDataListenerType.ON_BUFFER_READ].notify(m_profile, data);
// }
- protected void onSend(final OutputStream data) {
+ protected void onSend(OutputStream data) {
m_listeners.connectorData_[ConnectorDataListenerType.ON_SEND].notify(m_profile, data);
}
- protected void onReceived(final OutputStream data) {
+ protected void onReceived(OutputStream data) {
m_listeners.connectorData_[ConnectorDataListenerType.ON_RECEIVED].notify(m_profile, data);
}
- protected void onReceiverFull(final OutputStream data) {
+ protected void onReceiverFull(OutputStream data) {
m_listeners.connectorData_[ConnectorDataListenerType.ON_RECEIVER_FULL].notify(m_profile, data);
}
- protected void onReceiverTimeout(final OutputStream data) {
+ protected void onReceiverTimeout(OutputStream data) {
m_listeners.connectorData_[ConnectorDataListenerType.ON_RECEIVER_TIMEOUT].notify(m_profile, data);
}
- protected void onReceiverError(final OutputStream data) {
+ protected void onReceiverError(OutputStream data) {
m_listeners.connectorData_[ConnectorDataListenerType.ON_RECEIVER_ERROR].notify(m_profile, data);
}
Modified: trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/port/publisher/PublisherNew.java
===================================================================
--- trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/port/publisher/PublisherNew.java 2017-01-25 07:23:25 UTC (rev 915)
+++ trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/port/publisher/PublisherNew.java 2017-01-25 07:34:37 UTC (rev 916)
@@ -167,7 +167,7 @@
for (int i = 0; i < loopcnt; ++i) {
m_buffer.advanceRptr(postskip);
- final OutputStream cdr = m_buffer.get();
+ OutputStream cdr = m_buffer.get();
onBufferRead(cdr);
onSend(cdr);
@@ -540,7 +540,7 @@
* TIMEOUT Timeout occurred when writing to the buffer.}
*
*/
- public ReturnCode write(final OutputStream data, int sec, int usec) {
+ public ReturnCode write(OutputStream data, int sec, int usec) {
rtcout.println(Logbuf.PARANOID, "write()" );
if (m_consumer == null) { return ReturnCode.PRECONDITION_NOT_MET; }
if (m_buffer == null) { return ReturnCode.PRECONDITION_NOT_MET; }
@@ -569,7 +569,7 @@
return convertReturn(ret,data);
}
- public ReturnCode write(final OutputStream data) {
+ public ReturnCode write(OutputStream data) {
return this.write(data, -1, 0);
}
/**
@@ -648,7 +648,7 @@
*/
protected ReturnCode convertReturn(
jp.go.aist.rtm.RTC.buffer.ReturnCode status,
- final OutputStream data) {
+ OutputStream data) {
switch (status) {
case BUFFER_OK:
return ReturnCode.PORT_OK;
@@ -671,7 +671,7 @@
}
}
protected ReturnCode invokeListener(ReturnCode status,
- final OutputStream data) {
+ OutputStream data) {
// ret:
// PORT_OK, PORT_ERROR, SEND_FULL, SEND_TIMEOUT, CONNECTION_LOST,
// UNKNOWN_ERROR
@@ -729,43 +729,43 @@
/**
* <p> Connector data listener functions </p>
*/
- private void onBufferWrite(final OutputStream data) {
+ private void onBufferWrite(OutputStream data) {
m_listeners.connectorData_[ConnectorDataListenerType.ON_BUFFER_WRITE].notify(m_profile, data);
}
- protected void onBufferFull(final OutputStream data) {
+ protected void onBufferFull(OutputStream data) {
m_listeners.connectorData_[ConnectorDataListenerType.ON_BUFFER_FULL].notify(m_profile, data);
}
- protected void onBufferWriteTimeout(final OutputStream data) {
+ protected void onBufferWriteTimeout(OutputStream data) {
m_listeners.connectorData_[ConnectorDataListenerType.ON_BUFFER_WRITE_TIMEOUT].notify(m_profile, data);
}
- protected void onBufferWriteOverwrite(final OutputStream data) {
+ protected void onBufferWriteOverwrite(OutputStream data) {
m_listeners.connectorData_[ConnectorDataListenerType.ON_BUFFER_OVERWRITE].notify(m_profile, data);
}
- protected void onBufferRead(final OutputStream data) {
+ protected void onBufferRead(OutputStream data) {
m_listeners.connectorData_[ConnectorDataListenerType.ON_BUFFER_READ].notify(m_profile, data);
}
- protected void onSend(final OutputStream data) {
+ protected void onSend(OutputStream data) {
m_listeners.connectorData_[ConnectorDataListenerType.ON_SEND].notify(m_profile, data);
}
- protected void onReceived(final OutputStream data) {
+ protected void onReceived(OutputStream data) {
m_listeners.connectorData_[ConnectorDataListenerType.ON_RECEIVED].notify(m_profile, data);
}
- protected void onReceiverFull(final OutputStream data) {
+ protected void onReceiverFull(OutputStream data) {
m_listeners.connectorData_[ConnectorDataListenerType.ON_RECEIVER_FULL].notify(m_profile, data);
}
- protected void onReceiverTimeout(final OutputStream data) {
+ protected void onReceiverTimeout(OutputStream data) {
m_listeners.connectorData_[ConnectorDataListenerType.ON_RECEIVER_TIMEOUT].notify(m_profile, data);
}
- protected void onReceiverError(final OutputStream data) {
+ protected void onReceiverError(OutputStream data) {
m_listeners.connectorData_[ConnectorDataListenerType.ON_RECEIVER_ERROR].notify(m_profile, data);
}
Modified: trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/port/publisher/PublisherPeriodic.java
===================================================================
--- trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/port/publisher/PublisherPeriodic.java 2017-01-25 07:23:25 UTC (rev 915)
+++ trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/port/publisher/PublisherPeriodic.java 2017-01-25 07:34:37 UTC (rev 916)
@@ -83,7 +83,7 @@
rtcout.println(Logbuf.TRACE, "pushAll()");
while (m_buffer.readable() > 0) {
- final OutputStream cdr = m_buffer.get();
+ OutputStream cdr = m_buffer.get();
onBufferRead(cdr);
onSend(cdr);
@@ -111,7 +111,7 @@
rtcout.println(Logbuf.DEBUG, "buffer empty");
return ReturnCode.BUFFER_EMPTY;
}
- final OutputStream cdr = m_buffer.get();
+ OutputStream cdr = m_buffer.get();
onBufferRead(cdr);
onSend(cdr);
@@ -146,7 +146,7 @@
int postskip = m_skipn - m_leftskip;
for (int i = 0; i < loopcnt; ++i) {
m_buffer.advanceRptr(postskip);
- final OutputStream cdr = m_buffer.get();
+ OutputStream cdr = m_buffer.get();
onBufferRead(cdr);
onSend(cdr);
@@ -181,7 +181,7 @@
m_readback = true;
m_buffer.advanceRptr(m_buffer.readable() - 1);
- final OutputStream cdr = m_buffer.get();
+ OutputStream cdr = m_buffer.get();
onBufferRead(cdr);
onSend(cdr);
@@ -559,7 +559,7 @@
* has been performed.
* TIMEOUT Timeout occurred when writing to the buffer.}
*/
- public ReturnCode write(final OutputStream data, int sec, int usec) {
+ public ReturnCode write(OutputStream data, int sec, int usec) {
rtcout.println(Logbuf.PARANOID, "write()" );
if (m_consumer == null) { return ReturnCode.PRECONDITION_NOT_MET; }
if (m_buffer == null) { return ReturnCode.PRECONDITION_NOT_MET; }
@@ -583,7 +583,7 @@
return convertReturn(ret,data);
}
- public ReturnCode write(final OutputStream data) {
+ public ReturnCode write(OutputStream data) {
return this.write(data,-1,0);
}
@@ -649,7 +649,7 @@
*/
protected ReturnCode convertReturn(
jp.go.aist.rtm.RTC.buffer.ReturnCode status,
- final OutputStream data) {
+ OutputStream data) {
switch (status) {
case BUFFER_OK:
return ReturnCode.PORT_OK;
@@ -671,7 +671,7 @@
}
}
protected ReturnCode invokeListener(ReturnCode status,
- final OutputStream data) {
+ OutputStream data) {
// ret:
// PORT_OK, PORT_ERROR, SEND_FULL, SEND_TIMEOUT, CONNECTION_LOST,
// UNKNOWN_ERROR
@@ -736,15 +736,15 @@
/**
* <p> Connector data listener functions </p>
*/
- protected void onBufferWrite(final OutputStream data) {
+ protected void onBufferWrite(OutputStream data) {
m_listeners.connectorData_[ConnectorDataListenerType.ON_BUFFER_WRITE].notify(m_profile, data);
}
- protected void onBufferFull(final OutputStream data) {
+ protected void onBufferFull(OutputStream data) {
m_listeners.connectorData_[ConnectorDataListenerType.ON_BUFFER_FULL].notify(m_profile, data);
}
- protected void onBufferWriteTimeout(final OutputStream data) {
+ protected void onBufferWriteTimeout(OutputStream data) {
m_listeners.connectorData_[ConnectorDataListenerType.ON_BUFFER_WRITE_TIMEOUT].notify(m_profile, data);
}
@@ -752,27 +752,27 @@
// m_listeners.connectorData_[ConnectorListenerType.ON_BUFFER_OVERWRITE].notify(m_profile, data);
// }
- protected void onBufferRead(final OutputStream data) {
+ protected void onBufferRead(OutputStream data) {
m_listeners.connectorData_[ConnectorDataListenerType.ON_BUFFER_READ].notify(m_profile, data);
}
- protected void onSend(final OutputStream data) {
+ protected void onSend(OutputStream data) {
m_listeners.connectorData_[ConnectorDataListenerType.ON_SEND].notify(m_profile, data);
}
- protected void onReceived(final OutputStream data) {
+ protected void onReceived(OutputStream data) {
m_listeners.connectorData_[ConnectorDataListenerType.ON_RECEIVED].notify(m_profile, data);
}
- protected void onReceiverFull(final OutputStream data) {
+ protected void onReceiverFull(OutputStream data) {
m_listeners.connectorData_[ConnectorDataListenerType.ON_RECEIVER_FULL].notify(m_profile, data);
}
- protected void onReceiverTimeout(final OutputStream data) {
+ protected void onReceiverTimeout(OutputStream data) {
m_listeners.connectorData_[ConnectorDataListenerType.ON_RECEIVER_TIMEOUT].notify(m_profile, data);
}
- protected void onReceiverError(final OutputStream data) {
+ protected void onReceiverError(OutputStream data) {
m_listeners.connectorData_[ConnectorDataListenerType.ON_RECEIVER_ERROR].notify(m_profile, data);
}
More information about the openrtm-commit
mailing list