[Package Index | Mudlib Index | Effect Index]

File /d/learning/master.c

Learning Domain Master Object

Written by Who Knows

Started A Long Time Ago

Inherits

This class inherits the following classes /std/dom/base_master.c

Method index

Public Functions

These are functions that everyone can access.

add_member
int add_member(string name)
author_file
string author_file(string * path)
check_permission
int check_permission(string euid,
                     string * path,
                     int mask)
copy_with_read
int copy_with_read(string path,
                   string euid,
                   string func)
has_access_to_channel
int has_access_to_channel(object ob)
log_who
string log_who(string where)
query_info
string query_info()

The query_info function is used to return the descriptive text of the domain. It first checks to see if the INFO file exists. If it does, we read that in and return it. This allows us to modify the domain finger info without worrying about screwing up the master object with, for example, a forgotten quotation mark. If the file doesn't exist, then we tell everyone who fingers the domain to bug the active lord. Bwah-ha-ha. :-P
query_lord
string query_lord()
query_member
int query_member(string name)
query_members
string * query_members()
remove_member
int remove_member(string name)
reset_description
void reset_description()
set_info
void set_info(string words)
set_project
int set_project(string name,
                string pro)

This function sets the project of a domain member. It first checks to see if the person making the call to the function is the lord of the domain. If they are not, it will return 0 indicating failure. The method will make a call to the set_project of /std/dom/base_master.c if this initial check is passed.

Parameters:
name - The name of the person for which we want to change the project.
pro - The project the person is to have in the domain.

Returns:
1 if the project is successfully changed, 0 if it is not.

See also:
/std/dom/base_master.c

Example:
 ret = set_project ("drakkos", "Being Awesome"); 

setup_members
string * setup_members()

This function deals with setting up the member list for the domain in a nice, neat manner. At the top of the list, is the domain Lord, followed by the domain deputies. We then lump creators together by projects, and then go through the project list in alphabetical order, adding the sorted list of creators to the domain members list. Once we've done that, we add all the unassigned creators to the end of the list (those with 'newbie' for their domain project).