04-02-2015 11:51 AM
Hello,
I use Mega API to communicate via Java Application ( I'm include Mega Vocabulary in my projects ).
I'm retreive all mega object like "Business Process", "Organizational Process" etc... And i navigate to linked collection like this :
But when i try to get predecessor/successor of sequenceFlow megaObject, Mega API return me empty list...
public static final String MAE_Successor = "~jqV6ztHL71M0[Sequence Flow.Successor]";
public static final String MAE_Predecessor = "~2sV6luHL79O0[Sequence Flow.Predecessor]";
When i check the sequence Flow element in the Mega Repository, he has only one predecessor/successor. But MegaApi return me empty list.
When i launch :
sequenceFlow.isMemberName(MegaSequenceFlow.MAE_OwnerElement); => resutl is True
sequenceFlow.isMemberName(MegaSequenceFlow.MAE_Predecessor); => result is True
sequenceFlow.getAttribute(MegaSequenceFlow.MAE_Predecessor); => return null
sequenceFlow.getCollection("TestHackValue") => Launch exception
sequenceFlow.getCollection(MegaSequenceFlow.MAE_Predecessor).size() => 0 return empty list !!!!!!
It's a bug in Mega API ?
Can someone help me ?
Solved! Go to Solution.
17-01-2017 07:42 AM
09-02-2015 04:52 AM
I am new to filters: but i usually just use oRoot.GetSelection("") to get specific type of objects.
05-02-2015 09:11 AM - edited 05-02-2015 09:12 AM
Hi
mgObject.Getcollection("Owned Element") returns objects of the abstract metaclass "BPMN Owned Element".
You can filter this result to retain only sequence flow objects:
Megacollection mgColelction = mgObject.getCollection(BusinessProcess.MAE_OwnedElement).Filter("~jsV6VsHL7vJ0[Sequence Flow] ");
Best regards
Gregory