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: special functions
Topic Summary:
Created On: 8-Jan-2003 18:42
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.
 8-Jan-2003 18:42
User is offline View Users Profile Print this message


Mary Miller

Posts: 36
Joined: 12-Sep-2002

Hello,

I am looking at a script that I downloaded from the old DXL Exchange awhile back. I am in the process of understanding the code to make sure that it will be okay to put on the production database.

I ran across some functions that I have never seen before. I can't find them in the DXL 5.2 manual or the notes I received from Telelogic's DXL class. If someone could point me to a reference as to where these function could be found and explain these a little bit, that would be great. I may want to use more of these types of functions later.

I am just not sure when or why these types of functions are used.

Here are the functions. Since I do not know the types that are involved in each of these parameters, I will use the parameters from the program.

deleteList_( dbe, linkAttributeSkip ) // linkAttributeSkip is a global variable. Skip linkAttributeSkp = create

probeAttr_( m, "Name" ) // for a module. linkSrcMod = m

initModuleList_( linkTargetModList, "Formal", "", null )


I appreciate it,

Mary
Report this to a Moderator Report this to a Moderator
 8-Jan-2003 21:48
User is offline View Users Profile Print this message


Michael Sutherland

Posts: 248
Joined: 13-Sep-2002

deleteList_() and initModuleList_() are defined in

#include <example/include/listops.inc>

so if your code is working, you should have the include already defined.

deleteList_() is an overloaded function, with two definitions. deleteList_() can be defined as "By specifying a key in this function, you will delete all items off the list BEFORE the key. By specifying the skiplist to delete you will delete all items within the skip list. "

initModuleList_() populates a list DBE (alphabetically) with modules of a specified type ("Formal", etc.) within a Project (not the entire database).

probeAttr_() is defined in

#include <utils/attrutil.inc>

which is automatically loaded by "init.dxl" or "batchStartup.dxl" on startup of DOORS, so the functions within it appear to be native to the language and "built-in."

The specifics of probeAttr_() are difficult to explain without looking at the code. In summary:

(1) Returns values from DOORS meta-attributes "Object Identifier", "Object Number", and "Object Level", by using the corresponding functions "identifier o", "number o", and "level o".
(2) Handles probing (reading) attribute values from objects in modules that are not in the "current Module."
(3) Returns newline-separated list of all member values if a multi-valued enumerated attribute is probed.
(4) Allows bounding (truncation) of return values.

probeAttr_() is used in many standard DXL functions provided by Telelogic.

-------------------------
Michael Sutherland
michael@galactic-solutions.com
http://galactic-solutions.com
Report this to a Moderator Report this to a Moderator
 8-Jan-2003 22:04
User is offline View Users Profile Print this message


Louie Landale

Posts: 2070
Joined: 12-Sep-2002

probeAttr_(mod, NameAttr) and probeAttr_(obj, NameAttr) both have the desirable feature that they will return the null string (gracefully) when the NameAttr doesn't exist; whereas the native "obj.NameAttr" will abort (ungracefully) if NameAttr doesn't exist. The probeAttr_ functions, unfortunately, DO abort if you use the incorrect type (module/object) attribute; so since "prefix" is a module (only) attribute, probeAttr_(obj, "prefix") will abort.

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