Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » EMF » Creation of intermediate classes in FeaturePath
Creation of intermediate classes in FeaturePath [message #1780615] Wed, 24 January 2018 16:43 Go to next message
Michal Zyla is currently offline Michal ZylaFriend
Messages: 18
Registered: August 2016
Junior Member
Hello,

i'm looking for a solution for a follwoing problem. Let's asume follwing model
Person -> Adress.houseNumber. I want to bind the houseNumber to a text field using FeaturePath but I want that an empty Adress object is created if Person doesn't have the reference set. On subsequent edits (when the intermediate object is there) everything works as expected. I couldn' find any way to hook the behaviour.

Regards
Michal
Re: Creation of intermediate classes in FeaturePath [message #1780632 is a reply to message #1780615] Thu, 25 January 2018 06:43 Go to previous message
Ed Merks is currently offline Ed MerksFriend
Messages: 33140
Registered: July 2009
Senior Member
I'm not so familiar with all the details of data binding; Tom Schindl implemented and uses that. At some point in the code, you must create a Person instance; perhaps best at that point to immediately create an Address instance and set it, and then ensure that the UI does not allow it to be deleted. If using EMF.Edit, you can specialize the child creation code, XyzItemProvider.collectNewChildDescriptors where Xyz is the container of Person.

Ed Merks
Professional Support: https://www.macromodeling.com/
Previous Topic:[Announce] Stop Support for GWT
Next Topic:Using an External API with EMF
Goto Forum:
  


Current Time: Wed Apr 24 19:41:39 GMT 2024

Powered by FUDForum. Page generated in 0.02806 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top