Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.

Messages - aljazjelen

Pages: [1] 2
General Board / GetCurrentDiagram() returns null
« on: March 02, 2022, 04:03:39 am »
Hi to whoever reading this :)

I have a following code:

Code: [Select]

// Main
var rep as EA.Repository;
rep = Repository;

var diag as EA.Diagram;

diag = rep.GetCurrentDiagram();

if (diag != null){

I cannot get the "GetCurrentDiagram()" function returning anything. It always returns null (the if statement above in the code is skipped).

Anyone knows why?

Additional info:
EA v13
Selected diagram in tree
clicked on the diagram in the viewport

General Board / Composite Diagrams - Reuse Ports
« on: January 11, 2022, 08:37:56 pm »
Hi everyone,

The problem I have can be trivial. Maybe its not even solvable. In any case, any help&tips are appreciated! :)

I have a diagram, where I show an overview of elements. Those elements have ports. Now I would like to create a child diagram, reuse the ports from the parent element and model the "interior" of the parent element. For example to show what is happening inside.
I modelled in such a way, as shown in pictures below:

Then I would like to use "compartment visibility feature" (or anyother proposal) to show the "Interior" of the child diagram on the initial/diagram. See below:

However, when I do that, the ports are shown twice, eventho the port is defined only once.

Is there a way, to show interrior of the element (so to show child diagram) and reuse the ports from the parent?

I hope my question was clear :)

General Board / Re: Different variants of same Activity
« on: August 03, 2021, 08:19:24 pm »
Thank you both for answers! :)

@Sunshine I would need to use SysML as basis. Objects we are dealing with, are not only SW components but also HW elements.
As far as my minor knowledge goes, polymorphism is used in inheritence approach of SW Classes. So I dont see it applicable to HW elements. Or did you mean to model a Parent HW element, from where each conseuqent Child HW element originates from? So basically to try to "transfer polymorphism" to HW itself.

I am not sure whether I managed to explain my concern.

Best regards!

General Board / Re: Different variants of same Activity
« on: August 02, 2021, 09:05:13 pm »
bump :)

General Board / Re: ID of current diagram
« on: July 22, 2021, 06:38:19 pm »
Hi Geert and qwerty!

I have approached the problem in a different way. Now I will manually chance the GUIDs where relevant (at the end, there are only about 7-8 diagrams)

Thanks for support :)

General Board / Different variants of same Activity
« on: July 21, 2021, 01:29:13 am »
Hi everyone,

Basically I am stuck on how to properly model "variant handling" in the terms of one functionality being implemented in several different ways, where the elements (needed to implement the function) do not affect the meaning of the function itself. Enough talking, picture attached :)

  • Firstly, my thought would be to model elements like "GetData", "ProcessData", "React" as actions? That would however inherently mean to model myFunction (of each variant) as an Activity. Would you suggest otherwise?
  • Secondly, my idea is to have a generic function structures. As you see, both variants have same structure, however the implementation (realization) differs. Is there any proper way to model a function once and then reuse its structure completely? For example to model "myFunction" once and then create "variants", to which I could allocate elements which are needed for realization.
  • Another point, as seen in example the same Component is implementing "GetData" of variant 1 and variant 2. This is however not the case for other actions. My end-goal is to have an SQL querry which would return all dependencies if I use specific component or not.

Any help would be appreciated! :)

Thank you!

General Board / Re: ID of current diagram
« on: July 10, 2021, 12:07:49 am »
Hi Q!

So most likely there is no other option. Of course, one option would be making document fragments and generating report as well.
But I would like to have it interactively.

The reason: We are having a very complicated system with many independencies. For this reason, we are building a system in modular manner. And would be great to have an overview of all dependencies within a function diagram.
Relationship Matrix is cool, but it lacks the possibility to "filter empty cells" :(

However, thanks for reply!

General Board / ID of current diagram
« on: July 09, 2021, 10:52:35 pm »
Hi everyone,

I would like to use a "Model View" object where you can write an sql query to show the results. With it, I want to show a content of each diagram (currently selected) and their dependencies.
But to do it properly, I would need to somehow find the ID of the diagram, which is currently being viewed (not neccessarly selected on the tree!).

Can someone help me with SQL, to somehow:
  • query through diagrams but only select the one which is currently in scope
  • check all elements of type "Class" and return their dependencies

I am quite new to this, so if you have any additional learning material, I would appreciate it!

Regards :)

General Board / Re: Tagged values - SQL Query
« on: March 11, 2021, 02:48:27 am »
Hi Geert!

Once again, thank you for support. With your help I figured out where the mistake was. Still I am not entirely sure why it has to be done like so. But thats on me to discover.

