Sparx Systems Forum

Enterprise Architect => General Board => Topic started by: tzafrir on October 26, 2017, 04:20:54 pm

Title: Swimlines attribute
Post by: tzafrir on October 26, 2017, 04:20:54 pm
Hi,

Is there an attribute that represents the swimlines attribute of an element?

Title: Re: Swimlines attribute
Post by: Geert Bellekens on October 26, 2017, 04:29:40 pm
Hi,

Is there an attribute that represents the swimlines attribute of an element?

I'm sorry, that makes no sense at all to me. :-\

Geert
Title: Re: Swimlines attribute
Post by: tzafrir on October 27, 2017, 01:18:31 am
I will elaborate,
I am talking about boundary elements only.

In EA you stand on the boundary element->Right click -> choose properties --> you have horizontal and Vertical swim lanes tab.
When changing the numbers (for the horizontal to 5) EA put 5 horizontal lines on the diagrams.
I am looking for an API that will bring me this number 5 for my usage in my addin.

Title: Re: Swimlines attribute
Post by: qwerty on October 27, 2017, 01:23:48 am
It happens that MiscData[0] and [1] hold the number rows and columns.

q.
Title: Re: Swimlines attribute
Post by: tzafrir on October 27, 2017, 06:13:29 pm
Thanks,

In which table? or it is some sort of API?
Title: Re: Swimlines attribute
Post by: qwerty on October 27, 2017, 06:35:52 pm
EAElement.MiscData or t_Object.PATA.

q.
Title: Re: Swimlines attribute
Post by: tzafrir on October 28, 2017, 12:02:12 am
Thanks,

I see it is a readonly variable, changing it on EA, does not change the value of PDATA1 or PDATA2.
Is there anyway those values can be changed? I need to increment them and decrement them in my Addin.
Title: Re: Swimlines attribute
Post by: Uffe on October 28, 2017, 12:24:18 am
If an attribute is read-only in the API, the approved (well...) procedure is to use the hidden and undocumented Repository.Execute(), which takes a string containing an SQL statement and passes it to the database for execution.

In this case, you'd pass something like "update t_object set PDATA1=X, PDATA2=Y where Object_ID = " + element.ElementID

/Uffe
Title: Re: Swimlines attribute
Post by: tzafrir on November 06, 2017, 02:18:00 am
Thanks,
The did the job.

One small question,
Can this partition line be somehow thicker (meaning does EA gives any field that sets the thickness of the vertical\horzontal partition line?).
The reason I am asking is, I need it for presentation purposes and it is kind of hard to see.
Title: Re: Swimlines attribute
Post by: qwerty on November 06, 2017, 03:23:23 am
Instead of the swimlanes (which anyway have no defined semantics) create a pool (from activities) or a boundary which allow thicker lines.

There's a trick to create arbitrary lines by connecting two boundaries with an association and make the boundaries invisible by assigning an alternate image with a tiny dot.

q.
Title: Re: Swimlines attribute
Post by: Paolo F Cantoni on November 06, 2017, 10:46:59 am
Instead of the swimlanes (which anyway have no defined semantics) create a pool (from activities) or a boundary which allow thicker lines.

There's a trick to create arbitrary lines by connecting two boundaries with an association and make the boundaries invisible by assigning an alternate image with a tiny dot.

q.
Learn something new every day!

Thanks, q!