DBA Data[Home] [Help]

APPS.WF_ITEM dependencies on WF_ENGINE

Line 31: wf_engine.synch_attr_count := 0;

27:
28: --clear ondemand flag
29: wf_item.c_ondemand := null;
30: -- Clear the synch attribute cache too
31: wf_engine.synch_attr_count := 0;
32:
33: exception
34: when others then
35: Wf_Core.Context('Wf_Item', 'ClearCache');

Line 68: if (wf_item.c_itemkey = wf_engine.eng_synch) then

64: -- 2. The cached item is a synch process AND
65: -- 3. The cached item has not yet completed
66: -- then raise an error. Other items cannot be accessed until synch
67: -- item completes, because it can't be restarted from db
68: if (wf_item.c_itemkey = wf_engine.eng_synch) then
69: -- Get status of root process of cached item
70: -- Note: If process completed successfully, the last thing in the
71: -- WIAS runtime cache should be the root process, which is the
72: -- only reason this will work.

Line 81: if (nvl(status, 'x') <> wf_engine.eng_completed) then

77: exception
78: when others then
79: status := 'x'; -- Treat errors like incomplete process
80: end;
81: if (nvl(status, 'x') <> wf_engine.eng_completed) then
82: Wf_Core.Token('ITEMTYPE', itemtype);
83: Wf_Core.Token('ITEMKEY', itemkey);
84: Wf_Core.Raise('WFENG_SYNCH_ITEM');
85: end if;

