@@ -39,7 +39,51 @@ export class DataFlowService extends ServiceBase {
3939 options . prjCoordSys = options . projection ;
4040 }
4141 super ( url , options ) ;
42- this . dataFlow = new DataFlow ( url , options , this . _defaultEvent . bind ( this ) ) ;
42+ this . dataFlow = new DataFlow ( url , options ) ;
43+ /**
44+ * @event DataFlowService#broadcastSocketConnected
45+ * @description broadcast Socket 连接成功。
46+ */
47+ /**
48+ * @event DataFlowService#broadcastSocketError
49+ * @description broadcast Socket 连接失败。
50+ */
51+ /**
52+ * @event DataFlowService#broadcastFailed
53+ * @description 广播失败。
54+ */
55+ /**
56+ * @event DataFlowService#broadcastSucceeded
57+ * @description 广播成功。
58+ */
59+ /**
60+ * @event DataFlowService#subscribeSocketConnected
61+ * @description 订阅数据连接成功。
62+ */
63+ /**
64+ * @event DataFlowService#subscribeSocketError
65+ * @description 订阅数据连接失败。
66+ */
67+ /**
68+ * @event DataFlowService#messageSucceeded
69+ * @description 获取信息成功。
70+ */
71+ /**
72+ * @event DataFlowService#setFilterParamSucceeded
73+ * @description 设置过滤参数成功。
74+ */
75+
76+ this . dataFlow . events . on ( {
77+ "broadcastSocketConnected" : this . _defaultEvent ,
78+ "broadcastSocketError" : this . _defaultEvent ,
79+ "broadcastFailed" : this . _defaultEvent ,
80+ "broadcastSucceeded" : this . _defaultEvent ,
81+ "subscribeSocketConnected" : this . _defaultEvent ,
82+ "subscribeSocketError" : this . _defaultEvent ,
83+ "messageSucceeded" : this . _defaultEvent ,
84+ "setFilterParamSucceeded" : this . _defaultEvent ,
85+ scope : this
86+ } ) ;
4387 var me = this ;
4488 me . on ( 'subscribeSocketConnected' , function ( e ) {
4589 /**
0 commit comments