subroutine class_write_init(error) !--------------------------------------------------------------------- ! @ public ! Public procedure suited for programs linked basically to the ! libclass, i.e. with no Gildas specific features like interpreter or ! initializations or so. See demo program classdemo-telwrite.f90 ! Perform the basic initializations of the libclass needed for ! the writing process (e.g. stand-alone program at the telescope). ! Should be done once at program startup. !--------------------------------------------------------------------- logical, intent(inout) :: error ! Logical error flag end subroutine class_write_init subroutine class_write_clean(error) !--------------------------------------------------------------------- ! @ public ! Public procedure suited for programs linked basically to the ! libclass, i.e. with no Gildas specific features like interpreter or ! initializations or so. See demo program classdemo-telwrite.f90 ! Perform the basic cleaning of the libclass needed after the ! writing process (e.g. stand-alone program at the telescope). ! Should be done once before leaving the program !--------------------------------------------------------------------- logical, intent(inout) :: error ! Logical error flag end subroutine class_write_clean subroutine class_fileout_open(spec,lnew,lover,lsize,lsingle,error) use classic_api !--------------------------------------------------------------------- ! @ public ! Public entry point to open a new or reopen an old output file. !--------------------------------------------------------------------- character(len=*), intent(in) :: spec ! File name including extension logical, intent(in) :: lnew ! Should it be a new file or an old? logical, intent(in) :: lover ! If new, overwrite existing file or raise an error? integer(kind=entry_length), intent(in) :: lsize ! If new, maximum number of observations allowed logical, intent(in) :: lsingle ! If new, should spectra be unique? logical, intent(inout) :: error ! Logical error flag end subroutine class_fileout_open subroutine class_fileout_close(error) !--------------------------------------------------------------------- ! @ public ! CLASS External routine (available to other programs) ! Close the output file. !--------------------------------------------------------------------- logical, intent(inout) :: error ! Error status end subroutine class_fileout_close subroutine class_obs_init(obs,error) use class_types !--------------------------------------------------------------------- ! @ public ! Initialize the input observation for later use ! See demo program classdemo-telwrite.f90 !--------------------------------------------------------------------- type(observation), intent(inout) :: obs ! logical, intent(inout) :: error ! end subroutine class_obs_init subroutine class_obs_reset(obs,ndata,error) use class_types !--------------------------------------------------------------------- ! @ public ! Zero-ify and resize the input observation for later use ! See demo program classdemo-telwrite.f90 !--------------------------------------------------------------------- type(observation), intent(inout) :: obs ! integer(kind=4), intent(in) :: ndata ! Number of values the observation can accept in return logical, intent(inout) :: error ! Logical error flag end subroutine class_obs_reset subroutine class_obs_write(obs,error) use class_types !--------------------------------------------------------------------- ! @ public ! Write the observation to the currently opened output file ! See demo program classdemo-telwrite.f90 !--------------------------------------------------------------------- type(observation), intent(inout) :: obs ! logical, intent(inout) :: error ! Logical error flag end subroutine class_obs_write subroutine class_obs_clean(obs,error) use class_types !--------------------------------------------------------------------- ! @ public ! Clean/free the input observation before deleting it ! See demo program classdemo-telwrite.f90 !--------------------------------------------------------------------- type(observation), intent(inout) :: obs ! logical, intent(inout) :: error ! end subroutine class_obs_clean