Book a Demo

Author Topic: Multiple classes (same name) created - import code  (Read 3391 times)

Daniel Lindberg

  • EA Novice
  • *
  • Posts: 2
  • Karma: +0/-0
    • View Profile
Multiple classes (same name) created - import code
« on: May 22, 2008, 04:45:26 am »
When reverse engineering some C# code into my EA model, multiple classes are created with the same name.  I believe this is due to the partial classes that exist in multiple source files.  Each imported class contains methods/member data corresponding to individual files.

i.e.
class1.a.cs
public partial class class1
{
public m1(){}
public m2(){}
}

class1.b.cs
public partial class class1
{
public m3(){}
public m4(){}
}

ea creates 2 classes named class1.  1 with methods m1 and m2, the other with methods m3 and m4.

Eve

  • EA Administrator
  • EA Guru
  • *****
  • Posts: 8098
  • Karma: +118/-20
    • View Profile
Re: Multiple classes (same name) created - import
« Reply #1 on: May 22, 2008, 08:24:52 am »
EA currently supports partial classes by keeping them separate for two reasons.
  • So that code engineering can be performed on any of the parts.
  • To allow members to be added to the required class part/file.
We realise that this doesn't allow for a unified representation of the class as a whole, and that many users will have this requirement.  However, we believe that it is the best solution available at the moment.

At this stage we are unable to give a timeframe for when we would allow a unified representation of partial classes.