Welcome to Telelogic Product Support
  Home Downloads Knowledgebase Case Tracking Licensing Help Telelogic Passport
Telelogic DOORS (steve huntington)
Decrease font size
Increase font size
Topic Title: \G et children of objects regardless display set
Topic Summary:
Created On: 17-Sep-2007 14:44
Status: Post and Reply
Linear : Threading : Single : Branch
Search Topic Search Topic
Topic Tools Topic Tools
Quick Reply Quick Reply
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 Sjors de Leeuw, on Tuesday, September 18, 2007 7:53 AM

Answer:
Kevin, Louie,

Thank you both for your help. I restarted the programming of the LDXL script, and tried your examples, and both worked indeed. I found my mistake - an erroneous condition before displaying the actual data.
Apparently, I was looking at the wrong location for solving the bug.

Sorry...

Regards,
Sjors
 17-Sep-2007 14:44
User is offline View Users Profile Print this message


Sjors de Leeuw

Posts: 23
Joined: 18-Apr-2007

Hi,

I'm creating a LDXL column, which displays - for each object - its children (if there are any).
I manage to do this as long as the children are part of the display set. However, as soon as the children are not visible (e.g. when setting the display level), the LDXL column is no longer showing the object's children.

I have tried the following three mechanisms:

FIRST:
for o in obj do { ... }

SECOND:
Object o = first (obj);
o = first (sibling(o));
while  (o!=null) {
   ...
   o = next (sibling(o))
 }

THIRD:
absolute object addressing, with o = obj [ i ], with i starting at 1, until o = null


All three alternatives take current display set into account. Any alternatives, which really look into the database...???

Thanks!
Sjors

Edited: 17-Sep-2007 at 14:48 by Sjors de Leeuw
Report this to a Moderator Report this to a Moderator
 17-Sep-2007 15:02
User is offline View Users Profile Print this message


Kevin Murphy

Posts: 206
Joined: 15-Jul-2005

Sjors,

try

for object in entire module do {

}


You will get deleted objects with this, so you may have to insert something like

if (isDeleted o)
break

in your code. It will also get tables...

Let us know how it goes!
Kevin

-------------------------
Kevin Murphy
http://www.baselinesinc.com
The Requirements Management Experts
Report this to a Moderator Report this to a Moderator
 17-Sep-2007 15:22
User is offline View Users Profile Print this message


Sjors de Leeuw

Posts: 23
Joined: 18-Apr-2007

Hi Kevin,

Thank you for your swift answer!

Either I misunderstand your answer, or you misunderstood the question ;-)

Since it's a layout DXL column, I shouldn't browse the complete module for each object that is displayed, right?
It looks like your suggestion is an alternative for my first mechanism. However, there I use:

for o in obj  do { ... } instead of "for o in <module>"

(I would expect something like "for o in entire obj do {...}", but it's not existing)

Or... did I really misunderstand you?

Regards,
Sjors
Report this to a Moderator Report this to a Moderator
 17-Sep-2007 15:27
User is offline View Users Profile Print this message


Sjors de Leeuw

Posts: 23
Joined: 18-Apr-2007

By the way:
According to the DXL Manual, the "for o in obj" should ignore filters:

Copied from manual:

for object in object

Syntax

for o in parent do {
 ... 
} 

where:

o
is a variable of type Object
parent
is an object of type Object

Assigns o to each successive child of object parent.

This loop ignores filters, such that even if objects are filtered, they are still returned by this function. Deleted objects are included when they are displayed and excluded when they are not displayed.

......[ end of copy ]......

Apparently, "this loop" does not ignore filters.

Report this to a Moderator Report this to a Moderator
 17-Sep-2007 16:18
User is offline View Users Profile Print this message


Kevin Murphy

Posts: 206
Joined: 15-Jul-2005

Sjors,

I just tried the following at it worked. I am using DOORS 8.2, and I even filtered and it still worked.

-------------------------
Kevin Murphy
http://www.baselinesinc.com
The Requirements Management Experts
Report this to a Moderator Report this to a Moderator
 17-Sep-2007 16:23
User is offline View Users Profile Print this message


Kevin Murphy

Posts: 206
Joined: 15-Jul-2005

Sjors,

By the way, I realize my reply wasn't helpful to you--because it's the very first thing you did. Can you post your code, specifically of example 1 and what didn't work? Can you also take us through the steps you performed? Are you saving this LDXL in a view that is the default view for the module?

-------------------------
Kevin Murphy
http://www.baselinesinc.com
The Requirements Management Experts
Report this to a Moderator Report this to a Moderator
 17-Sep-2007 19:47
User is offline View Users Profile Print this message


Louie Landale

Posts: 2070
Joined: 12-Sep-2002

As other said, the 'for oSub in obj' loop should work, so long as you make an explicit check for deleted:
if (isDeleted(oSub)) continue. It works for me.

Perhaps you are calculating the results oddly. Try the attached.

- Louie

Edited: 17-Sep-2007 at 19:48 by Louie Landale
Report this to a Moderator Report this to a Moderator
 18-Sep-2007 07:53
User is offline View Users Profile Print this message


Sjors de Leeuw

Posts: 23
Joined: 18-Apr-2007

Answer Answer
Kevin, Louie,

Thank you both for your help. I restarted the programming of the LDXL script, and tried your examples, and both worked indeed. I found my mistake - an erroneous condition before displaying the actual data.
Apparently, I was looking at the wrong location for solving the bug.

Sorry...

Regards,
Sjors
Report this to a Moderator Report this to a Moderator
Statistics
20925 users are registered to the Telelogic DOORS forum.
There are currently 1 users logged in.
The most users ever online was 15 on 15-Jan-2009 at 16:36.
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.