IREP_SOA Integration程序注释语法Annotations(概念)
20150506 Created By BaoXinjian
一、摘要
在將程序發布成SOA Integration接口時,需要在書寫程序時,在描述中需通過規定的語法書寫SOA接口,并發發布為WSDL
每種不同類型的程序,其對應語法稍不用
1. 語法可以參考Metalink:
Oracle E-Business Suite Integrated SOA Gateway Developer's Guide
Integration Repository Annotation Standards
2. 對應的程序類型
(1). Java Annotations
(2). PL/SQL Annotations
(3). Concurrent Program Annotations
(4). XML Gateway Annotations
(5). Business Event Annotations
(6). Business Entity Annotations
(7). Composite Service - BPEL Annotations
(8). Glossary of Annotations
3. 介紹常用的三種Java、PLSQL、Concurrent Program
?
二、PL/SQL Annotations標記
可以使用pls或pkh文件作為注釋對象
注釋PL/SQL packages時,只需要注釋Package Header即可,無需處理Package Body
1. Package層面必須填寫內容Required Class-level Annotations
must begin with description sentence(s) rep:scope rep:product rep:displayname rep:category--Use BUSINESS_ENTITY at the class level only if all underlying methods have the same business entity. --In those cases, you do not need to repeat the annotation at the method level. rep:businessevent (if an event is raised)2. Package層面可選填寫內容Optional Class-level Annotations
link see rep:lifecycle rep:compatibility rep:ihelp rep:metalink rep:doccd3. Procedure層面必須填寫內容Required Method-level Annotations
must begin with description sentence(s) param --Use only when applicable and when other tags such as @see and @rep:metalink do not provide parameter explanations. return (if applicable) rep:displayname rep:paraminfo rep:businessevent (if an event is raised)4. Procedure層面可以填寫內容Optional Method-level Annotations
link see rep:scope rep:lifecycle rep:compatibility rep:category --Use BUSINESS_ENTITY at the method level only when a class methods have heterogeneous business entities. rep:ihelp rep:metalink rep:doccd rep:appscontext rep:primaryinstance5. 實踐案例
create or replace package WF_ENGINE as /*#* This is the public interface for the Workflow engine. It allows* execution of various WF engine functions.* @rep:scope public* @rep:product WF* @rep:displayname Workflow Engine* @rep:lifecycle active* @rep:compatibility S* @rep:category BUSINESS_ENTITY WF_WORKFLOW_ENGINE*/ g_nid number; -- current notification id g_text varchar2(2000); -- text information /*#* Adds Item Attribute* @param itemtype item type* @param itemkey item key* @param aname attribute name* @param text_value add text value to it if provided.* @param number_value add number value to it if provided.* @param date_value add date value to it if provided.* @rep:scope public* @rep:lifecycle active* @rep:displayname Add Item Attribute*/ procedure AddItemAttr(itemtype in varchar2,itemkey in varchar2,aname in varchar2,text_value in varchar2 default null,number_value in number default null,date_value in date default null); END WF_ENGINE; /commit; exit;?
三、Concurrent Program Annotations標記
需要將并發程序通過FND_LOAD下載為并解析為ldt文件,再進行注釋寫法
1. 并發程序級別必須填寫內容Required Class-level Annotations
must begin with description sentence(s) --The annotation takes precedence over the concurrent program own definition in the LDT. One or the other must exist; otherwise, interface generation will fail. rep:scope rep:product rep:displayname --The annotation takes precedence over the concurrent program own definition in the LDT. One or the other must exist; otherwise, interface generation will fail. rep:category rep:businessevent (if an event is raised)2. 并發程序級別可選填寫內容Optional Class-level Annotations
link see rep:lifecycle rep:compatibility rep:ihelp rep:metalink rep:doccd rep:usestable rep:usesmap3. 沒有程序級別的注釋concurrent programs
4. 實踐案例
?
四、Java Annotations標記
1. Class級別必須填寫的內容注釋:Required Class-level Annotations
must begin with description sentence(s) rep:scope rep:product rep:implementation (only required for Java business service objects; not required for plain Java or SDOs) rep:displayname rep:service rep:servicedoc2. Class級別可選填寫的內容注釋:Optional Class-level Annotations
link see rep:lifecycle rep:category --Use BUSINESS_ENTITY at the class level only if all underlying methods have the same business entity. In those cases, you do not need to repeat the annotation at the method level. rep:compatibility rep:standard rep:ihelp rep:metalink rep:doccd rep:synchronicity3. 程序級別必須填寫的內容注釋:Required Method-level Annotations
must begin with description sentence(s) param --Use only when applicable and when other tags such as @see and @rep:metalink do not provide parameter explanations. return (if applicable) rep:paraminfo rep:displayname rep:businessevent (if an event is raised)4. 程序級別可選的填寫的內容注釋:Optional Method-level Annotations
link see rep:scope rep:lifecycle rep:compatibility rep:category --Use BUSINESS_ENTITY at the method level only when a class methods have heterogeneous business entities. rep:ihelp rep:metalink rep:doccd rep:appscontext rep:synchronicity rep:primaryinstance5. 時間案例
/*===========================================================================+| Copyright (c) 2004 Oracle Corporation, Redwood Shores, CA, USA || All rights reserved. |+===========================================================================+| HISTORY |+===========================================================================*/ package oracle.apps.po.tutorial;import oracle.jbo.domain.Number;import oracle.svc.data.DataObjectImpl; import oracle.svc.data.DataList;/*** The Purchase Order Data Object holds the purchase order data including * nested data objects such as lines and shipments.* * @see oracle.apps.fnd.framework.toolbox.tutorial.PurchaseOrderLineSDO* * @rep:scope public* @rep:displayname Purchase Order Data Object* @rep:product PO* @rep:category BUSINESS_ENTITY PO_PURCHASE_ORDER* @rep:servicedoc */ public class PurchaseOrderSDO extends DataObjectImpl {public PurchaseOrderSDO (){super();}/*** Returns the purchase order header id.* * @return purchase order header id.*/public Number getHeaderId(){return (Number)getAttribute("HeaderId");}/*** Sets the purchase order header id.* * @param value purchase order header id.* @rep:paraminfo {@rep:precision 5} {@rep:required}*/public void setHeaderId(Number value){setAttribute("HeaderId", value);}/*** Returns the purchase order name.* * @return purchase order name.* @rep:paraminfo {rep:precision 80}*/public String getName(){return (String)getAttribute("Name");}/*** Sets the purchase order header name.* * @param value purchase order header name.* @rep:paraminfo {@rep:precision 80}*/public void setName(String value){setAttribute("Name", value);}/*** Returns the purchase order description.* * @return purchase order description.* @rep:paraminfo {rep:precision 120}*/public String getDescription(){return (String)getAttribute("Description");}/*** Sets the purchase order header description.* * @param value purchase order header description.* @rep:paraminfo {@rep:precision 80}*/public void setDescription(String value){setAttribute("Description", value);}/*** @return the purchase order lines DataList.* @rep:paraminfo {@rep:innertype oracle.apps.fnd.framework.toolbox.tutorial.PurchaseOrderLineSDO}*/public DataList getLines(){return (DataList)getAttribute("Lines");}/*** @param list the putrchase order lines DataList.* @rep:paraminfo {@rep:innertype oracle.apps.fnd.framework.toolbox.tutorial.PurchaseOrderLineSDO}*/public void setLines(DataList list){setAttribute("Lines", list);}}?
Thanks and Regards
參考:http://docs.oracle.com/cd/E18727_01/doc.121/e12065/T511473T545912.htm#5466320
轉載于:https://www.cnblogs.com/eastsea/p/4752398.html
與50位技術專家面對面20年技術見證,附贈技術全景圖總結
以上是生活随笔為你收集整理的IREP_SOA Integration程序注释语法Annotations(概念)的全部內容,希望文章能夠幫你解決所遇到的問題。
- 上一篇: Java DOC 转换给 PDF 格式文
- 下一篇: 多线程与并发编程实践