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 to Find Groups in object/attribute Access Records
Topic Summary:
Created On: 13-Sep-2005 22:08
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.
 13-Sep-2005 22:08
User is offline View Users Profile Print this message


Janet Ma

Posts: 115
Joined: 12-Sep-2002

I have no problem writing a script to output individual users in an object/attribute access record, but
I cannot find a way to print out the group names in the access record.

According to the DXL manual, this the sample code they give in the DOORS 7.1:

for ar in values ad do
{
string sUser = (username ar) ""
print sUser "\n"
}

How does one do this for groups?
Report this to a Moderator Report this to a Moderator
 14-Sep-2005 09:20
User is offline View Users Profile Print this message


Tony Goodman

Posts: 1098
Joined: 12-Sep-2002

The username property contains user AND group names, so your code will return group names as well as user names.

You can then use existsUser() and existsGroup() to determine whether you have the name of a user or a group.

-------------------------
Tony Goodman
http://www.smartdxl.com
Report this to a Moderator Report this to a Moderator
 23-Feb-2007 11:39
User is offline View Users Profile Print this message


Lucian Bodron

Posts: 24
Joined: 12-Oct-2005

I have the same situation too, but I cannot make DXL to print the name of users/groups which have the access.

To be more specific, I want to restrict the rights for some user groups to a specified attribute. In order to do that I will find it more consistent if I would be able to get (into a skipList maybe) the name of the groups which have the rights, and then restrict the rights only for the specified groups (to all groups except the ADMINS to be more specific).

Can this be done?
Report this to a Moderator Report this to a Moderator
 23-Feb-2007 12:17
User is offline View Users Profile Print this message


Lucian Bodron

Posts: 24
Joined: 12-Oct-2005

quote:

Originally posted by: Lucian Bodron
I have the same situation too, but I cannot make DXL to print the name of users/groups which have the access.



To be more specific, I want to restrict the rights for some user groups to a specified attribute. In order to do that I will find it more consistent if I would be able to get (into a skipList maybe) the name of the groups which have the rights, and then restrict the rights only for the specified groups (to all groups except the ADMINS to be more specific).



Can this be done?


I have found the solution in DXL help:

void restrictPrefix(Module m)
{

AttrDef pref = find(current Module, "Prefix")

User user
for user in userList do
{
string uName = user.name

string er_user = setDef(current Module, pref, read, uName)
string err_user = setVal(current Module, pref, read, uName)
}
Group group
for group in groupList do
{
string gName = group.name

if(gName != "ADMIN")
{
string er_group = setDef(current Module, pref, read, gName)
string err_group = setVal(current Module, pref, read, gName)
}
}

return
}
Report this to a Moderator Report this to a Moderator
 23-Feb-2007 12:36
User is offline View Users Profile Print this message


Lucian Bodron

Posts: 24
Joined: 12-Oct-2005



this is too much for me...I only what to restrict the rights for the users and groups in the current project, not for the entire database users and groups.

How can I get the groupList from the current project?
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.