SA_API int SA_ask_current_groupmember | ( | tag_t * | current_groupmember_tag | ) |
Returns the current groupmember tag of the logged in user. This is the groupmember that relates the user to his/her current group via his/her current role.
Restrictions:
You can only access these functions when logged in as a system or group administrator.
current_groupmember_tag | (O) |
This function returns the default role in a group for a specified user. If the default role is not defined, a null tag will be returned.
user_tag | (I) Tag of the user to find a role for |
group_tag | (I) Group to find the role in |
role_tag | (O) Default role tag |
Returns the group tag attribute for this group member.
member_tag | (I) |
group_tag | (O) |
Returns the group administration attribute for this group member. The group_admin_flag attribute indicates if the group member is to be the group administrator (true for group administrator, false if not).
member_tag | (I) |
group_admin_flag | (O) |
Returns a variable which indicates whether the status of the groupmember is inactive or active.
Restrictions:
You can only access this function when logged in as a system or group administrator.
groupmember_tag | (I) |
is_deactivated | (O) |
Returns the role tag attribute for this group member.
member_tag | (I) |
role_tag | (O) |
Returns the user tag attribute for this group member.
member_tag | (I) |
user_tag | (O) |
SA_API int SA_create_groupmember | ( | tag_t | group_tag, | |
tag_t | user_tag, | |||
logical | group_admin_flag, | |||
tag_t * | member_tag | |||
) |
Creates a GroupMember object. It is not saved to the database until an explicit call to AOM_save is made. You must specify a member_tag, group_tag, user_tag, and the group administration attributes.
The group_admin_flag attribute indicates if the group member is to be the group administrator (true for group administrator, false if not). Setting the group administrator attribute to true without having system administration privileges results in an error.
Restrictions:
You can only access this function when logged in as a system or group administrator.
group_tag | (I) |
user_tag | (I) |
group_admin_flag | (I) |
member_tag | (O) |
SA_API int SA_extent_active_groupmember | ( | int * | num_of_activegroupmembers, | |
tag_t ** | member_tags | |||
) |
Allocates an array of tags and stores in the array all active groupmembers in the database. The client is responsible for deallocating the array of member_tags. Use MEM_free to free the memory pointed to by member_tags.
num_of_activegroupmembers | (O) Stores the size of the array |
member_tags | (OF) num_of_activegroupmembers Points to the array of tags |
SA_API int SA_extent_groupmember | ( | int * | num_of_groupmembers, | |
tag_t ** | member_tags | |||
) |
Allocates an array of tags and stores in the array all groupmembers in the database. The client is responsible for deallocating the array of member_tags. Use MEM_free to free the memory pointed to by member_tags.
num_of_groupmembers | (O) Stores the size of the array |
member_tags | (OF) num_of_groupmembers Points to the array of tags |
SA_API int SA_find_all_groupmember_by_user | ( | tag_t | user_tag, | |
logical | includeInactive, | |||
int * | num_of_members, | |||
tag_t ** | member_tags | |||
) |
Allocates an array of tags and stores in the array all group members,who reference the specified user. Group members are filtered on the basis of includeInactive flag.It consider all( active and inactive) group members if includeInactive flag is true, otherwise consider only active group members. The client is responsible for deallocating the array of member_tags.Use MEM_free to free the memory pointed to by member_tags.
user_tag | (I) User tag references the group members |
includeInactive | (I) A boolean flag which filters the active, inactive group members |
num_of_members | (O) Stores the size of the array |
member_tags | (OF) num_of_members Points to the array of tags |
SA_API int SA_find_groupmember_by_role | ( | tag_t | role_tag, | |
tag_t | group_tag, | |||
int * | num_of_members, | |||
tag_t ** | member_tags | |||
) |
Allocates an array of tags and stores in the array all group members of a given group and role tag. member_tags points to the array of tags. num_of_members stores the size of the array. The client is responsible for deallocating the array of member_tags. Use MEM_free to free the memory pointed to by member_tags.
role_tag | (I) |
group_tag | (I) |
num_of_members | (O) |
member_tags | (OF) num_of_members |
SA_API int SA_find_groupmember_by_rolename | ( | const char * | role_name, | |
const char * | group_name, | |||
const char * | user_id, | |||
int * | number_found, | |||
tag_t ** | list | |||
) |
Locates group member objects. The caller may find the group members by role, group, user, or any combination of the input parameters as shown in the synopsis. As a result, this function passes the number of members found and an array of member tags. It is the caller's responsibility to free the returned tags.
The following are some examples of how this function may be used:
role_name | (I) NULL allowed |
group_name | (I) NULL allowed |
user_id | (I) NULL allowed |
number_found | (O) |
list | (OF) number_found |
SA_API int SA_find_groupmember_by_user | ( | tag_t | user_tag, | |
int * | num_of_members, | |||
tag_t ** | member_tags | |||
) |
Allocates an array of tags and stores in the array all group members who reference the specified user. The client is responsible for deallocating the array of member_tags. Use MEM_free to free the memory pointed to by member_tags.
user_tag | (I) |
num_of_members | (O) Stores the size of the array |
member_tags | (OF) num_of_members Points to the array of tags |
SA_API int SA_find_groupmembers | ( | tag_t | user_tag, | |
tag_t | group_tag, | |||
int * | n_members, | |||
tag_t ** | member_tags | |||
) |
Finds all groupmembers with the specified group and user tags. If an error occurs, then a non-zero integer returns. If no GroupMember exists with the specified group and user tags, then a zero returns and a NULLTAG is given for the groupmember tag.
user_tag | (I) |
group_tag | (I) |
n_members | (O) |
member_tags | (OF) n_members |
SA_API int SA_find_groupmembers_by_accessor | ( | tag_t | accessor, | |
int * | num_of_members, | |||
tag_t ** | member_tags | |||
) |
Allocates an array of tags and stores in the array all groupmembers associated with the particular accessor tag. This accessor may be a user, a group, or a role.
The client is responsible for freeing the array of member_tags. Use MEM_free to free the memory pointed to by member_tags.
accessor | (I) |
num_of_members | (O) Stores the size of the array |
member_tags | (OF) num_of_members Points to the array of tags |
SA_API int SA_find_groupmembers_by_group | ( | tag_t | group_tag, | |
int * | num_of_members, | |||
tag_t ** | member_tags | |||
) |
Allocates an array of tags and stores in the array all group members of the specified group. The client is responsible for deallocating the array of member_tags. Use MEM_free to free the memory pointed to by member_tags.
group_tag | (I) |
num_of_members | (O) Stores the size of the array |
member_tags | (OF) num_of_members Points to the array of tags |
SA_API int SA_initialize_groupmember | ( | tag_t | member_tag, | |
tag_t | group_tag, | |||
tag_t | user_tag, | |||
logical | group_admin_flag | |||
) |
Initializes a GroupMember object. It is not saved to the database until an explicit call to POM_save occurs. You must specify the member_tag, group_tag, user_tag and the group administration attributes. The group_admin_flag attribute indicates if the group member is to be the group administrator (true for group administrator, false if not). Setting the group administrator attribute to true without having system administration privileges results in an error.
You normally use this function with a subclass of GroupMember. For example, if you defined a class special GroupMember, you would first call POM_create_instance to create the object in memory. Then you would use this function to initialize the attributes which were inherited from GroupMember. Finally, you would use additional POM calls to initialize the attributes comprising your specialization of GroupMember.
Restrictions:
You can only access this function when logged in as a system or group administrator.
member_tag | (I) |
group_tag | (I) |
user_tag | (I) |
group_admin_flag | (I) |
groupmember_tag | (I) |
is_default_role | (O) |
This function sets the default role in a group for a specified user.
user_tag | (I) user tag |
group_tag | (I) group tag |
role_tag | (I) default role tag |
Sets the group_tag attribute for the group member.
member_tag | (I) |
group_tag | (I) |
Sets the group_admin_flag attribute for the group member. The group_admin_flag attribute indicates if the group member is to be the group administrator (true for group administrator, false if not). Setting the group_admin_flag attribute to true without having system administration privileges returns an integer error code.
member_tag | (I) |
group_admin_flag | (I) |
Sets the status of the input groupmember to active or inactive.
Restrictions:
You can only access this function when logged in as a system or group administrator.
groupmember_tag | (I) |
deactivate | (I) |
Sets the role_tag attribute for the group member.
Restrictions:
You can only access these functions when logged in as a system or group administrator.
member_tag | (I) |
role_tag | (I) |
Sets the user_tag attribute for the group member.
member_tag | (I) |
user_tag | (I) |