| Oracle® Fusion Middleware Oracle Business Process Managementユーザーズ・ガイド 11g リリース1 (11.1.1.7) B61408-10 |
|
![]() 前 |
![]() 次 |
この付録では、プロセス・ワークスペースに対して、ビューのお気に入りリスト、アプリケーション、およびお気に入りペインで使用可能になるカスタマイズ済み外部アプリケーションおよびリンクを作成する方法を説明します。また、プロセス・ワークスペースとワークリスト・アプリケーションの両方に対して、受信ボックスに表示される列を指定する方法も説明します。
|
注意: 任意の場所に一時ディレクトリを作成します(例: |
アプリケーションをカスタマイズするには:
Oracle JDeveloperでOracle Application Development Frameworkプロジェクトを作成します。図C-1は、「Fusion Webアプリケーション(ADF)の作成」ダイアログ・ボックスを示しています。
Javaクラスを作成し、WorkspaceCustomisationImplという名前を付与します。
ワークリスト・アプリケーションJARファイルを含めます。図C-2は、追加されるBPMワークリスト・コンポーネント・ライブラリを示しています。
カスタマイズ・クラスを作成します。このサンプルのクラスは、受信ボックス列を変更し、外部アプリケーションおよびリンクをカスタマイズします。例として、WorkspaceCustomisationImplとそのコンテンツを次に示します。
package view.customisationimpl;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
import oracle.bpel.services.workflow.client.IWorkflowServiceClient;
import oracle.bpel.services.workflow.runtimeconfig.IRuntimeConfigService;
import oracle.bpel.services.workflow.runtimeconfig.model.AttributeLabelType;
import oracle.bpel.services.workflow.runtimeconfig.model.AttributeLabelUsageList;
import oracle.bpel.services.workflow.runtimeconfig.model.AttributeLabelUsages;
import oracle.bpel.services.workflow.verification.IWorkflowContext;
import oracle.bpm.ui.customization.CustomLink;
import oracle.bpm.ui.customization.IBPMUICustomizations;
public class WorkspaceCustomisationImpl implements IBPMUICustomizations {
private static Map displayNameMap = new HashMap();
public WorkspaceCustomisationImpl() {
displayNameMap.put("instanceId", "Instance Id");
displayNameMap.put("protectedTextAttribute1", "Business Status");
}
public List<CustomLink> getCustomGlobalLinks() {
CustomLink globalLink1 =
new CustomLink("Oracle Home Page", "www.oracle.com", null);
CustomLink globalLink2 =
new CustomLink("Self Services Application", "http://global-ebusiness.example.com/",
null);
CustomLink globalLink3 =
new CustomLink("BUG DB", "https://bug.example.com/", null);
List<CustomLink> globalLinks = new ArrayList<CustomLink>();
globalLinks.add(globalLink1);
globalLinks.add(globalLink2);
globalLinks.add(globalLink3);
return globalLinks;
}
public String getColumnNames() {
return "title,taskNumber,instanceId,creator,protectedTextAttribute1";
}
private static void initDisplayMap(IWorkflowServiceClient client,
IWorkflowContext context) {
// you can use service to load all label names for text attributes
if (displayNameMap == null) {
synchronized (String.class) {
if (displayNameMap == null) {
displayNameMap = new HashMap();
try {
IRuntimeConfigService service =
client.getRuntimeConfigService();
AttributeLabelUsageList list =
service.getAttributeLabelUsages(context, "Text");
List<AttributeLabelUsages> list1 =
list.getAttributeLabelUsages();
for (AttributeLabelUsages usage : list1) {
AttributeLabelType type = usage.getLabel();
displayNameMap.put(type.getTaskAttribute(),
type.getLabelName());
}
} catch (Exception exc) {
}
}
}
}
}
public String getColumnDisplayName(IWorkflowServiceClient client,
IWorkflowContext context,
java.lang.String colName) {
initDisplayMap(client, context);
return (String)displayNameMap.get(colName);
}
}
JARデプロイメント・プロファイルを作成します。customer-impl.jarという名前のJARファイルを作成します。
このファイルを共有ライブラリcustom.client.applib.jarの一部としてデプロイします。これを行うには、付録D「イメージおよびJARファイルの共有ライブラリJARファイルの一部としてのデプロイ」の説明のとおり、MANIFEST.MFファイルと共有ライブラリを更新します。
カスタマイズによっては、その効果をここで確認できます。
プロセス・ワークスペース用のカスタマイズを実行し、外部アプリケーションの作成と「タスクの詳細」ペインでの受信ボックス列の指定のいずれか(あるいはその両方)を実行した場合、次が表示されます: