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: How do you Empty a Skip List
Topic Summary:
Created On: 21-Dec-2006 15:33
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 Tony Goodman, on Thursday, December 21, 2006 4:05 PM

Answer:
The only way to empty a skip list is to remove each entry individually using delete(skip, index).

I would delete the skip and recreate it every time.

if (!null skip) delete(skip)
skip = create()
 21-Dec-2006 15:33
User is offline View Users Profile Print this message


Mike Malloy

Posts: 9
Joined: 12-Dec-2006

I have a skiplist called "variant", and it gets populated several times in the same script.  I want to empty it between uses though, and haven't figured out how.  Right now, I'm using "variants == null", but that doesn't do it.  I don't want to delete it, because then I would have to create it multiple times.  Is there a way to just EMPTY a skip list?
Report this to a Moderator Report this to a Moderator
 21-Dec-2006 15:48
User is offline View Users Profile Print this message


Tony Goodman

Posts: 1098
Joined: 12-Sep-2002

Answer Answer
The only way to empty a skip list is to remove each entry individually using delete(skip, index).

I would delete the skip and recreate it every time.

if (!null skip) delete(skip)
skip = create()

-------------------------
Tony Goodman
http://www.smartdxl.com
Report this to a Moderator Report this to a Moderator
 21-Dec-2006 15:56
User is offline View Users Profile Print this message


Pete Kowalski

Posts: 301
Joined: 7-Feb-2003

OR, you can use the brute force method by deleting the skip list and then recreate it.

delete(variant)

--

EDIT MESSAGE: Sorry Tony I didn't see that you recommend delete as well. I don't want to steal your thunder here so credit goes to you.

-------------------------
pete.kowalski(at)motorola.com

Edited: 21-Dec-2006 at 15:58 by Pete Kowalski
Report this to a Moderator Report this to a Moderator
 21-Dec-2006 16:05
User is offline View Users Profile Print this message


Mike Malloy

Posts: 9
Joined: 12-Dec-2006

That's what I was afraid of.  Thanks for the quick response guys!

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