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: Ignoring links to deleted objects
Topic Summary:
Created On: 5-Dec-2006 14:25
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 Al Lione, on Tuesday, December 5, 2006 6:08 PM

Answer:
Thanks - I was looking at isDeleted(), the help file doesn't show Object as one of the parameters, but of course I am using that way in the outer loop. Also my confusion is that (target link) seems to be the target module and also the target object, depending on how it is referenced. Anyway, I declared another Object, then added the attached lines to the inner loop and it now ignores the deleted target objects.
 
 5-Dec-2006 14:25
User is offline View Users Profile Print this message


Al Lione

Posts: 59
Joined: 13-Jul-2004

I am writing a script to trace outlinks and compare the object text of the current object and the target object. I am getting stopped because some objects link to deleted objects in the target module. Notwithstanding the fact that this shouldn't be allowed, I need a way to skip these links so the script will work to completion. I am attaching my code and hopefully someone can steer me in the right direction. I am using a bunch of continue statements but I can't seem to get it to work. Thanks!
PS> using 7.1
Report this to a Moderator Report this to a Moderator
 5-Dec-2006 17:00
User is offline View Users Profile Print this message


ron lewis

Posts: 650
Joined: 20-Sep-2004

In help file look at

Object target(Link l)
Object source(Link l)
and
bool isDeleted(Object o)
Report this to a Moderator Report this to a Moderator
 5-Dec-2006 18:08
User is offline View Users Profile Print this message


Al Lione

Posts: 59
Joined: 13-Jul-2004

Answer Answer
Thanks - I was looking at isDeleted(), the help file doesn't show Object as one of the parameters, but of course I am using that way in the outer loop. Also my confusion is that (target link) seems to be the target module and also the target object, depending on how it is referenced. Anyway, I declared another Object, then added the attached lines to the inner loop and it now ignores the deleted target objects.
 
Report this to a Moderator Report this to a Moderator
 7-Dec-2006 01:30
User is offline View Users Profile Print this message


Louie Landale

Posts: 2070
Joined: 12-Sep-2002

Yes, DOORS generates an error when you try to delete an object with incoming links; but never-the-less there will be deleted objects with incoming links. That perhaps happens when the source module isn't open but I'm pretty sure it happens when the currrent user lacks "R" access to the source, and so doesn't know there's a link when deleting the target. Seems to me I can do it with DXL as well. So yes, check for deleted target objects.

The 'string target(Link)" and "string source(Link)" commands are worthless since they return the unqualified name of the module, not the full name. You need to first get the "modName_ (target(Link))" and then convert that to a full name, which is what you are doing with "if (null target link) continue".

If the target module isn't open I don't you want your script to open it and THEN try to get a handle on the target object? Look through that library of mine you've got in "Lib-Links.inc", and find "fLoadOtherMods" and "fLoadAllOthers" functions that load other modules for you. IIRC those functions opened up modules faster than the documented way when considering each and every link.

- Louie
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.