]> code.citadel.org Git - citadel.git/blobdiff - citadel/techdoc/citadelapi.txt
* Updated some of the docs. Bumped version number to 5.80 in anticipation
[citadel.git] / citadel / techdoc / citadelapi.txt
index db57448144ccfa697e796d6e0a3f786798a9f6ca..259299d4009abd25b4b7c35526539ea977183b02 100644 (file)
@@ -4,7 +4,11 @@
   This is a VERY INCOMPLETE documentation of the API for extending the
 Citadel server using dynamically loaded modules.  It really isn't an API at
 all, but rather a list of some of the functions available in the server which
-are likely to be of use to module writers.  
+are likely to be of use to module writers.
+  The current trend is to move as much stuff as possible out of the server
+proper and into loadable modules.  This makes the code much easier to read and
+understand.
   
   Expect this document to become more complete over time, as both the API and
 the person documenting it have a chance to mature a bit.  :)
@@ -178,16 +182,28 @@ contain:
 unsigned create_room(char *new_room_name,
                      int new_room_type,
                      char *new_room_pass,
-                     int new_room_floor)
-
- This function is used to create a new room.  new_room_name should be set to
-the desired name for the new room.  new_room_type should be set to 0 for a
-public room, 1 for a guessname room, 2 for a passworded room, 3 for an
-invitation-only room, or 4 for a personal room (a mailbox).  If the room is
-a type 2 (passworded) room, new_room_pass should be set to the desired
-password.  new_room_floor should be set to the number of the floor upon which
-the new room should reside.
+                     int new_room_floor,
+                    int really_create)
  
+ This function is used to create a new room.  new_room_name should be set to
+the desired name for the new room.
+  
+ new_room_type should be set to one of the following values:
+       0 = public room
+       1 = guess-name room
+       2 = passworded room
+       3 = invitation-only room
+       4 = personal (mailbox) room
+       5 = personal (mailbox) room, and new_room_name already contains
+           the namespace prefix (use with caution!)
+ new_room_pass should be set to the desired password for the room (obviously
+this is only valid for passworded rooms).
+ If the room is really to be created, set really_create to 1.  Otherwise, the
+caller may merely check to see if it's possible to create the room without
+actually creating it by setting really_create to 0.
+  
  create_room() returns the flags associated with the new room (as in the
 data structure item quickroom.QRflags).  If the room cannot be created (for
 example, a room with the name already exists), it returns 0.