Author Topic: Different variants of same Activity  (Read 3805 times)

aljazjelen

  • EA Novice
  • *
  • Posts: 19
  • Karma: +0/-0
    • View Profile
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 :)

https://imgur.com/a/8ycLrCl

  • 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!



aljazjelen

  • EA Novice
  • *
  • Posts: 19
  • Karma: +0/-0
    • View Profile
Re: Different variants of same Activity
« Reply #1 on: August 02, 2021, 09:05:13 pm »
bump :)

qwerty

  • EA Guru
  • *****
  • Posts: 12318
  • Karma: +346/-286
  • I'm no guru at all
    • View Profile
Re: Different variants of same Activity
« Reply #2 on: August 02, 2021, 10:54:35 pm »
I think the answer is: it's complicated. My customer does have a team struggling with variants since years and has not come to any conclusion yet.

q.

Sunshine

  • EA Practitioner
  • ***
  • Posts: 1107
  • Karma: +101/-9
  • Its the results that count
    • View Profile
Re: Different variants of same Activity
« Reply #3 on: August 03, 2021, 07:33:55 am »
Part of the answer lies in the modelling notation you intend to choose and part of it is what programming language you intend to implement for example;

In UML and OO language you could have a use case and several use case realizations that implement the same thing differently with different objects (with attributes and operations) that behave polymorphically which are deployed as components on to Nodes. This is classic object orientation using abstract class with multiple inherited classes for polymorphic behaviour. There are design patterns you can look up.

In ArchiMate you could have an application service that is realised by different application functions and components.

Hope that helps.
« Last Edit: August 03, 2021, 07:36:23 am by Sunshine »
Happy to help
:)

aljazjelen

  • EA Novice
  • *
  • Posts: 19
  • Karma: +0/-0
    • View Profile
Re: Different variants of same Activity
« Reply #4 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!

Sunshine

  • EA Practitioner
  • ***
  • Posts: 1107
  • Karma: +101/-9
  • Its the results that count
    • View Profile
Re: Different variants of same Activity
« Reply #5 on: August 04, 2021, 11:20:39 am »
Yes you are right polymorphism can be realised by inheritance in software but there are other mechanisms you can use too if you programming language doesn't support it.
SysML and the HW puts some context to your problem. I used to be an electronic engineer may years ago but moved into software engineering as it paid more. I have come across a few techniques but without knowing more can't help. What I can tell you is that polymorphism is possible in HW but using mechanisms other than inheritance. The bad news for you is that the company I designed those mechanisms for have intellectual property rights over those designs, plus I don't have access to them anymore as I've left the company.
Happy to help
:)

Paolo F Cantoni

  • EA Guru
  • *****
  • Posts: 7938
  • Karma: +205/-127
  • Inconsistently correct systems DON'T EXIST!
    • View Profile
Re: Different variants of same Activity
« Reply #6 on: August 04, 2021, 11:38:28 am »
Yes you are right polymorphism can be realised by inheritance in software but there are other mechanisms you can use too if you programming language doesn't support it.
SysML and the HW put some context to your problem. I used to be an electronic engineer may years ago but moved into software engineering as it paid more. I have come across a few techniques but without knowing more can't help. What I can tell you is that polymorphism is possible in HW but using mechanisms other than inheritance. The bad news for you is that the company I designed those mechanisms for have intellectual property rights over those designs, plus I don't have access to them anymore as I've left the company.
(my emphasis)
Many of us took the same route!  An engineering degree was a great course for teaching us to think, but computing paid more...

Paolo
« Last Edit: August 04, 2021, 11:40:06 am by Paolo F Cantoni »
Inconsistently correct systems DON'T EXIST!
... Therefore, aim for consistency; in the expectation of achieving correctness....
-Semantica-
Helsinki Principle Rules!

Sunshine

  • EA Practitioner
  • ***
  • Posts: 1107
  • Karma: +101/-9
  • Its the results that count
    • View Profile
Re: Different variants of same Activity
« Reply #7 on: August 05, 2021, 11:16:52 am »
...
Many of us took the same route!  An engineering degree was a great course for teaching us to think, but computing paid more...

Paolo

Indeed there are a lot of folk in IT now from various engineering disciplines. Can't complain its been fun and paid the bills at the same time.
Happy to help
:)

Paolo F Cantoni

  • EA Guru
  • *****
  • Posts: 7938
  • Karma: +205/-127
  • Inconsistently correct systems DON'T EXIST!
    • View Profile
Re: Different variants of same Activity
« Reply #8 on: August 05, 2021, 11:28:49 am »
...
Many of us took the same route!  An engineering degree was a great course for teaching us to think, but computing paid more...

Paolo

Indeed there are a lot of folk in IT now from various engineering disciplines. Can't complain it's been fun and paid the bills at the same time.
And from my view allows us to treat Software Development as an "Engineering discipline", not an "artistic endeavour".[1]

Paolo

[1]  This is, of course, not to say that such engineered software can't be a "work of art", but that is consequent on the good engineering.
Inconsistently correct systems DON'T EXIST!
... Therefore, aim for consistency; in the expectation of achieving correctness....
-Semantica-
Helsinki Principle Rules!