remove duplications in sequence [message #72056] |
Wed, 16 January 2008 05:57  |
Eclipse User |
|
|
|
Hello,
I used 'union' joined several Sequence, then used asSet() converted it to
a Set. A problem is duplications are not be removed.
Thanks for any help.
Wong.
|
|
|
|
|
|
|
|
|
|
Re: [ATL] Re: remove duplications in sequence [message #72729 is a reply to message #72682] |
Fri, 18 January 2008 11:48   |
Eclipse User |
|
|
|
Hello, Quentin,
I have worked on this several days. It is very strange.
I used the resolveTemp to assign all relationships to a container.
Everything works fine, but I can not retrieve the value of
attribute(label) of relationship to compare.
XML!Element.allInstancesFrom('IN')->select(e|e.name='skos:subject')- >collect(e|thisModule.resolveTemp(e,
'infRelSub'))
-----------------------
Then I used distinct to assign all relationships to the container, I can
retrieve the value of all attributes and compare, but the container does
not change after I deleted some elements in 'do' section of the rule.
conceptRelations <- allre),
allre: distinct CAVIAr!ConceptRelationship foreach (i in b)(
label<-'include',
source<-i.parent,
target<- if ........
Thank you very much.
Wong.
|
|
|
|
|
Powered by
FUDForum. Page generated in 0.04927 seconds