
  TYPE

{  The connection_level field of the active connected_files tree is
{  incremented on every create_file_connection and delete_file_connection.
{  On a PUSH this value is copied to the new tree and on a POP the
{  value of the previous tree is saved and used to update the 'new' tree.
{  Thus this value always increases and represents the total number
{  of connection events that have occurred.  It is used to update the
{  subject's connection_level when a subject participates in a
{  connection event (create or delete).  This value is often referred to
{  as the 'global' connection_level.

    clt$connected_files = record
      subject_tree: ^clt$connected_file_subject,
      echo_count: integer,
      connection_level: clt$file_connection_level,
    recend;

  TYPE

{  The connection_level field represents the value of the global
{  connection_level at the time this subject last had a file connection
{  created or deleted.  When the subject file is opened, this value
{  is copied to the connection_level field in the subject's TFT entry.

    clt$connected_file_subject = record
      path_handle_name: fst$path_handle_name,
      left_link: ^clt$connected_file_subject,
      right_link: ^clt$connected_file_subject,
      connection_level: clt$file_connection_level,
      targets: ^clt$connected_file_targets,
    recend;

  TYPE
    clt$file_connection_level = integer;

  CONST
    clc$min_connected_file_targets = 3;

  CONST
    clc$max_connected_file_targets = 7fffffff(16);

  TYPE
    clt$connected_file_target_index = 1 .. clc$max_connected_file_targets;

  TYPE
    clt$connected_file_targets = array [1 .. * ] of clt$connected_file_target;

  TYPE

{  Connection_level is copied from the target's subject connection_level
{  when the connection to the target is either created or deleted.
{  When the target is opened, this value is copied to the target_connection_level
{  field in the target's TFT entry.

    clt$connected_file_target = record
      connection_active: boolean,
      path_handle_name: fst$path_handle_name,
      open_position: fst$open_position,
      connection_level: clt$file_connection_level,
      connection_ring: ost$valid_ring,
    recend;

*copyc cld$path_description
*copyc fst$open_position
*copyc fst$path_handle_name
*copyc osd$virtual_address