I thought that it is possible to use multiple "from" in junction with the JOIN syntax. Guess I was wrong. Thanks for letting me know! :)


General Board / Re: Tagged values - SQL Query
« on: March 11, 2021, 12:54:15 am »
Hi Q, thanks for post!

So my goal is to select a package and search for all elements with a "type" and extract all required information, such as "Parent", "Status", "Tags" etc...

Its quite simple, but yet I have never done any SQL before, so I figured it would be faster if I asked experts.
I guess at some point, taking SQL course would not be a bad idea. :)


General Board / Re: Missing MDG Technology
« on: March 11, 2021, 12:33:20 am »
Hi Geert, sorry for takign so much time.

Yes we were in correct dialog.

The issue was, that one MDG was "as a part of the model" and another MDG was "imported from user".

The 2 MDGs were exactly the same, except one was outdated. Somehow EA library (of our MDG) decided to use the outdated version which caused consistency issues with the rest of our documents.

Anyhow, we fixed it by exporting XML, deleting the MDG of the user under %app, opening the latest "okay" version in our versioning system and imported XML again.

No work was lost.

Thanks for support!

General Board / Tagged values - SQL Query
« on: March 11, 2021, 12:24:58 am »
Hi everyone,

I have an sql querry below:
Code: [Select]
select pkg.Name as [Package Name] , parent.Name as [Parent Name] , o.Name as [Name], o.Status as [Status]
FROM ((t_object o
inner join t_package pkg on pkg.Package_ID = o.Package_ID)
left join t_object parent on parent.Object_ID = o.ParentID)
where o.Package_ID IN (#Branch#)
and o.Object_Type = 'Class'

which returns all classes, their status and parent name. Just as expected.

What if I would want to return also a value of specific tag?

So as I am really not so confident with SQL, I tried searching on the forums and found something like:
Code: [Select]
select t_object.ea_guid AS CLASSGUID, t_object.Object_Type AS CLASSTYPE, t_object.Name, tag1.[Value], tag2.[Value]
from t_object, t_objectproperties tag1, t_objectproperties tag2
where t_object.Object_ID = tag1.Object_ID
and t_object.Object_ID = tag2.Object_ID
and tag1.[Property] = 'tag1'
and tag2.[Property] = 'tag2'

However I am having problems merging the 2 codes together (obvious problem, since I am not dealing with SQL on daily basis).

I tried something like:
Code: [Select]
select pkg.Name as [Package Name] , parent.Name as [Parent Name] , o.Name as [Name], o.Status as [Status], tag1.[Value]
FROM ((t_object o, t_objectproperties tag1
inner join t_package pkg on pkg.Package_ID = o.Package_ID)
left join t_object parent on parent.Object_ID = o.ParentID)
where o.Package_ID IN (#Branch#)
and o.Object_Type = 'Class'
and tag1.[Property] = 'Level'

But it yields a problem. I am not entirely sure if I understand the Inner join, left Join etc... so I assume I made a mistake over there.

Anyone could help me out?


General Board / Re: Missing MDG Technology
« on: January 21, 2021, 07:06:34 pm »
Hi everyone reading this.

So we couldnt fix it with the update or simple "unchecking the box". So instead we exported his work as "xml", reverted down the version of our EA model which worked for all of us and imported back his work.
This works fine, because his MDG and our MDG are basically the same in naming, the difference being some stereotypes only.

So upon importing the "xml" in the stable version of EA model, the stereotypes of his classes automatically detected MDG of the model instead of his user MDG (which we deleted beforehand).

I hope I was clear with explanation, in case someone in future encounters similar issues.


General Board / Re: Missing MDG Technology
« on: January 21, 2021, 06:20:11 pm »
Hi Geert,

Thanks again for support. Unfortunatelly unchecking the boxes doesnt work, because doing so, it unchecks both version of MDG (correct and incorrect version).
Personally I havent seen anything like this before.

In regards to update query, we will give it a shot today.

Best regards

General Board / Missing MDG Technology
« on: January 21, 2021, 04:56:14 am »
Hi everyone,

We are having an issue with MDG technology packages.

Long story short, we created a custom package which would help us modeling. One of our colleague imported the MDG a bit differently than everyone else, somehow the MDG package on his computer resides on %appdata%.

Now here comes the issue. He started modelling with this setup and now no-one except him can open his models. We all receive the message: "Access to this model requires the following technologies which are not available ...".

Has anyone ever had similar issues? I guess we need to "import the MDG into his EA correctly" and then break the link of the previous version.

Thanks for support!

Pages: [1] 2