polly.c.chang wrote:
> 
> This works now.  However, when I was working on this function, I noticed a
> few things:
> 
> 1.  I originally called allDomainObjects() instead of allElements(), but I
> found that that function only seems to return domain objects inside the
> same design file.  It could not find duplicate objects defined in an
> imported file.  I am not sure if this behavior is intentional or not.  If
> it is, the name of the function seems kind of misleading.  If not, perhaps
> that function should call allElements() instead?  I am thinking that the
> function doesn't call allElements() because we didn't have that until
> recently.  This also applies to the other allEntities and allServices
> functions.
> 

It is a bug. It should use allElements()


polly.c.chang wrote:
> 
> 2.  I would like to be able to do the same validation for Services and
> Repositories.  I know that I can copy and paste the domainObjectsForName()
> function that I wrote and replace the type, but is there a more generic
> way to write the function?  Just wondering.
> 
> 

Maybe something like this:
List[emf::EObject] objectsWithSameTypeAndName(emf::EObject this, String
name) : 
        allElements().select(d | (d.metaType = this.metaType) && (d.id() ==
name));

Can you adjust Extensions.ext and add the new checks and send me the
changes, and I will commit it to trunk. 

/Patrik
-- 
View this message in context: 
http://www.nabble.com/-Sculptor--Duplicate-name-validation-tp20901565s17564p20903401.html
Sent from the Fornax-Platform mailing list archive at Nabble.com.


------------------------------------------------------------------------------
SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada.
The future of the web can't happen without you.  Join us at MIX09 to help
pave the way to the Next Web now. Learn more and register at
http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/
_______________________________________________
Fornax-developer mailing list
Fornax-developer@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/fornax-developer

Reply via email to