Book a Demo

Author Topic: How do C# property Accessors show??  (Read 2708 times)

MikeInParadise

  • EA Novice
  • *
  • Posts: 1
  • Karma: +0/-0
  • I love YaBB 1G - SP1!
    • View Profile
How do C# property Accessors show??
« on: May 22, 2005, 10:28:32 am »
I have just downloaded the trial and imported some code. I am trying to understand how it tracks C# properties and the get and set accessors.

It looks like it stores it as an Uml Operation which I take to be a C# method, but then classifies this using a sterotype of property.  

When you look at a class in a diagram how you know if a property only has a get accessor??

Also how does it handle C# Attributes that you have placed on the accessors?? All my property accessors
typically have a debugger step through on them..

It seems like on the properties themselves it puts an @CSAttribute... in the notes.

So far I am very impressed but just starting to get my feet wet with uml..




Code: [Select]

/// <summary>
/// Property: Gets or sets the FramingStyles Flags
/// </summary>
[DefaultValue(FramingStyles.All)]
public Bon.Drawing.Art2D.FramingStyles Framing
{

[DebuggerStepThrough()]

get

{


return artFraming;

}

[DebuggerStepThrough()]

set

{


artFraming = value;


PropertyChangedEventArgs e = new Bon.PropertyChangedEventArgs("Framing",value);


Change(e);


OnFramingChanged(this,e);

}
}

Eve

  • EA Administrator
  • EA Guru
  • *****
  • Posts: 8110
  • Karma: +119/-20
    • View Profile
Re: How do C# property Accessors show??
« Reply #1 on: May 22, 2005, 04:20:20 pm »
You can't see this on the diagram, but EA keeps track of it with a tagged value of readonly or writeonly.

Simon