/* BEGIN INCLUDE FILE mdbm_db_model.incl.pl1 -- jaw, 10/2/78 */ /****^ HISTORY COMMENTS: 1) change(79-02-01,Gray), approve(), audit(), install(): modified to save space occupied by model 2) change(80-11-03,Gray), approve(), audit(), install(): to add mdbm_secured bit in db_model 3) change(82-04-09,Davids), approve(), audit(), install(): collapsed the following into an unused_offset array: chng_before_path_ptr chng_err_path_ptr chng_after_path_ptr copy_before_path_ptr copy_err_path_ptr copy_after_path_ptr dsply_before_path_pt dsply_err_path_pt dsply_after_path_ptr accs_before_path_ptr accs_err_path_ptr accs_after_path_ptr unused_1 Also changed the name of unused_2 to restructuring_history_offset and changed the comment on the changer structure to indicate that it will contain on database creation information. 4) change(82-04-14,Davids), approve(), audit(), install(): used one of the unused_offsets to point to a message which indicates why the db is inconsistent. The offset will be null when the db is created and set the first time the message is used. this is so it will be consistent with existing data bases. Also added the message structure. 5) change(82-04-28,Davids), approve(), audit(), install(): added the undo_request element to the message structure 6) change(82-05-04,Davids), approve(), audit(), install(): changed unused_offset (12) to last_restructruring_history_offset and changed restructuring_history_offset to first_restructuring_history_offset 7) change(82-08-19,Davids), approve(), audit(), install(): changed the meaning of db_type from 1 => relational and 2 => CODASYL to 1 => vfile database and 2 => page_file database. Up to this point all database types were equal to 1. 8) change(83-02-14,Davids), approve(), audit(), install(): changed db_type from a fixed bin unal to a substructure of 18 bit (1) unal flags. This will allow information about transactions and dm_file concurrency to be independent of the db_type, i.e. vfile or dm_file. The change is compatable with all datamodels created by the released version of mrds. 9) change(83-02-15,Davids), approve(), audit(), install(): added the rollback_on flag to the db_type_flags since it appears that you can have a dmfile database that requires transactions but does not have any journalizing. Also switched the order of the transactions_needed and concurrency_on flags - this makes the change compatable with existing dmfile databases except when displaying the model since concurrency_on and rollback_on will be off in the model even though the dmfile relations had them on during creation. 10) change(83-02-22,Kubicar), approve(), audit(), install(): Removed ctl_file_path_ptr. 11) change(85-11-08,Spitzer), approve(85-12-03,MCR7311), audit(86-09-02,Blair), install(86-10-16,MR12.0-1187): used 1 unused offset for unreferenced attribute linked lists in db_model, 1 unused bit flag in domain_info to indicate an unreferenced domain, 1 bit in the flag word for rmdb copying. END HISTORY COMMENTS */ /* this include file contains the structures that go into the make up of the "db_model" segment in the model for the database. in addition there file_model.m segments, 1 for each database file(see mdbm_file_model.incl.pl1) the db_model structure goes at the base of the segment, and contains items unique to the whole databse. in addition, it has an area of size to fill the rest of a segment, that holds the lists of files and domains in the database. these lists are singly forward linked lists. all "pointers" in the database model are maintained as offsets(bit (18)) from the base of the particular model segment since actual pointers are process dependent on segment number. the remaining structures are first a path_entry one to save pathnames in, and the stack_item and constent structures, used to save a boolean expression in polish form, with the stack represented by a linked list. the final structure is one for identifying the status of version information */ dcl 1 db_model aligned based (dbm_ptr),/* base of db_model segment, allocated once per database */ 2 version unal fixed bin, /* data base version, currently 4 */ 2 db_type_flags unal, 3 copy_good bit (1) unal, /* "1"b => copy of the db_model is the valid copy */ 3 unused (13) bit (1) unal, 3 rollback_on bit (1) unal, /* "1"b => before journaling is to be done */ 3 concurrency_on bit (1) unal, /* "1"b => dm_file concurrency is being used */ 3 transactions_needed bit (1) unal, /* "1"b => transactions are needed to reference data */ 3 vfile_type bit (1) unal, /* "1"b => vfile type relations, "0"b => dm_file type relations */ 2 uniq_sw_name char (32), /* per database unique attach switch name for files */ 2 consistant bit (1) unal, /* ON => correctly created/restructured database, ok to open */ 2 mdbm_secured bit (1) unal, /* on => database has been secured */ 2 reserved bit (34) unal, /* reserved for flags */ 2 blk_file_id_len unal fixed bin, /* no. bits required for blocked file id. */ 2 unblk_file_id_len unal fixed bin, /* number of file id bits, unblocked file */ 2 num_blk_files unal fixed bin, /* number of blocked files defined in db */ 2 num_unblk_files unal fixed bin, /* number of unblocked files defined in db */ 2 num_rels unal fixed bin, /* number of relations defined in db. */ 2 num_domains unal fixed bin, /* number of domains defined */ 2 num_dyn_links unal fixed bin, /* no. dynamic links defined */ 2 max_max_tuples unal fixed bin (35), /* maximum max_tuples across all files */ 2 pad_1 unal fixed bin (35), /* for future use */ 2 pad_2 unal fixed bin (35), /* for future use */ 2 version_ptr bit (18), /* offset to version structure */ 2 file_ptr unal bit (18), /* offset to first in threaded list of file_infos */ 2 domain_ptr unal bit (18), /* offset to first in list of domain_infos */ 2 unreferenced_attribute_ptr unal bit (18), /* offset to first in list of unreferenced attr_infos */ 2 unused_offsets (11) unal bit (18), /* extra offsets if needed */ 2 last_restructuring_history_offset unal bit (18), /* offset to last restructuring history entry */ 2 inconsistent_message_offset unal bit (18), /* offset to message indicating why db is inconsistent */ 2 first_restructuring_history_offset unal bit (18), /* offset to first restructuring history entry */ 2 changer_ptr unal bit (18), /* offset to information about db creation */ 2 dbm_area area (sys_info$max_seg_size - fixed (rel (addr (db_model.dbm_area))) - 1); dcl dbm_ptr ptr; /* the files in the database each have a file_info containing their name, the file_model for each file is found by initiating the segment "file_name.m" (i.e. the file's name with suffix ".m") the file_info list is a singly linked list in definition order */ dcl 1 file_info aligned based (fi_ptr), /* list of file names and numbers */ 2 file_name char (30), /* name of file */ 2 file_id bit (36), /* id number of file */ 2 fwd_ptr unal bit (18), /* thread to next in list */ 2 unused unal bit (18); /* for future expansion */ dcl fi_ptr ptr; /* each domain used in the database will have a domain info saved in the db_model segment. it describes the domain of the given name, and it's options. the domain_info's form a singly linked list in definition order */ dcl 1 domain_info aligned based (di_ptr), /* one for each domain defined */ 2 name char (32), /* name of domain */ 2 db_desc_is_ptr bit (1) unal, /* on if descriptor is pointer to real desc. */ 2 user_desc_is_ptr bit (1) unal, /* on if user desc is ptr */ 2 no_conversion bit (1) unal, /* if no conversion allowed */ 2 procedures_present bit (1) unal, /* on => ids type procedures present */ 2 unreferenced bit (1) unal, /* on => this domain is not used in any attribute */ 2 reserved bit (31) unal, 2 db_desc bit (36), /* desc. for item in db, or ptr to it */ 2 user_desc bit (36), /* desc. for user-visible attr, or ptr */ 2 ave_len fixed bin (35), /* average length of varying string */ 2 nck_items unal fixed bin, /* no. items in check stack */ 2 fwd_thread unal bit (18), /* offset to next in list */ 2 check_path_ptr unal bit (18), /* integ. check proc. */ 2 ck_stack_ptr unal bit (18), /* to check stack */ 2 encd_path_ptr unal bit (18), /* encode procedure */ 2 decd_path_ptr unal bit (18), /* decode procedure */ 2 str_before_path_ptr unal bit (18), /* proc paths and entries */ 2 str_err_path_ptr unal bit (18), 2 str_after_path_ptr unal bit (18), 2 get_before_path_ptr unal bit (18), 2 get_err_path_ptr unal bit (18), 2 get_after_path_ptr unal bit (18), 2 mod_before_path_ptr unal bit (18), 2 mod_err_path_ptr unal bit (18), 2 mod_after_path_ptr unal bit (18), 2 unused_1 unal bit (18), /* for future expansion */ 2 unused_2 unal bit (18), 2 changer_ptr unal bit (18); /* pointer to change_id and chane_time structure */ dcl di_ptr ptr; /* information necessary for attributes that are not used in any relation */ dcl 1 unreferenced_attribute aligned based (ua_ptr), 2 name char (32), /* name of attribute */ 2 domain_ptr bit (18) unal, /* to domain_info */ 2 fwd_thread bit (18) unal, /* to next in list */ 2 unused (2) bit (18) unal; dcl ua_ptr ptr; /* space saving pathname$entryname structure, to be allocated only when a path$entry has to be saved, else only a bit(18) offset takes up space in the main model structure */ declare 1 path_entry based (path_entry_ptr), 2 path char (168), /* pathname portion of desired path$entry */ 2 entry char (32), /* entryname portion of desired path$entry */ 2 reserved unal bit (36); /* for future use */ declare path_entry_ptr ptr; /* declarations for model of postfix stack holding the check option boolean expression the following encoding values indicate the corresponding type of stack element 1 = 2 ^= 3 > 4 < 5 >= 6 <= 10 and 20 or 30 not 40 - (minus) 50 domain variable(same name as domain) 60 constant(number, bit string, or character string) */ declare 1 stack_item based (stack_item_ptr), /* element of stack model list */ 2 next bit (18), /* link to next in list */ 2 type fixed binary, /* code for this element type */ 2 value_ptr bit (18); /* pointer to variable holding value, if this is a constant element type */ declare stack_item_ptr ptr; /* pointer to a stack element */ declare 1 constant based (constant_ptr), /* variable size space for constant's value storage */ 2 length fixed bin (35), /* length allocated to hold value */ 2 value bit (alloc_length refer (constant.length)) aligned; /* value for this constant */ declare constant_ptr ptr; /* pointer to constant's value space */ declare alloc_length fixed binary (35) internal static; /* amount of space to allocate for constant's value */ /* version structure, giving status of source for CMDB/RMDB, status of model, and status of resultant */ /* version number is in form MM.N.Y where MM is the major version number, N is the minor version alteration, and Y is the lastest modification to that alteration, where M and N represent numbers 0-9, and Y is a letter */ declare 1 version_status unal based (version_status_ptr), 2 cmdb_rmdb, 3 major fixed bin, 3 minor fixed bin, 3 modification char (4), 2 model, 3 major fixed bin, 3 minor fixed bin, 3 modification char (4), 2 resultant, 3 major fixed bin, 3 minor fixed bin, 3 modification char (4); declare version_status_ptr ptr; /* maintains information only about the db creation */ declare 1 changer unal based (changer_ptr), 2 id char (32), 2 time fixed bin (71), 2 next bit (18); /* to next in the singly linked list */ declare changer_ptr ptr; dcl 01 message_str unal based (message_str_ptr), /* general purpose structure to hold messages */ 02 len fixed bin, /* length of the message */ 02 text char (message_str_len refer (message_str.len)), /* actual message */ 02 name char (32), /* name of thing that set the message */ 02 undo_request char (100), /* rmdb request that will undo the operation that caused the database to become inconsistent */ 02 mbz bit (36); /* for possible extensions, like an offset to another message */ dcl message_str_ptr ptr; /* pointer to the message_str structure */ dcl message_str_len fixed bin; /* initail length of the text string in message_str */ /* END INCLUDE FILE mdbm_db_model.incl.pl1 */ */ ----------------------------------------------------------- Historical Background This edition of the Multics software materials and documentation is provided and donated to Massachusetts Institute of Technology by Group Bull including Bull HN Information Systems Inc. as a contribution to computer science knowledge. This donation is made also to give evidence of the common contributions of Massachusetts Institute of Technology, Bell Laboratories, General Electric, Honeywell Information Systems Inc., Honeywell Bull Inc., Groupe Bull and Bull HN Information Systems Inc. to the development of this operating system. Multics development was initiated by Massachusetts Institute of Technology Project MAC (1963-1970), renamed the MIT Laboratory for Computer Science and Artificial Intelligence in the mid 1970s, under the leadership of Professor Fernando Jose Corbato. Users consider that Multics provided the best software architecture for managing computer hardware properly and for executing programs. Many subsequent operating systems incorporated Multics principles. Multics was distributed in 1975 to 2000 by Group Bull in Europe , and in the U.S. by Bull HN Information Systems Inc., as successor in interest by change in name only to Honeywell Bull Inc. and Honeywell Information Systems Inc. . ----------------------------------------------------------- Permission to use, copy, modify, and distribute these programs and their documentation for any purpose and without fee is hereby granted,provided that the below copyright notice and historical background appear in all copies and that both the copyright notice and historical background and this permission notice appear in supporting documentation, and that the names of MIT, HIS, Bull or Bull HN not be used in advertising or publicity pertaining to distribution of the programs without specific prior written permission. Copyright 1972 by Massachusetts Institute of Technology and Honeywell Information Systems Inc. Copyright 2006 by Bull HN Information Systems Inc. Copyright 2006 by Bull SAS All Rights Reserved */