none
Code stubbing with Visual Studio 2010 UML modeling RRS feed

  • Question

  • Hello,

    I'd like to first say that I'm very impressed with the work done on Visual Studio 2010. Albeit its a little slow, but that's totally understandable due to the number of COM Inter-ops that need to take place with the new designers. Now onto the question.

    Currently I'm exploring my way through all the new features added to the IDE and I found a feature that will hopefully be of great help to me. The UML Modeling tool in the Architecture Addition. I wanted to create a new test project, nothing special. I started out with creating just a standard UML Logical Class Diagram. Then after I had finished I wanted to export my diagram to C# code with class stubs but I couldn't figure out how to do it. So naturally I consulted MSDN, but I couldn't find any reference to the top down approach of design and sort of gave up on it. Then I happened to be on the Channel 9 website and I watch the Top down architecture video and they alluded to the possibility of Visual Studio 2010 being able to accomplish this task.

    So I guess my question is, can Visual Studio 2010 take a Logical Class Diagram and generate code stubs from it?

    I'm currently using Visual Studio 2010 Beta 1 Team System on Windows 7 (if that helps any).

    Thank you,
    Aaron
    Wednesday, August 12, 2009 10:53 PM

Answers

All replies

  • Hi Aaron,

    Glad to hear that you like the new features in Visual Studio 2010, especially the modeling tools in the Architecture Edition.

    The bad news is that we currently don't support generating code from Logical Class Diagrams.

    Now for the good news.. :)  Since Beta 1 we have invested a lot of effort in making the tool extensibile (be able to access the underlying model data, add custom commands, etc.).   We intend to ship several features by leveraging this extensibility.  Generating code from Logical Class Diagrams is at the very top of such a feature list.   We are still working out the delivery mechanism.  Stay tuned for an announcement on that front.

    BTW, thanks also for your feedback on (slow) performance of VS.  Improving performance is another area all teams within Visual Studio have worked heavily on.  Expect to see improved performance in Beta 2.

    Cheers,
    Ramesh Rajagopal.
    This posting is provided "AS IS" with no warranties, and confers no rights.
    Monday, August 17, 2009 7:14 AM
    Moderator
  • Hello. 

    Yesterday, I attended to the ALM 09 sessions here in Spain. The same question came up in one of the sessions and the answer was that in the RTM of March 22 is not going to implement this feature. The only way to do this seems to be use DSL toolkit, but i'm not sure of what this involve. 

    Desarrollador de software
    Wednesday, November 25, 2009 9:30 AM
  • Hi Aaron,

    Glad to hear that you like the new features in Visual Studio 2010, especially the modeling tools in the Architecture Edition.

    The bad news is that we currently don't support generating code from Logical Class Diagrams.

    Now for the good news.. :)  Since Beta 1 we have invested a lot of effort in making the tool extensibile (be able to access the underlying model data, add custom commands, etc.).   We intend to ship several features by leveraging this extensibility.  Generating code from Logical Class Diagrams is at the very top of such a feature list.   We are still working out the delivery mechanism.  Stay tuned for an announcement on that front.

    BTW, thanks also for your feedback on (slow) performance of VS.  Improving performance is another area all teams within Visual Studio have worked heavily on.  Expect to see improved performance in Beta 2.

    Cheers,
    Ramesh Rajagopal.
    This posting is provided "AS IS" with no warranties, and confers no rights.

    Hello,

    To me, being able to design in UML without being able to generate code or reverse engineering is like having a car with no wheels. The tool could be very nice, I mean very very nice... A lamborghini with no wheel is totally useless !!!
    Eric Ouellet

    Eric Ouellet
    Thursday, January 7, 2010 6:37 PM
  • Hi Aaron,

    Glad to hear that you like the new features in Visual Studio 2010, especially the modeling tools in the Architecture Edition.

    The bad news is that we currently don't support generating code from Logical Class Diagrams.

    Now for the good news.. :)  Since Beta 1 we have invested a lot of effort in making the tool extensibile (be able to access the underlying model data, add custom commands, etc.).   We intend to ship several features by leveraging this extensibility.  Generating code from Logical Class Diagrams is at the very top of such a feature list.   We are still working out the delivery mechanism.  Stay tuned for an announcement on that front.

    BTW, thanks also for your feedback on (slow) performance of VS.  Improving performance is another area all teams within Visual Studio have worked heavily on.  Expect to see improved performance in Beta 2.

    Cheers,
    Ramesh Rajagopal.
    This posting is provided "AS IS" with no warranties, and confers no rights.

    Hello,

    To me, being able to design in UML without being able to generate code or reverse engineering is like having a car with no wheels. The tool could be very nice, I mean very very nice... A lamborghini with no wheel is totally useless !!!
    Eric Ouellet

    Eric Ouellet

    Until then you can put some of your own wheels on it. I've been looking into options also for a new project that will hopefully be developed in 2010. There's a couple of viable plugins it seems (Visual Paradigm for UML seems decent). It would of course be preferable to have everything completely integrated. Now that Microsft are part of the OMG I'm sure we'll start seeing this.

    I like the lamborghini reference... but surely it's more of a slower big vehicle but with great comfort inside like a Hummer lol
    Friday, January 15, 2010 11:05 AM
  • You can use text templates to generate code from UML models. Here is how:

    http://www.olegsych.com/2010/01/uml-modeling-and-code-generation-in-visual-studio-2010/

    According to Peter Provost (a PM at Microsoft), this is the approach the architecture team intended for code generation: http://www.peterprovost.org/blog/post/UML-Modeling-and-Code-Generation-in-Visual-Studio-2010.aspx


    Oleg
    Wednesday, February 24, 2010 12:45 PM
  • Thanks for the info.

    Personnally, I follow information (UML - Code generation/reverse engineering) on the Cameron Skinner Blog at http://blogs.msdn.com/camerons/archive/2010/03/19/announcing-the-first-feature-pack-for-vs2010-visualization-and-modeling-tools.aspx

    I think a solution for MSDN ultimate subscribers should be released soon (near 2010-05-??)

    Eric


    Eric Ouellet
    Wednesday, April 28, 2010 9:08 PM
  •  

    You can now download the Visualization and Modeling Feature Pack to generate code from UML class diagrams.


    Esther Fan | VS Visualization and Modeling Tools, Content Lead | If a post answers your question, please click "Mark As Answer" on that post. Thanks!
    Wednesday, July 7, 2010 9:10 PM