Book a Demo

Author Topic: sorting / arranging compartment items  (Read 5619 times)

bechbp

  • EA Novice
  • *
  • Posts: 11
  • Karma: +0/-0
    • View Profile
sorting / arranging compartment items
« on: February 15, 2022, 09:25:31 am »
Hello community

I would like to have control over how items are being displayed in an object compartment (ex: parts or values compartment). I understand that from a systems view, the order of these parts or values shouldn't matter, but when the object is a data packet, then the order of the values in the data packet is important. 

I know that attributes can be sorted using the Ctrl-UP or Ctrl-Down once selected in the "Features" window. BUT this does not apply to other compartments (ex: parts or values)

I thought the items in the parts or values compartments are sorted alphabetically, but that doesn't seem to happen every time.

Any ideas from the community: HOW can i represent a data packet with specific byte order sequence if I can not control how the "values" compartment is displayed?

cheers!

qwerty

  • EA Guru
  • *****
  • Posts: 13584
  • Karma: +397/-301
  • I'm no guru at all
    • View Profile
Re: sorting / arranging compartment items
« Reply #1 on: February 15, 2022, 10:22:59 am »
Probably a silly (but EA-typical) approach would be to take a screen shot and use that as alternate image. Elsewise you have no real control on what appears where. Even worse if you toggle the "sort features alphabetically" thinhgs get messes up in an instant.

Anyways I'm not sure whether UML has any means to enforce any order on  properties or operations. (I might look that up in the specs if I don't forget it...)


q.

P.S. A DataType has {ordered} Property and Operation (p. 165 of UML 2.5). And a Class dito (p. 192). So well, since EA somehow get things in some order it is compliant. Of course, since the order has the stability of a card house it's a bit questionable for a practical use.
« Last Edit: February 15, 2022, 10:36:47 am by qwerty »

bechbp

  • EA Novice
  • *
  • Posts: 11
  • Karma: +0/-0
    • View Profile
Re: sorting / arranging compartment items
« Reply #2 on: February 15, 2022, 02:41:05 pm »
Thank you for your reply!

I did see that a user can check the "ordered" box if the element has an upper limit multiplicity defined. Ex: if 10 bytes are part of Element B, then you can say that these 10 bytes are "ordered", which means there is a specific order for the 10 bytes.

What I can't figure out it is: where do I define/specify the order of these 10 bytes? for example, where do I specify that Byte 1 is User ID, Byte 2 is Age, Byte 3 is Gender...etc

Maybe the actual order of bytes will live in a comment rather than the element itself... sounds like that is a short coming of SySML or UML.

Cheers!
BB

qwerty

  • EA Guru
  • *****
  • Posts: 13584
  • Karma: +397/-301
  • I'm no guru at all
    • View Profile
Re: sorting / arranging compartment items
« Reply #3 on: February 15, 2022, 09:33:25 pm »
Basically (but only that!) the features in a compartment show in the order you arrange them in the Features window (using the Ctrl-UP/DOWN keys).

q.

KP

  • EA Administrator
  • EA Expert
  • *****
  • Posts: 2919
  • Karma: +55/-3
    • View Profile
Re: sorting / arranging compartment items
« Reply #4 on: February 17, 2022, 07:50:16 am »
Basically (but only that!) the features in a compartment show in the order you arrange them in the Features window (using the Ctrl-UP/DOWN keys).

q.

I think this is only true for attributes and operations. For compartments such as "values" and "parts" on SysML blocks - basically, anything created by shape script custom compartments - they aren't currently sortable.
The Sparx Team
[email protected]