Book a Demo

Author Topic: Custom Tagged values, masks and template  (Read 3154 times)

bcrier

  • EA User
  • **
  • Posts: 30
  • Karma: +0/-0
  • I love YaBB 1G - SP1!
    • View Profile
Custom Tagged values, masks and template
« on: June 03, 2008, 05:26:43 am »
Hello everyone,

We are trying to store IPAddress information for each node in project structure.  The solution we are trying to implement is creating a custom tag IPAddress with the following details:

Type=Custom;
Mask=ddd.ddd.ddd.ddd;
Template=___.___.___.___;

It works if I add the tag on each and every node manually in the project.

It does not work if I define a new UML profile, define a new stereotyped element and add this tag as an attribute to it and import the profile in the project.  I followed the steps that are in EA help file.  But with this approach the EA does not restrict the formatting.

Any help you can provide here will be helpful?

Regards,
Bobby


Eve

  • EA Administrator
  • EA Guru
  • *****
  • Posts: 8110
  • Karma: +119/-20
    • View Profile
Re: Custom Tagged values, masks and template
« Reply #1 on: June 03, 2008, 08:27:09 am »
There is a bit of a trick to it.  You need to define the tag in the model you are exporting the profile from.  It should then get the custom type when exporting.

See http://www.sparxsystems.com.au/EAUserGuide/index.html?definestereotypetagswithsu2.htm

bcrier

  • EA User
  • **
  • Posts: 30
  • Karma: +0/-0
  • I love YaBB 1G - SP1!
    • View Profile
Re: Custom Tagged values, masks and template
« Reply #2 on: June 05, 2008, 02:54:18 am »
I did that but it did not work.  But found a solution.

After much trial and error noticed that if you define the same custom tag value in the project which is using the UML profile, the formatting starts working.

So, in short, if you create a custom UML profile which has a custom tag value with specific formatting mask, and use it in a project, everything works except the formatting mask.  But the moment you define the same custom tag in the project (that is using the profile) the formatting starts working.  The tag name should be the same as the original.  Seems like a bug or did I miss something.

If anyone is interested I can share a sample project and profile.

Thank you.

Bobby


KP

  • EA Administrator
  • EA Expert
  • *****
  • Posts: 2919
  • Karma: +55/-3
    • View Profile
Re: Custom Tagged values, masks and template
« Reply #3 on: June 05, 2008, 08:50:48 am »
Create an MDG Technology that bundles your UML Profile and your tagged value type definitions into a single file. Then when you import the technology your target model is guaranteed to have the tagged value types.
The Sparx Team
[email protected]