Page 1 of 1

Print enumeration attribute in an opaque behavior

PostPosted: Thu Mar 16, 2017 9:29 pm
by douglas.courtney@navy.mil
When I try to print an attribute that was passed into an opaque behavior. When I print the variable, I get an address object.

tType = ALH.getValue(taskOrdData, "TaskType")
print(tType)
print(str(tType))

Console output:
com.nomagic.uml2.ext.magicdraw.classes.mdkernel.impl.EnumerationLiteralImpl@2253cdb9
com.nomagic.uml2.ext.magicdraw.classes.mdkernel.impl.EnumerationLiteralImpl@2253cdb9

I have tried using the str() function and also tried to use the .value. Any helpful hints.

Re: Print enumeration attribute in an opaque behavior

PostPosted: Thu Aug 09, 2018 9:04 am
by alvin.murphy@navy.mil
What this problem ever resolved? I'm having the same issue.

Re: Print enumeration attribute in an opaque behavior

PostPosted: Fri Sep 27, 2019 6:45 am
by ivan.baeriswyl@hefr.ch
I am also interested by a solution to this issue.