Author Topic: C# Plugin: Product Line Feature Diagram in UML  (Read 18802 times)

Edoardo

  • EA User
  • **
  • Posts: 20
  • Karma: +0/-0
    • View Profile
Re: C# Plugin: Product Line Feature Diagram in UML
« Reply #15 on: September 22, 2009, 09:06:41 pm »
Yes I found it, is project.layoutDiagram. Thanks.

How can I access to the project object to call it's method, assuming I'm handling a Diagram or a Package in it?

Geert Bellekens

  • EA Guru
  • *****
  • Posts: 13228
  • Karma: +551/-33
  • Make EA work for YOU!
    • View Profile
    • Enterprise Architect Consultant and Value Added Reseller
Re: C# Plugin: Product Line Feature Diagram in UML
« Reply #16 on: September 22, 2009, 09:31:48 pm »
through the repository object.

Geert

Edoardo

  • EA User
  • **
  • Posts: 20
  • Karma: +0/-0
    • View Profile
Re: C# Plugin: Product Line Feature Diagram in UML
« Reply #17 on: September 22, 2009, 10:44:42 pm »
ok, thanks, I used this statement:

this.repository.GetProjectInterface().LayoutDiagram(diagram.DiagramGUID, 1);

the integer is layoutStyle. Do you know what integer i should insert to obtain the same effect as I get using the EA menu Layout Diagram?

When I use "1" it seems somehow different...

Geert Bellekens

  • EA Guru
  • *****
  • Posts: 13228
  • Karma: +551/-33
  • Make EA work for YOU!
    • View Profile
    • Enterprise Architect Consultant and Value Added Reseller
Re: C# Plugin: Product Line Feature Diagram in UML
« Reply #18 on: September 22, 2009, 10:48:40 pm »
No sorry, I don't use the autolayout functions so I wouldn't know.
But isn't there a mapping somewhere in the documentation between the numbers and the layout styles?

Geert

Edoardo

  • EA User
  • **
  • Posts: 20
  • Karma: +0/-0
    • View Profile
Re: C# Plugin: Product Line Feature Diagram in UML
« Reply #19 on: September 22, 2009, 10:53:48 pm »
I do not know where to find the documentation... Maybe I was looking in the wrong places, could you please give me a link? Thanks a lot!

Geert Bellekens

  • EA Guru
  • *****
  • Posts: 13228
  • Karma: +551/-33
  • Make EA work for YOU!
    • View Profile
    • Enterprise Architect Consultant and Value Added Reseller

Edoardo

  • EA User
  • **
  • Posts: 20
  • Karma: +0/-0
    • View Profile
Re: C# Plugin: Product Line Feature Diagram in UML
« Reply #21 on: September 24, 2009, 12:11:38 am »
Here I am again,
I cannot find a way to modify, by API, the appearance of the classes in the Diagram. I would like to change background color and, mostly important, the dimensions.
Can you help me?
Many thanks!

Geert Bellekens

  • EA Guru
  • *****
  • Posts: 13228
  • Karma: +551/-33
  • Make EA work for YOU!
    • View Profile
    • Enterprise Architect Consultant and Value Added Reseller
Re: C# Plugin: Product Line Feature Diagram in UML
« Reply #22 on: September 24, 2009, 02:21:54 am »
look into the DiagramObject and its properties.

Geert

Edoardo

  • EA User
  • **
  • Posts: 20
  • Karma: +0/-0
    • View Profile
Re: C# Plugin: Product Line Feature Diagram in UML
« Reply #23 on: October 01, 2009, 02:14:57 am »
I am trying to change color of a Connector, but it seems to produce no results.

I'm calling

connector.color = 255      000000() //which is red
connector.update();

I got no results from theese statements.

Any ideas?

thanks

Edoardo

  • EA User
  • **
  • Posts: 20
  • Karma: +0/-0
    • View Profile
Re: C# Plugin: Product Line Feature Diagram in UML
« Reply #24 on: October 06, 2009, 09:00:00 pm »
Hi again,

when I try to connect a class to another using "composition" with this statement:

Code: [Select]
EA.Connector con1 = (EA.Connector)associazione.Connectors.AddNew("", "Composition");
con1.SupplierID = madre.ElementID;
con1.Update();

in my diagram appears an aggregation relation instead (a white diamond)

How can I create a real composition connector (black diamond)?

thanks a lot
« Last Edit: October 06, 2009, 09:01:29 pm by e.varasi »

Edoardo

  • EA User
  • **
  • Posts: 20
  • Karma: +0/-0
    • View Profile
Re: C# Plugin: Product Line Feature Diagram in UML
« Reply #25 on: October 29, 2009, 03:12:17 am »
Hi,

I would like to change the route style of my diagram connectors via automation interface. I need them to be routed with "vertical" style.

I tried with the following code but it has no effect:

  con2.RouteStyle = 4;
  con2.Update();

(con2 is an EA.Connector)

Can you help me please?

Makulik

  • EA User
  • **
  • Posts: 400
  • Karma: +0/-0
    • View Profile
Re: C# Plugin: Product Line Feature Diagram in UML
« Reply #26 on: October 29, 2009, 03:19:21 am »
Hi Edoardo,

Did you already try to update/refresh the diagram where these connectors appear?
Just a guess ...

WBR
Günther

Edoardo

  • EA User
  • **
  • Posts: 20
  • Karma: +0/-0
    • View Profile
Re: C# Plugin: Product Line Feature Diagram in UML
« Reply #27 on: October 29, 2009, 03:20:00 am »
Quote
Hi Edoardo,

Did you already try to update/refresh the diagram where these connectors appear?
Just a guess ...

WBR
Günther

Yes I did...

Edoardo

  • EA User
  • **
  • Posts: 20
  • Karma: +0/-0
    • View Profile
Re: C# Plugin: Product Line Feature Diagram in UML
« Reply #28 on: October 31, 2009, 04:18:50 am »
Quote
Quote
Hi Edoardo,

Did you already try to update/refresh the diagram where these connectors appear?
Just a guess ...

WBR
Günther

Yes I did...

Any clues?
« Last Edit: October 31, 2009, 04:19:37 am by e.varasi »

Geert Bellekens

  • EA Guru
  • *****
  • Posts: 13228
  • Karma: +551/-33
  • Make EA work for YOU!
    • View Profile
    • Enterprise Architect Consultant and Value Added Reseller
Re: C# Plugin: Product Line Feature Diagram in UML
« Reply #29 on: November 03, 2009, 07:00:14 pm »
I would try to create a DiagramLink and set the layout options on that one.

Geert