Solved

Need to learn to read a Class Diagram

Posted on 2010-08-14
10
522 Views
Last Modified: 2013-12-17
I can not read the attached Class Diagram.

Please describe the meaning of the various pointers and inter-relationships.

I am trying to understand View-Model-ViewModel and find it tricky...


Thanks,
newbieweb
ViewModelClassDiagram.png
0
Comment
Question by:newbieweb
  • 6
  • 3
10 Comments
 

Author Comment

by:newbieweb
ID: 33438497
Also, this demo project has a second Class Diagram which might explain the first...

Thanks,
newbieweb
ClassDiagram2.png
0
 
LVL 42

Assisted Solution

by:sedgwick
sedgwick earned 150 total points
ID: 33440119
what exactly u don't understand?
i assume u have object-oriented knowledge which is a fundamental to understand the relationships of the classes here.
i can go through each diagram and describe in words what are the relationships between the classes if u like.
0
 
LVL 96

Accepted Solution

by:
Bob Learned earned 350 total points
ID: 33440498
The second one is easier to read, since it is just a simple inheritance chain:

CommandViewModel : ViewModelBase
WorkspaceViewModel : ViewModelBase

CustomerViewModel : WorkspaceViewModel, IDataErrorInfo
AllCustomersViewModel : WorkspaceViewModel
MainWindowViewModel : WorkspaceViewModel

Since I moved passed the Class Diagram tool to other things, I don't have a lot of experience with the all the symbols.  In the first diagram, it looks like dependency/association links.  I would be curious to know what those single, and double-arrow links mean.  

0
 

Author Comment

by:newbieweb
ID: 33440667
I am interested in the English desriptions for the arrows, etc. which connect the charts.
0
 
LVL 96

Expert Comment

by:Bob Learned
ID: 33442104
It might help to know how to read the class diagram, if you include the source code that was used to generate the diagram...
0
Why You Should Analyze Threat Actor TTPs

After years of analyzing threat actor behavior, it’s become clear that at any given time there are specific tactics, techniques, and procedures (TTPs) that are particularly prevalent. By analyzing and understanding these TTPs, you can dramatically enhance your security program.

 

Author Comment

by:newbieweb
ID: 33442184
Here is the link where I downloaded this MVVM demo from MS.

http://code.msdn.microsoft.com/mag200902MVVM/Release/ProjectReleases.aspx?ReleaseId=2026

I was trying to learn to read the class diagram so I could then understand the code:)
0
 

Author Comment

by:newbieweb
ID: 33442197
I have shifted my attention away from this demo to trying to get my Winforms app to use its first WPF form.

I could really use help on my other post:

http://www.experts-exchange.com/Microsoft/Development/Microsoft_Programming/WPF_and_Silverlight/Q_26404120.html

if you get the chance.  I have trouble with the namespace.

Thanks.
0
 

Author Comment

by:newbieweb
ID: 33442398
I am going back to the tried and true WinForms and Visual Studio 2008.  I'm going to close out this question to save you all the time...

I find that an error in the XAML causes Visual Studio 2010 to hand and hang.  So I have no time right now for that steep learning curve.

Model-View-Presenter, WinForms, LINQ and Entity Framework wil have to do :)
0
 

Author Closing Comment

by:newbieweb
ID: 33442404
Thanks.
0
 
LVL 96

Expert Comment

by:Bob Learned
ID: 33442457
I think that it is still a question worth answering, since I don't use the Class Diagram tool, so I don't know what those errors are referring to.

The CustomerViewModel has a private field (_customer), which depends on the Customer class.  That arrow is a dependency indicator between the two classes.

The AllCustomersViewModel.AllCustomers property is an ObservableCollection of CustomerViewModel, which is an association.
0

Featured Post

Do You Know the 4 Main Threat Actor Types?

Do you know the main threat actor types? Most attackers fall into one of four categories, each with their own favored tactics, techniques, and procedures.

Join & Write a Comment

A theme is a collection of property settings that allow you to define the look of pages and controls, and then apply the look consistently across pages in an application. Themes can be made up of a set of elements: skins, style sheets, images, and o…
Whether you've completed a degree in computer sciences or you're a self-taught programmer, writing your first lines of code in the real world is always a challenge. Here are some of the most common pitfalls for new programmers.
This is Part 3 in a 3-part series on Experts Exchange to discuss error handling in VBA code written for Excel. Part 1 of this series discussed basic error handling code using VBA. http://www.experts-exchange.com/videos/1478/Excel-Error-Handlin…
You have products, that come in variants and want to set different prices for them? Watch this micro tutorial that describes how to configure prices for Magento super attributes. Assigning simple products to configurable: We assigned simple products…

746 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

12 Experts available now in Live!

Get 1:1 Help Now