newbie question on-viewmodels and common packages
CapableObjects Forums
Home       Members    Calendar    Who's On
Welcome Guest ( Login | Register )
        



newbie question on-viewmodels and common... Expand / Collapse
Author
Message
Posted 2010-04-13 02:06:08
Forum Newbie

Forum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum Newbie

Group: Forum Members
Last Login: 2010-04-21 23:10:13
Posts: 3, Visits: 26
Well,
I kind of hate to bother anyone, but it there is a place you could point me to read at least, I would be very grateful.
I can figure out how to play around with creating viewmodels, but it is not apparent to me how to actually RUN the things, with some data.

Also the instructions say
" To define the model for an EcoSpace the developer must
select one or more UML Packages. UML Packages may be used in more than one EcoSpace type, and in more than one
application. In the following diagram both EcoSpace types use the CommonPackage, in addition to this both the
AccountsPackage and the PersonnelPackage have classes that descend from classes within the CommonPackage."
(by the way, thank you SO much for these help files, they are great)
Creating one diagram in one package is a piece of cake with all the help you have provided...but what needs to happen for me to create something like the instructions mention: two packages, each having classes which descend from classes in a common package? And am I correct in thinking these three packages are all in the same ecospace, or at least can be (I'm sure they don't have to be)?

Here's what I am thinking - am I on the right track?
1) add a new eco project to the solution (specifying a dll package)
2) dblclick the ecospace.cs in the solution explorer
3)in the modlr tab, rightclick the packages level and in "import/export", edit the referenced packackes to include the ecopkg containing the class you wish to descend from.
4)this enables you to drag that class onto the new design space.

This clearly creates two ecospaces. Can you have multiple packages in one ecospace? Is there anything special to know about how to handle persistence with multiple ecospaces? (and how dirty object catcher works with multiple ecospaces)? What's the difference in importing a modlr file vs an ecopkg file vs an mmsceco file?
Post #5136
Posted 2010-04-13 09:59:10
Supreme Being

Supreme BeingSupreme BeingSupreme BeingSupreme BeingSupreme BeingSupreme BeingSupreme BeingSupreme Being

Group: Administrators
Last Login: 2010-11-30 12:17:13
Posts: 1 230, Visits: 1 382
* Each project (.csproj) can only have one model (ecomdl).
* A model can have multiple packages (ecopkg)
* A solution can contain multiple projects with models

The easiest to start with is to have all packages in the same model. Classes can inherit from any other class in the model. If you want to inherit from a class in a package that is in another project/model, you need to add that package (ecopkg) file as a referenced package. To do this, you rightclick the "Packages" node in the modlr treeview and select Import/Export -> Edit referenced packages. Add the ecopkg-file (it needs to be in a relative path that is the same for all developers that open the model).

Now you will have "readonly"-access to all classes in that package. You can inherit from them and even have associations to them, but not modify them (from within this model).

You normally don't need multiple ecospaces in your project though it is not illegal. What you should to do add a new model to your project is normally to add a ClassLibrary and then add an EcoModel to that project. You will need to add some Eco references (Eco.Handles.dll and Eco.Interfaces.dll).

The only difference between importing an mmcseco-file vs an ecopkg or a modlr-file is the format of the source file. In all cases, the model contents will be copied into the model you are importing to. The only way to have an external reference to an already existing package is the above mechanism with "Referenced packages"


/Jonas Hogstrom [CapableObjects]
Post #5143
Posted 2010-04-14 03:38:27
Forum Newbie

Forum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum Newbie

Group: Forum Members
Last Login: 2010-04-21 23:10:13
Posts: 3, Visits: 26
Thank you very much for your help Jonas: I am anxious to go see if I understand or only think I do
Post #5148
« Prev Topic | Next Topic »


Reading This Topic Expand / Collapse
Active Users: 0 (0 guests, 0 members, 0 anonymous members)
No members currently viewing this topic.
Forum Moderators: HansKarlsen, Jonas Hogstrom, PeterMorris

Permissions Expand / Collapse

All times are GMT +1:00, Time now is 10:17

Powered By InstantForum.NET v4.1.4 © 2012
Execution: 0,313. 9 queries. Compression Disabled.