1 /* BEGIN INCLUDE FILE . . . star_structures.incl.pl1 */
  2 
  3 /* This include file contains structures for the hcs_$star_,
  4    hcs_$star_list_ and hcs_$star_dir_list_ entry points.
  5 
  6    Written 23 October 1978 by Monte Davidoff.
  7    Modified January 1979 by Michael R. Jordan to use unsigned and different pointers for different structures.
  8    Modified June 1981 by C. Hornig to count link pathnames more efficiently.
  9 */
 10 
 11 /* automatic */
 12 
 13 declare  star_branch_count fixed binary;                    /* hcs_$star_list_, hcs_$star_dir_list_: matching branch count */
 14 declare  star_entry_count fixed binary;                     /* hcs_$star_: number of matching entries */
 15 declare  star_entry_ptr pointer;                            /* hcs_$star_: pointer to array of entry information */
 16 declare  star_list_branch_ptr pointer;                      /* hcs_$star_list_, hcs_$star_dir_list_: ptr to array of info */
 17 declare  star_link_count fixed binary;                      /* hcs_$star_list_, hcs_$star_dir_list_: matching link count */
 18 declare  star_linkx fixed binary;                           /* hcs_$star_list_, hcs_$star_dir_list_: index into star_links */
 19 declare  star_names_ptr pointer;                            /* hcs_$star_: pointer to array of entry names */
 20 declare  star_list_names_ptr pointer;                       /* hcs_$star_list_, hcs_$star_dir_list_: ptr to entry names */
 21 declare  star_select_sw fixed binary (3);                   /* hcs_$star_list_, hcs_$star_dir_list_: what info to return */
 22 
 23 /* based */
 24 
 25 /* hcs_$star_ entry structure */
 26 
 27 declare 1 star_entries (star_entry_count) aligned based (star_entry_ptr),
 28         2 type fixed binary (2) unsigned unaligned,
 29                                                             /* storage system type */
 30         2 nnames fixed binary (16) unsigned unaligned,
 31                                                             /* number of names of entry that match star_name */
 32         2 nindex fixed binary (18) unsigned unaligned;
 33                                                             /* index of first name in star_names */
 34 
 35 /* hcs_$star_ name structure */
 36 
 37 declare  star_names (sum (star_entries (*).nnames)) char (32) based (star_names_ptr);
 38 
 39 /* hcs_$star_list_ branch structure */
 40 
 41 declare 1 star_list_branch (star_branch_count + star_link_count) aligned based (star_list_branch_ptr),
 42         2 type fixed binary (2) unsigned unaligned,
 43                                                             /* storage system type */
 44         2 nnames fixed binary (16) unsigned unaligned,
 45                                                             /* number of names of entry that match star_name */
 46         2 nindex fixed binary (18) unsigned unaligned,
 47                                                             /* index of first name in star_list_names */
 48         2 dtcm bit (36) unaligned,                          /* date-time contents of branch were last modified */
 49         2 dtu bit (36) unaligned,                           /* date-time branch was last used */
 50         2 mode bit (5) unaligned,                           /* user's access mode to the branch */
 51         2 raw_mode bit (5) unaligned,                       /* user's ACL access mode */
 52         2 master_dir bit (1) unaligned,                     /* is branch a master directory */
 53         2 pad bit (7) unaligned,
 54         2 records fixed binary (18) unsigned unaligned;
 55                                                             /* records used by branch */
 56 
 57 /* hcs_$star_dir_list_ branch structure */
 58 
 59 declare 1 star_dir_list_branch (star_branch_count + star_link_count) aligned based (star_list_branch_ptr),
 60         2 type fixed binary (2) unsigned unaligned,
 61                                                             /* storage system type */
 62         2 nnames fixed binary (16) unsigned unaligned,
 63                                                             /* number of names of entry that match star_name */
 64         2 nindex fixed binary (18) unsigned unaligned,
 65                                                             /* index of first name in star_list_names */
 66         2 dtem bit (36) unaligned,                          /* date-time directory entry of branch was last modified */
 67         2 pad bit (36) unaligned,
 68         2 mode bit (5) unaligned,                           /* user's access mode to the branch */
 69         2 raw_mode bit (5) unaligned,                       /* user's ACL access mode */
 70         2 master_dir bit (1) unaligned,                     /* is branch a master directory */
 71         2 bit_count fixed binary (24) unaligned;
 72                                                             /* bit count of the branch */
 73 
 74 /* hcs_$star_list_ and hcs_$star_dir_list_ link structure */
 75 
 76 declare 1 star_links (star_branch_count + star_link_count) aligned based (star_list_branch_ptr),
 77         2 type fixed binary (2) unsigned unaligned,
 78                                                             /* storage system type */
 79         2 nnames fixed binary (16) unsigned unaligned,
 80                                                             /* number of names of entry that match star_name */
 81         2 nindex fixed binary (18) unsigned unaligned,
 82                                                             /* index of first name in star_list_names */
 83         2 dtem bit (36) unaligned,                          /* date-time link was last modified */
 84         2 dtd bit (36) unaligned,                           /* date-time the link was last dumped */
 85         2 pathname_len fixed binary (18) unsigned unaligned,
 86                                                             /* length of the pathname of the link */
 87         2 pathname_index fixed binary (18) unsigned unaligned;
 88                                                             /* index of start of pathname in star_list_names */
 89 
 90 /* hcs_$star_list_ and hcs_$star_dir_list_ name array */
 91 
 92 declare  star_list_names char (32) based (star_list_names_ptr)
 93           dimension (star_links (star_branch_count + star_link_count).nindex
 94            + star_links (star_branch_count + star_link_count).nnames
 95            + divide (star_links (star_branch_count + star_link_count).pathname_len + 31, 32, 17, 0)
 96              * binary (
 97                (star_links (star_branch_count + star_link_count).type = star_LINK)
 98                & (star_select_sw >= star_LINKS_ONLY_WITH_LINK_PATHS), 1));
 99 
100 /* hcs_$star_list_ and hcs_$star_dir_list_ link pathname */
101 
102 declare  star_link_pathname char (star_links (star_linkx).pathname_len)
103          based (addr (star_list_names (star_links (star_linkx).pathname_index)));
104 
105 /* internal static */
106 
107 /* star_select_sw values */
108 
109 declare  star_LINKS_ONLY fixed binary (2) internal static options (constant) initial (1);
110 declare  star_BRANCHES_ONLY fixed binary (2) internal static options (constant) initial (2);
111 declare  star_ALL_ENTRIES fixed binary (2) internal static options (constant) initial (3);
112 declare  star_LINKS_ONLY_WITH_LINK_PATHS
113          fixed binary (3) internal static options (constant) initial (5);
114 declare  star_ALL_ENTRIES_WITH_LINK_PATHS
115          fixed binary (3) internal static options (constant) initial (7);
116 
117 /* storage system types */
118 
119 declare  star_LINK fixed binary (2) unsigned internal static options (constant) initial (0);
120 declare  star_SEGMENT fixed binary (2) unsigned internal static options (constant) initial (1);
121 declare  star_DIRECTORY fixed binary (2) unsigned internal static options (constant) initial (2);
122 
123 /* END INCLUDE FILE . . . star_structures.incl.pl1 */