Line 220: if (WF_ENGINE.AddToItemAttrNumber(parent_itemType, parent_itemKey,

216: Wf_Core.Raise('WFENG_ITEM_LOOP');
217: end;
218: if (masterdetail) then
219: --Increment #WAITFORDETAIL master counter if it exists.
220: if (WF_ENGINE.AddToItemAttrNumber(parent_itemType, parent_itemKey,
221: '#WAITFORDETAIL', 1) is NOT NULL) then
222: if (parent_context is NOT null) then
223: --Increment/Create label counter.
224: if (length(parent_context) > 30) then

Line 229: elsif (WF_ENGINE.AddToItemAttrNumber(parent_itemType, parent_itemKey,

225: WF_CORE.Token('LABEL', parent_context);
226: WF_CORE.Token('LENGTH', '30');
227: WF_CORE.Raise('WFENG_LABEL_TOO_LARGE');
228:
229: elsif (WF_ENGINE.AddToItemAttrNumber(parent_itemType, parent_itemKey,
230: '#CNT_'||parent_context, 1)
231: is NULL) then
232: WF_ENGINE.AddItemAttr(itemType=>parent_itemType,
233: itemKey=>parent_itemKey,

Line 232: WF_ENGINE.AddItemAttr(itemType=>parent_itemType,

228:
229: elsif (WF_ENGINE.AddToItemAttrNumber(parent_itemType, parent_itemKey,
230: '#CNT_'||parent_context, 1)
231: is NULL) then
232: WF_ENGINE.AddItemAttr(itemType=>parent_itemType,
233: itemKey=>parent_itemKey,
234: aname=>'#CNT_'||parent_context,
235: number_value=>1);
236: end if; --Label Counter exists

Line 238: WF_ENGINE.AddItemAttr(itemType=>itemType, itemKey=>itemKey,

234: aname=>'#CNT_'||parent_context,
235: number_value=>1);
236: end if; --Label Counter exists
237:
238: WF_ENGINE.AddItemAttr(itemType=>itemType, itemKey=>itemKey,
239: aname=>'#LBL_'||parent_context,
240: text_value=>parent_context);
241:
242: else

Line 495: if (itemkey <> wf_engine.eng_synch) then

491: begin
492:
493: rootversion := Wf_Activity.Version(itemtype, wflow, actdate);
494:
495: if (itemkey <> wf_engine.eng_synch) then
496: -- NORMAL: Insert new item and attributes directly in the db
497: insert into WF_ITEMS (
498: ITEM_TYPE,
499: ITEM_KEY,

Line 546: if (itemkey <> wf_engine.eng_synch) then

542: wf_item.c_ondemand := false;
543: end;
544:
545: -- Initialize item attributes
546: if (itemkey <> wf_engine.eng_synch) then
547: -- NORMAL: store attributes in table
548: if(not wf_item.c_ondemand) then
549: -- only popluate when the flag is false
550: insert into WF_ITEM_ATTRIBUTE_VALUES (

Line 644: --on , WF Engine will raise exception etc.

640: --Here we will not do any error handling but return true/false
641: --for the case of lock_acquired or not . This leaves the caller
642: --the decision of what to do when a resource busy error occurs
643: --(ie FALSE) . For eg : Background engine will ignore it and move
644: --on , WF Engine will raise exception etc.
645:
646: function acquire_lock(itemtype in varchar2,
647: itemkey in varchar2,
648: raise_exception in boolean)

Line 746: if l_parent_itemType=Wf_Engine.GetItemAttrText(p_itemtype, p_itemkey,

742: if ((l_parent_itemType is NOT null) and
743: (l_parent_itemKey is NOT null)) then
744: --No counter Processing to be done for error process
745:
746: if l_parent_itemType=Wf_Engine.GetItemAttrText(p_itemtype, p_itemkey,
747: 'ERROR_ITEM_TYPE',TRUE) and l_parent_itemkey=
748: Wf_Engine.GetItemAttrText(p_itemtype, p_itemkey,
749: 'ERROR_ITEM_KEY',TRUE) then
750: return 0;

Line 748: Wf_Engine.GetItemAttrText(p_itemtype, p_itemkey,

744: --No counter Processing to be done for error process
745:
746: if l_parent_itemType=Wf_Engine.GetItemAttrText(p_itemtype, p_itemkey,
747: 'ERROR_ITEM_TYPE',TRUE) and l_parent_itemkey=
748: Wf_Engine.GetItemAttrText(p_itemtype, p_itemkey,
749: 'ERROR_ITEM_KEY',TRUE) then
750: return 0;
751: end if;
752:

Line 753: if (WF_ENGINE.AddToItemAttrNumber(l_parent_itemType, l_parent_itemKey,

749: 'ERROR_ITEM_KEY',TRUE) then
750: return 0;
751: end if;
752:
753: if (WF_ENGINE.AddToItemAttrNumber(l_parent_itemType, l_parent_itemKey,
754: '#WAITFORDETAIL', -1) is NOT null) then
755: if ((l_parent_context is NOT null) and
756: (WF_ENGINE.GetItemAttrText(p_itemType, p_itemKey,
757: '#LBL_'||l_parent_context, TRUE) is NOT NULL)) then

Line 756: (WF_ENGINE.GetItemAttrText(p_itemType, p_itemKey,

752:
753: if (WF_ENGINE.AddToItemAttrNumber(l_parent_itemType, l_parent_itemKey,
754: '#WAITFORDETAIL', -1) is NOT null) then
755: if ((l_parent_context is NOT null) and
756: (WF_ENGINE.GetItemAttrText(p_itemType, p_itemKey,
757: '#LBL_'||l_parent_context, TRUE) is NOT NULL)) then
758: l_context_label := '#LBL_'||l_parent_context;
759: if (WF_ENGINE.SetItemAttrText2(p_itemType, p_itemKey,
760: l_context_label, NULL)) then

Line 759: if (WF_ENGINE.SetItemAttrText2(p_itemType, p_itemKey,

755: if ((l_parent_context is NOT null) and
756: (WF_ENGINE.GetItemAttrText(p_itemType, p_itemKey,
757: '#LBL_'||l_parent_context, TRUE) is NOT NULL)) then
758: l_context_label := '#LBL_'||l_parent_context;
759: if (WF_ENGINE.SetItemAttrText2(p_itemType, p_itemKey,
760: l_context_label, NULL)) then
761: l_context_label := '#CNT_'||l_parent_context;
762: l_result := WF_ENGINE.AddToItemAttrNumber(l_parent_itemType,
763: l_parent_itemKey,

Line 762: l_result := WF_ENGINE.AddToItemAttrNumber(l_parent_itemType,

758: l_context_label := '#LBL_'||l_parent_context;
759: if (WF_ENGINE.SetItemAttrText2(p_itemType, p_itemKey,
760: l_context_label, NULL)) then
761: l_context_label := '#CNT_'||l_parent_context;
762: l_result := WF_ENGINE.AddToItemAttrNumber(l_parent_itemType,
763: l_parent_itemKey,
764: l_context_label,
765: -1);
766: end if;

Line 779: if (WF_ENGINE.SetItemAttrText2(p_itemType, p_itemKey,

775:
776: if (attrNames.COUNT > 0) then
777: for i in attrNames.FIRST..attrNames.LAST loop
778: l_context_label := '#LBL_'||attrNames(i);
779: if (WF_ENGINE.SetItemAttrText2(p_itemType, p_itemKey,
780: l_context_label, NULL)) then
781: l_context_label := '#CNT_'||attrNames(i);
782: l_result := WF_ENGINE.AddToItemAttrNumber(l_parent_itemtype,
783: l_parent_itemkey,

Line 782: l_result := WF_ENGINE.AddToItemAttrNumber(l_parent_itemtype,

778: l_context_label := '#LBL_'||attrNames(i);
779: if (WF_ENGINE.SetItemAttrText2(p_itemType, p_itemKey,
780: l_context_label, NULL)) then
781: l_context_label := '#CNT_'||attrNames(i);
782: l_result := WF_ENGINE.AddToItemAttrNumber(l_parent_itemtype,
783: l_parent_itemkey,
784: l_context_label,
785: -1);
786: end if; --#LBL_ exists as expected.

Line 805: l_result := WF_ENGINE.AddToItemAttrNumber(l_parent_itemtype,

801: and wiav2.item_key = p_itemKey
802: and wiav2.name = REPLACE(wiav.name,'#CNT_','#LBL_'));
803: if (attrNames.COUNT > 0) then
804: for i in attrNames.FIRST..attrNames.LAST loop
805: l_result := WF_ENGINE.AddToItemAttrNumber(l_parent_itemtype,
806: l_parent_itemkey,
807: attrNames(i), -1);
808: end loop;
809: end if; --There were unvisited ContinueFlow() activites in the child.

Line 837: WF_ENGINE.AbortProcess(c_abort.item_type, c_abort.item_key);

833: and wiav.item_key = wi.item_key
834: and wiav.name = 'ERROR_ACTIVITY_LABEL')
835: and end_date is null)
836: loop
837: WF_ENGINE.AbortProcess(c_abort.item_type, c_abort.item_key);
838: end loop;
839:
840: return 0;
841: exception

Line 843: Wf_Core.Context('WF_ENGINE', l_module, p_itemtype, p_itemkey,

839:
840: return 0;
841: exception
842: when ValTooLarge OR ValTooLargeNew then
843: Wf_Core.Context('WF_ENGINE', l_module, p_itemtype, p_itemkey,
844: l_parent_itemType, l_parent_itemKey);
845: WF_CORE.Token('LABEL', l_context_label);
846: WF_CORE.Token('LENGTH', 30);
847: WF_CORE.Raise('WFENG_LABEL_TOO_LARGE');