IBASE read buffer
Created by Jerry Wang, last modified on Apr 22, 2014
Function group IB_CRM_API里定義了一個類型為int的全局變量handle, 其作用是作為一個指向internal read / write buffer的pointer。
?
?
?
?
write / read buffer定義在下列的function group里:
?
?
?
?
?
?
?
?
?
?
使用下列report 測試:
?
?
PARAMETERS:?id?TYPE?ibib-ibase?OBLIGATORY?DEFAULT?'13835'.
DATA:?ls_header??????TYPE?ibap_head1,
??????lt_struc_tab???TYPE?ibap_struc1_tab,
??????ls_line????????LIKE?LINE?OF?lt_struc_tab,
??????ls_comp????????TYPE?ibap_dat1,
??????ls_comp_detail?TYPE?ibap_comp2.
ls_header-ibase?=?id.
CALL?FUNCTION?'CRM_IBASE_GET_DETAIL'
??EXPORTING
????i_ibase_head??????=?ls_header
??IMPORTING
????e_struc_ibase_tab?=?lt_struc_tab
??EXCEPTIONS
????not_specified?????=?1
????doesnt_exist??????=?2
????no_authority??????=?3.
CHECK?sy-subrc?=?0.
LOOP?AT?lt_struc_tab?INTO?ls_line.
??WRITE:?/?'Component?ID:?'?,?ls_line-instance?COLOR?COL_NEGATIVE.
??ls_comp-ibase?=?id.
??ls_comp-instance?=?ls_line-instance.
??CALL?FUNCTION?'CRM_IBASE_COMP_GET_DETAIL'
????EXPORTING
??????i_comp????????=?ls_comp
????IMPORTING
??????e_comp_det????=?ls_comp_detail
????EXCEPTIONS
??????not_specified?=?1
??????doesnt_exist??=?2
??????no_authority??=?3.
??WRITE:?/?'Component?Description:'?,?ls_comp_detail-descr?COLOR?COL_POSITIVE.
ENDLOOP.
?
?
?
UI上有一個root IBASE 13835,里面包含13836和13837兩個IBASE component。
?
?
在使用CRM_IBASE_GET_DETAIL獲取IBASE detail時,首先要獲得一個handler,其value 為1:
?
?
?
首先去IBIBHANDLE_TAB buffer table里的write buffer IBIB_PROC_TAB 嘗試讀取指定的IBASE信息,
?
?
?
讀取失敗,再嘗試read buffer,仍然失敗:
?
?
?
最后從DB table IBIB取值,然后將讀取出的信息寫入read buffer:
?
?
?
對于讀取IBASE hierarchy的邏輯同理:
?
?
?
采用buffer class讀取instance信息:
?
?
?
?
雙擊c_wa-r_engine->struc->G_R_STRUC_BUF查看read buffer和write buffer:
?
可以發現在read scenario里read buffer被填充,而write buffer為空:
?
?
?
總結
以上是生活随笔為你收集整理的IBASE read buffer的全部內容,希望文章能夠幫你解決所遇到的問題。
- 上一篇: 西藏公积金怎么提取出来 西藏的公积金如何
- 下一篇: 哪些彩票能用手机购买?手机彩票APP推荐