Item type |
SIG Technical Reports(1) |
公開日 |
2018-03-02 |
タイトル |
|
|
タイトル |
非同期処理の記述を支援するライブラリの提案と実装 |
タイトル |
|
|
言語 |
en |
|
タイトル |
Proposal and Implementation of Library Supporting Descriptions of Asynchronous Processing |
言語 |
|
|
言語 |
jpn |
キーワード |
|
|
主題Scheme |
Other |
|
主題 |
コード解析・ライブラリ |
資源タイプ |
|
|
資源タイプ識別子 |
http://purl.org/coar/resource_type/c_18gh |
|
資源タイプ |
technical report |
著者所属 |
|
|
|
芝浦工業大学 |
著者所属 |
|
|
|
芝浦工業大学 |
著者所属(英) |
|
|
|
en |
|
|
Shibaura Institute of Technology |
著者所属(英) |
|
|
|
en |
|
|
Shibaura Institute of Technology |
著者名 |
佐久間, 隆平
福田, 浩章
|
著者名(英) |
Ryuhei, Sakuma
Hiroaki, Fukuda
|
論文抄録 |
|
|
内容記述タイプ |
Other |
|
内容記述 |
近年のソフトウェア開発では,非同期処理を取り扱う機会が増加している.非同期処理とは,関数の終了を待たずに次の処理を開始し,関数の終了は処理結果とともに通知されるという仕組みである.非同期処理は,データの取得や出力といった I / O 処理など,時間のかかる処理で頻繁に用いられ,処理結果を受け取るためにコールバック関数が使用される.また,非同期処理の関数では処理の終了するタイミングが一意に決まらないため,処理の順序を保つためにはコールバック関数を入れ子にする必要がある.その結果,コールバック関数を多用する場合や入れ子にする場合などはコードが複雑になる.この複雑化を回避する手法として,現在は Promise が頻繁に用いられている.また,Promise には複数の非同期処理を並列に実行し,それらの実行状況に応じて then に登録した関数を実行する仕組みとして Promise.all や Promise.race が実装されている.しかし,これらのメソッドでは then に登録した関数を実行するタイミングが一意に決まるため柔軟な対応を行うことができない.そこで本研究では,コールバック関数の実行するタイミングを,開発者が同一のインタフェースで柔軟に変更できるライブラリ,MatchingPromise の提案と実装を行う.MatchingPromise では,コールバック関数を実行するタイミングを指定する手段として,パターンマッチを用いる.そして,柔軟にパターンを指定する方法として MatcherCells を用いる.また,MatchingPromise の実装後,評価を行い,コールバック関数の実行タイミングを柔軟に変更可能であることを示した. |
論文抄録(英) |
|
|
内容記述タイプ |
Other |
|
内容記述 |
In recent software development, opportunities to deal with asynchronous processing are increasing. The synchronization process starts the next process without waiting for the end of the function and terminates the function It is a mechanism that it is notified together with fruits.In asynchronous processing, data acquisition and output Frequently used in time-consuming processing such as I / O processing such as power, callbacks are used to receive processing results. Also, with the asynchronous processing function, the timing at which the processing ends can not be uniquely determined, In order to preserve processing order, it is necessary to nest callbacks. As a result, when call back is heavily used, nested etc. The code becomes complicated. As a method to avoid this complication and Currently Promise is used frequently, and Promise contains multiple non - Synchronization processing was executed in parallel and registered in then according to their execution status Promise.all and Promise.race are implemented as a mechanism for executing functions However, these methods execute the function registered in then It is impossible to flexibly respond because timing is uniquely determined. Therefore, in this research, the timing to execute the callback function is set to be the same as that by the developer Proposal and implementation of library, MatchingPromise which can be flexibly changed by interface In MatchingPromise, as a means to specify the timing to execute the callback function, putter We use MatcherCells as a method to flexibly specify patterns. After implementing MatchingPromise, evaluation was performed, and it was shown that the execution timing of the callback function can be changed flexibly. |
書誌レコードID |
|
|
収録物識別子タイプ |
NCID |
|
収録物識別子 |
AN10112981 |
書誌情報 |
研究報告ソフトウェア工学(SE)
巻 2018-SE-198,
号 19,
p. 1-8,
発行日 2018-03-02
|
ISSN |
|
|
収録物識別子タイプ |
ISSN |
|
収録物識別子 |
2188-8825 |
Notice |
|
|
|
SIG Technical Reports are nonrefereed and hence may later appear in any journals, conferences, symposia, etc. |
出版者 |
|
|
言語 |
ja |
|
出版者 |
情報処理学会 |