Welcome to Telelogic Product Support
  Home Downloads Knowledgebase Case Tracking Licensing Help Telelogic Passport
Telelogic TAU (steve huntington)
Decrease font size
Increase font size
Topic Title: EditList control
Topic Summary:
Created On: 9-Mar-2007 08:03
Status: Read Only
Linear : Threading : Single : Branch
Search Topic Search Topic
Topic Tools Topic Tools
Subscribe to this topic Subscribe to this topic
E-mail this topic to someone. E-mail this topic
Bookmark this topic Bookmark this topic
View similar topics View similar topics
View topic in raw text format. Print this topic.
Answer This question was answered by Ian Barnard, on Friday, March 9, 2007 8:47 AM

Answer:
James

What are you trying to get the property editor to show for Configurability?

Ian
 9-Mar-2007 08:03
User is offline View Users Profile Print this message


James Chan

Posts: 11
Joined: 20-Sep-2006

Does anyone know how to use EditList control when defining a stereotype of class?
As my try, the value of EditList control cannot be inserted in  property page.
I just define as follow:

stereotype DM extends TTDMetamodel::Class [0 .. 1]
{
    <<extensionPresentation(.control = EditList (.text = "Configurablility.).) >>Charstring Configurablity;
}

Is there anything needed?

Report this to a Moderator Report this to a Moderator
 9-Mar-2007 08:31
User is offline View Users Profile Print this message


Ian Barnard

Posts: 91
Joined: 4-Jul-2002

Answer Answer
James

What are you trying to get the property editor to show for Configurability?

Ian

-------------------------
=============
Ian Barnard
Principal Consultant
Telelogic UK, an IBM company


Edited: 9-Mar-2007 at 08:31 by Ian Barnard
Report this to a Moderator Report this to a Moderator
 9-Mar-2007 08:38
User is offline View Users Profile Print this message


Ian Barnard

Posts: 91
Joined: 4-Jul-2002

If you're trying to get a drop-down list of options, here is the simplest way to do it:

stereotype Stereotype1 extends TTDMetamodel::Class [0 .. 1] {
Configurability_e Configurability;

}

enum Configurability_e {
fixed,
partial,
fully
}

Now when you've applied Stereotype1 onto a Class, the property editor shows a drop-down list with fixed, partial and fully as the choices.

HTH
Ian

-------------------------
=============
Ian Barnard
Principal Consultant
Telelogic UK, an IBM company
Report this to a Moderator Report this to a Moderator
 9-Mar-2007 08:51
User is offline View Users Profile Print this message


James Chan

Posts: 11
Joined: 20-Sep-2006

Thank you! 

But I'm trying to insert a list of items,  so CRUD operatons are needed. 

Report this to a Moderator Report this to a Moderator
 9-Mar-2007 08:59
User is offline View Users Profile Print this message


Ian Barnard

Posts: 91
Joined: 4-Jul-2002

What sort of items? If they are Charstrings, just make Configurability a Charstring[*].

-------------------------
=============
Ian Barnard
Principal Consultant
Telelogic UK, an IBM company
Report this to a Moderator Report this to a Moderator
 9-Mar-2007 09:24
User is offline View Users Profile Print this message


James Chan

Posts: 11
Joined: 20-Sep-2006

Thank you.

As my need, each item of Configurablity has 4 field: Name, Description, Range, Remark 

I hope when I insert an item of Configurablity there are 4 fields can be editable for user.
Report this to a Moderator Report this to a Moderator
 9-Mar-2007 09:47
User is offline View Users Profile Print this message


Ian Barnard

Posts: 91
Joined: 4-Jul-2002

James

As is documented in the help, the TAU property editor only supports multiplicity 1 (or unspecified which is taken as 1) for a tagged value definition using a structured type.

So this works:

stereotype Stereotype1 extends TTDMetamodel::Class [0 .. 1] {
part Configurability_t configurability;
}
class Configurability_t {
Charstring name;
Charstring range;
Charstring description;
Charstring remark;
}

but it doesn't support configurability being defined as Configurability_t[*]. NOTE that the property editor needs configurability to be specified as 'part' to display the four fields of Conffigurability_t.

Some alternative approaches:

1. use Charstring[*] and the user enters the four values into each string

2. Refactor the UML modeling approach you are using: as your stereotype extends Class, maybe you could attach a <<configurability>> stereotype to attributes of the class? Also then you wouldn't need Name in the Configurability_t definition (because the Attribute has a name).

Depending on your model there may be other ways of achieving the same objective.

HTH
Ian

-------------------------
=============
Ian Barnard
Principal Consultant
Telelogic UK, an IBM company


Edited: 9-Mar-2007 at 15:51 by Ian Barnard
Report this to a Moderator Report this to a Moderator
 9-Mar-2007 15:49
User is offline View Users Profile Print this message


Greg Gorman

Posts: 75
Joined: 4-Oct-2002

We are working on a solution for the cases where you have very complex datatypes in a multivalued attribute. Not sure it will make the next release due to time constraints (it's not that easy to do...) but it is on our radar.

/Greg

-------------------------
Greg Gorman
Vice President, Product Management
Modeling and Test Products
Telelogic AB
Report this to a Moderator Report this to a Moderator
Statistics
20925 users are registered to the Telelogic TAU forum.
There are currently 1 users logged in.
The most users ever online was 15 on 31-Mar-2008 at 16:22.
There are currently 0 guests browsing this forum, which makes a total of 1 users using this forum.
You have posted 0 messages to this forum. 0 overall.

FuseTalk Standard Edition v3.2 - © 1999-2009 FuseTalk Inc. All rights reserved.